{"version":3,"file":"RadioInput-f565Hdlm.js","sources":["../../../app/javascript/components/shared/RadioInput.vue"],"sourcesContent":["<template>\n <div :class=\"{ 'has-errors': hasErrors }\">\n <label\n class=\"typeset-6\"\n :class=\"[\n block ? 'flex p-4' : 'inline-flex label',\n labelClass,\n isChecked ? checkedClass : uncheckedClass\n ]\">\n <input\n :id=\"`${inputId}-${value}`\"\n :class=\"inputClass\"\n :name=\"inputId\"\n :checked=\"value === currentValue\"\n type=\"radio\"\n @change=\"$emit('input', value)\" />\n <div>\n <div>\n <span v-html=\"label\"></span>\n <span v-if=\"required\">*</span>\n </div>\n <slot name=\"description\"></slot>\n </div>\n </label>\n </div>\n</template>\n<script>\nexport default {\n name: \"RadioInput\",\n model: {\n prop: \"currentValue\",\n event: \"input\"\n },\n props: {\n value: {\n required: true\n },\n currentValue: {\n required: false\n },\n label: {\n type: String,\n default: \"\"\n },\n required: {\n type: Boolean,\n default: false\n },\n inputId: {\n type: String,\n required: true,\n default: \"\"\n },\n inputClass: {\n type: String,\n default: \"\"\n },\n errors: {\n type: Array,\n default: () => []\n },\n block: {\n type: Boolean,\n default: false\n },\n labelClass: {\n type: String,\n default: \"gap-x-3\"\n },\n checkedClass: {\n type: String,\n default: \"\"\n },\n uncheckedClass: {\n type: String,\n default: \"\"\n }\n },\n emits: [\"input\"],\n computed: {\n isChecked() {\n return this.value === this.currentValue;\n },\n inputErrors() {\n return this.errors || [];\n },\n hasErrors() {\n return this.inputErrors.length > 0;\n }\n }\n};\n</script>\n"],"names":["_sfc_main","_hoisted_1","_hoisted_2","_createElementBlock","_normalizeClass","$options","_createElementVNode","$props","_cache","$event","_ctx","_hoisted_3","_createCommentVNode","_renderSlot"],"mappings":"sGA2BA,MAAKA,EAAU,CACb,KAAM,aACN,MAAO,CACL,KAAM,eACN,MAAO,OACR,EACD,MAAO,CACL,MAAO,CACL,SAAU,EACX,EACD,aAAc,CACZ,SAAU,EACX,EACD,MAAO,CACL,KAAM,OACN,QAAS,EACV,EAC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