{"version":3,"sources":["../../src/mixins/loadable.ts"],"names":[],"mappings":"AAAA,OAAO,GAAP,MAA2B,KAA3B;AACA,OAAO,eAAP,MAA4B,+BAA5B;AAMA;;;;;;;;;AASA;AACA,eAAe,IAAI,MAAJ,GAAwB,MAAxB,CAA+B;AAC5C,UAAM,UADsC;AAG5C,WAAO;AACL,iBAAS;AACP,kBAAM,CAAC,OAAD,EAAU,MAAV,CADC;AAEP,qBAAS;AAFF;AADJ,KAHqC;AAU5C,aAAS;AACP,mBADO,yBACI;AACT,gBAAI,KAAK,OAAL,KAAiB,KAArB,EAA4B,OAAO,IAAP;AAE5B,mBAAO,KAAK,MAAL,CAAY,QAAZ,IAAwB,KAAK,cAAL,CAAoB,eAApB,EAAqC;AAClE,uBAAO;AACL,2BAAQ,KAAK,OAAL,KAAiB,IAAjB,IAAyB,KAAK,OAAL,KAAiB,EAA3C,GACF,KAAK,KAAL,IAAc,SADZ,GAEH,KAAK,OAHJ;AAIL,4BAAQ,CAJH;AAKL,mCAAe;AALV;AAD2D,aAArC,CAA/B;AASD;AAbM;AAVmC,CAA/B,CAAf","sourcesContent":["import Vue, { VNode } from 'vue'\nimport VProgressLinear from '../components/VProgressLinear'\n\ninterface colorable extends Vue {\n color?: string\n}\n\n/**\n * Loadable\n *\n * @mixin\n *\n * Used to add linear progress bar to components\n * Can use a default bar with a specific color\n * or designate a custom progress linear bar\n */\n/* @vue/component */\nexport default Vue.extend().extend({\n name: 'loadable',\n\n props: {\n loading: {\n type: [Boolean, String],\n default: false\n }\n },\n\n methods: {\n genProgress (): VNode | VNode[] | null {\n if (this.loading === false) return null\n\n return this.$slots.progress || this.$createElement(VProgressLinear, {\n props: {\n color: (this.loading === true || this.loading === '')\n ? (this.color || 'primary')\n : this.loading,\n height: 2,\n indeterminate: true\n }\n })\n }\n }\n})\n"],"sourceRoot":""}