{"version":3,"sources":["webpack:///./app/javascript/src/mixins/init_evaporate.js","webpack:///./app/javascript/src/vue_shared/components/RequestFieldInput.vue?a169","webpack:///./app/javascript/src/vue_shared/types/request_fields.ts","webpack:///./app/javascript/src/vue_shared/components/RequestFieldInput.vue?0cae","webpack:///./app/javascript/src/vue_shared/components/RequestFieldInput.vue","webpack:///./app/javascript/src/pages/create_request/components/create_request.vue?2f14","webpack:///./app/javascript/src/pages/create_request/components/create_request.vue?623b","webpack:///./app/javascript/src/pages/create_request/components/create_request.vue?6e3a","webpack:///./app/javascript/src/pages/create_request/components/create_request.vue"],"names":["methods","setupEvaporateFileUploader","_this","Evaporate","create","aws_key","process","bucket","awsRegion","signerUrl","awsSignatureVersion","partSize","sendCanonicalRequestToSignerUrl","onlyRetryForSameFileName","computeContentMd5","mockLocalStorage","cryptoMd5Method","data","AWS","util","crypto","md5","cryptoHexEncodedHash256","sha256","then","evaporateResponse","catch","e","nrError","Error","cause","NrSentry","captureError","FieldType","_hoisted_1","key","class","_hoisted_2","__name","props","definition","modelValue","emits","setup","__props","__emit","emit","typedProps","value","field_type","Text","type_settings","Checkbox","Array","isArray","noLabel","hideLabel","labelText","isChecked","option","currentlyChecked","some","checked","uuid","isCheckboxValid","isMandatory","length","val","id","immediate","handleFormInputValidation","isValid","_ctx","_cache","type","fieldValue","tag","isTextArea","label","placeholder","placeholderText","help","helperText","required","maxLength","characterLimitMax","toString","minLength","characterLimitMin","withTooltip","tooltipText","iconTooltipText","onOnValidate","options","name","alreadyChecked","selectedOptions","filter","other","checkOption","__exports__","_hoisted_3","_hoisted_4","_hoisted_5","_hoisted_6","_hoisted_7","_hoisted_8","_hoisted_9","_hoisted_10","_hoisted_11","_hoisted_12","_hoisted_13","_hoisted_14","_hoisted_15","_hoisted_16","_hoisted_17","_hoisted_18","_hoisted_19","_hoisted_20","_hoisted_21","_hoisted_22","_hoisted_23","_hoisted_24","_hoisted_25","_hoisted_26","_hoisted_27","_hoisted_28","_hoisted_29","_hoisted_30","_hoisted_31","_hoisted_32","_hoisted_33","_hoisted_34","_hoisted_35","_hoisted_36","_hoisted_37","_hoisted_38","_hoisted_39","_hoisted_40","for","_hoisted_41","_hoisted_42","_hoisted_43","selected","_hoisted_44","_hoisted_45","_hoisted_46","_hoisted_47","_hoisted_48","_hoisted_49","_hoisted_50","_hoisted_51","_hoisted_52","_hoisted_53","_hoisted_54","_hoisted_55","_hoisted_56","_hoisted_57","_hoisted_58","_hoisted_59","_hoisted_60","EMAIL_REGEX","mixins","components","DocumentUploadModal","NrIcon","NrSelect","NrFormInput","NrFormSelect","NrButton","NrTooltip","NrDatepicker","RequestFieldInput","showNoRequesterEmailModal","isMakingRequest","invisibleCaptcha","dateReceived","Date","departmentSearchTerm","documentsToAdd","formats","formatReceived","embargoVisibilityTip","emailDisabled","emailNotice","keywordAlerts","requestText","isRequesterValid","email","phone","address","city","state","zip","isRequestFieldsValid","requester","company","selectedDepartments","selectedFolder","showUploadModal","states","termsAndConditionsChecked","uploadedDocuments","requestVisibility","isRequesterFieldsDisabled","requestFields","mounted","this","getNewRequestData","handleRequestInput","parseQueryParams","computed","account","currentUser","showDepartments","$can","show_dept_select","departmentRequired","require_department","departments","sidebarRequestText","sidebar_request_text","subheader","request_page_subheader","termsAndConditions","terms_and_conditions","requesterRequired","required_fields","defaultVisibility","visibility_default","showRequester","show_requester","usStates","map","isRequesterFieldsValid","Object","keys","every","hasInvalidRequestFields","values","disabledCreate","selectedDeptIds","trim","termsAndConditionsRequired","noDeptsSelected","multipleDeptSelection","department","formatedFormData","phone_number","zipcode","request_date","request_submit_type_id","visibility","request_text","documents","request_field_values","field","request_field_version_id","version_id","folder","folder_name","request","department_ids","get","set","visibilityTips","restricted_visibilities_feature_flag","tip","join","visibilities","isSignedIn","canManageDocuments","s3Bucket","departmentSelectionText","isOptional","createRequestClassnames","handleCreateRequestByRole","no_email","createRequest","toggleNoRequesterEmailModal","handleRequestFieldValid","fieldId","handleRequesterInputValidState","validState","assign","validateEmailInput","input","test","http","pretty_id","window","location","href","err","response","error","errorMessage","$toasted","handleEmailInput","handleEmailCheck","encodeURIComponent","accountUser","enabled","setRequesterInfo","console","info","handleFolderSelection","names","pop","text","search_text","handleDocumentUploads","document","push","handleDocumentRemoveClick","assetUrl","url","success","handleUploadModalClick","toggleUploadModal","undefined","embargo_visibility_tooltip","initialRequestFieldValid","parsedRequestFields","request_fields","forEach","email_or_name","handleSaveDocumentsToRequest","handleDepartmentSelectionEvent","eventType","$route","query","deptId","dept","find","formatDate","date","watch","next","_prev","disabled","$props","$setup","$data","$options","_component_NrFormInput","_component_nr_editor","_component_NrIcon","_component_NrButton","_component_NrTooltip","_component_NrSelect","_component_RequestFieldInput","_component_NrFormSelect","_component_NrDatepicker","_component_nr_documentuploadmodal","_component_nr_modal","innerHTML","onSubmit","$event","bulletList","orderedList","autofocus","rows","onInput","alert","index","variant","title","onClick","default","_","onSearch","multiple","position","validations","message","validate","onBlur","readonly","maxDate","trigger","format","show","folders","isModalActive","onOnCloseModal","onOnFileUploadComplete","onOnSubmit","onSelectedFolder","secondaryButtonText","primaryButtonText","hasSecondaryButton","onOnSecondaryClick","onOnCloseClick","onOnPrimaryClick"],"mappings":"gHAAA,mDAIe,KACbA,QAAS,CACPC,2BAA0B,WAAI,IAADC,EAAA,KAC3BC,IAAUC,OAAO,CACfC,QAASC,uBACTC,OAAQD,iBACRE,UAAWF,YACXG,UAAW,iBACXC,oBAAqB,IAErBC,SAAU,SACVC,iCAAiC,EACjCC,0BAA0B,EAC1BC,mBAAmB,EACnBC,kBAAkB,EAClBC,gBAAiB,SAACC,GAChB,OAAOC,IAAIC,KAAKC,OAAOC,IAAIJ,EAAM,SACnC,EACAK,wBAAyB,SAACL,GACxB,OAAOC,IAAIC,KAAKC,OAAOG,OAAON,EAAM,MACtC,IAECO,MAAK,SAACP,GAELf,EAAKuB,kBAAoBR,CAC3B,IACCS,OAAM,SAACC,GACN,IAAMC,EAAU,IAAIC,MAAM,0BAA2B,CACnDC,MAAO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Be,Y","file":"js/CreateRequestPage-c2b3d6313e8662cff59e.chunk.js","sourcesContent":["import Evaporate from 'evaporate'\nimport AWS from 'aws-sdk/global'\nimport NrSentry from '../utils/nr_sentry'\n\nexport default {\n methods: {\n setupEvaporateFileUploader() {\n Evaporate.create({\n aws_key: process.env.S3_MULTIPART_UPLOAD_KEY_ID, // Required\n bucket: process.env.S3_BUCKET, // Required\n awsRegion: process.env.S3_AWS_REGION, // Defaults to us-east-1\n signerUrl: '/aws_signature', // Required\n awsSignatureVersion: '4',\n // partSize - 20 MB per part. AWS's 10,000 part maximum means max upload size is 195 GB.\n partSize: 20 * 1024 * 1024,\n sendCanonicalRequestToSignerUrl: true,\n onlyRetryForSameFileName: true,\n computeContentMd5: true,\n mockLocalStorage: true,\n cryptoMd5Method: (data) => {\n return AWS.util.crypto.md5(data, 'base64')\n },\n cryptoHexEncodedHash256: (data) => {\n return AWS.util.crypto.sha256(data, 'hex')\n }\n })\n .then((data) => {\n // set state so we know Evaporate.js is ready to upload docs to s3\n this.evaporateResponse = data\n })\n .catch((e) => {\n const nrError = new Error('Evaporate.create failed', {\n cause: e\n })\n NrSentry.captureError(nrError)\n })\n }\n }\n}\n","export * from \"-!../../../../../node_modules/mini-css-extract-plugin/dist/loader.js!../../../../../node_modules/css-loader/dist/cjs.js??ref--7-1!../../../../../node_modules/vue-loader/dist/stylePostLoader.js!../../../../../node_modules/postcss-loader/src/index.js??ref--7-2!../../../../../node_modules/sass-loader/dist/cjs.js??ref--7-3!../../../../../node_modules/vue-loader/dist/index.js??ref--21-0!./RequestFieldInput.vue?vue&type=style&index=0&id=ee81d586&scoped=true&lang=scss\"","export enum FieldType {\n Text = 'text',\n Checkbox = 'checkbox'\n}\n\nexport type RequestFieldValue = string\n\nexport interface TextSettings {\n isMandatory: boolean\n labelText: string | null\n hideLabel: boolean\n placeholderText: string | null\n helperText: string | null\n tooltipText: string | null\n isTextArea: boolean\n characterLimitMin: number | null\n characterLimitMax: number | null\n}\n\nexport interface CheckboxOption {\n uuid: string\n name: string\n}\n\nexport interface CheckboxSettings {\n isMandatory: boolean\n labelText: string | null\n hideLabel: boolean\n options: CheckboxOption[]\n}\n\nexport type TypedSettings =\n | {\n field_type: FieldType.Text // eslint-disable-line camelcase\n type_settings: TextSettings // eslint-disable-line camelcase\n }\n | {\n field_type: FieldType.Checkbox // eslint-disable-line camelcase\n type_settings: CheckboxSettings // eslint-disable-line camelcase\n }\n\nexport type FieldDefinition = {\n id: number\n version_id: number // eslint-disable-line camelcase\n visibility: string\n} & TypedSettings\n","import { defineComponent as _defineComponent } from 'vue'\nimport { unref as _unref, normalizeClass as _normalizeClass, openBlock as _openBlock, createBlock as _createBlock, createCommentVNode as _createCommentVNode, toDisplayString as _toDisplayString, createElementBlock as _createElementBlock, renderList as _renderList, Fragment as _Fragment, createVNode as _createVNode, pushScopeId as _pushScopeId, popScopeId as _popScopeId } from \"vue\"\n\nconst _withScopeId = n => (_pushScopeId(\"data-v-ee81d586\"),n=n(),_popScopeId(),n)\nconst _hoisted_1 = {\n key: 1,\n class: \"checkbox-group\"\n}\nconst _hoisted_2 = {\n key: 1,\n class: \"help is-danger\"\n}\n\nimport { computed, watch } from 'vue'\nimport { isEmpty } from 'lodash'\nimport NrFormInput from '@nextrequestco/components/src/components/NrFormInput/nr-form-input.vue'\nimport {\n CheckboxOption,\n CheckboxSettings,\n FieldDefinition,\n FieldType,\n RequestFieldValue,\n TextSettings\n} from '../types/request_fields'\n\ntype TypedProps =\n | {\n field_type: FieldType.Text // eslint-disable-line camelcase\n type_settings: TextSettings // eslint-disable-line camelcase\n modelValue: string\n }\n | {\n field_type: FieldType.Checkbox // eslint-disable-line camelcase\n type_settings: CheckboxSettings // eslint-disable-line camelcase\n modelValue: CheckboxOption[]\n }\n\n\nexport default /*#__PURE__*/_defineComponent({\n __name: 'RequestFieldInput',\n props: {\n definition: {},\n modelValue: {}\n },\n emits: [\"update:modelValue\", \"on-validate\"],\n setup(__props: any, { emit: __emit }) {\n\nconst props = __props\nconst emit = __emit\n\n// This combines the definition and modelValue into one type so that code can know the type of the `modelValue` depending on the `field_type`.\nconst typedProps = computed(() => {\n let value = props.modelValue\n\n switch (props.definition.field_type) {\n case FieldType.Text:\n value = value || ''\n if (typeof value !== 'string') {\n throw new Error('Unexpected type')\n }\n return {\n field_type: props.definition.field_type,\n modelValue: value || '',\n type_settings: props.definition.type_settings\n }\n case FieldType.Checkbox:\n value = value || []\n if (!Array.isArray(value)) {\n throw new Error('Unexpected type')\n }\n return {\n field_type: props.definition.field_type,\n modelValue: value,\n type_settings: props.definition.type_settings\n }\n default:\n throw new Error('Unexpected field type')\n }\n})\n\nconst noLabel = computed(\n () =>\n props.definition.type_settings.hideLabel ||\n isEmpty(props.definition.type_settings.labelText)\n)\n\nconst isChecked = (\n option: CheckboxOption,\n currentlyChecked: CheckboxOption[]\n) => {\n return currentlyChecked.some((checked) => checked.uuid === option.uuid)\n}\n\nconst checkOption = (\n option: CheckboxOption,\n checked: boolean,\n currentlyChecked: CheckboxOption[]\n) => {\n const alreadyChecked = isChecked(option, currentlyChecked)\n if (alreadyChecked && !checked) {\n const selectedOptions: CheckboxOption[] = currentlyChecked.filter(\n (other: CheckboxOption) => other.uuid !== option.uuid\n )\n emit('update:modelValue', selectedOptions)\n } else if (!alreadyChecked && checked) {\n const selectedOptions: CheckboxOption[] = [\n option,\n ...(currentlyChecked || [])\n ]\n emit('update:modelValue', selectedOptions)\n }\n}\nconst isCheckboxValid = computed(() => {\n return (\n !typedProps.value.type_settings.isMandatory ||\n (typedProps.value.modelValue && typedProps.value.modelValue.length > 0)\n )\n})\n\nwatch(\n isCheckboxValid,\n (val) => {\n if (typedProps.value.field_type === 'checkbox') {\n emit('on-validate', props.definition.id, val)\n }\n },\n { immediate: true }\n)\n\nconst handleFormInputValidation = (isValid: boolean) => {\n emit('on-validate', props.definition.id, isValid)\n}\n\nreturn (_ctx: any,_cache: any) => {\n return (_openBlock(), _createElementBlock(_Fragment, null, [\n (typedProps.value.field_type === _unref(FieldType).Text)\n ? (_openBlock(), _createBlock(NrFormInput, {\n key: 0,\n type: \"text\",\n modelValue: typedProps.value.modelValue,\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = \n (fieldValue) => emit('update:modelValue', fieldValue)\n ),\n tag: typedProps.value.type_settings.isTextArea ? 'textarea' : 'input',\n label: typedProps.value.type_settings.labelText,\n hideLabel: noLabel.value,\n class: _normalizeClass(noLabel.value ? 'request-field-no-label' : null),\n placeholder: typedProps.value.type_settings.placeholderText,\n help: typedProps.value.type_settings.helperText,\n required: typedProps.value.type_settings.isMandatory,\n maxLength: typedProps.value.type_settings.characterLimitMax?.toString(),\n minLength: typedProps.value.type_settings.characterLimitMin?.toString(),\n withTooltip: !_unref(isEmpty)(typedProps.value.type_settings.tooltipText),\n iconTooltipText: typedProps.value.type_settings.tooltipText,\n onOnValidate: handleFormInputValidation\n }, null, 8, [\"modelValue\", \"tag\", \"label\", \"hideLabel\", \"class\", \"placeholder\", \"help\", \"required\", \"maxLength\", \"minLength\", \"withTooltip\", \"iconTooltipText\"]))\n : _createCommentVNode(\"\", true),\n (typedProps.value.field_type === _unref(FieldType).Checkbox)\n ? (_openBlock(), _createElementBlock(\"fieldset\", _hoisted_1, [\n (typedProps.value.type_settings.labelText)\n ? (_openBlock(), _createElementBlock(\"legend\", {\n key: 0,\n class: _normalizeClass(noLabel.value ? 'is-sr-only' : 'checkbox-header')\n }, _toDisplayString(typedProps.value.type_settings.labelText) + \" \" + _toDisplayString(typedProps.value.type_settings.isMandatory ? '*' : ''), 3))\n : _createCommentVNode(\"\", true),\n (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(typedProps.value.type_settings.options, (option) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n key: option.uuid,\n class: \"checkbox-item\"\n }, [\n _createVNode(NrFormInput, {\n type: \"checkbox\",\n label: option.name,\n modelValue: isChecked(option, typedProps.value.modelValue),\n \"onUpdate:modelValue\": \n (checked) =>\n checkOption(option, checked, typedProps.value.modelValue)\n \n }, null, 8, [\"label\", \"modelValue\", \"onUpdate:modelValue\"])\n ]))\n }), 128)),\n (!isCheckboxValid.value)\n ? (_openBlock(), _createElementBlock(\"p\", _hoisted_2, \" At least one option must be selected. \"))\n : _createCommentVNode(\"\", true)\n ]))\n : _createCommentVNode(\"\", true)\n ], 64))\n}\n}\n\n})","import script from \"./RequestFieldInput.vue?vue&type=script&setup=true&lang=ts\"\nexport * from \"./RequestFieldInput.vue?vue&type=script&setup=true&lang=ts\"\n\nimport \"./RequestFieldInput.vue?vue&type=style&index=0&id=ee81d586&scoped=true&lang=scss\"\n\nimport exportComponent from \"/app/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['__scopeId',\"data-v-ee81d586\"]])\n\nexport default __exports__","export * from \"-!../../../../../../node_modules/mini-css-extract-plugin/dist/loader.js!../../../../../../node_modules/css-loader/dist/cjs.js??ref--7-1!../../../../../../node_modules/vue-loader/dist/stylePostLoader.js!../../../../../../node_modules/postcss-loader/src/index.js??ref--7-2!../../../../../../node_modules/sass-loader/dist/cjs.js??ref--7-3!../../../../../../node_modules/vue-loader/dist/index.js??ref--21-0!./create_request.vue?vue&type=style&index=0&id=073fb80b&lang=scss\"","import { createElementVNode as _createElementVNode, resolveComponent as _resolveComponent, createVNode as _createVNode, renderList as _renderList, Fragment as _Fragment, openBlock as _openBlock, createElementBlock as _createElementBlock, toDisplayString as _toDisplayString, withModifiers as _withModifiers, withCtx as _withCtx, createBlock as _createBlock, createCommentVNode as _createCommentVNode, createTextVNode as _createTextVNode, vModelSelect as _vModelSelect, withDirectives as _withDirectives, normalizeClass as _normalizeClass } from \"vue\"\n\nconst _hoisted_1 = {\n id: \"skip-to-main-content\",\n class: \"create-request-page container mb-6\"\n}\nconst _hoisted_2 = { class: \"section\" }\nconst _hoisted_3 = { class: \"columns is-variable\" }\nconst _hoisted_4 = { class: \"column is-7\" }\nconst _hoisted_5 = /*#__PURE__*/_createElementVNode(\"h1\", { class: \"is-uppercase is-size-5 has-text-weight-bold\" }, \" Request a public record \", -1)\nconst _hoisted_6 = [\"innerHTML\"]\nconst _hoisted_7 = { class: \"block\" }\nconst _hoisted_8 = { class: \"field\" }\nconst _hoisted_9 = { \"aria-live\": \"polite\" }\nconst _hoisted_10 = [\"innerHTML\"]\nconst _hoisted_11 = { class: \"field\" }\nconst _hoisted_12 = { class: \"document-upload\" }\nconst _hoisted_13 = {\n key: 0,\n class: \"document-upload__list\"\n}\nconst _hoisted_14 = /*#__PURE__*/_createElementVNode(\"p\", null, \"Upload and attach files (optional)\", -1)\nconst _hoisted_15 = {\n key: 0,\n class: \"field\"\n}\nconst _hoisted_16 = {\n key: 0,\n class: \"block\"\n}\nconst _hoisted_17 = /*#__PURE__*/_createElementVNode(\"h2\", { class: \"is-uppercase is-size-5 has-text-weight-bold\" }, \" Requester information \", -1)\nconst _hoisted_18 = { class: \"field\" }\nconst _hoisted_19 = { class: \"columns is-variable\" }\nconst _hoisted_20 = { class: \"column\" }\nconst _hoisted_21 = { class: \"column is-3\" }\nconst _hoisted_22 = { class: \"column is-3\" }\nconst _hoisted_23 = {\n key: 1,\n class: \"block\"\n}\nconst _hoisted_24 = /*#__PURE__*/_createElementVNode(\"h2\", { class: \"is-uppercase is-size-5 has-text-weight-bold\" }, \" Your information \", -1)\nconst _hoisted_25 = { class: \"columns is-variable\" }\nconst _hoisted_26 = { class: \"column\" }\nconst _hoisted_27 = { class: \"column is-3\" }\nconst _hoisted_28 = { class: \"column is-3\" }\nconst _hoisted_29 = {\n key: 2,\n class: \"block\"\n}\nconst _hoisted_30 = /*#__PURE__*/_createElementVNode(\"h2\", { class: \"is-size-5 has-text-weight-bold\" }, \" Terms and Conditions \", -1)\nconst _hoisted_31 = [\"innerHTML\"]\nconst _hoisted_32 = /*#__PURE__*/_createElementVNode(\"hr\", null, null, -1)\nconst _hoisted_33 = { class: \"field\" }\nconst _hoisted_34 = {\n key: 3,\n class: \"block\"\n}\nconst _hoisted_35 = /*#__PURE__*/_createElementVNode(\"h2\", { class: \"is-uppercase is-size-5 has-text-weight-bold\" }, \" Additional request information \", -1)\nconst _hoisted_36 = { class: \"columns is-variable\" }\nconst _hoisted_37 = { class: \"column is-4\" }\nconst _hoisted_38 = { class: \"column is-4\" }\nconst _hoisted_39 = { class: \"field\" }\nconst _hoisted_40 = /*#__PURE__*/_createElementVNode(\"label\", {\n class: \"label\",\n for: \"formatReceived\"\n}, \" Format received \", -1)\nconst _hoisted_41 = { class: \"control\" }\nconst _hoisted_42 = { class: \"select\" }\nconst _hoisted_43 = /*#__PURE__*/_createElementVNode(\"option\", {\n selected: \"\",\n value: \"\"\n}, \"Select\", -1)\nconst _hoisted_44 = [\"value\"]\nconst _hoisted_45 = {\n key: 0,\n class: \"column is-4\"\n}\nconst _hoisted_46 = { class: \"field\" }\nconst _hoisted_47 = {\n class: \"label\",\n for: \"visibility\"\n}\nconst _hoisted_48 = [\"innerHTML\"]\nconst _hoisted_49 = { class: \"control\" }\nconst _hoisted_50 = { class: \"select\" }\nconst _hoisted_51 = [\"value\", \"selected\"]\nconst _hoisted_52 = /*#__PURE__*/_createElementVNode(\"div\", null, null, -1)\nconst _hoisted_53 = { class: \"block mt-6\" }\nconst _hoisted_54 = /*#__PURE__*/_createElementVNode(\"div\", { class: \"block\" }, [\n /*#__PURE__*/_createElementVNode(\"p\", null, \"* Indicates required field\")\n], -1)\nconst _hoisted_55 = { class: \"column is-4 is-offset-1\" }\nconst _hoisted_56 = { class: \"notification content\" }\nconst _hoisted_57 = [\"innerHTML\"]\nconst _hoisted_58 = /*#__PURE__*/_createElementVNode(\"h3\", { class: \"is-size-5\" }, \"Tips\", -1)\nconst _hoisted_59 = /*#__PURE__*/_createElementVNode(\"ul\", null, [\n /*#__PURE__*/_createElementVNode(\"li\", null, \" Don't put personal information, like your social security number in your public request. \"),\n /*#__PURE__*/_createElementVNode(\"li\", null, \" If you don't know the name of the record, describe the information you believe is contained in it. \")\n], -1)\nconst _hoisted_60 = /*#__PURE__*/_createElementVNode(\"div\", { class: \"content\" }, [\n /*#__PURE__*/_createElementVNode(\"p\", null, \" Are you sure? If you don't provide an email address, you won't be able to: \"),\n /*#__PURE__*/_createElementVNode(\"ul\", null, [\n /*#__PURE__*/_createElementVNode(\"li\", null, \"receive automatic email updates about request status\"),\n /*#__PURE__*/_createElementVNode(\"li\", null, \"see the request status here whenever you choose\"),\n /*#__PURE__*/_createElementVNode(\"li\", null, \" easily download your documents from this site unless this request is made available to the general public \"),\n /*#__PURE__*/_createElementVNode(\"li\", null, \" have your contact information automatically added to any future requests \")\n ]),\n /*#__PURE__*/_createElementVNode(\"p\", null, \" If you wish to continue anyway without providing an email address, click \\\"Continue\\\". \")\n], -1)\n\nexport function render(_ctx: any,_cache: any,$props: any,$setup: any,$data: any,$options: any) {\n const _component_NrFormInput = _resolveComponent(\"NrFormInput\")!\n const _component_nr_editor = _resolveComponent(\"nr-editor\")!\n const _component_NrIcon = _resolveComponent(\"NrIcon\")!\n const _component_NrButton = _resolveComponent(\"NrButton\")!\n const _component_NrTooltip = _resolveComponent(\"NrTooltip\")!\n const _component_NrSelect = _resolveComponent(\"NrSelect\")!\n const _component_RequestFieldInput = _resolveComponent(\"RequestFieldInput\")!\n const _component_NrFormSelect = _resolveComponent(\"NrFormSelect\")!\n const _component_NrDatepicker = _resolveComponent(\"NrDatepicker\")!\n const _component_nr_documentuploadmodal = _resolveComponent(\"nr-documentuploadmodal\")!\n const _component_nr_modal = _resolveComponent(\"nr-modal\")!\n\n return (_openBlock(), _createElementBlock(\"main\", _hoisted_1, [\n _createElementVNode(\"section\", _hoisted_2, [\n _createElementVNode(\"div\", _hoisted_3, [\n _createElementVNode(\"div\", _hoisted_4, [\n _hoisted_5,\n _createElementVNode(\"div\", {\n innerHTML: _ctx.subheader,\n class: \"content\"\n }, null, 8, _hoisted_6),\n _createElementVNode(\"form\", {\n class: \"block\",\n onSubmit: _cache[38] || (_cache[38] = _withModifiers(() => {}, [\"prevent\",\"stop\"]))\n }, [\n _createElementVNode(\"div\", _hoisted_7, [\n _createVNode(_component_NrFormInput, {\n modelValue: _ctx.invisibleCaptcha,\n \"onUpdate:modelValue\": _cache[0] || (_cache[0] = ($event: any) => ((_ctx.invisibleCaptcha) = $event)),\n name: \"description\",\n class: \"description\",\n label: \"Description\"\n }, null, 8, [\"modelValue\"]),\n _createElementVNode(\"div\", _hoisted_8, [\n _createVNode(_component_nr_editor, {\n bulletList: \"\",\n label: \"Request description\",\n orderedList: \"\",\n autofocus: \"\",\n placeholder: \"Enter your request - please include all information that could help fulfill this request.\",\n rows: 12,\n \"data-id\": \"request_text\",\n modelValue: _ctx.requestText,\n \"onUpdate:modelValue\": _cache[1] || (_cache[1] = ($event: any) => ((_ctx.requestText) = $event)),\n onInput: _ctx.handleRequestInput\n }, null, 8, [\"modelValue\", \"onInput\"]),\n _createElementVNode(\"div\", _hoisted_9, [\n (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.keywordAlerts, (alert, index) => {\n return (_openBlock(), _createElementBlock(\"div\", {\n innerHTML: alert,\n key: `request-alert-${index}`,\n class: \"notification is-warning\"\n }, null, 8, _hoisted_10))\n }), 128))\n ])\n ]),\n _createElementVNode(\"div\", _hoisted_11, [\n _createElementVNode(\"div\", _hoisted_12, [\n (!!_ctx.documentsToAdd.length)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_13, [\n (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.documentsToAdd, (document) => {\n return (_openBlock(), _createBlock(_component_NrButton, {\n variant: \"minimal-neutral\",\n class: \"has-icon document-upload__list-item\",\n \"aria-label\": `Remove document: ${document.title}`,\n key: document.id,\n onClick: _withModifiers(($event: any) => (_ctx.handleDocumentRemoveClick(document.url)), [\"prevent\"])\n }, {\n default: _withCtx(() => [\n _createElementVNode(\"span\", null, _toDisplayString(document.title), 1),\n _createVNode(_component_NrIcon, {\n name: \"times\",\n class: \"m-left-8\"\n })\n ]),\n _: 2\n }, 1032, [\"aria-label\", \"onClick\"]))\n }), 128))\n ]))\n : _createCommentVNode(\"\", true),\n _hoisted_14,\n (_ctx.isSignedIn)\n ? (_openBlock(), _createBlock(_component_NrButton, {\n key: 1,\n onClick: _withModifiers(_ctx.handleUploadModalClick, [\"prevent\"]),\n variant: \"filled-neutral\"\n }, {\n default: _withCtx(() => [\n _createTextVNode(\" Choose file(s) \")\n ]),\n _: 1\n }, 8, [\"onClick\"]))\n : (_openBlock(), _createBlock(_component_NrTooltip, {\n key: 2,\n label: \"Need to upload supporting documentation? If you have a NextRequest account for this agency, sign in to enable the upload button. Otherwise, finish making your request. You will be prompted to set up a your new user account which will allow you to upload any supporting documents on the request after it has been submitted.\"\n }, {\n default: _withCtx(() => [\n _createVNode(_component_NrButton, {\n disabled: true,\n variant: \"filled-neutral\"\n }, {\n default: _withCtx(() => [\n _createTextVNode(\" Choose file(s) \")\n ]),\n _: 1\n })\n ]),\n _: 1\n }))\n ])\n ]),\n (_ctx.showDepartments)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_15, [\n _createVNode(_component_NrSelect, {\n label: \"name\",\n placeholder: _ctx.departmentSelectionText,\n modelValue: _ctx.selectedDepartments,\n \"onUpdate:modelValue\": _cache[2] || (_cache[2] = ($event: any) => ((_ctx.selectedDepartments) = $event)),\n onInput: _cache[3] || (_cache[3] = ($event: any) => (_ctx.handleDepartmentSelectionEvent('input', $event))),\n onSearch: _cache[4] || (_cache[4] = ($event: any) => (_ctx.handleDepartmentSelectionEvent('typing', $event))),\n options: _ctx.departments,\n required: !!_ctx.departmentRequired,\n multiple: _ctx.multipleDeptSelection,\n class: \"department-select\"\n }, {\n label: _withCtx(() => [\n _createTextVNode(_toDisplayString(_ctx.departmentRequired) + \" Department\" + _toDisplayString(_ctx.multipleDeptSelection ? 's' : ''), 1)\n ]),\n _: 1\n }, 8, [\"placeholder\", \"modelValue\", \"options\", \"required\", \"multiple\"])\n ]))\n : _createCommentVNode(\"\", true),\n (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.requestFields, (field) => {\n return (_openBlock(), _createBlock(_component_RequestFieldInput, {\n definition: field.definition,\n key: field.definition.id,\n modelValue: field.value,\n \"onUpdate:modelValue\": ($event: any) => ((field.value) = $event),\n onOnValidate: _ctx.handleRequestFieldValid\n }, null, 8, [\"definition\", \"modelValue\", \"onUpdate:modelValue\", \"onOnValidate\"]))\n }), 128))\n ]),\n (_ctx.$can('read', 'staff_only_items'))\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_16, [\n _hoisted_17,\n _createVNode(_component_NrTooltip, {\n position: \"right\",\n label: \"Personal information is visible only to staff by default,\\n but requests are part of the public record and the\\n information may be released in response to a public\\n records request.\"\n }, {\n default: _withCtx(() => [\n _createTextVNode(\" Who can see this information? \"),\n _createVNode(_component_NrIcon, {\n class: \"info-circle-icon request-personal-information-icon\",\n name: \"info-circle\"\n })\n ]),\n _: 1\n }),\n _createVNode(_component_NrFormInput, {\n label: \"Email\",\n type: \"email\",\n name: \"email\",\n modelValue: _ctx.requester.email,\n \"onUpdate:modelValue\": _cache[5] || (_cache[5] = ($event: any) => ((_ctx.requester.email) = $event)),\n help: _ctx.emailNotice,\n disabled: _ctx.emailDisabled,\n validations: {\n email: {\n message: 'Email must be valid.',\n validate: _ctx.validateEmailInput\n }\n },\n onBlur: _ctx.handleEmailCheck,\n onInput: _ctx.handleEmailInput,\n onOnValidate: _cache[6] || (_cache[6] = ($event: any) => (_ctx.handleRequesterInputValidState('email', $event)))\n }, null, 8, [\"modelValue\", \"help\", \"disabled\", \"validations\", \"onBlur\", \"onInput\"]),\n _createElementVNode(\"div\", _hoisted_18, [\n _createVNode(_component_NrFormInput, {\n type: \"checkbox\",\n label: \"No email address available\",\n name: \"no_email\",\n modelValue: _ctx.emailDisabled,\n \"onUpdate:modelValue\": _cache[7] || (_cache[7] = ($event: any) => ((_ctx.emailDisabled) = $event))\n }, null, 8, [\"modelValue\"])\n ]),\n _createVNode(_component_NrFormInput, {\n label: \"Name\",\n name: \"name\",\n modelValue: _ctx.requester.name,\n \"onUpdate:modelValue\": _cache[8] || (_cache[8] = ($event: any) => ((_ctx.requester.name) = $event)),\n disabled: _ctx.isRequesterFieldsDisabled,\n required: !!_ctx.requesterRequired,\n onOnValidate: _cache[9] || (_cache[9] = ($event: any) => (_ctx.handleRequesterInputValidState('name', $event)))\n }, null, 8, [\"modelValue\", \"disabled\", \"required\"]),\n _createVNode(_component_NrFormInput, {\n label: \"Phone\",\n name: \"phone_number\",\n modelValue: _ctx.requester.phone,\n \"onUpdate:modelValue\": _cache[10] || (_cache[10] = ($event: any) => ((_ctx.requester.phone) = $event)),\n disabled: _ctx.isRequesterFieldsDisabled,\n required: !!_ctx.requesterRequired,\n onOnValidate: _cache[11] || (_cache[11] = ($event: any) => (_ctx.handleRequesterInputValidState('phone', $event)))\n }, null, 8, [\"modelValue\", \"disabled\", \"required\"]),\n _createVNode(_component_NrFormInput, {\n label: \"Street address\",\n name: \"street_address\",\n tag: \"textarea\",\n modelValue: _ctx.requester.address,\n \"onUpdate:modelValue\": _cache[12] || (_cache[12] = ($event: any) => ((_ctx.requester.address) = $event)),\n disabled: _ctx.isRequesterFieldsDisabled,\n required: !!_ctx.requesterRequired,\n onOnValidate: _cache[13] || (_cache[13] = ($event: any) => (\n _ctx.handleRequesterInputValidState('address', $event)\n ))\n }, null, 8, [\"modelValue\", \"disabled\", \"required\"]),\n _createElementVNode(\"div\", _hoisted_19, [\n _createElementVNode(\"div\", _hoisted_20, [\n _createVNode(_component_NrFormInput, {\n label: \"City\",\n name: \"city\",\n modelValue: _ctx.requester.city,\n \"onUpdate:modelValue\": _cache[14] || (_cache[14] = ($event: any) => ((_ctx.requester.city) = $event)),\n disabled: _ctx.isRequesterFieldsDisabled,\n required: !!_ctx.requesterRequired,\n onOnValidate: _cache[15] || (_cache[15] = ($event: any) => (\n _ctx.handleRequesterInputValidState('city', $event)\n ))\n }, null, 8, [\"modelValue\", \"disabled\", \"required\"])\n ]),\n _createElementVNode(\"div\", _hoisted_21, [\n _createVNode(_component_NrFormSelect, {\n label: \"State\",\n name: \"state\",\n \"include-blank\": \"\",\n modelValue: _ctx.requester.state,\n \"onUpdate:modelValue\": _cache[16] || (_cache[16] = ($event: any) => ((_ctx.requester.state) = $event)),\n disabled: _ctx.isRequesterFieldsDisabled,\n required: !!_ctx.requesterRequired,\n options: _ctx.usStates\n }, null, 8, [\"modelValue\", \"disabled\", \"required\", \"options\"])\n ]),\n _createElementVNode(\"div\", _hoisted_22, [\n _createVNode(_component_NrFormInput, {\n label: \"Zip\",\n name: \"zip\",\n modelValue: _ctx.requester.zip,\n \"onUpdate:modelValue\": _cache[17] || (_cache[17] = ($event: any) => ((_ctx.requester.zip) = $event)),\n disabled: _ctx.isRequesterFieldsDisabled,\n required: !!_ctx.requesterRequired,\n onOnValidate: _cache[18] || (_cache[18] = ($event: any) => (\n _ctx.handleRequesterInputValidState('zip', $event)\n ))\n }, null, 8, [\"modelValue\", \"disabled\", \"required\"])\n ])\n ]),\n _createVNode(_component_NrFormInput, {\n label: \"Company\",\n name: \"company\",\n modelValue: _ctx.requester.company,\n \"onUpdate:modelValue\": _cache[19] || (_cache[19] = ($event: any) => ((_ctx.requester.company) = $event)),\n disabled: _ctx.isRequesterFieldsDisabled\n }, null, 8, [\"modelValue\", \"disabled\"])\n ]))\n : (_openBlock(), _createElementBlock(\"div\", _hoisted_23, [\n _hoisted_24,\n _createVNode(_component_NrFormInput, {\n label: \"Email\",\n type: \"email\",\n name: \"email\",\n modelValue: _ctx.requester.email,\n \"onUpdate:modelValue\": _cache[20] || (_cache[20] = ($event: any) => ((_ctx.requester.email) = $event)),\n disabled: _ctx.isSignedIn && !_ctx.$can('read', 'staff_only_items'),\n readonly: _ctx.isSignedIn && !_ctx.$can('read', 'staff_only_items'),\n validations: {\n email: {\n message: 'Email must be valid.',\n validate: _ctx.validateEmailInput\n }\n },\n onOnValidate: _cache[21] || (_cache[21] = ($event: any) => (_ctx.handleRequesterInputValidState('email', $event)))\n }, null, 8, [\"modelValue\", \"disabled\", \"readonly\", \"validations\"]),\n _createVNode(_component_NrFormInput, {\n label: \"Name\",\n name: \"name\",\n modelValue: _ctx.requester.name,\n \"onUpdate:modelValue\": _cache[22] || (_cache[22] = ($event: any) => ((_ctx.requester.name) = $event)),\n required: !!_ctx.requesterRequired,\n onOnValidate: _cache[23] || (_cache[23] = ($event: any) => (_ctx.handleRequesterInputValidState('name', $event)))\n }, null, 8, [\"modelValue\", \"required\"]),\n _createVNode(_component_NrFormInput, {\n label: \"Phone\",\n name: \"phone_number\",\n modelValue: _ctx.requester.phone,\n \"onUpdate:modelValue\": _cache[24] || (_cache[24] = ($event: any) => ((_ctx.requester.phone) = $event)),\n required: !!_ctx.requesterRequired,\n onOnValidate: _cache[25] || (_cache[25] = ($event: any) => (_ctx.handleRequesterInputValidState('phone', $event)))\n }, null, 8, [\"modelValue\", \"required\"]),\n _createVNode(_component_NrFormInput, {\n label: \"Street address\",\n name: \"street_address\",\n tag: \"textarea\",\n modelValue: _ctx.requester.address,\n \"onUpdate:modelValue\": _cache[26] || (_cache[26] = ($event: any) => ((_ctx.requester.address) = $event)),\n required: !!_ctx.requesterRequired,\n onOnValidate: _cache[27] || (_cache[27] = ($event: any) => (\n _ctx.handleRequesterInputValidState('address', $event)\n ))\n }, null, 8, [\"modelValue\", \"required\"]),\n _createElementVNode(\"div\", _hoisted_25, [\n _createElementVNode(\"div\", _hoisted_26, [\n _createVNode(_component_NrFormInput, {\n label: \"City\",\n name: \"city\",\n modelValue: _ctx.requester.city,\n \"onUpdate:modelValue\": _cache[28] || (_cache[28] = ($event: any) => ((_ctx.requester.city) = $event)),\n required: !!_ctx.requesterRequired,\n onOnValidate: _cache[29] || (_cache[29] = ($event: any) => (\n _ctx.handleRequesterInputValidState('city', $event)\n ))\n }, null, 8, [\"modelValue\", \"required\"])\n ]),\n _createElementVNode(\"div\", _hoisted_27, [\n _createVNode(_component_NrFormSelect, {\n label: \"State\",\n name: \"state\",\n \"include-blank\": \"\",\n modelValue: _ctx.requester.state,\n \"onUpdate:modelValue\": _cache[30] || (_cache[30] = ($event: any) => ((_ctx.requester.state) = $event)),\n required: !!_ctx.requesterRequired,\n options: _ctx.usStates\n }, null, 8, [\"modelValue\", \"required\", \"options\"])\n ]),\n _createElementVNode(\"div\", _hoisted_28, [\n _createVNode(_component_NrFormInput, {\n label: \"Zip\",\n name: \"zip\",\n modelValue: _ctx.requester.zip,\n \"onUpdate:modelValue\": _cache[31] || (_cache[31] = ($event: any) => ((_ctx.requester.zip) = $event)),\n required: !!_ctx.requesterRequired,\n onOnValidate: _cache[32] || (_cache[32] = ($event: any) => (\n _ctx.handleRequesterInputValidState('zip', $event)\n ))\n }, null, 8, [\"modelValue\", \"required\"])\n ])\n ]),\n _createVNode(_component_NrFormInput, {\n label: \"Company\",\n name: \"company\",\n modelValue: _ctx.requester.company,\n \"onUpdate:modelValue\": _cache[33] || (_cache[33] = ($event: any) => ((_ctx.requester.company) = $event))\n }, null, 8, [\"modelValue\"])\n ])),\n (_ctx.termsAndConditionsRequired)\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_29, [\n _hoisted_30,\n _createElementVNode(\"div\", {\n class: \"terms-and-conditions content\",\n innerHTML: _ctx.termsAndConditions\n }, null, 8, _hoisted_31),\n _hoisted_32,\n _createElementVNode(\"div\", _hoisted_33, [\n _createVNode(_component_NrFormInput, {\n type: \"checkbox\",\n label: \"I acknowledge the above terms and conditions.*\",\n name: \"terms\",\n modelValue: _ctx.termsAndConditionsChecked,\n \"onUpdate:modelValue\": _cache[34] || (_cache[34] = ($event: any) => ((_ctx.termsAndConditionsChecked) = $event))\n }, null, 8, [\"modelValue\"])\n ])\n ]))\n : _createCommentVNode(\"\", true),\n (_ctx.$can('update', 'Request'))\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_34, [\n _hoisted_35,\n _createElementVNode(\"div\", _hoisted_36, [\n _createElementVNode(\"div\", _hoisted_37, [\n _createVNode(_component_NrDatepicker, {\n name: \"date\",\n modelValue: _ctx.dateReceived,\n \"onUpdate:modelValue\": _cache[35] || (_cache[35] = ($event: any) => ((_ctx.dateReceived) = $event)),\n maxDate: _ctx.formatDate(new Date())\n }, {\n label: _withCtx(() => [\n _createTextVNode(\"Date received\")\n ]),\n trigger: _withCtx(() => [\n _createVNode(_component_NrIcon, { name: \"calendar-alt\" })\n ]),\n _: 1\n }, 8, [\"modelValue\", \"maxDate\"])\n ]),\n _createElementVNode(\"div\", _hoisted_38, [\n _createElementVNode(\"div\", _hoisted_39, [\n _hoisted_40,\n _createElementVNode(\"div\", _hoisted_41, [\n _createElementVNode(\"div\", _hoisted_42, [\n _withDirectives(_createElementVNode(\"select\", {\n id: \"formatReceived\",\n name: \"format_received\",\n \"onUpdate:modelValue\": _cache[36] || (_cache[36] = ($event: any) => ((_ctx.formatReceived) = $event))\n }, [\n _hoisted_43,\n (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.formats, (format) => {\n return (_openBlock(), _createElementBlock(\"option\", {\n key: format.id,\n value: format.id\n }, _toDisplayString(format.name), 9, _hoisted_44))\n }), 128))\n ], 512), [\n [_vModelSelect, _ctx.formatReceived]\n ])\n ])\n ])\n ])\n ]),\n (_ctx.$can('publish', 'Request'))\n ? (_openBlock(), _createElementBlock(\"div\", _hoisted_45, [\n _createElementVNode(\"div\", _hoisted_46, [\n _createElementVNode(\"label\", _hoisted_47, [\n _createTextVNode(\" Visibility \"),\n _createVNode(_component_NrTooltip, { position: \"right\" }, {\n label: _withCtx(() => [\n _createElementVNode(\"p\", { innerHTML: _ctx.visibilityTips }, null, 8, _hoisted_48)\n ]),\n default: _withCtx(() => [\n _createVNode(_component_NrIcon, {\n class: \"info-circle-icon request-personal-information-icon\",\n name: \"info-circle\"\n })\n ]),\n _: 1\n })\n ]),\n _createElementVNode(\"div\", _hoisted_49, [\n _createElementVNode(\"div\", _hoisted_50, [\n _withDirectives(_createElementVNode(\"select\", {\n id: \"visibility\",\n name: \"visibility\",\n \"onUpdate:modelValue\": _cache[37] || (_cache[37] = ($event: any) => ((_ctx.visibility) = $event))\n }, [\n (_openBlock(true), _createElementBlock(_Fragment, null, _renderList(_ctx.visibilities, (visibility) => {\n return (_openBlock(), _createElementBlock(\"option\", {\n key: visibility.name,\n value: visibility.value,\n selected: \n _ctx.defaultVisibility === visibility.value\n \n }, _toDisplayString(visibility.name), 9, _hoisted_51))\n }), 128))\n ], 512), [\n [_vModelSelect, _ctx.visibility]\n ])\n ])\n ])\n ])\n ]))\n : _createCommentVNode(\"\", true)\n ]),\n _hoisted_52\n ]))\n : _createCommentVNode(\"\", true),\n _createElementVNode(\"div\", _hoisted_53, [\n _createVNode(_component_NrButton, {\n variant: \"filled-neutral\",\n class: _normalizeClass(_ctx.createRequestClassnames),\n disabled: _ctx.disabledCreate,\n onClick: _ctx.handleCreateRequestByRole\n }, {\n default: _withCtx(() => [\n _createTextVNode(\" Make request \")\n ]),\n _: 1\n }, 8, [\"class\", \"disabled\", \"onClick\"])\n ]),\n _hoisted_54\n ], 32)\n ]),\n _createElementVNode(\"div\", _hoisted_55, [\n _createElementVNode(\"aside\", _hoisted_56, [\n (!!_ctx.sidebarRequestText)\n ? (_openBlock(), _createElementBlock(\"div\", {\n key: 0,\n innerHTML: _ctx.sidebarRequestText\n }, null, 8, _hoisted_57))\n : (_openBlock(), _createElementBlock(_Fragment, { key: 1 }, [\n _hoisted_58,\n _hoisted_59\n ], 64))\n ])\n ])\n ]),\n _createVNode(_component_nr_documentuploadmodal, {\n show: _ctx.showUploadModal,\n account: _ctx.account,\n evaporateResponse: _ctx.evaporateResponse,\n folders: [],\n folder: _ctx.selectedFolder,\n isModalActive: _ctx.showUploadModal,\n \"s3-bucket\": _ctx.s3Bucket,\n \"uploaded-docs\": _ctx.uploadedDocuments,\n onOnCloseModal: _cache[39] || (_cache[39] = ($event: any) => (_ctx.toggleUploadModal(false))),\n onOnFileUploadComplete: _ctx.handleDocumentUploads,\n onOnSubmit: _ctx.handleSaveDocumentsToRequest,\n onSelectedFolder: _ctx.handleFolderSelection\n }, null, 8, [\"show\", \"account\", \"evaporateResponse\", \"folder\", \"isModalActive\", \"s3-bucket\", \"uploaded-docs\", \"onOnFileUploadComplete\", \"onOnSubmit\", \"onSelectedFolder\"])\n ]),\n _createVNode(_component_nr_modal, {\n title: \"No email entered\",\n secondaryButtonText: \"Cancel\",\n primaryButtonText: \"Continue\",\n hasSecondaryButton: true,\n show: _ctx.showNoRequesterEmailModal,\n onOnSecondaryClick: _cache[40] || (_cache[40] = ($event: any) => (_ctx.toggleNoRequesterEmailModal(false))),\n onOnCloseClick: _cache[41] || (_cache[41] = ($event: any) => (_ctx.toggleNoRequesterEmailModal(false))),\n onOnPrimaryClick: _ctx.createRequest\n }, {\n default: _withCtx(() => [\n _hoisted_60\n ]),\n _: 1\n }, 8, [\"show\", \"onOnPrimaryClick\"])\n ]))\n}","\nimport { defineComponent } from 'vue'\nimport { mapState } from 'vuex'\nimport { debounce, isEmpty } from 'lodash'\nimport { format as dateFormat } from 'date-fns'\nimport NrEditor from '@nextrequestco/components/src/components/NrEditor/nr-editor.vue'\nimport DocumentUploadModal from '@nextrequestco/components/src/components/DocumentUploadModal/DocumentUploadModal.vue'\nimport NrIcon from '@nextrequestco/components/src/components/NrIcon/NrIcon.vue'\nimport NrButton from '@nextrequestco/components/src/components/NrButton/nr-button.vue'\nimport NrTooltip from '@nextrequestco/components/src/components/NrTooltip/NrTooltip.vue'\nimport NrModal from '@nextrequestco/components/src/components/NrModal/nr-modal.vue'\nimport NrSelect from '@nextrequestco/components/src/components/NrSelect/nr-select.vue'\nimport NrFormInput from '@nextrequestco/components/src/components/NrFormInput/nr-form-input.vue'\nimport NrFormSelect from '@nextrequestco/components/src/components/NrFormSelect/nr-form-select'\nimport {\n State,\n RequestVisibilityValue,\n RequestVisibility,\n accountRequestVisibilities\n} from 'src/store/globalModule'\nimport * as http from '../../../vue_shared/http'\nimport setupEvaporateFileUploader from '../../../mixins/init_evaporate'\nimport NrDatepicker from '@nextrequestco/components/src/components/NrDatePicker/nr-datepicker.vue'\nimport RequestFieldInput from '../../../vue_shared/components/RequestFieldInput.vue'\nimport {\n FieldDefinition,\n RequestFieldValue\n} from '../../../vue_shared/types/request_fields'\n\ninterface NewRequestPrep {\n states: [string, string][]\n formats: { id: number; name: string }[]\n embargo_visibility_tooltip: string | undefined // eslint-disable-line camelcase\n request_fields: FieldDefinition[] // eslint-disable-line camelcase\n}\n\ninterface Document {\n id: number\n asset_url: string // eslint-disable-line camelcase\n [key: string]: unknown\n}\n\ninterface Requester {\n email?: string\n name?: string\n phone?: string\n address?: string\n city?: string\n state?: string\n zip?: string\n company?: string\n}\n\ninterface NewRequest {\n requester: Requester\n documents: object[]\n folder: string\n request: {\n request_text: string // eslint-disable-line camelcase\n request_date: string // eslint-disable-line camelcase\n request_submit_type_id: number // eslint-disable-line camelcase\n visibility: string\n department_ids: number[] // eslint-disable-line camelcase\n }\n}\n\ninterface AccountUser extends Requester {\n active: boolean\n enabled: boolean\n}\n\ninterface RequestField {\n definition: FieldDefinition\n value: RequestFieldValue | null\n // eslint-disable-next-line camelcase\n type_settings?: Record\n}\n\ninterface Data {\n showNoRequesterEmailModal: boolean\n isMakingRequest: boolean\n invisibleCaptcha: string\n dateReceived: string\n departmentSearchTerm: string\n documentsToAdd: Document[]\n embargoVisibilityTip: string | undefined\n emailDisabled: boolean\n emailNotice: string\n evaporateResponse: object\n formats: []\n formatReceived: number | ''\n keywordAlerts: string[]\n requestText: string\n requester: Requester\n isRequesterValid: { [key: string]: boolean }\n isRequestFieldsValid: { [key: number]: boolean }\n selectedDepartments: []\n selectedFolder: object | null\n showUploadModal: boolean\n states: []\n termsAndConditionsChecked: boolean\n uploadedDocuments: []\n requestVisibility: RequestVisibilityValue | null\n requestFields: RequestField[]\n}\n\n// Regular expression taken from https://html.spec.whatwg.org/multipage/input.html#valid-e-mail-address\nconst EMAIL_REGEX =\n /^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/\n\nexport default defineComponent({\n mixins: [setupEvaporateFileUploader],\n components: {\n 'nr-documentuploadmodal': DocumentUploadModal,\n 'nr-editor': NrEditor,\n NrIcon,\n 'nr-modal': NrModal,\n NrSelect,\n NrFormInput,\n NrFormSelect,\n NrButton,\n NrTooltip,\n NrDatepicker,\n RequestFieldInput\n },\n\n data() {\n return {\n showNoRequesterEmailModal: false,\n isMakingRequest: false,\n invisibleCaptcha: '',\n dateReceived: dateFormat(new Date(), 'MM/dd/yyyy'),\n departmentSearchTerm: '',\n documentsToAdd: [],\n formats: [],\n formatReceived: '',\n embargoVisibilityTip: null,\n emailDisabled: false,\n emailNotice: '',\n evaporateResponse: {},\n keywordAlerts: [],\n requestText: '',\n isRequesterValid: {\n email: true,\n name: true,\n phone: true,\n address: true,\n city: true,\n state: true,\n zip: true\n },\n isRequestFieldsValid: {},\n requester: {\n email: '',\n name: '',\n phone: '',\n address: '',\n city: '',\n state: '',\n zip: '',\n company: ''\n },\n selectedDepartments: [],\n selectedFolder: null,\n showUploadModal: false,\n states: [],\n termsAndConditionsChecked: false,\n uploadedDocuments: [],\n requestVisibility: null,\n isRequesterFieldsDisabled: false,\n requestFields: []\n }\n },\n\n mounted() {\n this.getNewRequestData()\n this.setupEvaporateFileUploader()\n this.handleRequestInput = debounce(this.handleRequestInput, 400)\n this.parseQueryParams()\n },\n\n computed: {\n ...mapState({\n account: (state: State): object | null => state.account,\n currentUser: (state: State): object | null => state.currentUser,\n showDepartments(state: State): boolean {\n return (\n this.$can('read', 'staff_only_items') ||\n state.account?.show_dept_select\n )\n },\n departmentRequired: (state: State): '*' | '' =>\n state.account?.require_department ? '*' : '',\n departments: (state: State): { id: number; name: string }[] =>\n state.account?.departments || [],\n sidebarRequestText: (state: State): string =>\n state.account?.sidebar_request_text || '',\n subheader: (state: State): string =>\n state.account?.request_page_subheader || '',\n termsAndConditions: (state: State): string =>\n state.account?.terms_and_conditions || '',\n requesterRequired(state: State): '*' | null {\n if (this.isRequesterFieldsDisabled) {\n return null\n } else {\n return (\n (state.account?.required_fields &&\n !this.$can('read', 'staff_only_items') &&\n '*') ||\n null\n )\n }\n },\n defaultVisibility(state: State): RequestVisibilityValue {\n return this.requestVisibility || state.account?.visibility_default\n },\n showRequester(state: State): boolean {\n return state.account?.show_requester || false\n }\n }),\n usStates(): { name: string; value: string }[] {\n const states: [string, string][] = this.states\n\n return states.map((state) => ({\n name: state[0],\n value: state[1]\n }))\n },\n isRequesterFieldsValid(): boolean {\n return Object.keys(this.isRequesterValid).every((key) => {\n if (key === 'email' && !this.requester[key]) {\n return true\n }\n return this.requester[key] && this.isRequesterValid[key]\n })\n },\n hasInvalidRequestFields(): boolean {\n return Object.values(this.isRequestFieldsValid).some(\n (isValid) => isValid === false\n )\n },\n\n disabledCreate(): boolean {\n if (!this.selectedDeptIds.length && this.departmentRequired) {\n return true\n }\n\n if (\n this.invisibleCaptcha ||\n this.isMakingRequest ||\n !this.requestText.trim() ||\n (this.termsAndConditionsRequired && !this.termsAndConditionsChecked) ||\n this.hasInvalidRequestFields\n ) {\n return true\n }\n\n if (!this.isRequesterFieldsDisabled && this.requesterRequired) {\n return !this.isRequesterFieldsValid\n }\n\n return false\n },\n\n noDeptsSelected(): boolean {\n return isEmpty(this.selectedDepartments)\n },\n\n selectedDeptIds(): Array {\n if (this.noDeptsSelected) return []\n\n if (this.multipleDeptSelection) {\n return this.selectedDepartments.map(\n (department: { name: string; id: number }) => department.id\n )\n }\n return [this.selectedDepartments.id]\n },\n formatedFormData(): object {\n const {\n email,\n name,\n phone: phone_number, // eslint-disable-line camelcase\n address,\n city,\n state,\n zip: zipcode,\n company\n } = this.requester\n\n const {\n invisibleCaptcha,\n dateReceived: request_date, // eslint-disable-line camelcase\n formatReceived: request_submit_type_id, // eslint-disable-line camelcase\n visibility,\n requestText: request_text, // eslint-disable-line camelcase\n selectedFolder,\n documentsToAdd: documents\n } = this\n\n if (invisibleCaptcha) {\n return\n }\n\n // eslint-disable-next-line camelcase\n const request_field_values = this.requestFields.map(\n (field: RequestField) => ({\n request_field_version_id: field.definition.version_id,\n value: field.value\n })\n )\n\n return {\n requester: {\n email,\n name,\n phone_number,\n address,\n city,\n state,\n zipcode,\n company\n },\n state: this.$can('read', 'staff_only_items') ? 'staff' : 'requester',\n documents,\n folder: selectedFolder?.folder_name,\n request: {\n request_text,\n request_date: dateFormat(new Date(request_date), 'MM/dd/yy'),\n request_submit_type_id,\n visibility,\n department_ids: this.selectedDeptIds,\n request_field_values\n }\n }\n },\n\n visibility: {\n get() {\n return this.requestVisibility || this.defaultVisibility\n },\n set(state: RequestVisibilityValue) {\n this.requestVisibility = state\n }\n },\n\n visibilityTips() {\n return [\n 'Published: Everyone',\n ...(this.account.restricted_visibilities_feature_flag\n ? [\n 'Published - department only: Admins, all assigned departments’ staff, requester, and any public user'\n ]\n : []),\n this.embargoVisibilityTip,\n 'Staff: Staff + requester',\n \"Department: Admins, assigned departments' staff + requester\",\n 'Restricted: Admins, assigned staff, + requester'\n ]\n .filter((tip) => !!tip)\n .join('

')\n },\n\n visibilities(): RequestVisibility[] {\n return accountRequestVisibilities(this.account)\n },\n\n isSignedIn(): boolean {\n return !!this.currentUser\n },\n\n canManageDocuments(): boolean {\n return this.isSignedIn ? this.$can('read', 'staff_only_items') : false\n },\n\n s3Bucket(): string {\n return process.env.S3_BUCKET || ''\n },\n\n departmentSelectionText(): string {\n const isOptional = this.departmentRequired ? 'required' : 'optional'\n\n if (this.$can('read', 'staff_only_items')) {\n return `Assign departments (${isOptional})`\n } else {\n return `Select a department (${isOptional})`\n }\n },\n\n termsAndConditionsRequired(): boolean {\n if (this.$can('read', 'staff_only_items')) {\n return false\n } else {\n return !!this.termsAndConditions\n }\n },\n\n createRequestClassnames(): object {\n return {\n 'is-loading': this.isMakingRequest\n }\n },\n\n multipleDeptSelection(): boolean {\n return this.$can('read', 'staff_only_items')\n }\n },\n\n methods: {\n handleCreateRequestByRole(): void {\n if (!this.requester.email && !this.no_email) {\n return this.toggleNoRequesterEmailModal(true)\n } else {\n return this.createRequest()\n }\n },\n handleRequestFieldValid(fieldId: number, isValid: boolean) {\n this.isRequestFieldsValid = {\n ...this.isRequestFieldsValid,\n [fieldId]: isValid\n }\n },\n handleRequesterInputValidState(field: string, isValid: boolean) {\n if (!field) {\n return\n }\n\n const validState =\n field === 'email' ? (this.emailDisabled ? true : isValid) : isValid\n\n this.isRequesterValid = Object.assign({}, this.isRequesterValid, {\n [`${field}`]: validState\n })\n },\n\n validateEmailInput(input: string): boolean {\n return input.length ? EMAIL_REGEX.test(input) : true\n },\n createRequest(): void {\n this.toggleNoRequesterEmailModal(false)\n if (this.invisibleCaptcha) return\n\n this.isMakingRequest = true\n http\n // eslint-disable-next-line camelcase\n .post<\n NewRequest,\n { pretty_id?: string; email?: string; error?: string } // eslint-disable-line camelcase\n >('/requests', this.formatedFormData)\n .then((data) => {\n if (data.pretty_id) {\n // NOTE(TODO): We cannot let vue-router optimize loading and\n // rendering the requests how page until we stop loading the legacy\n // page. Or load the legacy request show with a different path\n // e.g., /requests/:id/legacy\n // This is because the RequestsController#show gets called and ends\n // up loading the legacy view for guest users.\n // this.$router.push({\n // path: `/requests/${data.pretty_id}`\n // })\n window.location.href = `/requests/${data.pretty_id}?email=${data.email}`\n }\n })\n .catch((err) => {\n this.isMakingRequest = false\n const { email, error } = err.response.data\n if (email) {\n this.requester.email = email\n }\n const errorMessage =\n error || 'Request failed to save, please contact support'\n this.$toasted.error(errorMessage)\n })\n },\n\n handleEmailInput(): void {\n if (!this.requester.email) {\n this.isRequesterFieldsDisabled = false\n this.emailNotice = ''\n }\n\n if (this.requester.email === this.currentUser.email) {\n this.isRequesterFieldsDisabled = true\n } else {\n this.isRequesterFieldsDisabled = false\n }\n },\n\n handleEmailCheck(): void {\n if (!this.isSignedIn) {\n return\n }\n\n if (!this.$can('read', 'staff_only_items')) {\n return\n }\n\n if (!this.requester.email) {\n return\n }\n\n if (!EMAIL_REGEX.test(this.requester.email)) {\n return\n }\n\n http\n .get(\n `/account_lookup?email=${encodeURIComponent(this.requester.email)}`\n )\n .then((accountUser) => {\n if (accountUser.email) {\n if (accountUser.email === this.currentUser.email) {\n // Make the current user the requester\n this.emailNotice =\n 'Staff member: Are you sure? This will make YOU the requester.'\n this.isRequesterFieldsDisabled = true\n } else if (!accountUser.enabled) {\n // User account is deactived\n this.emailNotice =\n 'This user account has been deactivated. It will need to be reactivated before the requester can sign in and receive emails'\n } else {\n this.emailNotice = 'Account found'\n }\n\n this.setRequesterInfo(accountUser)\n } else {\n this.emailNotice =\n 'New email address. An account will be created for this requester.'\n }\n })\n .catch((error) => console.error(error))\n },\n\n setRequesterInfo(info: Requester) {\n this.requester = Object.assign({}, this.requester, info)\n },\n\n handleFolderSelection(names?: string[]): void {\n if (names && names.length) {\n this.selectedFolder = { id: -1, folder_name: names.pop() }\n } else {\n this.selectedFolder = null\n }\n },\n\n handleRequestInput(): void {\n if (this.requestText) {\n http\n .post('/alerts', { text: { search_text: this.requestText } })\n .then((data) => {\n this.keywordAlerts = data\n })\n .catch(() => {\n this.keywordAlerts = []\n })\n } else {\n this.keywordAlerts = []\n }\n },\n\n handleDocumentUploads(document: object) {\n this.uploadedDocuments.push(document)\n },\n\n handleDocumentRemoveClick(assetUrl: string): void {\n this.documentsToAdd = this.documentsToAdd.filter(\n (document: Document) => document.url !== assetUrl\n )\n this.$toasted.success('Successfully removed document')\n },\n\n handleUploadModalClick(): void {\n this.toggleUploadModal()\n },\n\n toggleNoRequesterEmailModal(state?: boolean): void {\n if (state === undefined || state === null) {\n this.showNoRequesterEmailModal = !this.showNoRequesterEmailModal\n } else {\n this.showNoRequesterEmailModal = state\n }\n },\n\n toggleUploadModal(state?: boolean): void {\n if (state === undefined || state === null) {\n this.showUploadModal = !this.showUploadModal\n } else {\n this.showUploadModal = state\n }\n if (!this.showUploadModal) this.uploadedDocuments = []\n },\n\n getNewRequestData(): void {\n http.get('/requests/new').then((data) => {\n this.states = (data.states || []).filter(\n (state: [string, string]) => state && state[0] && state[1]\n )\n this.formats = data.formats\n this.embargoVisibilityTip = data.embargo_visibility_tooltip\n\n const initialRequestFieldValid = {}\n const parsedRequestFields: RequestField[] = []\n const preParsedRequestFields = data.request_fields || []\n\n preParsedRequestFields.forEach((definition) => {\n if (definition.type_settings?.isMandatory) {\n initialRequestFieldValid[definition.id] = false\n }\n\n parsedRequestFields.push({ definition, value: null })\n })\n\n this.isRequestFieldsValid = initialRequestFieldValid\n this.requestFields = parsedRequestFields\n\n if (this.isSignedIn && !this.$can('read', 'staff_only_items')) {\n this.requester.email = this.currentUser.email\n if (this.currentUser.email !== this.currentUser.email_or_name) {\n this.requester.name = this.currentUser.email_or_name\n }\n }\n })\n },\n handleSaveDocumentsToRequest(data: {\n [key: string]: any\n documents: []\n }): void {\n this.documentsToAdd = [...this.documentsToAdd, ...data.documents]\n this.$toasted.success('Successfully uploaded document(s)')\n },\n\n handleDepartmentSelectionEvent(eventType: string, data?: any) {\n if (eventType === 'typing') {\n this.departmentSearchTerm = (data || '').trim()\n } else {\n this.departmentSearchTerm = ''\n }\n },\n\n parseQueryParams(): void {\n if (isEmpty(this.$route.query)) return\n\n const { dept_id: deptId } = this.$route.query\n if (deptId) {\n const dept = this.departments.find(\n (dept: { id: number; name: string }) => +dept.id === +deptId\n )\n if (!dept) return\n if (this.multipleDeptSelection) {\n this.selectedDepartments = [dept]\n } else {\n this.selectedDepartments = dept\n }\n }\n },\n\n formatDate(date) {\n return dateFormat(new Date(date), 'MM/dd/yyyy')\n }\n },\n\n watch: {\n departments(next) {\n if (!next) return\n if (!next.length) return\n\n this.parseQueryParams()\n },\n\n currentUser(next, _prev) {\n if (!next) {\n return\n }\n if (!next.email) {\n return\n }\n if (this.$can('read', 'staff_only_items')) {\n return\n }\n\n this.requester.email = next.email\n },\n emailDisabled(disabled) {\n if (disabled) {\n this.isRequesterFieldsDisabled = false\n }\n if (this.requester.email) {\n this.requester.email = ''\n }\n }\n }\n})\n","import { render } from \"./create_request.vue?vue&type=template&id=073fb80b&ts=true\"\nimport script from \"./create_request.vue?vue&type=script&lang=ts\"\nexport * from \"./create_request.vue?vue&type=script&lang=ts\"\n\nimport \"./create_request.vue?vue&type=style&index=0&id=073fb80b&lang=scss\"\n\nimport exportComponent from \"/app/node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render]])\n\nexport default __exports__"],"sourceRoot":""}