{"version":3,"sources":["webpack:///./app/javascript/widget/components/ArticleCategoryCard.vue?4712","webpack:///./app/javascript/widget/views/Home.vue?733d","webpack:///./app/javascript/widget/components/GroupedAvatars.vue?4d56","webpack:///app/javascript/widget/components/GroupedAvatars.vue","webpack:///./app/javascript/widget/components/AvailableAgents.vue?df8c","webpack:///app/javascript/widget/components/AvailableAgents.vue","webpack:///./app/javascript/widget/components/GroupedAvatars.vue","webpack:///./app/javascript/widget/components/GroupedAvatars.vue?c723","webpack:///./app/javascript/widget/components/AvailableAgents.vue","webpack:///./app/javascript/widget/components/AvailableAgents.vue?a900","webpack:///app/javascript/widget/components/TeamAvailability.vue","webpack:///./app/javascript/widget/components/TeamAvailability.vue?b386","webpack:///./app/javascript/widget/components/TeamAvailability.vue","webpack:///./app/javascript/widget/components/TeamAvailability.vue?0260","webpack:///./app/javascript/widget/components/ArticleListItem.vue?f2ac","webpack:///app/javascript/widget/components/ArticleListItem.vue","webpack:///./app/javascript/widget/components/ArticleList.vue?0d08","webpack:///app/javascript/widget/components/ArticleList.vue","webpack:///./app/javascript/widget/components/ArticleListItem.vue","webpack:///./app/javascript/widget/components/ArticleListItem.vue?6052","webpack:///./app/javascript/widget/components/ArticleList.vue","webpack:///./app/javascript/widget/components/ArticleList.vue?f6c9","webpack:///app/javascript/widget/components/ArticleCategoryCard.vue","webpack:///./app/javascript/widget/components/ArticleCategoryCard.vue?e9ab","webpack:///./app/javascript/widget/components/ArticleHero.vue?6b77","webpack:///app/javascript/widget/components/ArticleHero.vue","webpack:///./app/javascript/widget/components/ArticleCategoryCard.vue","webpack:///./app/javascript/widget/components/ArticleCategoryCard.vue?5276","webpack:///./app/javascript/widget/components/ArticleHero.vue","webpack:///./app/javascript/widget/components/ArticleHero.vue?cb3d","webpack:///./app/javascript/widget/components/ArticleCardSkeletonLoader.vue","webpack:///./app/javascript/widget/components/ArticleCardSkeletonLoader.vue?e2d1","webpack:///app/javascript/widget/views/Home.vue","webpack:///./app/javascript/widget/views/Home.vue?129f","webpack:///./app/javascript/widget/views/Home.vue"],"names":["_vm","this","_c","_self","staticClass","_l","user","index","key","id","class","attrs","name","avatar","users","_v","_s","isOnline","$t","replyWaitMessage","availableAgents","_e","style","color","widgetColor","on","startConversation","hasConversation","onClick","title","article","slug","link","articles","onArticleClick","$event","$emit","slice","_m","showArticles","conversationSize","unreadMessageCount","articleUiFlags","isFetching","isError","popularArticles","length","openArticleInArticleViewer","viewAllArticles"],"mappings":"mHAAA,S,oGCAA,I,2BCAoN,G,kBCsBpN,CACA,sBACA,sB,OAAA,GACA,OACA,OACA,WACA,iC,OC5BqN,ECOrN,CACA,uBACA,2BCFgB,YACd,GCRW,WAAkB,IAAIA,EAAIC,KAAKC,EAAGF,EAAIG,MAAMD,GAAG,OAAOA,EAAG,MAAM,CAACE,YAAY,QAAQJ,EAAIK,GAAIL,EAAS,OAAE,SAASM,EAAKC,GAAO,OAAOL,EAAG,OAAO,CAACM,IAAIF,EAAKG,GAAGC,OACjKH,EAAQ,QAAU,IADqJ,sDAEnH,CAACL,EAAG,YAAY,CAACS,MAAM,CAAC,KAAO,OAAO,SAAWL,EAAKM,KAAK,IAAMN,EAAKO,OAAO,aAAa,OAAO,MAAK,KAE1I,IDOpB,EACA,KACA,KACA,M,SDJF,OACA,QACA,WACA,+BAGA,UACA,MADA,WAEA,sDACA,QACA,oBACA,mBGHe,EAXC,YACd,GCRW,WAA+C,OAAOX,EAA5BD,KAAYE,MAAMD,IAAa,kBAAkB,CAACS,MAAM,CAAC,MAAzDV,KAAqEa,WAEtF,IDSpB,EACA,KACA,KACA,M,4uBE+BF,IC7CsN,ED6CtN,CACA,wBACA,YACA,kBACA,gBAEA,qBACA,OACA,iBACA,WACA,sBAEA,iBACA,aACA,YAEA,aACA,YACA,YAIA,gBACA,sBACA,0CAFA,IAIA,UAJA,WAKA,sCAEA,SAPA,WAQA,6CACA,gCAEA,SACA,gCAEA,KAGA,SACA,kBADA,WAEA,iCACA,sBACA,iBACA,gBACA,oBACA,+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KAAMf,EAAI0C,eAAyB,WAAExC,EAAG,MAAM,CAACE,YAAY,oBAAoB,CAACF,EAAG,MAAM,CAACE,YAAY,8DAA8D,CAACF,EAAG,iCAAiC,KAAKF,EAAIqB,SAE3W,IiCKpB,EACA,KACA,KACA,MAIa,Y","file":"js/90-0e5844a7002259150cff.chunk.js","sourcesContent":["export * from \"-!../../../../node_modules/mini-css-extract-plugin/dist/loader.js!../../../../node_modules/css-loader/dist/cjs.js??ref--3-1!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/postcss-loader/dist/cjs.js??ref--3-2!../../../../node_modules/sass-loader/dist/cjs.js??ref--3-3!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ArticleCategoryCard.vue?vue&type=style&index=0&id=109d0cc8&prod&lang=scss&scoped=true&\"","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('div',{staticClass:\"z-50 rounded-md w-full flex flex-1 flex-col\",class:{ 'pb-2': _vm.showArticles, 'justify-end': !_vm.showArticles }},[_c('div',{staticClass:\"px-4 pt-4 w-full\"},[_c('team-availability',{attrs:{\"available-agents\":_vm.availableAgents,\"has-conversation\":!!_vm.conversationSize,\"unread-count\":_vm.unreadMessageCount},on:{\"start-conversation\":_vm.startConversation}})],1),_vm._v(\" \"),(_vm.showArticles)?_c('div',{staticClass:\"px-4 py-2 w-full\"},[_c('div',{staticClass:\"p-4 rounded-md bg-white dark:bg-slate-700 shadow-sm w-full\"},[(\n !_vm.articleUiFlags.isFetching &&\n !_vm.articleUiFlags.isError &&\n _vm.popularArticles.length\n )?_c('article-hero',{attrs:{\"articles\":_vm.popularArticles},on:{\"view\":_vm.openArticleInArticleViewer,\"view-all\":_vm.viewAllArticles}}):_vm._e()],1)]):_vm._e(),_vm._v(\" \"),(_vm.articleUiFlags.isFetching)?_c('div',{staticClass:\"px-4 py-2 w-full\"},[_c('div',{staticClass:\"p-4 rounded-md bg-white dark:bg-slate-700 shadow-sm w-full\"},[_c('article-card-skeleton-loader')],1)]):_vm._e()])\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--7-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./GroupedAvatars.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--7-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./GroupedAvatars.vue?vue&type=script&lang=js&\"","<template>\n <div class=\"flex\">\n <span\n v-for=\"(user, index) in users\"\n :key=\"user.id\"\n :class=\"`${\n index ? '-ml-4' : ''\n } inline-block rounded-full text-white shadow-solid`\"\n >\n <thumbnail\n size=\"36px\"\n :username=\"user.name\"\n :src=\"user.avatar\"\n has-border\n />\n </span>\n </div>\n</template>\n\n<script>\nimport Thumbnail from 'dashboard/components/widgets/Thumbnail.vue';\n\nexport default {\n name: 'GroupedAvatars',\n components: { Thumbnail },\n props: {\n users: {\n type: Array,\n default: () => [],\n },\n },\n};\n</script>\n","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--7-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./AvailableAgents.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--7-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./AvailableAgents.vue?vue&type=script&lang=js&\"","<template>\n <grouped-avatars :users=\"users\" />\n</template>\n\n<script>\nimport GroupedAvatars from 'widget/components/GroupedAvatars.vue';\n\nexport default {\n name: 'AvailableAgents',\n components: { GroupedAvatars },\n props: {\n agents: {\n type: Array,\n default: () => [],\n },\n },\n computed: {\n users() {\n return this.agents.slice(0, 4).map(agent => ({\n id: agent.id,\n avatar: agent.avatar_url,\n name: agent.name,\n }));\n },\n },\n};\n</script>\n","import { render, staticRenderFns } from \"./GroupedAvatars.vue?vue&type=template&id=4e666ae4&\"\nimport script from \"./GroupedAvatars.vue?vue&type=script&lang=js&\"\nexport * from \"./GroupedAvatars.vue?vue&type=script&lang=js&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('div',{staticClass:\"flex\"},_vm._l((_vm.users),function(user,index){return _c('span',{key:user.id,class:`${\n index ? '-ml-4' : ''\n } inline-block rounded-full text-white shadow-solid`},[_c('thumbnail',{attrs:{\"size\":\"36px\",\"username\":user.name,\"src\":user.avatar,\"has-border\":\"\"}})],1)}),0)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import { render, staticRenderFns } from \"./AvailableAgents.vue?vue&type=template&id=9b8cb78a&\"\nimport script from \"./AvailableAgents.vue?vue&type=script&lang=js&\"\nexport * from \"./AvailableAgents.vue?vue&type=script&lang=js&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('grouped-avatars',{attrs:{\"users\":_vm.users}})\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","<template>\n <div class=\"p-4 shadow-sm rounded-md bg-white dark:bg-slate-700\">\n <div class=\"flex items-center justify-between\">\n <div class=\" \">\n <div class=\"text-sm font-medium text-slate-700 dark:text-slate-50\">\n {{\n isOnline\n ? $t('TEAM_AVAILABILITY.ONLINE')\n : $t('TEAM_AVAILABILITY.OFFLINE')\n }}\n </div>\n <div class=\"text-sm mt-1 text-slate-500 dark:text-slate-100\">\n {{ replyWaitMessage }}\n </div>\n </div>\n <available-agents v-if=\"isOnline\" :agents=\"availableAgents\" />\n </div>\n <button\n class=\"inline-flex text-sm font-medium rounded-md py-1 mt-2 px-2 -ml-2 leading-6 text-slate-800 dark:text-slate-50 justify-between items-center hover:bg-slate-25 dark:hover:bg-slate-800\"\n :style=\"{ color: widgetColor }\"\n @click=\"startConversation\"\n >\n <span class=\"pr-2 text-sm\">\n {{\n hasConversation\n ? $t('CONTINUE_CONVERSATION')\n : $t('START_CONVERSATION')\n }}\n </span>\n <fluent-icon icon=\"arrow-right\" size=\"14\" />\n </button>\n </div>\n</template>\n\n<script>\nimport { mapGetters } from 'vuex';\nimport { getContrastingTextColor } from '@chatwoot/utils';\nimport nextAvailabilityTime from 'widget/mixins/nextAvailabilityTime';\nimport AvailableAgents from 'widget/components/AvailableAgents.vue';\nimport configMixin from 'widget/mixins/configMixin';\nimport availabilityMixin from 'widget/mixins/availability';\nimport FluentIcon from 'shared/components/FluentIcon/Index.vue';\nimport { IFrameHelper } from 'widget/helpers/utils';\nimport { CHATWOOT_ON_START_CONVERSATION } from '../constants/sdkEvents';\n\nexport default {\n name: 'TeamAvailability',\n components: {\n AvailableAgents,\n FluentIcon,\n },\n mixins: [configMixin, nextAvailabilityTime, availabilityMixin],\n props: {\n availableAgents: {\n type: Array,\n default: () => {},\n },\n hasConversation: {\n type: Boolean,\n default: false,\n },\n unreadCount: {\n type: Number,\n default: 0,\n },\n },\n\n computed: {\n ...mapGetters({\n widgetColor: 'appConfig/getWidgetColor',\n }),\n textColor() {\n return getContrastingTextColor(this.widgetColor);\n },\n isOnline() {\n const { workingHoursEnabled } = this.channelConfig;\n const anyAgentOnline = this.availableAgents.length > 0;\n\n if (workingHoursEnabled) {\n return this.isInBetweenTheWorkingHours;\n }\n return anyAgentOnline;\n },\n },\n methods: {\n startConversation() {\n this.$emit('start-conversation');\n if (!this.hasConversation) {\n IFrameHelper.sendMessage({\n event: 'onEvent',\n eventIdentifier: CHATWOOT_ON_START_CONVERSATION,\n data: { hasConversation: false },\n });\n }\n },\n },\n};\n</script>\n","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--7-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./TeamAvailability.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--7-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./TeamAvailability.vue?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./TeamAvailability.vue?vue&type=template&id=5f869825&\"\nimport script from \"./TeamAvailability.vue?vue&type=script&lang=js&\"\nexport * from \"./TeamAvailability.vue?vue&type=script&lang=js&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('div',{staticClass:\"p-4 shadow-sm rounded-md bg-white dark:bg-slate-700\"},[_c('div',{staticClass:\"flex items-center justify-between\"},[_c('div',{staticClass:\"\"},[_c('div',{staticClass:\"text-sm font-medium text-slate-700 dark:text-slate-50\"},[_vm._v(\"\\n \"+_vm._s(_vm.isOnline\n ? _vm.$t('TEAM_AVAILABILITY.ONLINE')\n : _vm.$t('TEAM_AVAILABILITY.OFFLINE'))+\"\\n \")]),_vm._v(\" \"),_c('div',{staticClass:\"text-sm mt-1 text-slate-500 dark:text-slate-100\"},[_vm._v(\"\\n \"+_vm._s(_vm.replyWaitMessage)+\"\\n \")])]),_vm._v(\" \"),(_vm.isOnline)?_c('available-agents',{attrs:{\"agents\":_vm.availableAgents}}):_vm._e()],1),_vm._v(\" \"),_c('button',{staticClass:\"inline-flex text-sm font-medium rounded-md py-1 mt-2 px-2 -ml-2 leading-6 text-slate-800 dark:text-slate-50 justify-between items-center hover:bg-slate-25 dark:hover:bg-slate-800\",style:({ color: _vm.widgetColor }),on:{\"click\":_vm.startConversation}},[_c('span',{staticClass:\"pr-2 text-sm\"},[_vm._v(\"\\n \"+_vm._s(_vm.hasConversation\n ? _vm.$t('CONTINUE_CONVERSATION')\n : _vm.$t('START_CONVERSATION'))+\"\\n \")]),_vm._v(\" \"),_c('fluent-icon',{attrs:{\"icon\":\"arrow-right\",\"size\":\"14\"}})],1)])\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--7-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ArticleListItem.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--7-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ArticleListItem.vue?vue&type=script&lang=js&\"","<template>\n <li\n class=\"py-1 flex items-center justify-between -mx-1 px-1 hover:bg-slate-25 dark:hover:bg-slate-600 rounded cursor-pointer text-slate-700 dark:text-slate-50 dark:hover:text-slate-25 hover:text-slate-900\"\n role=\"button\"\n @click=\"onClick\"\n >\n <button class=\"underline-offset-2 text-sm leading-6 text-left\">\n {{ title }}\n </button>\n <span class=\"pl-1 arrow\">\n <fluent-icon icon=\"arrow-right\" size=\"14\" />\n </span>\n </li>\n</template>\n\n<script>\nimport FluentIcon from 'shared/components/FluentIcon/Index.vue';\n\nexport default {\n components: { FluentIcon },\n props: {\n link: {\n type: String,\n default: '',\n },\n title: {\n type: String,\n default: '',\n },\n },\n data() {\n return {};\n },\n methods: {\n onClick() {\n this.$emit('click', this.link);\n },\n },\n};\n</script>\n","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--7-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ArticleList.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--7-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ArticleList.vue?vue&type=script&lang=js&\"","<template>\n <ul role=\"list\" class=\"py-2\">\n <article-list-item\n v-for=\"article in articles\"\n :key=\"article.slug\"\n :link=\"article.link\"\n :title=\"article.title\"\n @click=\"onClick\"\n />\n </ul>\n</template>\n\n<script>\nimport ArticleListItem from './ArticleListItem.vue';\n\nexport default {\n components: {\n ArticleListItem,\n },\n props: {\n articles: {\n type: Array,\n default: () => [],\n },\n },\n data() {\n return {};\n },\n methods: {\n onClick(link) {\n this.$emit('click', link);\n },\n },\n};\n</script>\n","import { render, staticRenderFns } from \"./ArticleListItem.vue?vue&type=template&id=32ecc582&\"\nimport script from \"./ArticleListItem.vue?vue&type=script&lang=js&\"\nexport * from \"./ArticleListItem.vue?vue&type=script&lang=js&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('li',{staticClass:\"py-1 flex items-center justify-between -mx-1 px-1 hover:bg-slate-25 dark:hover:bg-slate-600 rounded cursor-pointer text-slate-700 dark:text-slate-50 dark:hover:text-slate-25 hover:text-slate-900\",attrs:{\"role\":\"button\"},on:{\"click\":_vm.onClick}},[_c('button',{staticClass:\"underline-offset-2 text-sm leading-6 text-left\"},[_vm._v(\"\\n \"+_vm._s(_vm.title)+\"\\n \")]),_vm._v(\" \"),_c('span',{staticClass:\"pl-1 arrow\"},[_c('fluent-icon',{attrs:{\"icon\":\"arrow-right\",\"size\":\"14\"}})],1)])\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import { render, staticRenderFns } from \"./ArticleList.vue?vue&type=template&id=302482e3&\"\nimport script from \"./ArticleList.vue?vue&type=script&lang=js&\"\nexport * from \"./ArticleList.vue?vue&type=script&lang=js&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('ul',{staticClass:\"py-2\",attrs:{\"role\":\"list\"}},_vm._l((_vm.articles),function(article){return _c('article-list-item',{key:article.slug,attrs:{\"link\":article.link,\"title\":article.title},on:{\"click\":_vm.onClick}})}),1)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","<template>\n <div>\n <h3 class=\"text-sm font-medium text-slate-800 dark:text-slate-50 mb-0\">\n {{ title }}\n </h3>\n <article-list :articles=\"articles\" @click=\"onArticleClick\" />\n <button\n class=\"inline-flex text-sm font-medium rounded-md px-2 py-1 -ml-2 leading-6 text-slate-800 dark:text-slate-50 justify-between items-center hover:bg-slate-25 dark:hover:bg-slate-800 see-articles\"\n :style=\"{ color: widgetColor }\"\n @click=\"$emit('view-all')\"\n >\n <span class=\"pr-2 text-sm\">{{ $t('PORTAL.VIEW_ALL_ARTICLES') }}</span>\n <fluent-icon icon=\"arrow-right\" size=\"14\" />\n </button>\n </div>\n</template>\n\n<script>\nimport { mapGetters } from 'vuex';\nimport ArticleList from './ArticleList.vue';\nimport FluentIcon from 'shared/components/FluentIcon/Index.vue';\n\nexport default {\n components: { FluentIcon, ArticleList },\n props: {\n title: {\n type: String,\n default: '',\n },\n articles: {\n type: Array,\n default: () => [],\n },\n },\n computed: {\n ...mapGetters({ widgetColor: 'appConfig/getWidgetColor' }),\n },\n methods: {\n onArticleClick(link) {\n this.$emit('view', link);\n },\n },\n};\n</script>\n<style lang=\"scss\" scoped>\n.see-articles {\n color: var(--brand-textButtonClear);\n svg {\n color: var(--brand-textButtonClear);\n }\n}\n</style>\n","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--7-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ArticleCategoryCard.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--7-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ArticleCategoryCard.vue?vue&type=script&lang=js&\"","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--7-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ArticleHero.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--7-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ArticleHero.vue?vue&type=script&lang=js&\"","<template>\n <category-card\n :title=\"$t('PORTAL.POPULAR_ARTICLES')\"\n :articles=\"articles.slice(0, 6)\"\n @view-all=\"$emit('view-all')\"\n @view=\"onArticleClick\"\n />\n</template>\n\n<script>\nimport CategoryCard from './ArticleCategoryCard.vue';\nexport default {\n components: { CategoryCard },\n props: {\n articles: {\n type: Array,\n default: () => [],\n },\n categoryPath: {\n type: String,\n default: '',\n },\n },\n methods: {\n onArticleClick(link) {\n this.$emit('view', link);\n },\n },\n};\n</script>\n\n<style></style>\n","import { render, staticRenderFns } from \"./ArticleCategoryCard.vue?vue&type=template&id=109d0cc8&scoped=true&\"\nimport script from \"./ArticleCategoryCard.vue?vue&type=script&lang=js&\"\nexport * from \"./ArticleCategoryCard.vue?vue&type=script&lang=js&\"\nimport style0 from \"./ArticleCategoryCard.vue?vue&type=style&index=0&id=109d0cc8&prod&lang=scss&scoped=true&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"109d0cc8\",\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('div',[_c('h3',{staticClass:\"text-sm font-medium text-slate-800 dark:text-slate-50 mb-0\"},[_vm._v(\"\\n \"+_vm._s(_vm.title)+\"\\n \")]),_vm._v(\" \"),_c('article-list',{attrs:{\"articles\":_vm.articles},on:{\"click\":_vm.onArticleClick}}),_vm._v(\" \"),_c('button',{staticClass:\"inline-flex text-sm font-medium rounded-md px-2 py-1 -ml-2 leading-6 text-slate-800 dark:text-slate-50 justify-between items-center hover:bg-slate-25 dark:hover:bg-slate-800 see-articles\",style:({ color: _vm.widgetColor }),on:{\"click\":function($event){return _vm.$emit('view-all')}}},[_c('span',{staticClass:\"pr-2 text-sm\"},[_vm._v(_vm._s(_vm.$t('PORTAL.VIEW_ALL_ARTICLES')))]),_vm._v(\" \"),_c('fluent-icon',{attrs:{\"icon\":\"arrow-right\",\"size\":\"14\"}})],1)],1)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import { render, staticRenderFns } from \"./ArticleHero.vue?vue&type=template&id=fe50520a&\"\nimport script from \"./ArticleHero.vue?vue&type=script&lang=js&\"\nexport * from \"./ArticleHero.vue?vue&type=script&lang=js&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('category-card',{attrs:{\"title\":_vm.$t('PORTAL.POPULAR_ARTICLES'),\"articles\":_vm.articles.slice(0, 6)},on:{\"view-all\":function($event){return _vm.$emit('view-all')},\"view\":_vm.onArticleClick}})\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import { render, staticRenderFns } from \"./ArticleCardSkeletonLoader.vue?vue&type=template&id=ba622d24&\"\nvar script = {}\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _vm._m(0)\n}\nvar staticRenderFns = [function (){var _vm=this,_c=_vm._self._c;return _c('div',{staticClass:\"py-4 space-y-4 bg-white dark:bg-slate-700\"},[_c('div',{staticClass:\"space-y-2 animate-pulse\"},[_c('div',{staticClass:\"h-6 bg-slate-100 dark:bg-slate-500 rounded w-2/5\"})]),_vm._v(\" \"),_c('div',{staticClass:\"space-y-2 animate-pulse\"},[_c('div',{staticClass:\"h-4 bg-slate-100 dark:bg-slate-500 rounded\"}),_vm._v(\" \"),_c('div',{staticClass:\"h-4 bg-slate-100 dark:bg-slate-500 rounded\"}),_vm._v(\" \"),_c('div',{staticClass:\"h-4 bg-slate-100 dark:bg-slate-500 rounded\"})]),_vm._v(\" \"),_c('div',{staticClass:\"space-y-2 animate-pulse\"},[_c('div',{staticClass:\"h-4 bg-slate-100 dark:bg-slate-500 rounded w-1/5\"})])])\n}]\n\nexport { render, staticRenderFns }","<template>\n <div\n class=\"z-50 rounded-md w-full flex flex-1 flex-col\"\n :class=\"{ 'pb-2': showArticles, 'justify-end': !showArticles }\"\n >\n <div class=\"px-4 pt-4 w-full\">\n <team-availability\n :available-agents=\"availableAgents\"\n :has-conversation=\"!!conversationSize\"\n :unread-count=\"unreadMessageCount\"\n @start-conversation=\"startConversation\"\n />\n </div>\n <div v-if=\"showArticles\" class=\"px-4 py-2 w-full\">\n <div class=\"p-4 rounded-md bg-white dark:bg-slate-700 shadow-sm w-full\">\n <article-hero\n v-if=\"\n !articleUiFlags.isFetching &&\n !articleUiFlags.isError &&\n popularArticles.length\n \"\n :articles=\"popularArticles\"\n @view=\"openArticleInArticleViewer\"\n @view-all=\"viewAllArticles\"\n />\n </div>\n </div>\n <div v-if=\"articleUiFlags.isFetching\" class=\"px-4 py-2 w-full\">\n <div class=\"p-4 rounded-md bg-white dark:bg-slate-700 shadow-sm w-full\">\n <article-card-skeleton-loader />\n </div>\n </div>\n </div>\n</template>\n\n<script>\nimport TeamAvailability from 'widget/components/TeamAvailability.vue';\nimport ArticleHero from 'widget/components/ArticleHero.vue';\nimport ArticleCardSkeletonLoader from 'widget/components/ArticleCardSkeletonLoader.vue';\n\nimport { mapGetters } from 'vuex';\nimport darkModeMixin from 'widget/mixins/darkModeMixin';\nimport routerMixin from 'widget/mixins/routerMixin';\nimport configMixin from 'widget/mixins/configMixin';\n\nexport default {\n name: 'Home',\n components: {\n ArticleHero,\n TeamAvailability,\n ArticleCardSkeletonLoader,\n },\n mixins: [configMixin, routerMixin, darkModeMixin],\n props: {\n hasFetched: {\n type: Boolean,\n default: false,\n },\n isCampaignViewClicked: {\n type: Boolean,\n default: false,\n },\n },\n computed: {\n ...mapGetters({\n availableAgents: 'agent/availableAgents',\n activeCampaign: 'campaign/getActiveCampaign',\n conversationSize: 'conversation/getConversationSize',\n unreadMessageCount: 'conversation/getUnreadMessageCount',\n popularArticles: 'article/popularArticles',\n articleUiFlags: 'article/uiFlags',\n }),\n widgetLocale() {\n return this.$i18n.locale || 'en';\n },\n portal() {\n return window.chatwootWebChannel.portal;\n },\n showArticles() {\n return (\n this.portal &&\n !this.articleUiFlags.isFetching &&\n this.popularArticles.length\n );\n },\n defaultLocale() {\n const widgetLocale = this.widgetLocale;\n const { allowed_locales: allowedLocales, default_locale: defaultLocale } =\n this.portal.config;\n\n // IMPORTANT: Variation strict locale matching, Follow iso_639_1_code\n // If the exact match of a locale is available in the list of portal locales, return it\n // Else return the default locale. Eg: `es` will not work if `es_ES` is available in the list\n if (allowedLocales.includes(widgetLocale)) {\n return widgetLocale;\n }\n return defaultLocale;\n },\n },\n mounted() {\n if (this.portal && this.popularArticles.length === 0) {\n const locale = this.defaultLocale;\n this.$store.dispatch('article/fetch', {\n slug: this.portal.slug,\n locale,\n });\n }\n },\n methods: {\n startConversation() {\n if (this.preChatFormEnabled && !this.conversationSize) {\n return this.replaceRoute('prechat-form');\n }\n return this.replaceRoute('messages');\n },\n openArticleInArticleViewer(link) {\n let linkToOpen = `${link}?show_plain_layout=true`;\n const isDark = this.prefersDarkMode;\n if (isDark) {\n linkToOpen = `${linkToOpen}&theme=dark`;\n }\n this.$router.push({\n name: 'article-viewer',\n params: { link: linkToOpen },\n });\n },\n viewAllArticles() {\n const locale = this.defaultLocale;\n const {\n portal: { slug },\n } = window.chatwootWebChannel;\n this.openArticleInArticleViewer(`/hc/${slug}/${locale}`);\n },\n },\n};\n</script>\n","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--7-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Home.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../../../node_modules/babel-loader/lib/index.js??ref--7-0!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Home.vue?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./Home.vue?vue&type=template&id=31426bcf&\"\nimport script from \"./Home.vue?vue&type=script&lang=js&\"\nexport * from \"./Home.vue?vue&type=script&lang=js&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n null,\n null\n \n)\n\nexport default component.exports"],"sourceRoot":""}