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vue/apps/catalog/components/FormattedCredit.vue?035e","webpack://lawline/./resources/assets/js/vue/apps/catalog/components/FormattedCredit.vue","webpack://lawline/./resources/assets/js/vue/apps/catalog/components/FormattedCredit.vue?f2cc"],"sourcesContent":["import { toDisplayString as _toDisplayString, createElementVNode as _createElementVNode, normalizeClass as _normalizeClass, openBlock as _openBlock, createElementBlock as _createElementBlock } from \"vue\";\nvar _hoisted_1 = [\"title\"];\nexport function render(_ctx, _cache, $props, $setup, $data, $options) {\n  return _openBlock(), _createElementBlock(\"div\", null, [_createElementVNode(\"span\", null, _toDisplayString($options.formattedCredit), 1), _createElementVNode(\"span\", {\n    \"class\": _normalizeClass([$options.approvalStatusClass, \"ml-1 mr-2 inline-block h-4 w-4 rounded-full text-center align-text-bottom text-xs leading-[14px] text-white\"]),\n    title: \"\".concat($props.credit.status, \" CLE Status\")\n  }, _toDisplayString($props.credit.status[0]), 11, _hoisted_1)]);\n}","export default {\n  props: {\n    credit: {\n      type: Object\n    }\n  },\n  computed: {\n    formattedCredit: function formattedCredit() {\n      var _this = this;\n      // hide the parent credit type if we're already showing the category as \"<type> : <category>\"\n      var hide = [];\n      this.credit.credit_types.forEach(function (type) {\n        if (type.is_category) {\n          hide.push(type.name.split(' : ')[0]);\n        }\n      });\n      var credit_types = this.credit.credit_types.filter(function (type) {\n        return hide.indexOf(type.name) === -1;\n      });\n      var formattedCreditTypes = credit_types.map(function (type) {\n        type.amount = _this.formatCreditAmount(type.amount);\n        return \"\".concat(type.amount, \" \").concat(type.name);\n      }).join(', ');\n      return \"\".concat(this.credit.state_abbr, \" \").concat(this.credit.profession_abbr, \" \").concat(formattedCreditTypes);\n    },\n    approvalStatusClass: function approvalStatusClass() {\n      return this.credit.status.toLowerCase().replace(' ', '-');\n    }\n  },\n  methods: {\n    formatCreditAmount: function formatCreditAmount(amount) {\n      if (Number.isInteger(amount)) {\n        return amount.toFixed(1);\n      }\n      return amount;\n    }\n  }\n};","/* unplugin-vue-components disabled */import { render } from \"./FormattedCredit.vue?vue&type=template&id=2ce17503\"\nimport script from \"./FormattedCredit.vue?vue&type=script&lang=js\"\nexport * from \"./FormattedCredit.vue?vue&type=script&lang=js\"\n\nimport exportComponent from \"../../../../../../../node_modules/vue-loader/dist/exportHelper.js\"\nconst __exports__ = /*#__PURE__*/exportComponent(script, [['render',render]])\n\nexport default __exports__"],"names":["_hoisted_1","props","credit","type","Object","computed","formattedCredit","_this","this","hide","credit_types","forEach","is_category","push","name","split","formattedCreditTypes","filter","indexOf","map","amount","formatCreditAmount","concat","join","state_abbr","profession_abbr","approvalStatusClass","status","toLowerCase","replace","methods","Number","isInteger","toFixed","_ctx","_cache","$props","$setup","$data","$options","title"],"sourceRoot":""}