{"version":3,"sources":["_api/aesgcm.js","_components/spacer.component.jsx","_pages/error.page.jsx","_api/handleerror.js","_api/api.js","_helpers/utility.helper.js","_helpers/localization.helper.js","_forms/useFormInput.js","_forms/useForm.js","_forms/useFormConsent.js","_contexts/urlsearchparams.js","_contexts/data.context.js","_components/fields/text.field.component.jsx","_components/fields/select.field.component.jsx","_components/fields/email.field.component.jsx","_components/fields/info.text.component.jsx","_components/fields/radio.field.component.jsx","_components/fields/date.field.component.jsx","_components/fields/maskeddate.field.component.jsx","_components/fields/maskedphone.field.component.jsx","_components/fields/maskedtext.field.component.jsx","_components/field.list.component.jsx","_components/dialog.component.jsx","_components/consent.component.jsx","_components/consent.list.component.jsx","_components/action.button.component.jsx","_helpers/redirect.helper.js","_components/action.buttons.component.jsx","_pages/form.page.jsx","_pages/page.page.jsx","_pages/splash.page.jsx","_pages/success.page.jsx","app.jsx","index.js"],"names":["crypto","require","AESGCM","K1","Buffer","from","Uint8Array","K2","K3","K4","KEY","concat","encrypt","message","IV","randomBytes","cipher","createCipheriv","encrypted","update","final","str","tag","getAuthTag","hexString","replace","length","console","log","bad","match","integers","map","s","parseInt","array","props","tobuffer","toString","Spacer","vertical","Stack","sx","flexGrow","style","width","height","Error","error","boxSizing","flexDirection","alignItems","justifyContent","backgroundColor","padding","marginBottom","src","alt","Typography","align","variant","gutterBottom","color","handleError","response","code","status","data","Code","Message","date","Date","SERVER_DOMAIN","process","axios","defaults","headers","post","crossDomain","preflightContinue","withCredentials","header","ApiClientKey","ApiClientSecret","Timestamp","getTime","JSON","stringify","path","Promise","resolve","reject","then","Data","catch","getOSType","navigator","userAgent","includes","isAndroid","isIOS","isBrowser","phoneformats","name","iso2","dialcode","mask","reg","validate","value","isrequired","field","Regex","Boolean","RegExp","test","InputType","String","toLowerCase","InputMask","formatted","split","reverse","join","compareDate","moment","startDate","endDate","isBetween","diff","validateRegexPhone","valid","formattedphone","i","phonenumber","checklist","union","countrycode","toUpperCase","Countries","isValidPhoneNumber","parsePhoneNumber","format","isValid","country","find","useForm","useState","values","setValues","errors","setErrors","validating","setValidating","useCallback","isvalid","tmperrors","index","findIndex","splice","push","clearForm","language","prev","FormData","useInput","Name","Required","inputtype","fields","formValue","key","setValue","setIsValid","isTouched","setIsTouched","isFocused","setIsFocused","handleValidation","checkvalid","useEffect","handleChange","event","target","formattedvalue","handleFocus","handleBlur","helpertext","ValidationText","HelperText","onChange","onFocus","onBlur","required","helperText","useFormInput","useConsent","consent","isRequired","checked","useFormConsent","UrlSearchParams","query","getSearchObject","slice","reduce","params","param","decodeURIComponent","getAll","get","setUrl","searchParams","Object","keys","this","DataContext","createContext","DataProvider","offerhash","window","location","pathname","substr","isMobile","useMemo","search","state","submitting","appState","setAppState","formGetResponse","setFormGetResponse","formSendResponse","setFormSendResponse","theme","setTheme","form","setForm","updateTheme","a","createTheme","palette","Config","Theme","components","MuiFormHelperText","styleOverrides","root","primary","main","MuiInputLabel","MuiInputBase","input","MuiInput","borderBottom","MuiTextField","borderColor","MuiButton","textTransform","MuiSvgIcon","zIndex","fetchForm","additionalparams","getresponse","Form","document","body","background","paper","BgImageMobile","backgroundImage","BgImageWeb","Values","SendFormIfValuesOK","Msisdn","sendresponse","Page","ReturnMessage","submitForm","externalUrl","forEach","Provider","children","TextInputField","useContext","multiline","classes","Shrink","PlaceHolder","shrink","TextField","label","Label","placeholder","disabled","Disabled","fullWidth","rows","Variant","InputLabelProps","className","textfield","InputProps","SelectField","select","SelectProps","native","ValueTexts","Value","EmailField","type","InfoText","whiteSpace","textAlign","text","startsWith","getConfirmMessage","RadioField","InputLabel","isDisabled","textOverflow","FormControl","component","RadioGroup","FormControlLabel","radiolabel","control","Radio","marginLeft","labelPlacement","FormHelperText","paddingLeft","DateField","autoComplete","autoCorrect","MaskedDateField","maskChar","inputProps","MaskedPhoneField","alwaysShowMask","MaskedTextField","InputField","Field","rest","FieldType","labelPercentage","colors","display","v","alignContent","FieldList","makeStyles","border","nativeRoot","nativeSelect","lineHeight","positionStart","position","useStyles","orderBy","py","Dialog","dialogText","dialogTitle","fullScreen","title","onClose","open","DialogTitle","DialogContent","DialogContentText","wordWrap","DialogActions","Button","onClick","Consent","setOpen","handleConsentDialog","FormGroup","row","flexWrap","Checkbox","maxwidth","cursor","textDecoration","Text","TermsOfUse","captionText","Caption","ConsentList","Consents","ActionButton","button","linker","Type","Action","Size","handleClick","action","openURL","history","go","LoadingButton","size","loading","defaultProps","DeepLinker","options","hasFocus","didHide","onVisibilityChange","e","visibilityState","onReturn","onFallback","setTimeout","bindEvents","mode","conf","destroy","bind","url","onIgnored","ActionButtons","Buttons","buttons","spacing","direction","buttongroup","groupindex","rowindex","caption","pb","Box","Fields","gap","page","overflow","Splash","CircularProgress","Success","px","App","Container","disableGutters","maxWidth","CssBaseline","ThemeProvider","StylesProvider","Pages","Id","RedirectURL","ReactDOM","render","FallbackComponent","onReset","CookiesProvider","getElementById"],"mappings":"6GAAA,gBAAMA,EAASC,EAAQ,KAiDRC,IAvBA,WACb,IAAMC,EAAKC,EAAOC,KAAK,IAAIC,WAAW,CAAC,GAAI,GAAI,IAAK,GAAI,IAAK,GAAI,GAAI,MAC/DC,EAAKH,EAAOC,KAAK,IAAIC,WAAW,CAAC,GAAI,IAAK,IAAK,IAAK,GAAI,GAAI,GAAI,MAChEE,EAAKJ,EAAOC,KAAK,IAAIC,WAAW,CAAC,GAAI,GAAI,GAAI,IAAK,IAAK,IAAK,GAAI,MAChEG,EAAKL,EAAOC,KAAK,IAAIC,WAAW,CAAC,GAAI,IAAK,IAAK,IAAK,GAAI,GAAI,GAAI,MAChEI,EAAMN,EAAOO,OAAO,CAACR,EAAII,EAAIC,EAAIC,IAavC,MAAO,CACLG,QAZF,SAAiBC,GACf,IAAMC,EAAKd,EAAOe,YAAY,IACxBC,EAAShB,EAAOiB,eAAe,cAAeP,EAAKI,GACrDI,EAAYF,EAAOG,OAAON,EAAS,OAAQ,OAC/CK,GAAaF,EAAOI,MAAM,OAC1B,IAhBuBC,EAgBjBC,EA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AAK,OACJ,OACC,cAAC,GAAD,CACCkN,KAAI,UAAE9M,EAAgBkC,YAAlB,iBAAE,EAAsBtB,cAAxB,aAAE,EAA8B+M,MAAMjT,MAAK,SAACoS,GAAD,OAAUA,EAAKc,OAAwB,OAAhB1N,QAAgB,IAAhBA,OAAA,EAAAA,EAAkB4C,QAAlB,OAA0B9C,QAA1B,IAA0BA,OAA1B,EAA0BA,EAAiB8C,MAAlE,MAGlD,IAAK,UAIJ,OAHI5C,EAAiB2N,aACpB1D,EAAOM,QAAP,OAAevK,QAAf,IAAeA,OAAf,EAAeA,EAAkB2N,aAE3B,cAAC,GAAD,IAER,QACC,MAAO,GAET,CAnBC,SAwBN,EChDDC,IAASC,OACP,cAAC,gBAAD,CAAeC,kBAHK,SAAC,GAAD,IAAGvZ,EAAH,EAAGA,MAAH,OAAgB,cAAC,EAAD,CAAOA,MAAOA,EAAOkH,SAAU,MAA/C,EAG6BsS,QAAS,WAAS,EAAnE,SACE,cAACC,EAAA,EAAD,UACE,cAAC,EAAD,UACE,cAAC,GAAD,UAIJ/L,SAASgM,eAAe,Q","file":"static/js/main.85e97fb4.chunk.js","sourcesContent":["const crypto = require(\"crypto\");\n\nconst tobuffer = function (hexString) {\n hexString = hexString.replace(/^0x/, \"\");\n if (hexString.length % 2 !== 0) {\n console.log(\n \"WARNING: expecting an even number of characters in the hexString\"\n );\n }\n var bad = hexString.match(/[G-Z\\s]/i);\n if (bad) {\n console.log(\"WARNING: found non-hex characters\", bad);\n }\n var pairs = hexString.match(/[\\dA-F]{2}/gi);\n var integers = pairs.map(function (s) {\n return parseInt(s, 16);\n });\n var array = Buffer.from(new Uint8Array(integers));\n var props = Buffer.from(new Uint8Array([16, 16]));\n var response = Buffer.concat([props, array]);\n return response;\n};\nconst tobase64 = function (str) {\n return Buffer.from(str, \"utf8\").toString(\"base64\");\n};\n\nconst AESGCM = () => {\n const K1 = Buffer.from(new Uint8Array([71, 89, 104, 55, 102, 85, 43, 50]));\n const K2 = Buffer.from(new Uint8Array([64, 121, 115, 101, 89, 43, 33, 55]));\n const K3 = Buffer.from(new Uint8Array([33, 66, 53, 120, 115, 113, 95, 33]));\n const K4 = Buffer.from(new Uint8Array([70, 102, 116, 102, 55, 98, 89, 74]));\n const KEY = Buffer.concat([K1, K2, K3, K4]);\n\n function encrypt(message) {\n const IV = crypto.randomBytes(16);\n const cipher = crypto.createCipheriv(\"aes-256-gcm\", KEY, IV);\n let encrypted = cipher.update(message, \"utf8\", \"hex\");\n encrypted += cipher.final(\"hex\");\n const tag = cipher.getAuthTag();\n return tobase64(\n tobuffer(IV.toString(\"hex\") + encrypted + tag.toString(\"hex\"))\n );\n }\n\n return {\n encrypt\n }\n};\n\nexport default AESGCM;\n","import React from 'react'\n\n// Material UI\nimport Stack from '@mui/material/Stack';\n\nconst Spacer = (props) => {\n const { vertical } = props;\n return \n}\n\nexport default Spacer;\n","import React from 'react'\n\n// Material UI\nimport Stack from '@mui/material/Stack'\nimport Typography from '@mui/material/Typography';\n\n// Components\nimport Spacer from '../_components/spacer.component';\n\nconst Error = (props) => {\n const { error } = props;\n\n return (\n \n \n Beklenmeyen bir hata oluştu. Lütfen tekrar deneyin.\n Bir hata oluştu!\n \n {error.message}\n \n );\n}\n\nexport default Error;","const handleError = (error) => {\n const { message, response } = error;\n\n console.log('error ->', error);\n console.log('message ->', message);\n console.log('response ->', response);\n\n if (message === 'Network Error') // We could not connect to api\n return { code: 503, message: 'Service Unavailable', status: 503 };\n\n return { code: response.data.Code, message: response.data.Message, status: response.status };\n}\n\nexport default handleError;","import axios from 'axios';\nimport handleError from './handleerror';\n\nimport AESGCM from './aesgcm';\n\nconst date = new Date();\n\nconst SERVER_DOMAIN = process.env.REACT_APP_API_URL;\nconst CLIENT_KEY = process.env.REACT_APP_API_KEY;\nconst CLIENT_SECRET = process.env.REACT_APP_API_SECRET;\n\naxios.defaults.headers.post['Content-Type'] = 'application/json';\naxios.defaults.headers['Accept'] = 'application/json';\naxios.defaults.crossDomain = true;\naxios.defaults.preflightContinue = true;\naxios.defaults.withCredentials = false;\n\nconst header = {\n ApiClientKey: CLIENT_KEY,\n ApiClientSecret: CLIENT_SECRET,\n Timestamp: parseInt(date.getTime() / 1000) - 300\n}\n\n\nconst { encrypt } = AESGCM();\nconst encrypted = encrypt(JSON.stringify(header))\n\nexport const getdatafromip = (path) => {\n return new Promise((resolve, reject) => {\n axios.get(path)\n .then(response => resolve(response.data.Data))\n .catch(error => reject(handleError(error)));\n });\n};\n\nexport const get = (path) => {\n return new Promise((resolve, reject) => {\n axios.get(`${SERVER_DOMAIN}/${path}`)\n .then(response => resolve(response.data.Data))\n .catch(error => reject(handleError(error)));\n });\n};\n\nexport const post = (path, data) => {\n return new Promise((resolve, reject) => {\n axios.post(`${SERVER_DOMAIN}/${path}`, data, { headers: { 'Authorization': encrypted } })\n .then(response => resolve(response.data.Data))\n .catch(error => reject(handleError(error)));\n });\n};\n\nexport const postExternal = (externalUrl, data) => {\n return new Promise((resolve, reject) => {\n axios.post(externalUrl, data, { headers: { 'Authorization': encrypted } })\n .then(response => resolve(response.data.Data))\n .catch(error => reject(handleError(error)));\n });\n};","import {\n isIOS,\n isAndroid,\n isChrome,\n isSafari,\n isBrowser,\n} from \"react-device-detect\";\n\nexport const getUserAgent = () => navigator.userAgent;\nexport const getHash = () => window.location.pathname.substr(1);\nexport const isWalletPasses = () => navigator.userAgent.includes(\"WalletPasses\");\n\nexport function getBrowserType() {\n if (isChrome) return 1;\n else if (isSafari) return 2;\n else return 0;\n}\n\nexport function getOSType() {\n if (isWalletPasses()) return 3;\n if (isAndroid) return 2;\n if (isIOS) return 1;\n if (isBrowser) return 4;\n return 0;\n}","export const phoneformats = [\n {\n name: 'Azerbaijan',\n iso2: 'az',\n dialcode: '994',\n mask: '+\\\\9\\\\94 99-999 9999',\n reg: /(\\+994) ([0-9]{2})-([0-9]{3}) ([0-9]{4})/\n },\n {\n name: 'Bahrain',\n iso2: 'bh',\n dialcode: '973',\n mask: '+\\\\973 9999 9999',\n reg: /(\\+973) ([0-9]{4}) ([0-9]{4})/\n },\n {\n name: 'Canada',\n iso2: 'ca',\n dialcode: '1',\n mask: '+1 999 999-9999',\n reg: /(\\+1) ([0-9]{3}) ([0-9]{3})-([0-9]{4})/\n },\n {\n name: 'China',\n iso2: 'cn',\n dialcode: '86',\n mask: '+86 99-999999999',\n reg: /(\\+86) ([0-9]{2})-([0-9]{9})/\n },\n {\n name: 'Egypt',\n iso2: 'eg',\n dialcode: '20',\n mask: '+20 99-999-9999',\n reg: /(\\+20) ([0-9]{2})-([0-9]{3})-([0-9]{4})/\n },\n {\n name: 'France',\n iso2: 'fr',\n dialcode: '33',\n mask: '+33 9 99 99 99 99',\n reg: /(\\+33) ([0-9]{1}) ([0-9]{2}) ([0-9]{2}) ([0-9]{2}) ([0-9]{2})/\n },\n {\n name: 'Germany',\n iso2: 'de',\n dialcode: '49',\n mask: '+4\\\\9 9999 99999999',\n reg: /(\\+49) ([0-9]{4}) ([0-9]{8})/\n },\n {\n name: 'Italy',\n iso2: 'it',\n dialcode: '39',\n mask: '+3\\\\9 999 9999999',\n reg: /(\\+39) ([0-9]{3}) ([0-9]{7})/\n },\n {\n name: 'Kuwait',\n iso2: 'kw',\n dialcode: '965',\n mask: '+\\\\965 99999999',\n reg: /(\\+965) ([0-9]{8})/\n },\n {\n name: 'Netherlands',\n iso2: 'nl',\n dialcode: '31',\n mask: '+31 99 99999999',\n reg: /(\\+31) ([0-9]{2}) ([0-9]{8})/\n },\n {\n name: 'Oman',\n iso2: 'om',\n dialcode: '968',\n mask: '+\\\\968 9999 9999',\n reg: /(\\+968) ([0-9]{4}) ([0-9]{4})/\n },\n {\n name: 'Qatar',\n iso2: 'qa',\n dialcode: '974',\n mask: '+\\\\974 99 999999',\n reg: /(\\+974) ([0-9]{2}) ([0-9]{6})/\n },\n {\n name: 'Russia',\n iso2: 'ru',\n dialcode: '7',\n mask: '+7 999 999-99-99',\n reg: /(\\+7)( )?([0-9]{3})( )?([0-9]{3})(-)?([0-9]{2})(-)?([0-9]{2})/\n },\n {\n name: 'Saudi Arabia',\n iso2: 'sa',\n dialcode: '966',\n mask: '+\\\\966 99 999 9999',\n reg: /(\\+966)( )?([0-9]{2})( )?([0-9]{3})( )?([0-9]{4})/\n },\n {\n name: 'Spain',\n iso2: 'es',\n dialcode: '34',\n mask: '+34 999 999 999',\n reg: /(\\+34)( )?([0-9]{3})( )?([0-9]{3})( )?([0-9]{3})/\n },\n {\n name: 'Turkey',\n iso2: 'tr',\n dialcode: '90',\n mask: '+\\\\90 999 999 99 99',\n reg: /(\\+90)( )?(501|505|506|507|551|552|553|554|555|559|530|531|532|533|534|535|536|537|538|539|561|540|541|542|543|544|545|546|547|548|549)( )?([0-9]{3})( )?([0-9]{2})( )?([0-9]{2})/\n },\n {\n name: 'Ukraine',\n iso2: 'ua',\n dialcode: '380',\n mask: '+380 99 999 99 99',\n reg: /(\\+380) ([0-9]{2}) ([0-9]{3}) ([0-9]{2}) ([0-9]{2})/\n },\n {\n name: 'United Arab Emirates',\n iso2: 'ae',\n dialcode: '971',\n mask: '+\\\\971 99 999 999',\n reg: /(\\+971) (50|52|54|55|56|58) ([0-9]{3}) ([0-9]{4})/\n },\n {\n name: 'United Kingdom',\n iso2: 'uk',\n dialcode: '44',\n mask: '+44 9999 999999',\n reg: /(\\+44) ([0-9]{4}) ([0-9]{6})/\n },\n {\n name: 'United States',\n iso2: 'us',\n dialcode: '1',\n mask: '+1 999 999-9999',\n reg: /(\\+1) ([0-9]{3}) ([0-9]{3})-([0-9]{4})/\n },\n];","import { useState, useCallback, useEffect } from 'react';\nimport { find, union } from 'lodash';\nimport { parsePhoneNumber, isValidPhoneNumber } from 'libphonenumber-js';\nimport { phoneformats } from '../_helpers/localization.helper';\nimport moment from 'moment';\n\nexport function useFormInput({ field, values, validating, setValues, setValidating, handleError }) {\n const name = field.Name;\n const isrequired = field.Required;\n const inputtype = field.InputType;\n const fields = values.FormData;\n let formValue = '';\n for (var key in fields) {\n if (key === name) formValue = fields[key];\n }\n\n const [value, setValue] = useState(formValue);\n const [isValid, setIsValid] = useState(true);\n const [isTouched, setIsTouched] = useState(false);\n const [isFocused, setIsFocused] = useState(false);\n\n const handleValidation = useCallback(() => {\n const checkvalid = validate(value, isrequired, field);\n setIsValid(checkvalid);\n handleError(name, checkvalid);\n }, [setIsValid, name, value, isrequired, field, handleError]);\n\n // watch for external parent data changes\n useEffect(() => {\n if (value !== formValue) {\n if (formValue === '') setValue(formValue);\n setIsTouched(false);\n setIsFocused(false);\n }\n }, [formValue, value, setValue, setIsFocused, setIsTouched]);\n\n // validate on value change\n useEffect(() => {\n handleValidation();\n }, [value, handleValidation]);\n\n // rewrite self and parent's value\n const handleChange = useCallback(\n (event) => {\n const value = event.target.value;\n var formattedvalue = value;\n\n if (inputtype === 'regex-phone') {\n const { valid, formattedphone } = validateRegexPhone(value, field);\n valid ? (formattedvalue = formattedphone) : (formattedvalue = value);\n }\n\n fields[name] = formattedvalue;\n\n setValidating(false);\n setValue(value);\n setValues((prev) => ({ ...prev, FormData: fields }));\n // eslint-disable-next-line react-hooks/exhaustive-deps\n },\n [setValue, setValues, setValidating, name, inputtype, fields]\n );\n\n const handleFocus = useCallback(() => {\n setIsTouched(true);\n setIsFocused(true);\n handleValidation();\n }, [setIsTouched, setIsFocused, handleValidation]);\n\n const handleBlur = useCallback(() => setIsFocused(false), [setIsFocused]);\n\n const error = validating ? !isValid : !isValid && isTouched && !isFocused;\n const helpertext = error ? field.ValidationText : field.HelperText;\n\n return {\n name,\n value,\n onChange: handleChange,\n onFocus: handleFocus,\n onBlur: handleBlur,\n error,\n required: isrequired,\n helperText: helpertext || ' ',\n };\n}\n\nexport const validate = (value, isrequired, field) => {\n if (isrequired && !value) return false;\n\n if (field.Regex) {\n if (!isrequired && !Boolean(value)) return true;\n const regex = new RegExp(field.Regex);\n return regex.test(value);\n }\n\n if (field.InputType === 'select') {\n if (!isrequired && !Boolean(value)) return true;\n return value !== null;\n }\n\n if (field.InputType === 'email') {\n if (!isrequired && !Boolean(value)) return true;\n var re_email =\n /^(([^<>()[\\]\\\\.,;:\\s@\"]+(\\.[^<>()[\\]\\\\.,;:\\s@\"]+)*)|(\".+\"))@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\])|(([a-zA-Z\\-0-9]+\\.)+[a-zA-Z]{2,}))$/;\n return re_email.test(String(value).toLowerCase());\n }\n\n if (field.InputType === 'phone') {\n if (!isrequired && (value === '' || value === field.InputMask.replace(/9/gi, ' '))) return true;\n var re_phone = new RegExp(field.Regex);\n return re_phone.test(String(value).toLowerCase());\n }\n\n if (field.InputType === 'masked-text') {\n if (!isrequired && !Boolean(value)) return true;\n var re_masked_text = new RegExp(field.Regex);\n return re_masked_text.test(String(value).toLowerCase());\n }\n\n /*if (field.InputType === 'regex-phone') {\n if (!isrequired && !Boolean(value)) return true;\n const { valid, } = validateRegexPhone(value, field);\n return valid;\n }\n\n if (field.InputType === 'int-phone') {\n if (!isrequired && !Boolean(value)) return true;\n return field.country.reg.test(String(value).toLowerCase());\n }*/\n\n if (field.InputType === 'tr-mobile') {\n if (!isrequired && !Boolean(value)) return true;\n var re_mobile =\n /^(500|501|502|503|504|505|506|507|508|509|510|516|522|530|531|532|533|534|535|536|537|538|539|540|541|542|543|544|545|546|547|548|549|550|551|552|553|554|555|556|557|558|559|561|592)([0-9]{7})$/;\n return re_mobile.test(String(value).toLowerCase());\n }\n\n if (field.InputType === 'date') {\n const formatted = value.split('-').reverse().join('.');\n\n if (!isrequired && (value === '' || value === field.InputMask.replace(/9/gi, ' '))) return true;\n var re_date = /^(0[1-9]|1[0-9]|2[0-9]|3[0-1])\\.?(0[1-9]|1[0-2])\\.?(19|20)\\d{2}$/;\n return re_date.test(String(formatted).toLowerCase());\n }\n\n if (field.InputType === 'masked-date') {\n if (!isrequired && !Boolean(value)) return true;\n var re_maskeddate = /^(0[1-9]|1[0-9]|2[0-9]|3[0-1])\\/(0[1-9]|1[0-2])\\/(19|20)\\d{2}$/;\n return re_maskeddate.test(String(value).toLowerCase());\n }\n\n if (field.InputType === 'age-control') {\n var compareDate = moment(value, 'YYYY-MM-DD');\n var startDate = moment('27-10-1995', 'DD-MM-YYYY');\n var endDate = moment('18-01-2004', 'DD-MM-YYYY');\n\n return compareDate.isBetween(startDate, endDate);\n }\n\n if (field.InputType === 'age-control18') {\n var compareDate = moment(value, 'YYYY-MM-DD');\n\n return moment().diff(compareDate, 'years') >= 18;\n }\n\n return true;\n};\n\nconst validateRegexPhone = (value, field) => {\n // First check the length of the phone number. We do not allow phone numbers less that 8 chars\n if (value.length < 8) return { valid: false, formattedphone: '' };\n\n var valid = false;\n var phonenumber = '';\n var formattedphone = '';\n\n // Create a list of country codes to be checked for international phone number format library\n // We unique merge the list that comes with the field and the country code we fetched from IP\n const checklist = union([field.countrycode?.toUpperCase()], field.Countries);\n\n // First check if the phone number is a valid international phone number\n if (isValidPhoneNumber(value)) {\n phonenumber = parsePhoneNumber(value);\n formattedphone = phonenumber.format('INTERNATIONAL');\n valid = phonenumber.isValid();\n\n if (phonenumber && phonenumber.country === 'TR') {\n const format = find(phoneformats, ['iso2', 'tr']);\n valid = format?.reg?.test(formattedphone);\n }\n } else {\n // The phone number is NOT a valid int-phone. We will check the phone number against every country in our checklist\n var i;\n\n for (i = 0; i < checklist.length; i++) {\n const country = checklist[i];\n\n if (isValidPhoneNumber(value, country)) {\n phonenumber = parsePhoneNumber(value, country);\n formattedphone = phonenumber.format('INTERNATIONAL');\n valid = phonenumber.isValid();\n\n if (phonenumber && phonenumber.country === 'TR') {\n const format = find(phoneformats, ['iso2', 'tr']);\n valid = format?.reg?.test(formattedphone);\n }\n\n break;\n }\n }\n }\n\n return { valid, formattedphone };\n};\n","import { useState, useCallback } from 'react'\nimport { useFormInput } from './useFormInput';\nimport { useFormConsent } from './useFormConsent';\n\nexport function useForm() {\n const [values, setValues] = useState({});\n const [errors, setErrors] = useState([]);\n const [validating, setValidating] = useState(false);\n\n const handleError = useCallback((name, isvalid) => {\n let tmperrors = errors;\n const index = tmperrors.findIndex(error => error === name);\n\n if (!isvalid) {\n if (index < 0) tmperrors.push(name);\n } else {\n if (index > -1) tmperrors.splice(index, 1);\n }\n\n setErrors(tmperrors);\n }, [errors]);\n\n const clearForm = useCallback((language) => {\n setValues(prev => { return { ...prev, FormData: [] } });\n setErrors([]);\n }, []);\n\n const useInput = (field) => useFormInput({\n field,\n values,\n validating,\n setValues,\n setValidating,\n handleError\n });\n\n const useConsent = (consent) => useFormConsent({\n consent,\n values,\n validating,\n setValues,\n setValidating,\n handleError\n });\n\n return {\n values,\n errors,\n validating,\n setValues,\n setErrors,\n clearForm,\n setValidating,\n useInput,\n useConsent\n };\n}","import { useState, useCallback, useEffect } from 'react';\n\nexport const useFormConsent = ({\n consent,\n values,\n validating,\n setValues,\n setValidating,\n handleError\n}) => {\n const fields = values.FormData;\n const name = consent.Name;\n const isrequired = consent.isRequired;\n\n let formValue;\n for (var key in fields) {\n if (key === String(name)) formValue = fields[key]\n\n }\n\n const [value, setValue] = useState(formValue);\n const [isValid, setIsValid] = useState(true);\n const [isTouched, setIsTouched] = useState(false);\n\n const handleValidation = useCallback(() => {\n const valid = isrequired ? (value) : true\n setIsValid(valid);\n handleError(name, valid);\n }, [setIsValid, name, value, isrequired, handleError]);\n\n // validate on value change\n useEffect(() => {\n handleValidation();\n }, [value, handleValidation]);\n\n // rewrite self and parent's value\n const handleChange = useCallback((event) => {\n const value = (event.target.checked ? true : false);\n\n fields[name] = value\n\n setValidating(false);\n setValue(value);\n setValues(prev => ({ ...prev, FormData: fields }));\n }, [setValue, setValues, setValidating, name, fields]);\n\n const handleFocus = useCallback(() => {\n setIsTouched(true);\n handleValidation();\n }, [setIsTouched, handleValidation]);\n\n const error = validating ? !isValid : !isValid && isTouched;\n const helpertext = error ? consent.ValidationText : consent.HelperText;\n\n return {\n name,\n value,\n onChange: handleChange,\n onFocus: handleFocus,\n error,\n required: isrequired,\n helperText: helpertext,\n };\n}","class UrlSearchParams {\n constructor(query) {\n this.query = query;\n }\n getSearchObject = () => {\n const { query } = this;\n return query\n ? (/^[?#]/.test(query) ? query.slice(1) : query)\n .split(\"&\")\n .reduce((params, param) => {\n let [key, value] = param.split(\"=\");\n params[key] = value\n ? decodeURIComponent(value.replace(/\\+/g, \" \"))\n : \"\";\n return params;\n }, {})\n : {};\n };\n getAll = () => {\n const searchParams = this.getSearchObject();\n return searchParams;\n }\n get = param => {\n const searchParams = this.getSearchObject();\n return searchParams[param];\n };\n setUrl = (param, value) => {\n const searchParams = this.getSearchObject();\n searchParams[param] = value;\n return Object.keys(searchParams)\n .map(key => key + \"=\" + searchParams[key])\n .join(\"&\");\n };\n}\n\nexport default UrlSearchParams;","import React, { createContext, useState, useEffect, useCallback, useMemo } from 'react';\n\n// Api\nimport { post /*getdatafromip*/ } from '../_api/api';\n\n// Helpers\nimport { getHash, getOSType } from '../_helpers/utility.helper';\n\n// Material UI\nimport { createTheme } from '@mui/material/styles';\n\n// Hooks\nimport { useForm } from '../_forms/useForm';\n\nimport UrlSearchParams from './urlsearchparams.js';\n\nexport const DataContext = createContext();\n\nexport const DataProvider = (props) => {\n\tconst offerhash = getHash();\n\tconst isMobile = getOSType();\n\tconst params = useMemo(() => new UrlSearchParams(window.location.search), []);\n\n\tconst [appState, setAppState] = useState({ state: 'resting', submitting: false, error: null });\n\tconst [formGetResponse, setFormGetResponse] = useState(null);\n\tconst [formSendResponse, setFormSendResponse] = useState(null);\n\t//const [countrycode, setCountrycode] = useState('tr');\n\tconst [theme, setTheme] = useState(null);\n\tconst [form, setForm] = useState(null);\n\n\tconst { values, errors, setValues, setValidating, useInput, useConsent } = useForm();\n\n\tuseEffect(() => {\n\t\tconst updateTheme = async () => {\n\t\t\tsetTheme(\n\t\t\t\tcreateTheme({\n\t\t\t\t\tpalette: form.Config?.Theme?.palette,\n\t\t\t\t\tcomponents: {\n\t\t\t\t\t\tMuiFormHelperText: {\n\t\t\t\t\t\t\tstyleOverrides: {\n\t\t\t\t\t\t\t\troot: {\n\t\t\t\t\t\t\t\t\tcolor: form.Config?.Theme?.palette?.primary?.main,\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t},\n\t\t\t\t\t\tMuiInputLabel: {\n\t\t\t\t\t\t\tstyleOverrides: {\n\t\t\t\t\t\t\t\troot: {\n\t\t\t\t\t\t\t\t\tcolor: form.Config?.Theme?.palette?.primary?.main,\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t},\n\t\t\t\t\t\tMuiInputBase: {\n\t\t\t\t\t\t\tstyleOverrides: {\n\t\t\t\t\t\t\t\tinput: {\n\t\t\t\t\t\t\t\t\t'&-webkit-autofill': {\n\t\t\t\t\t\t\t\t\t\tbackgroundColor: 'transparent !important',\n\t\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t},\n\t\t\t\t\t\tMuiInput: {\n\t\t\t\t\t\t\tstyleOverrides: {\n\t\t\t\t\t\t\t\troot: {\n\t\t\t\t\t\t\t\t\tcolor: form.Config?.Theme?.palette?.primary?.main,\n\t\t\t\t\t\t\t\t\t'&::before': {\n\t\t\t\t\t\t\t\t\t\tborderBottom: `1px solid ${form.Config?.Theme?.palette?.primary?.main}`,\n\t\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\t\t'&::after': {\n\t\t\t\t\t\t\t\t\t\tborderBottom: `1px solid ${form.Config?.Theme?.palette?.primary?.main}`,\n\t\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t\tMuiTextField: {\n\t\t\t\t\t\tstyleOverrides: {\n\t\t\t\t\t\t\troot: {\n\t\t\t\t\t\t\t\t'& .MuiOutlinedInput-root': {\n\t\t\t\t\t\t\t\t\t'&::before': {\n\t\t\t\t\t\t\t\t\t\tborderBottom: `1px solid ${form.Config?.Theme?.palette?.primary?.main}`,\n\t\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\t\t'&::after': {\n\t\t\t\t\t\t\t\t\t\tborderBottom: `1px solid ${form.Config?.Theme?.palette?.primary?.main}`,\n\t\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\t\t'& fieldset': {\n\t\t\t\t\t\t\t\t\t\tborderColor: form.Config?.Theme?.palette?.primary?.main,\n\t\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\t\t'&:hover fieldset': {\n\t\t\t\t\t\t\t\t\t\tborderColor: form.Config?.Theme?.palette?.primary?.main,\n\t\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\t\t'&.Mui-focused fieldset': {\n\t\t\t\t\t\t\t\t\t\tborderColor: form.Config?.Theme?.palette?.primary?.main,\n\t\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t},\n\t\t\t\t\t\tMuiButton: {\n\t\t\t\t\t\t\tstyleOverrides: {\n\t\t\t\t\t\t\t\troot: {\n\t\t\t\t\t\t\t\t\ttextTransform: 'none',\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t},\n\t\t\t\t\t\tMuiSvgIcon: {\n\t\t\t\t\t\t\tstyleOverrides: {\n\t\t\t\t\t\t\t\troot: {\n\t\t\t\t\t\t\t\t\tzIndex: 1000,\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t})\n\t\t\t);\n\t\t};\n\n\t\tif (form) updateTheme();\n\t}, [form, setTheme]);\n\n\t/*useEffect(() => {\n const fetchCountryCode = async () => {\n getdatafromip('https://ipapi.co/json/')\n .then(response => setCountrycode(response.country_code.toLowerCase()))\n .catch(() => setCountrycode('tr'));\n }\n\n fetchCountryCode();\n }, [setCountrycode]);\n */\n\n\tuseEffect(() => {\n\t\tconst fetchForm = async () => {\n\t\t\tsetAppState((prev) => {\n\t\t\t\treturn { ...prev, state: 'checking', submitting: false, error: null };\n\t\t\t});\n\n\t\t\tconst additionalparams = params.getAll();\n\n\t\t\tpost(`Form/get/${offerhash}`, additionalparams)\n\t\t\t\t.then((getresponse) => {\n\t\t\t\t\tsetForm(getresponse.Form);\n\t\t\t\t\tconsole.log(getresponse);\n\t\t\t\t\tdocument.body.style.backgroundColor = getresponse.Form.Config?.Theme?.palette.background.paper;\n\t\t\t\t\tif (isMobile !== 4) {\n\t\t\t\t\t\tif (getresponse.Form.Config.Theme.BgImageMobile)\n\t\t\t\t\t\t\tdocument.body.style.backgroundImage = `url(${getresponse.Form.Config.Theme.BgImageMobile})`;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tif (getresponse.Form.Config.Theme.BgImageWeb) document.body.style.backgroundImage = `url(${getresponse.Form.Config.Theme.BgImageWeb})`;\n\t\t\t\t\t}\n\t\t\t\t\tsetFormGetResponse(getresponse);\n\t\t\t\t\tif (getresponse.Values) {\n\t\t\t\t\t\tif (getresponse.SendFormIfValuesOK) {\n\t\t\t\t\t\t\tpost(`Form/send/${offerhash}`, {\n\t\t\t\t\t\t\t\t...additionalparams,\n\t\t\t\t\t\t\t\tMsisdn: getresponse.Values.Data?.Msisdn || null,\n\t\t\t\t\t\t\t\tFormData: { ...getresponse.Values.Data },\n\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t\t.then((sendresponse) => {\n\t\t\t\t\t\t\t\t\tsetFormSendResponse(sendresponse);\n\t\t\t\t\t\t\t\t\tif (sendresponse.Page)\n\t\t\t\t\t\t\t\t\t\tsetAppState((prev) => {\n\t\t\t\t\t\t\t\t\t\t\treturn { ...prev, state: 'page', submitting: false };\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\telse if (sendresponse.ReturnMessage)\n\t\t\t\t\t\t\t\t\t\tsetAppState((prev) => {\n\t\t\t\t\t\t\t\t\t\t\treturn { ...prev, state: 'success', submitting: false };\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\tsetAppState((prev) => {\n\t\t\t\t\t\t\t\t\t\t\treturn { ...prev, state: 'error', submitting: false };\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t\t.catch((error) =>\n\t\t\t\t\t\t\t\t\tsetAppState((prev) => {\n\t\t\t\t\t\t\t\t\t\treturn { ...prev, state: 'error', submitting: false, error: error };\n\t\t\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tsetValues({ FormData: { ...getresponse.Values.Data } });\n\t\t\t\t\t\t\tif (getresponse.Page)\n\t\t\t\t\t\t\t\tsetAppState((prev) => {\n\t\t\t\t\t\t\t\t\treturn { ...prev, state: 'page', submitting: false };\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\tsetAppState((prev) => {\n\t\t\t\t\t\t\t\t\treturn { ...prev, state: 'form', submitting: false };\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\tsetValues({ FormData: { ...additionalparams } });\n\t\t\t\t\t\tif (getresponse.Page)\n\t\t\t\t\t\t\tsetAppState((prev) => {\n\t\t\t\t\t\t\t\treturn { ...prev, state: 'page', submitting: false };\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\telse\n\t\t\t\t\t\t\tsetAppState((prev) => {\n\t\t\t\t\t\t\t\treturn { ...prev, state: 'form', submitting: false };\n\t\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t})\n\t\t\t\t.catch((error) => setAppState({ state: 'error', error: error }));\n\t\t};\n\n\t\tfetchForm();\n\t}, [offerhash, setValues, params]);\n\n\tconst submitForm = useCallback(\n\t\t(externalUrl) => {\n\t\t\tconst additionalparams = params.getAll();\n\n\t\t\tconst valid = !Boolean(errors.length);\n\t\t\tsetValidating(true);\n\n\t\t\tif (valid) {\n\t\t\t\tsetAppState((prev) => {\n\t\t\t\t\treturn { ...prev, submitting: true, error: null };\n\t\t\t\t});\n\t\t\t\t// replace ' and \" characters with empty string from all fields in values. Replace \\ with /.\n\t\t\t\tObject.keys(values.FormData).forEach((key) => {\n\t\t\t\t\tif (typeof values.FormData[key] === 'string') {\n\t\t\t\t\t\tvalues.FormData[key] = values.FormData[key].replace(/[\"']+/g, '').replace(/\\\\/g, '/');\n\t\t\t\t\t}\n\t\t\t\t});\n\n\t\t\t\tpost(externalUrl || `Form/send/${offerhash}`, { ...additionalparams, Msisdn: values.FormData?.Msisdn || null, ...values })\n\t\t\t\t\t.then((sendresponse) => {\n\t\t\t\t\t\tsetFormSendResponse(sendresponse);\n\n\t\t\t\t\t\tif (sendresponse.Page)\n\t\t\t\t\t\t\tsetAppState((prev) => {\n\t\t\t\t\t\t\t\treturn { ...prev, state: 'page', submitting: false };\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\telse if (sendresponse.ReturnMessage)\n\t\t\t\t\t\t\tsetAppState((prev) => {\n\t\t\t\t\t\t\t\treturn { ...prev, state: 'success', submitting: false };\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\telse\n\t\t\t\t\t\t\tsetAppState((prev) => {\n\t\t\t\t\t\t\t\treturn { ...prev, state: 'error', submitting: false };\n\t\t\t\t\t\t\t});\n\t\t\t\t\t})\n\t\t\t\t\t.catch((error) =>\n\t\t\t\t\t\tsetAppState((prev) => {\n\t\t\t\t\t\t\treturn { ...prev, state: 'form', submitting: false, error: error };\n\t\t\t\t\t\t})\n\t\t\t\t\t);\n\t\t\t}\n\t\t},\n\t\t[setValidating, errors, values, offerhash, params]\n\t);\n\n\treturn (\n\t\t\n\t\t\t{props.children}\n\t\t\n\t);\n};\n","import React, { useContext } from 'react';\n\n// Material UI\nimport TextField from '@mui/material/TextField';\n\n// Contexts\nimport { DataContext } from '../../_contexts/data.context';\n\nconst TextInputField = (props) => {\n const { appState, useInput } = useContext(DataContext);\n\n const { field, multiline, classes } = props;\n const Shrink = field.PlaceHolder ? { shrink: true } : null;\n\n return (\n \n );\n};\n\nexport default TextInputField;\n","import React, { useContext } from 'react'\n\n\n// Material UI\nimport TextField from '@mui/material/TextField';\n\n// Contexts\nimport { DataContext } from '../../_contexts/data.context';\n\nconst SelectField = (props) => {\n const { field, classes } = props;\n const { appState, useInput } = useContext(DataContext); // Extract Forms and Credentials from context\n const Shrink = (field.PlaceHolder) ? { shrink: true, } : null;\n\n return \n {field.ValueTexts.map((Value, i) => (\n \n ))}\n \n}\n\nexport default SelectField;","import React, { useContext } from 'react'\n\n// Material UI\nimport TextField from '@mui/material/TextField';\n\n// Contexts\nimport { DataContext } from '../../_contexts/data.context';\n\nconst EmailField = (props) => {\n const { field, classes } = props;\n const { appState, useInput } = useContext(DataContext);\n const Shrink = (field.PlaceHolder) ? { shrink: true, } : null;\n\n return \n}\n\nexport default EmailField;","import React, { useContext } from 'react'\n\nimport Typography from '@mui/material/Typography';\n\nimport { DataContext } from '../../_contexts/data.context';\n\nconst InfoText = (props) => {\n const { field } = props;\n const { formGetResponse, formSendResponse } = useContext(DataContext);\n\n const getConfirmMessage = (text) => {\n if (text) {\n if (formSendResponse) {\n let message = text;\n if (text.includes('@')) {\n message.split(' ').map(param => {\n if (param.startsWith('@')) message = message.replace(param, formSendResponse[param.substr(1)])\n return null;\n });\n }\n return message\n }\n else {\n let message = text;\n if (text.includes('@')) {\n message.split(' ').map(param => {\n if (param.startsWith('@')) message = message.replace(param, formGetResponse[param.substr(1)])\n return null;\n });\n }\n return message\n }\n }\n return ''\n }\n\n return {getConfirmMessage(field.Label)}\n}\n\nexport default InfoText\n","import React, { useContext } from 'react'\n\n// Material UI\nimport {\n InputLabel,\n RadioGroup,\n FormHelperText,\n FormControlLabel,\n FormControl,\n Radio\n} from '@mui/material';\n\n// Contexts\nimport { DataContext } from '../../_contexts/data.context';\n\nconst RadioField = (props) => {\n const { field, classes } = props;\n const { appState, useInput } = useContext(DataContext); // Extract Forms and Credentials from context\n const { value, onChange, onFocus, onBlur, error, required, helperText } = useInput(field);\n\n return (\n
\n {field.Label}\n \n \n {\n field.ValueTexts.map((Value, i) => (\n }\n label={Value}\n labelPlacement='end'\n />\n ))\n }\n \n {helperText}\n \n
\n );\n}\n\nexport default RadioField;","import React, { useContext } from 'react';\n\n// Material UI\nimport TextField from '@mui/material/TextField';\n\n// Contexts\nimport { DataContext } from '../../_contexts/data.context';\n\nconst DateField = (props) => {\n const { field, classes } = props;\n const { appState, useInput } = useContext(DataContext);\n const { value, onChange, onFocus, onBlur, error, required, helperText } = useInput(field);\n\n return (\n \n );\n};\n\nexport default DateField;\n","import React, { useContext } from 'react'\n\n// Material UI\nimport TextField from '@mui/material/TextField';\nimport InputMask from \"react-input-mask\";\n\n// Contexts\nimport { DataContext } from '../../_contexts/data.context';\n\nconst MaskedDateField = (props) => {\n const { field, classes } = props;\n const { appState, useInput } = useContext(DataContext);\n\n return (\n \n {(inputProps) =>\n }\n \n )\n}\n\nexport default MaskedDateField;","import React, { useContext } from 'react'\n\n// Material UI\nimport { TextField } from '@mui/material';\nimport InputMask from \"react-input-mask\";\n\n// Contexts\nimport { DataContext } from '../../_contexts/data.context';\n\nconst MaskedPhoneField = (props) => {\n const { field, classes } = props;\n const { appState, useInput } = useContext(DataContext);\n\n return (\n \n {(inputProps) =>\n }\n \n )\n}\n\nexport default MaskedPhoneField;","import React, { useContext } from 'react'\n\n// Material UI\nimport TextField from '@mui/material/TextField';\nimport InputMask from \"react-input-mask\";\n\n// Contexts\nimport { DataContext } from '../../_contexts/data.context';\n\nconst MaskedTextField = (props) => {\n const { field, classes } = props;\n const { appState, useInput } = useContext(DataContext);\n\n return (\n \n {(inputProps) =>\n }\n \n )\n}\n\nexport default MaskedTextField;","import React, { useContext } from 'react';\nimport { orderBy } from 'lodash';\n\n// Material UI\nimport { makeStyles } from '@mui/styles';\nimport Stack from '@mui/material/Stack';\n\n// Fields\nimport TextInputField from './fields/text.field.component';\nimport SelectField from './fields/select.field.component';\nimport EmailField from './fields/email.field.component';\nimport InfoText from './fields/info.text.component';\n//import IntPhoneField from './fields/intphone.field.component';\nimport RadioField from './fields/radio.field.component';\nimport DateField from './fields/date.field.component';\nimport MaskedDateField from './fields/maskeddate.field.component';\nimport MaskedPhoneField from './fields/maskedphone.field.component';\nimport MaskedTextField from './fields/maskedtext.field.component';\n//import RegexPhoneField from './fields/regexphone.field.component';\n\nimport { DataContext } from '../_contexts/data.context';\nimport { Typography } from '@mui/material';\n\nconst InputField = (props) => {\n\tswitch (props.field.InputType) {\n\t\tcase 'textarea':\n\t\t\treturn ;\n\t\tcase 'masked-date':\n\t\t\treturn ;\n\t\tcase 'age-control':\n\t\t\treturn ;\n\t\tcase 'age-control18':\n\t\t\treturn ;\n\t\tcase 'masked-text':\n\t\t\treturn ;\n\t\t//case 'regex-phone': return \n\t\tcase 'tr-mobile':\n\t\t\treturn ;\n\t\t//case 'int-phone': return \n\t\tcase 'phone':\n\t\t\treturn ;\n\t\tcase 'date':\n\t\t\treturn ;\n\t\tcase 'text':\n\t\t\treturn ;\n\t\tcase 'select':\n\t\t\treturn ;\n\t\tcase 'infotext':\n\t\t\treturn ;\n\t\tcase 'email':\n\t\t\treturn ;\n\t\tcase 'radio':\n\t\t\treturn ;\n\t\tdefault:\n\t\t\treturn '';\n\t}\n};\n\nconst Field = (props) => {\n\tconst { field, ...rest } = props;\n\tconst { formGetResponse, formSendResponse } = useContext(DataContext);\n\n\tswitch (field.FieldType) {\n\t\tcase 'text':\n\t\t\treturn ;\n\t\tcase 'input':\n\t\t\treturn ;\n\t\tcase 'image':\n\t\t\treturn {field.Label};\n\n\t\tcase 'surveyResult':\n\t\t\tconst itemCount = field.Values.length;\n\t\t\tconst labelPercentage = 100 / itemCount;\n\t\t\tconst colors = ['#001d97', '#a90432', '#5E3B8E', '#F76C3B', '003C43', 'A34343'];\n\t\t\tconst values = field.Values.map((text) => {\n\t\t\t\tlet message = text;\n\t\t\t\tif (formSendResponse) {\n\t\t\t\t\tif (text.includes('@')) {\n\t\t\t\t\t\tmessage.split(' ').map((param) => {\n\t\t\t\t\t\t\tif (param.startsWith('@')) message = message.replace(param, formSendResponse[param.substr(1)]);\n\t\t\t\t\t\t\treturn null;\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t\treturn message;\n\t\t\t\t} else {\n\t\t\t\t\tif (text.includes('@')) {\n\t\t\t\t\t\tmessage.split(' ').map((param) => {\n\t\t\t\t\t\t\tif (param.startsWith('@')) message = message.replace(param, formGetResponse[param.substr(1)]);\n\t\t\t\t\t\t\treturn null;\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t\treturn message;\n\t\t\t\t}\n\t\t\t});\n\n\t\t\treturn (\n\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t\t{field.ValueTexts.map((v, i) => (\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t{v}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t))}\n\t\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t\t{values.map((v, i) => (\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t{`${v}%`}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t))}\n\t\t\t\t\t
\n\t\t\t\t
\n\t\t\t);\n\t\tdefault:\n\t\t\treturn '';\n\t}\n};\n\nconst FieldList = (props) => {\n\tconst { fields } = props;\n\n\tconst useStyles = makeStyles((theme) => ({\n\t\ttextfield: {\n\t\t\tcolor: theme.palette.text.primary,\n\t\t\t'& .MuiOutlinedInput-root': {\n\t\t\t\t'& .MuiOutlinedInput-notchedOutline': {\n\t\t\t\t\tborder: `1px solid ${theme.palette.primary.main}`,\n\t\t\t\t},\n\t\t\t},\n\t\t},\n\t\tinput: {\n\t\t\tzIndex: 999,\n\t\t},\n\t\tselect: {\n\t\t\twidth: '100%',\n\t\t\tdisplay: 'flex',\n\t\t\tflexDirection: 'column',\n\t\t},\n\t\tradiolabel: {\n\t\t\tcolor: theme.palette.text.primary,\n\t\t},\n\t\tnative: {\n\t\t\twidth: 50,\n\t\t\theight: 30,\n\t\t\tpadding: 8,\n\t\t},\n\t\tnativeRoot: {\n\t\t\tpadding: 0,\n\t\t\t'& + svg': {\n\t\t\t\tdisplay: 'none',\n\t\t\t},\n\t\t},\n\t\tnativeSelect: {\n\t\t\tpadding: 0,\n\t\t\tlineHeight: 0,\n\t\t\theight: 11,\n\t\t},\n\t\tpositionStart: {\n\t\t\tposition: 'relative',\n\t\t},\n\t}));\n\n\tconst classes = useStyles();\n\n\tif (!fields) return '';\n\n\tconst sortedFields = orderBy(fields, ['Order'], ['asc']);\n\n\treturn sortedFields.map((field, index) => (\n\t\t\n\t\t\t\n\t\t\n\t));\n};\n\nexport default FieldList;\n","import React from 'react'\n\n// Material UI\nimport { DialogContentText, DialogActions, DialogContent, DialogTitle, Button, Dialog as MuiDialog } from '@mui/material';\n\nconst Dialog = (props) => {\n const { dialogText, dialogTitle, fullScreen, title, onClose, open } = props;\n\n return (\n \n {dialogTitle || ''}\n \n {\n title && {title}\n }\n {dialogText}\n \n \n \n \n \n )\n}\n\nexport default Dialog;","import React, { useContext, useState } from 'react'\n\n// Material UI\nimport { FormHelperText, Typography, FormGroup, Checkbox, Stack } from '@mui/material';\n\n// Components\nimport Dialog from './dialog.component';\n\n// Contexts\nimport { DataContext } from '../_contexts/data.context';\n\nconst Consent = (props) => {\n const { consent } = props;\n\n const { appState, useConsent } = useContext(DataContext);\n\n const [open, setOpen] = useState(false);\n\n const handleConsentDialog = () => setOpen(!open);\n\n const { value, onChange, onFocus, error, required, helperText } = useConsent(consent);\n\n return (\n
\n \n \n \n \n {consent.Text}\n \n \n \n \n {helperText || ' '}\n \n \n
\n )\n}\n\nexport default Consent;","import React, { useContext } from 'react'\n\n// Components\nimport Consent from './consent.component';\n\n// Contexts\nimport { DataContext } from '../_contexts/data.context';\n\nconst ConsentList = () => {\n const { form } = useContext(DataContext);\n\n if (!form?.Config.Form?.Consents) return '';\n return form.Config.Form.Consents.map((consent, index) => );\n};\n\nexport default ConsentList\n","import React, { useState, useContext } from 'react';\n\n// Components\nimport Stack from '@mui/material/Stack';\nimport Button from '@mui/material/Button';\nimport Dialog from './dialog.component';\nimport LoadingButton from '@mui/lab/LoadingButton';\n\n// Contexts\nimport { DataContext } from '../_contexts/data.context';\n\nconst ActionButton = (props) => {\n const { submitForm, appState } = useContext(DataContext);\n const { button, linker, color } = props;\n\n const { Label, Type, Action, Variant, Size, disabled } = button;\n\n const [open, setOpen] = useState(false);\n const handleConsentDialog = () => setOpen(!open);\n\n const handleClick = (type, action) => {\n switch (type) {\n case 'deeplink': linker.openURL(action); break;\n case 'history-go': window.history.go(action); break;\n case 'redirect': window.location = action; break;\n case 'submit': submitForm(); break;\n case 'external-submit': submitForm(action); break;\n case 'modal': handleConsentDialog(); break;\n default: return ''\n }\n }\n\n // If type is 'submit' return SubmitButton else return button with its props\n if (Type === 'submit') return (\n \n handleClick(Type, Action)}>\n {Label}\n \n \n )\n\n else {\n return <>\n handleClick(Type, Action)}>\n {Label}\n \n {\n Type === 'modal' &&\n \n }\n \n }\n}\n\n// Set the default props of Button\nActionButton.defaultProps = {\n size: 'large',\n color: 'primary'\n\n}\nexport default ActionButton;","export function DeepLinker(options) {\n if (!options) {\n throw new Error('no options')\n }\n\n var hasFocus = true;\n var didHide = false;\n\n // window is blurred when dialogs are shown\n function onBlur() {\n hasFocus = false;\n };\n\n // document is hidden when native app is shown or browser is backgrounded\n function onVisibilityChange(e) {\n if (e.target.visibilityState === 'hidden') {\n didHide = true;\n }\n };\n\n // window is focused when dialogs are hidden, or browser comes into view\n function onFocus() {\n if (didHide) {\n if (options.onReturn) {\n options.onReturn();\n }\n\n didHide = false; // reset\n } else {\n // ignore duplicate focus event when returning from native app on\n // iOS Safari 13.3+\n if (!hasFocus && options.onFallback) {\n // wait for app switch transition to fully complete - only then is\n // 'visibilitychange' fired\n setTimeout(function () {\n // if browser was not hidden, the deep link failed\n if (!didHide) {\n options.onFallback();\n }\n }, 1000);\n }\n }\n\n hasFocus = true;\n };\n\n // add/remove event listeners\n // `mode` can be \"add\" or \"remove\"\n function bindEvents(mode) {\n [\n [window, 'blur', onBlur],\n [document, 'visibilitychange', onVisibilityChange],\n [window, 'focus', onFocus],\n ].forEach(function (conf) {\n conf[0][mode + 'EventListener'](conf[1], conf[2]);\n });\n }\n\n // add event listeners\n bindEvents('add');\n\n // expose public API\n this.destroy = bindEvents.bind(null, 'remove');\n this.openURL = function (url) {\n // it can take a while for the dialog to appear\n var dialogTimeout = 1000;\n\n setTimeout(function () {\n if (hasFocus && options.onIgnored) {\n options.onIgnored();\n }\n }, dialogTimeout);\n\n window.location = url;\n };\n}","import React, { useContext } from 'react'\n\n// Material UI\nimport Stack from '@mui/material/Stack';\n\n// Components\nimport ActionButton from './action.button.component';\n\n// Contexts\nimport { DataContext } from '../_contexts/data.context';\n\n// Utilities and Helpers\nimport { DeepLinker } from '../_helpers/redirect.helper';\n\nconst ActionButtons = () => {\n const { form } = useContext(DataContext);\n\n if (!form?.Config.Form.Buttons || form?.Config.Form.Buttons === []) return '';\n\n const buttons = form.Config.Form.Buttons;\n\n var linker = new DeepLinker({\n onIgnored: function () {\n },\n onFallback: function () {\n ('dialog hidden or user returned to tab');\n },\n onReturn: function () {\n },\n });\n\n return (\n \n {\n buttons.map((buttongroup, groupindex) =>\n \n {\n buttongroup.map((button, rowindex) => )\n }\n \n )}\n \n )\n}\nexport default ActionButtons;\n","import React, { useContext } from 'react';\n\n// Material UI\nimport Stack from '@mui/material/Stack';\nimport Box from '@mui/material/Box';\n\n// Components\nimport FieldList from '../_components/field.list.component';\nimport ConsentList from '../_components/consent.list.component';\nimport ActionButtons from '../_components/action.buttons.component';\nimport Dialog from '../_components/dialog.component';\n\n// Contexts\nimport { DataContext } from '../_contexts/data.context';\n\nconst Form = () => {\n const { appState, setAppState, form } = useContext(DataContext);\n\n var caption = '';\n var title = '';\n\n if (appState.error) {\n if (appState.error.status === 400) {\n caption = 'Beklenmeyen bir hata oluştu';\n title = 'Şu anda hizmet veremiyoruz. Lütfen servis yetkilisi ile iletişime geçin';\n } else {\n caption = 'Beklenmeyen bir hata oluştu - ' + appState.error.status;\n title = 'Şu anda hizmet veremiyoruz. Lütfen servis yetkilisi ile iletişime geçin';\n }\n }\n\n const handleClose = () =>\n setAppState((prev) => {\n return { ...prev, error: null };\n });\n\n return (\n \n \n \n \n \n \n \n
\n );\n};\n\nexport default Form;\n","import React from 'react';\n\n// Material UI\nimport Stack from '@mui/material/Stack';\n\n// Components\nimport ActionButton from '../_components/action.button.component';\n\n// Utilities and Helpers\nimport { DeepLinker } from '../_helpers/redirect.helper';\nimport FieldList from '../_components/field.list.component';\n\nconst ActionButtons = ({ buttons }) => {\n if (!buttons || buttons.length === 0) return '';\n\n var linker = new DeepLinker({\n onIgnored: function () {},\n onFallback: function () {\n ('dialog hidden or user returned to tab');\n },\n onReturn: function () {},\n });\n\n return (\n \n {buttons.map((buttongroup, groupindex) => (\n \n {buttongroup.map((button, rowindex) => (\n \n ))}\n \n ))}\n \n );\n};\n\nconst Page = (props) => {\n const { page } = props;\n\n return (\n \n \n \n \n \n \n );\n};\n\nexport default Page;\n","import React from 'react'\n\n// Material UI\nimport Stack from '@mui/material/Stack';\nimport CircularProgress from '@mui/material/CircularProgress';\n\nconst Splash = () =>\n \n \n \n\nexport default Splash;","import React, { useContext } from 'react'\n\n// Material UI\nimport Stack from '@mui/material/Stack';\nimport Typography from '@mui/material/Typography';\n\nimport { DataContext } from '../_contexts/data.context';\n\nconst Success = () => {\n const { form, formSendResponse } = useContext(DataContext);\n\n return (\n \n {\n (form.Config.Form.Fields[0].FieldType === 'image') &&\n \"Logo\"\n }\n {formSendResponse.ReturnMessage}\n \n );\n}\n\nexport default Success;\n\n","import React, { useContext } from 'react';\n\n// Material UI\nimport { ThemeProvider } from '@mui/material/styles';\nimport CssBaseline from '@mui/material/CssBaseline';\nimport Container from '@mui/material/Container';\nimport { StylesProvider } from '@mui/styles';\n\n// Pages\nimport Form from './_pages/form.page';\nimport Page from './_pages/page.page';\nimport Error from './_pages/error.page';\nimport Splash from './_pages/splash.page';\nimport Success from './_pages/success.page';\n\n// Contexts\nimport { DataContext } from './_contexts/data.context';\n\n// Helpers\nimport { DeepLinker } from './_helpers/redirect.helper';\n\nconst App = () => {\n\tconst { appState, formGetResponse, formSendResponse, theme } = useContext(DataContext);\n\n\tif (appState.state === 'resting') return ;\n\tif (appState.state === 'checking') return ;\n\tif (appState.state === 'error') return ;\n\n\tvar linker = new DeepLinker({\n\t\tonIgnored: function () {},\n\t\tonFallback: function () {},\n\t\tonReturn: function () {},\n\t});\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t{(() => {\n\t\t\t\t\t\tswitch (appState.state) {\n\t\t\t\t\t\t\tcase 'form':\n\t\t\t\t\t\t\t\treturn
;\n\t\t\t\t\t\t\tcase 'page':\n\t\t\t\t\t\t\t\treturn (\n\t\t\t\t\t\t\t\t\t page.Id === (formSendResponse?.Page || formGetResponse?.Page))}\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t);\n\t\t\t\t\t\t\tcase 'success': {\n\t\t\t\t\t\t\t\tif (formSendResponse.RedirectURL) {\n\t\t\t\t\t\t\t\t\tlinker.openURL(formSendResponse?.RedirectURL);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\treturn ;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\treturn '';\n\t\t\t\t\t\t}\n\t\t\t\t\t})()}\n\t\t\t\t\n\t\t\t\n\t\t\n\t);\n};\nexport default App;\n","import React from 'react';\nimport ReactDOM from 'react-dom';\nimport { ErrorBoundary } from 'react-error-boundary';\nimport { CookiesProvider } from 'react-cookie';\nimport './index.css';\n\n// Pages\nimport Error from './_pages/error.page';\nimport App from './app';\n\n// Context\nimport { DataProvider } from './_contexts/data.context';\n\nconst ErrorFallback = ({ error, }) => ;\n\nReactDOM.render(\n { }} >\n \n \n \n \n \n \n , document.getElementById('root'));\n"],"sourceRoot":""}