@ecomplus/widget-martan 1.1.24 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/cms.config.js +78 -83
- package/dist/public/widget-martan.0.min.js +62 -0
- package/dist/public/widget-martan.0.min.js.map +1 -0
- package/dist/public/widget-martan.2.min.js +1 -1
- package/dist/public/widget-martan.2.min.js.map +1 -1
- package/dist/public/widget-martan.3.min.js +1 -1
- package/dist/public/widget-martan.3.min.js.map +1 -1
- package/dist/public/widget-martan.4.min.js +1 -1
- package/dist/public/widget-martan.4.min.js.map +1 -1
- package/dist/public/widget-martan.5.min.js +1 -1
- package/dist/public/widget-martan.5.min.js.map +1 -1
- package/dist/public/widget-martan.6.min.js +2 -0
- package/dist/public/widget-martan.6.min.js.map +1 -0
- package/dist/public/widget-martan.7.min.js +2 -0
- package/dist/public/widget-martan.7.min.js.map +1 -0
- package/dist/public/widget-martan.8.min.js +2 -0
- package/dist/public/widget-martan.8.min.js.map +1 -0
- package/dist/public/widget-martan.9.min.js +2 -0
- package/dist/public/widget-martan.9.min.js.map +1 -0
- package/dist/public/widget-martan.var.min.js +3 -3
- package/dist/public/widget-martan.var.min.js.map +1 -1
- package/dist/widget-martan.0.min.js +62 -0
- package/dist/widget-martan.0.min.js.map +1 -0
- package/dist/widget-martan.2.min.js +1 -1
- package/dist/widget-martan.2.min.js.map +1 -1
- package/dist/widget-martan.3.min.js +1 -1
- package/dist/widget-martan.3.min.js.map +1 -1
- package/dist/widget-martan.4.min.js +1 -1
- package/dist/widget-martan.4.min.js.map +1 -1
- package/dist/widget-martan.5.min.js +1 -1
- package/dist/widget-martan.5.min.js.map +1 -1
- package/dist/widget-martan.6.min.js +2 -0
- package/dist/widget-martan.6.min.js.map +1 -0
- package/dist/widget-martan.7.min.js +2 -0
- package/dist/widget-martan.7.min.js.map +1 -0
- package/dist/widget-martan.8.min.js +2 -0
- package/dist/widget-martan.8.min.js.map +1 -0
- package/dist/widget-martan.9.min.js +2 -0
- package/dist/widget-martan.9.min.js.map +1 -0
- package/dist/widget-martan.min.js +3 -3
- package/dist/widget-martan.min.js.map +1 -1
- package/package.json +2 -2
- package/src/append/product-block.ejs +5 -1
- package/src/append/product-card-slots.ejs +1 -1
- package/src/append/product-slots.ejs +1 -9
- package/src/index.js +17 -12
- package/src/utils/configProps.js +29 -0
- package/src/utils/lighten-color.js +20 -0
- package/src/utils/widget-initializer.js +60 -0
- package/src/widgets/questions/Questions.vue +436 -0
- package/src/widgets/questions/index.js +10 -0
- package/src/widgets/ratings/Rating.vue +223 -0
- package/src/widgets/ratings/index.js +232 -0
- package/src/widgets/reviews/Reviews.vue +317 -288
- package/src/widgets/reviews/components/Quickview.vue +390 -0
- package/src/widgets/reviews/components/Rating.vue +106 -0
- package/src/widgets/reviews/components/RatingBreakdown.vue +171 -0
- package/src/widgets/reviews/components/RatingHistogram.vue +306 -0
- package/src/widgets/reviews/components/RatingSummary.vue +226 -0
- package/src/widgets/reviews/components/RatingSummaryG.vue +104 -0
- package/src/widgets/reviews/components/ReviewCard.vue +223 -0
- package/src/widgets/reviews/{ReviewReply.vue → components/ReviewReply.vue} +42 -1
- package/src/widgets/reviews/{Score.vue → components/Score.vue} +3 -4
- package/src/widgets/reviews/{Sort.vue → components/Sort.vue} +1 -1
- package/src/widgets/reviews/components/SortDropdown.vue +184 -0
- package/src/widgets/reviews/components/VerifiedPurchase.vue +121 -0
- package/src/widgets/reviews/headers/Center.vue +248 -0
- package/src/widgets/reviews/headers/Compact.vue +225 -0
- package/src/widgets/reviews/headers/Histogram.vue +224 -0
- package/src/widgets/reviews/headers/Padrao.vue +113 -0
- package/src/widgets/reviews/headers/Summary.vue +217 -0
- package/src/widgets/reviews/index.js +2 -48
- package/src/append/body.ejs +0 -79
- package/src/append/head.ejs +0 -5
- package/src/append/stamps.ejs +0 -3
- package/src/widgets/reviews/AuthorAndRating.vue +0 -30
- package/src/widgets/reviews/AverageScore.vue +0 -160
- package/src/widgets/reviews/AverageTotal.vue +0 -35
- package/src/widgets/reviews/CardReview.vue +0 -87
- package/src/widgets/reviews/GridView.vue +0 -113
- package/src/widgets/reviews/HeaderExpanded.vue +0 -84
- package/src/widgets/reviews/HeaderMinimal.vue +0 -110
- package/src/widgets/reviews/ListView.vue +0 -47
- package/src/widgets/reviews/Quickview.vue +0 -397
- package/src/widgets/reviews/ReviewBody.vue +0 -39
- package/src/widgets/reviews/ThumbsPictures.vue +0 -135
- package/src/widgets/reviews/Total.vue +0 -79
- package/src/widgets/reviews/VerifiedPurchase.vue +0 -110
- package/src/widgets/reviews/isRecommended.vue +0 -44
- package/src/widgets/snippets/Rating.vue +0 -71
- package/src/widgets/snippets/Snippets.vue +0 -311
- package/src/widgets/snippets/index.js +0 -45
- /package/src/widgets/reviews/{VideoPlayer.vue → components/VideoPlayer.vue} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack://widgetMartan/./src/widgets/reviews/Score.vue?1837","webpack://widgetMartan/./src/widgets/reviews/Score.vue?bda0","webpack://widgetMartan/./src/widgets/reviews/Score.vue?ddb7","webpack://widgetMartan/./src/utils/textToNumber.js","webpack://widgetMartan/src/widgets/reviews/Score.vue","webpack://widgetMartan/./src/widgets/reviews/Score.vue?8ad5","webpack://widgetMartan/./src/utils/get-width.js","webpack://widgetMartan/./src/widgets/reviews/Score.vue","webpack://widgetMartan/./src/widgets/reviews/Score.vue?4cc2"],"names":["content","__esModule","default","module","i","locals","exports","add","___CSS_LOADER_API_IMPORT___","push","numberToText","text","name","props","reviews","type","Object","list","orderRating","total","average","one","two","three","four","five","averageTotal","offset","starColor","String","data","maxReviews","methods","getWidth","rating","toFixed","setRating","e","removeClass","Promise","resolve","Array","from","$refs","options","children","map","option","style","removeProperty","childNodes","stroke","color","classList","remove","catch","console","error","el","opacity","forEach","index","$parent","$emit","component","_vm","this","_h","$createElement","_c","_self","ref","staticClass","_l","key","on","$event","_v","_s","staticStyle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,EAAI,iRAAiR,eAAe,IAAI,KAAO,sBAAsBX,EAAG,MAAM,CAACG,YAAY,mBAAmB,CAACH,EAAG,MAAM,CAACG,YAAY,gBAAgBxB,MAAM,CACpoCiC,MAAOhB,EAAIhC,SAASgC,EAAInD,QAAS+C,GACjC,mBAAoBI,EAAIrC,WAAa,WAChCyC,EAAG,MAAM,CAACG,YAAY,mBAAmB,CAACH,EAAG,OAAO,CAACJ,EAAIY,GAAGZ,EAAIa,GAAGb,EAAInD,QAAQM,QAAQ6C,EAAIvD,aAAamD,QAAYQ,EAAG,OAAO,CAACJ,EAAIY,GAAG,IAAIZ,EAAIa,GAAGb,EAAIhC,SAASgC,EAAInD,QAAS+C,IAAQ,OAAOQ,EAAG,OAAO,CAACG,YAAY,oBAAoB,CAACH,EAAG,MAAM,CAACG,YAAY,iCAAiCQ,MAAM,CAAC,MAAQ,6BAA6B,MAAQ,KAAK,OAAS,KAAK,QAAU,YAAY,eAAe,IAAI,OAAS,eAAe,KAAO,OAAO,iBAAiB,QAAQ,kBAAkB,UAAU,CAACX,EAAG,OAAO,CAACW,MAAM,CAAC,OAAS,OAAO,EAAI,gBAAgB,KAAO,UAAUX,EAAG,OAAO,CAACW,MAAM,CAAC,EAAI,kBAAkBX,EAAG,OAAO,CAACW,MAAM,CAAC,EAAI,2BAA0B,KAC/nB,IDQpB,EACA,KACA,KACA,MAIa,UAAAhB,E","file":"widget-martan.4.min.js","sourcesContent":["// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../../../../node_modules/css-loader/dist/cjs.js!../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Score.vue?vue&type=style&index=0&id=ced6d2fe&prod&lang=css\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../../../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"774c1cb8\", content, true, {});","export * from \"-!../../../../../node_modules/vue-style-loader/index.js!../../../../../node_modules/css-loader/dist/cjs.js!../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Score.vue?vue&type=style&index=0&id=ced6d2fe&prod&lang=css\"","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \".mt-rating-remove{align-items:center;cursor:pointer;display:flex;visibility:hidden}.mt-rating__list.is-active .mt-rating-remove{visibility:visible}.mt-average__options li:hover{cursor:pointer}.mt-rating__list{align-items:center;display:flex;height:23px;transition:opacity .25s ease-in-out}.mt-rating__list.is-active .mt-rating-total,.mt-rating__list:hover .mt-rating-total{visibility:visible}.mt-rating__list:hover{opacity:.9}.mt-rating-meter{background-color:#e3e6e6;border-radius:50px;box-shadow:inset 0 0 0 1px #e3e6e6;display:flex;height:10px;overflow:hidden;width:100%}.mt-average__options{list-style:none;margin:0;max-width:800px;padding:0;width:100%}.mt-rating-star{align-items:center;justify-content:space-around;margin-left:5px;width:30px}.mt-rating-star,.mt-rating-total{color:#757373;display:flex;font-size:12px}.mt-rating-total{gap:3px;margin-left:2px;visibility:hidden;width:50px}\", \"\"]);\n// Exports\nmodule.exports = exports;\n","const textToNumber = (number) => {\n switch (number) {\n case 'one':\n return 1\n case 'two':\n return 2\n case 'three':\n return 3\n case 'four':\n return 4\n case 'five':\n return 5\n }\n}\n\nconst numberToText = (text) => {\n switch (text) {\n case 1:\n return 'one'\n case 2:\n return 'two'\n case 3:\n return 'three'\n case 4:\n return 'four'\n case 5:\n return 'five'\n }\n}\n\nexport { textToNumber, numberToText }\n","<template>\n <ul class=\"mt-average__options\" ref=\"options\">\n <li class=\"mt-rating__list\" v-for=\"index in maxReviews\" :key=\"index\"\n @click=\"(reviews.total === 0 ? null : setRating($event, index))\">\n <div class=\"mt-rating-star\">\n <span>{{ index }}</span>\n\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"14\" height=\"14\" viewBox=\"0 0 24 24\" stroke-width=\"2\"\n stroke=\"#E6E3E3\" style=\"color:#E6E3E3;\" fill=\"none\" stroke-linecap=\"round\" stroke-linejoin=\"round\">\n <path stroke=\"none\" d=\"M0 0h24v24H0z\" fill=\"none\" />\n <path\n d=\"M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z\"\n stroke-width=\"0\" fill=\"currentColor\" />\n </svg>\n </div>\n\n\n <div class=\"mt-rating-meter\">\n <div class=\"mt-rating-bar\" v-bind:style=\"{\n width: getWidth(reviews, index),\n 'background-color': starColor || 'red',\n }\" />\n </div>\n\n <div class=\"mt-rating-total\">\n <span>{{ reviews.average[numberToText(index)] }}</span>\n <span>({{ getWidth(reviews, index) }})</span>\n\n <span class=\"mt-rating-remove\"><svg xmlns=\"http://www.w3.org/2000/svg\" class=\"icon icon-tabler icon-tabler-x\"\n width=\"15\" height=\"15\" viewBox=\"0 0 24 24\" stroke-width=\"2\" stroke=\"currentColor\" fill=\"none\"\n stroke-linecap=\"round\" stroke-linejoin=\"round\">\n <path stroke=\"none\" d=\"M0 0h24v24H0z\" fill=\"none\"></path>\n <path d=\"M18 6l-12 12\"></path>\n <path d=\"M6 6l12 12\"></path>\n </svg></span>\n </div>\n </li>\n </ul>\n</template>\n\n<script>\nimport { getWidth } from './../../utils/get-width'\nimport { numberToText } from './../../utils/textToNumber'\n\nexport default {\n name: 'Score',\n\n props: {\n reviews: {\n type: Object,\n default: {\n list: [],\n orderRating: null,\n total: 0,\n average: {\n one: 0,\n two: 0,\n three: 0,\n four: 0,\n five: 0\n },\n averageTotal: 0,\n offset: 0,\n }\n },\n\n starColor: {\n type: String,\n default: '#212529'\n },\n },\n\n data () {\n return {\n maxReviews: 5,\n };\n },\n\n methods: {\n getWidth,\n numberToText,\n setRating: async function (e, rating) {\n const removeClass = () =>\n new Promise((resolve) => {\n const res = Array.from(this.$refs.options.children).map((option) => {\n option.style.removeProperty(\"opacity\");\n option.children[0].childNodes[2].style.stroke = \"rgb(227, 230, 230)\";\n option.children[0].childNodes[2].style.color = 'rgb(227, 230, 230)';\n\n return option.classList.remove(\"is-active\");\n });\n resolve(res);\n });\n\n await removeClass().catch(e => console.error(e))\n\n if (rating !== this.reviews.orderRating) {\n const el = Array.from(this.$refs.options.children)[rating - 1];\n el.classList.add(\"is-active\");\n el.style.opacity = 1;\n el.children[0].childNodes[2].style.stroke = this.starColor;\n el.children[0].childNodes[2].style.color = this.starColor;\n Array.from(this.$refs.options.children).forEach((option, index) => {\n if (index !== rating - 1) {\n option.style.opacity = \".5\";\n }\n });\n }\n\n this.$parent.$emit('updateOrderByAverage', { rating })\n },\n },\n};\n</script>\n\n\n<style>\n.mt-rating-remove {\n visibility: hidden;\n cursor: pointer;\n display: flex;\n align-items: center;\n}\n\n.mt-rating__list.is-active .mt-rating-remove {\n visibility: visible;\n}\n\n.mt-average__options li:hover {\n cursor: pointer;\n}\n\n.mt-rating__list {\n display: flex;\n align-items: center;\n height: 23px;\n transition: opacity .25s ease-in-out;\n}\n\n.mt-rating__list.is-active .mt-rating-total,\n.mt-rating__list:hover .mt-rating-total {\n visibility: visible;\n}\n\n.mt-rating__list:hover {\n opacity: 0.9;\n}\n\n.mt-rating-meter {\n overflow: hidden;\n box-shadow: inset 0 0 0 1px #e3e6e6;\n background-color: #e3e6e6;\n height: 10px;\n width: 100%;\n border-radius: 50px;\n display: flex;\n}\n\n.mt-average__options {\n margin: 0;\n list-style: none;\n padding: 0;\n max-width: 800px;\n width: 100%;\n}\n\n.mt-rating-star {\n display: flex;\n width: 30px;\n justify-content: space-around;\n font-size: 12px;\n color: #757373;\n align-items: center;\n margin-left: 5px;\n}\n\n.mt-rating-total {\n visibility: hidden;\n width: 50px;\n font-size: 12px;\n color: #757373;\n margin-left: 2px;\n display: flex;\n gap: 3px;\n}\n</style>\n","import mod from \"-!../../../../../node_modules/babel-loader/lib/index.js!../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Score.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../../node_modules/babel-loader/lib/index.js!../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Score.vue?vue&type=script&lang=js\"","import { numberToText } from './textToNumber'\n\n// calcula a % usando a média de avaliacoes / total de avaliacoes do produto\nexport function getWidth(reviews, rating) {\n if (reviews.total === 0) return '0%'\n\n return `${(\n (100 * reviews.average[numberToText(rating)]) /\n reviews.total\n ).toFixed()}%`\n}\n","import { render, staticRenderFns } from \"./Score.vue?vue&type=template&id=ced6d2fe\"\nimport script from \"./Score.vue?vue&type=script&lang=js\"\nexport * from \"./Score.vue?vue&type=script&lang=js\"\nimport style0 from \"./Score.vue?vue&type=style&index=0&id=ced6d2fe&prod&lang=css\"\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 () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('ul',{ref:\"options\",staticClass:\"mt-average__options\"},_vm._l((_vm.maxReviews),function(index){return _c('li',{key:index,staticClass:\"mt-rating__list\",on:{\"click\":function($event){(_vm.reviews.total === 0 ? null : _vm.setRating($event, index))}}},[_c('div',{staticClass:\"mt-rating-star\"},[_c('span',[_vm._v(_vm._s(index))]),_c('svg',{staticStyle:{\"color\":\"#E6E3E3\"},attrs:{\"xmlns\":\"http://www.w3.org/2000/svg\",\"width\":\"14\",\"height\":\"14\",\"viewBox\":\"0 0 24 24\",\"stroke-width\":\"2\",\"stroke\":\"#E6E3E3\",\"fill\":\"none\",\"stroke-linecap\":\"round\",\"stroke-linejoin\":\"round\"}},[_c('path',{attrs:{\"stroke\":\"none\",\"d\":\"M0 0h24v24H0z\",\"fill\":\"none\"}}),_c('path',{attrs:{\"d\":\"M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z\",\"stroke-width\":\"0\",\"fill\":\"currentColor\"}})])]),_c('div',{staticClass:\"mt-rating-meter\"},[_c('div',{staticClass:\"mt-rating-bar\",style:({\n width: _vm.getWidth(_vm.reviews, index),\n 'background-color': _vm.starColor || 'red',\n })})]),_c('div',{staticClass:\"mt-rating-total\"},[_c('span',[_vm._v(_vm._s(_vm.reviews.average[_vm.numberToText(index)]))]),_c('span',[_vm._v(\"(\"+_vm._s(_vm.getWidth(_vm.reviews, index))+\")\")]),_c('span',{staticClass:\"mt-rating-remove\"},[_c('svg',{staticClass:\"icon icon-tabler icon-tabler-x\",attrs:{\"xmlns\":\"http://www.w3.org/2000/svg\",\"width\":\"15\",\"height\":\"15\",\"viewBox\":\"0 0 24 24\",\"stroke-width\":\"2\",\"stroke\":\"currentColor\",\"fill\":\"none\",\"stroke-linecap\":\"round\",\"stroke-linejoin\":\"round\"}},[_c('path',{attrs:{\"stroke\":\"none\",\"d\":\"M0 0h24v24H0z\",\"fill\":\"none\"}}),_c('path',{attrs:{\"d\":\"M18 6l-12 12\"}}),_c('path',{attrs:{\"d\":\"M6 6l12 12\"}})])])])])}),0)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }"],"sourceRoot":""}
|
|
1
|
+
{"version":3,"sources":["webpack://widgetMartan/./src/widgets/reviews/headers/Center.vue?1993","webpack://widgetMartan/./src/widgets/reviews/headers/Center.vue?b993","webpack://widgetMartan/src/widgets/reviews/headers/Center.vue","webpack://widgetMartan/./src/widgets/reviews/headers/Center.vue","webpack://widgetMartan/./src/widgets/reviews/components/Rating.vue?a507","webpack://widgetMartan/./src/widgets/reviews/components/Rating.vue?cca9","webpack://widgetMartan/./src/widgets/reviews/components/Rating.vue?34e3","webpack://widgetMartan/src/widgets/reviews/components/Rating.vue","webpack://widgetMartan/./src/widgets/reviews/components/Rating.vue","webpack://widgetMartan/./src/widgets/reviews/components/RatingBreakdown.vue?98ff","webpack://widgetMartan/./src/widgets/reviews/components/Rating.vue?6f6d","webpack://widgetMartan/./src/widgets/reviews/components/Rating.vue?4189","webpack://widgetMartan/./src/widgets/reviews/components/RatingBreakdown.vue?eff2","webpack://widgetMartan/./src/widgets/reviews/components/RatingBreakdown.vue?4ab9","webpack://widgetMartan/./src/widgets/reviews/components/SortDropdown.vue?8af5","webpack://widgetMartan/./src/widgets/reviews/components/RatingBreakdown.vue?d63f","webpack://widgetMartan/./src/widgets/reviews/components/RatingBreakdown.vue?03ac","webpack://widgetMartan/src/widgets/reviews/components/RatingBreakdown.vue","webpack://widgetMartan/./src/widgets/reviews/components/RatingBreakdown.vue","webpack://widgetMartan/./src/widgets/reviews/components/SortDropdown.vue?8885","webpack://widgetMartan/./src/widgets/reviews/components/SortDropdown.vue?1fd2","webpack://widgetMartan/./src/widgets/reviews/components/SortDropdown.vue?a094","webpack://widgetMartan/./src/widgets/reviews/components/SortDropdown.vue?4238","webpack://widgetMartan/src/widgets/reviews/components/SortDropdown.vue","webpack://widgetMartan/./src/widgets/reviews/components/SortDropdown.vue","webpack://widgetMartan/./src/widgets/reviews/headers/Center.vue?1288","webpack://widgetMartan/./src/widgets/reviews/headers/Center.vue?283a","webpack://widgetMartan/./src/widgets/reviews/headers/Center.vue?f071","webpack://widgetMartan/./src/widgets/reviews/headers/Center.vue?0e2f","webpack://widgetMartan/./src/widgets/reviews/headers/Center.vue?a5f8","webpack://widgetMartan/./src/widgets/reviews/headers/Center.vue?114a"],"names":["name","components","RatingBreakdown","SortDropdown","props","configProp","rating","type","Object","default","five","four","three","two","one","recommended","Number","average","totalRating","data","showDropdown","showFilter","currentSort","currentActive","computed","formatReviewsCount","toFixed","replace","toLocaleString","methods","lightenColor","toggleDropdown","onRatingSelected","$emit","onSortSelected","sortValue","toggleFilter","component","_vm","this","_h","$createElement","_c","_self","staticClass","style","backgroundColor","config","widget_review","star_color","attrs","_v","_s","on","$event","content","__esModule","module","i","locals","exports","add","color","String","stars","Array","fill","mounted","updateStars","Math","max","min","map","_","index","getStarClass","star","getStarFill","watch","_l","key","class","_e","___CSS_LOADER_API_IMPORT___","push","ratingBreakdown","houverColor","getBarWidth","count","selectRating","Rating","parseInt","width","visible","Boolean","sortOptions","value","label","addClickOutsideListener","beforeDestroy","removeClickOutsideListener","newValue","$nextTick","selectSort","document","addEventListener","handleClickOutside","removeEventListener","event","target","classList","contains","nodeName","$refs","dropdown","ref","_m","option"],"mappings":"yHAAA,I,+BCA6M,ECsD9L,CACfA,KAAA,SAEAC,WAAA,CACAC,oBACAC,kBAGAC,MAAA,IACAC,IAEAC,OAAA,CACAC,KAAAC,OACAC,aAAA,CACAC,KAAA,EACAC,KAAA,EACAC,MAAA,EACAC,IAAA,EACAC,IAAA,KAIAC,YAAA,CACAR,KAAAS,OACAP,QAAA,GAGAQ,QAAA,CACAV,KAAAS,OACAP,QAAA,GAGAS,YAAA,CACAX,KAAAS,OACAP,QAAA,IAIAU,UACA,CACAC,cAAA,EACAC,YAAA,EACAC,YAAA,cACAC,cAAA,OAIAC,SAAA,CACAC,q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AA+B,CAAzKL,KAA8KY,GAAG,gCGWjb,EACA,KACA,WACA,MAIa,IAAAd,E,4BChBf,IAAIkB,EAAU,EAAQ,IACnBA,EAAQC,aAAYD,EAAUA,EAAQ9C,SACnB,iBAAZ8C,IAAsBA,EAAU,CAAC,CAACE,EAAOC,EAAIH,EAAS,MAC7DA,EAAQI,SAAQF,EAAOG,QAAUL,EAAQI,SAG/BE,EADH,EAAQ,GAA2EpD,SAC5E,WAAY8C,GAAS,EAAM,K,mBCN5C,IAAIA,EAAU,EAAQ,IACnBA,EAAQC,aAAYD,EAAUA,EAAQ9C,SACnB,iBAAZ8C,IAAsBA,EAAU,CAAC,CAACE,EAAOC,EAAIH,EAAS,MAC7DA,EAAQI,SAAQF,EAAOG,QAAUL,EAAQI,SAG/BE,EADH,EAAQ,GAA2EpD,SAC5E,WAAY8C,GAAS,EAAM,K,gCCT5C,O,oBCEAK,EADkC,EAAQ,EAChCuB,EAA4B,IAE9BC,KAAK,CAAC3B,EAAOC,EAAI,0EAA2E,KAEpGD,EAAOG,QAAUA,G,gCCNjB,O,oBCEAA,EADkC,EAAQ,EAChCuB,EAA4B,IAE9BC,KAAK,CAAC3B,EAAOC,EAAI,sgDAAugD,KAEhiDD,EAAOG,QAAUA","file":"widget-martan.4.min.js","sourcesContent":["var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"mrtn-header--center\"},[_c('div',{staticClass:\"mrtn-header__main\"},[_c('div',{staticClass:\"mrtn-average-section\"},[_c('div',{staticClass:\"mrtn-average-icon\",style:({ backgroundColor: _vm.lightenColor(_vm.config.widget_review.star_color, 0.8) })},[_c('svg',{attrs:{\"xmlns\":\"http://www.w3.org/2000/svg\",\"width\":\"18\",\"height\":\"18\",\"viewBox\":\"0 0 24 24\",\"stroke\":_vm.config.widget_review.star_color,\"fill\":_vm.average > 0 ? _vm.config.widget_review.star_color : 'none',\"stroke-width\":\"2\",\"stroke-linecap\":\"round\",\"stroke-linejoin\":\"round\"}},[_c('defs',[_c('linearGradient',{attrs:{\"id\":'starGradient' + _vm.average}},[_c('stop',{attrs:{\"offset\":\"0%\",\"stop-color\":_vm.config.widget_review.star_color}}),_c('stop',{attrs:{\"offset\":((_vm.average < 5 ? _vm.average - 1 : _vm.average) / 5) *\n 100 +\n '%',\"stop-color\":_vm.config.widget_review.star_color}}),_c('stop',{attrs:{\"offset\":((_vm.average < 5 ? _vm.average - 1 : _vm.average) / 5) *\n 100 +\n '%',\"stop-color\":\"transparent\"}}),_c('stop',{attrs:{\"offset\":\"100%\",\"stop-color\":\"transparent\"}})],1)],1),_c('path',{attrs:{\"stroke\":\"none\",\"d\":\"M0 0h24v24H0z\",\"fill\":\"none\"}}),_c('path',{attrs:{\"d\":\"M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z\",\"fill\":(\"url(#starGradient\" + _vm.average + \")\")}})])]),_c('div',{staticClass:\"mrtn-average-info\"},[_c('span',{staticClass:\"mrtn-average-score\"},[_vm._v(_vm._s(_vm.average.toFixed(1)))]),_c('span',{staticClass:\"mrtn-total-reviews\"},[_vm._v(_vm._s(_vm.formatReviewsCount)+\" Avaliações\")])])])]),_c('RatingBreakdown',{attrs:{\"config\":_vm.config,\"rating\":_vm.rating,\"total-rating\":_vm.totalRating,\"current-active\":_vm.currentActive},on:{\"rating-selected\":_vm.onRatingSelected}}),_c('div',{staticClass:\"mrtn-filter-container\"},[_c('button',{staticClass:\"mrtn-filter-btn\",on:{\"click\":_vm.toggleFilter}},[_vm._v(\" Ordenar por \")]),_c('SortDropdown',{attrs:{\"visible\":_vm.showFilter,\"current-sort\":_vm.currentSort},on:{\"sort-selected\":_vm.onSortSelected,\"close\":function($event){_vm.showFilter = false}}})],1)],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import mod from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Center.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Center.vue?vue&type=script&lang=js\"","<template>\n <div class=\"mrtn-header--center\">\n <div class=\"mrtn-header__main\">\n <div class=\"mrtn-average-section\">\n <div class=\"mrtn-average-icon\" :style=\"{ backgroundColor: lightenColor(config.widget_review.star_color, 0.8) }\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"18\" height=\"18\" viewBox=\"0 0 24 24\" :stroke=\"config.widget_review.star_color\"\n :fill=\"average > 0 ? config.widget_review.star_color : 'none'\" stroke-width=\"2\" stroke-linecap=\"round\"\n stroke-linejoin=\"round\">\n <defs>\n <linearGradient :id=\"'starGradient' + average\">\n <stop offset=\"0%\" :stop-color=\"config.widget_review.star_color\" />\n <stop :offset=\"((average < 5 ? average - 1 : average) / 5) *\n 100 +\n '%'\n \" :stop-color=\"config.widget_review.star_color\" />\n <stop :offset=\"((average < 5 ? average - 1 : average) / 5) *\n 100 +\n '%'\n \" stop-color=\"transparent\" />\n <stop offset=\"100%\" stop-color=\"transparent\" />\n </linearGradient>\n </defs>\n <path stroke=\"none\" d=\"M0 0h24v24H0z\" fill=\"none\" />\n <path\n d=\"M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z\"\n :fill=\"`url(#starGradient${average})`\" />\n </svg>\n </div>\n <div class=\"mrtn-average-info\">\n <span class=\"mrtn-average-score\">{{ average.toFixed(1) }}</span>\n <span class=\"mrtn-total-reviews\">{{ formatReviewsCount }} Avaliações</span>\n </div>\n </div>\n </div>\n\n <RatingBreakdown :config=\"config\" :rating=\"rating\" :total-rating=\"totalRating\" :current-active=\"currentActive\"\n @rating-selected=\"onRatingSelected\" />\n\n <div class=\"mrtn-filter-container\">\n <button class=\"mrtn-filter-btn\" @click=\"toggleFilter\">\n Ordenar por\n </button>\n\n <SortDropdown :visible=\"showFilter\" :current-sort=\"currentSort\" @sort-selected=\"onSortSelected\" @close=\"showFilter = false\" />\n </div>\n </div>\n</template>\n\n<script>\nimport RatingBreakdown from '../components/RatingBreakdown.vue'\nimport SortDropdown from '../components/SortDropdown.vue'\nimport { configProp } from \"../../../utils/configProps\";\nimport { lightenColor } from \"../../../utils/lighten-color\";\n\nexport default {\n name: 'Center',\n\n components: {\n RatingBreakdown,\n SortDropdown\n },\n\n props: {\n ...configProp,\n\n rating: {\n type: Object,\n default: () => ({\n five: 0,\n four: 0,\n three: 0,\n two: 0,\n one: 0\n })\n },\n\n recommended: {\n type: Number,\n default: 0\n },\n\n average: {\n type: Number,\n default: 0\n },\n\n totalRating: {\n type: Number,\n default: 0\n }\n },\n\n data() {\n return {\n showDropdown: true,\n showFilter: false,\n currentSort: 'most_recent',\n currentActive: null\n }\n },\n\n computed: {\n formatReviewsCount() {\n if (this.totalRating >= 1000) {\n return (this.totalRating / 1000).toFixed(1).replace('.0', '') + 'k'\n }\n return this.totalRating.toLocaleString()\n }\n },\n\n methods: {\n lightenColor,\n toggleDropdown() {\n this.showDropdown = !this.showDropdown\n },\n\n onRatingSelected(rating) {\n if (this.currentActive === rating) {\n this.currentActive = null\n this.$emit('rating-selected', null)\n } else {\n this.currentActive = rating\n this.$emit('rating-selected', rating)\n }\n },\n\n onSortSelected(sortValue) {\n this.currentSort = sortValue\n this.showFilter = false\n this.$emit('sort-selected', sortValue)\n },\n\n toggleFilter() {\n this.showFilter = !this.showFilter\n this.$emit('filter-toggle', this.showFilter)\n },\n }\n}\n</script>\n\n<style lang=\"scss\">\n.mrtn-header--center .mrtn-rating-breakdown {\n max-width: 520px;\n width: 100%;\n}\n</style>\n\n<style lang=\"scss\" scoped>\n.mrtn-filter-container {\n position: relative;\n\n .mrtn-filter-btn {\n border: none;\n background: transparent;\n cursor: pointer;\n color: #000000;\n transition: all 0.2s ease;\n\n &:hover {\n color: #666666;\n }\n\n &:active {\n transform: scale(0.95);\n }\n }\n}\n\n.mrtn-header--center {\n display: flex;\n flex-direction: column;\n align-items: center;\n background: white;\n position: relative;\n gap: 12px;\n}\n\n.mrtn-header__main {\n display: flex;\n align-items: center;\n gap: 16px;\n max-width: 320px;\n width: 100%;\n justify-content: center;\n}\n\n.mrtn-average-section {\n display: flex;\n align-items: center;\n gap: 12px;\n}\n\n.mrtn-average-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 40px;\n height: 40px;\n border-radius: 8px;\n}\n\n.mrtn-average-info {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n}\n\n.mrtn-average-score {\n font-size: 32px;\n font-weight: 700;\n color: #000000;\n line-height: 1;\n}\n\n.mrtn-total-reviews {\n font-size: 14px;\n color: #666666;\n margin-top: 4px;\n}\n\n.mrtn-dropdown-toggle {\n display: flex;\n align-items: center;\n justify-content: center;\n width: 32px;\n height: 32px;\n border: 1px solid #e5e5e5;\n border-radius: 6px;\n background: white;\n cursor: pointer;\n color: #000000;\n transition: all 0.2s ease;\n\n &:hover {\n border-color: #cccccc;\n background: #f8f8f8;\n }\n\n &:active {\n transform: scale(0.95);\n }\n\n svg {\n width: 12px;\n height: 12px;\n }\n}\n</style>\n","import { render, staticRenderFns } from \"./Center.vue?vue&type=template&id=3eefd51d&scoped=true\"\nimport script from \"./Center.vue?vue&type=script&lang=js\"\nexport * from \"./Center.vue?vue&type=script&lang=js\"\nimport style0 from \"./Center.vue?vue&type=style&index=0&id=3eefd51d&prod&lang=scss\"\nimport style1 from \"./Center.vue?vue&type=style&index=1&id=3eefd51d&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 \"3eefd51d\",\n null\n \n)\n\nexport default component.exports","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Rating.vue?vue&type=style&index=0&id=39af319e&prod&lang=css\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../../../../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"5a552598\", content, true, {});","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('span',{staticClass:\"martan-rating\"},_vm._l((_vm.stars),function(star,index){return _c('svg',{key:index,staticClass:\"icon icon-tabler\",class:_vm.getStarClass(star),style:({ color: _vm.color }),attrs:{\"xmlns\":\"http://www.w3.org/2000/svg\",\"width\":\"14\",\"height\":\"14\",\"viewBox\":\"0 0 24 24\",\"stroke-width\":\"2\",\"stroke\":\"currentColor\",\"fill\":\"none\",\"stroke-linecap\":\"round\",\"stroke-linejoin\":\"round\"}},[(star === 0.5)?_c('defs',[_c('linearGradient',{attrs:{\"id\":(\"gradient-\" + index),\"x1\":\"0%\",\"y1\":\"0%\",\"x2\":\"100%\",\"y2\":\"0%\"}},[_c('stop',{style:((\"stop-color:\" + _vm.color + \";stop-opacity:1\")),attrs:{\"offset\":\"50%\"}}),_c('stop',{style:((\"stop-color:\" + _vm.color + \";stop-opacity:0\")),attrs:{\"offset\":\"50%\"}})],1)],1):_vm._e(),_c('path',{attrs:{\"stroke\":\"none\",\"d\":\"M0 0h24v24H0z\",\"fill\":\"none\"}}),_c('path',{attrs:{\"d\":\"M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z\",\"fill\":_vm.getStarFill(star, index)}})])}),0)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import mod from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Rating.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Rating.vue?vue&type=script&lang=js\"","<template>\n <span class=\"martan-rating\">\n <svg\n v-for=\"(star, index) in stars\"\n :key=\"index\"\n xmlns=\"http://www.w3.org/2000/svg\"\n class=\"icon icon-tabler\"\n :class=\"getStarClass(star)\"\n width=\"14\"\n height=\"14\"\n viewBox=\"0 0 24 24\"\n stroke-width=\"2\"\n stroke=\"currentColor\"\n fill=\"none\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n :style=\"{ color }\"\n >\n <defs v-if=\"star === 0.5\">\n <linearGradient :id=\"`gradient-${index}`\" x1=\"0%\" y1=\"0%\" x2=\"100%\" y2=\"0%\">\n <stop offset=\"50%\" :style=\"`stop-color:${color};stop-opacity:1`\" />\n <stop offset=\"50%\" :style=\"`stop-color:${color};stop-opacity:0`\" />\n </linearGradient>\n </defs>\n <path stroke=\"none\" d=\"M0 0h24v24H0z\" fill=\"none\" />\n <path\n d=\"M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z\"\n :fill=\"getStarFill(star, index)\" />\n </svg>\n </span>\n</template>\n\n<script>\nexport default {\n name: 'Rating',\n\n props: {\n rating: {\n type: Number,\n default: 5\n },\n\n color: {\n type: String,\n default: \"#000000\"\n },\n },\n\n data() {\n return {\n stars: Array(5).fill(0)\n };\n },\n\n mounted() {\n this.updateStars();\n },\n\n methods: {\n updateStars() {\n const rating = Math.max(0, Math.min(5, this.rating));\n this.stars = Array(5).fill(0).map((_, index) => {\n const starPosition = index + 1;\n if (rating >= starPosition) {\n return 1;\n } else if (rating > index) {\n return 0.5;\n } else {\n return 0;\n }\n });\n },\n\n getStarClass(star) {\n if (star === 1) {\n return 'icon-tabler-star-filled';\n } else if (star === 0.5) {\n return 'icon-tabler-star-half';\n } else {\n return 'icon-tabler-star';\n }\n },\n\n getStarFill(star, index) {\n if (star === 1) {\n return 'currentColor';\n } else if (star === 0.5) {\n return `url(#gradient-${index})`;\n } else {\n return 'none';\n }\n }\n },\n\n watch: {\n rating: 'updateStars'\n }\n};\n</script>\n\n<style lang=\"css\">\n.martan-rating {\n display: flex;\n gap: 4px;\n}\n</style>\n","import { render, staticRenderFns } from \"./Rating.vue?vue&type=template&id=39af319e\"\nimport script from \"./Rating.vue?vue&type=script&lang=js\"\nexport * from \"./Rating.vue?vue&type=script&lang=js\"\nimport style0 from \"./Rating.vue?vue&type=style&index=0&id=39af319e&prod&lang=css\"\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","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./RatingBreakdown.vue?vue&type=style&index=0&id=121d360c&prod&lang=scss&scoped=true\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../../../../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"8c4908ae\", content, true, {});","export * from \"-!../../../../../../node_modules/vue-style-loader/index.js!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Rating.vue?vue&type=style&index=0&id=39af319e&prod&lang=css\"","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../../../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \".martan-rating{display:flex;gap:4px}\", \"\"]);\n// Exports\nmodule.exports = exports;\n","export * from \"-!../../../../../../node_modules/vue-style-loader/index.js!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./RatingBreakdown.vue?vue&type=style&index=0&id=121d360c&prod&lang=scss&scoped=true\"","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../../../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \".mrtn-rating-breakdown[data-v-121d360c]{display:flex;flex-direction:column;width:100%}.mrtn-rating-row[data-v-121d360c]{align-items:center;border-radius:6px;cursor:pointer;display:flex;gap:12px;padding:8px;position:relative;transition:all .2s ease}.mrtn-rating-row--active[data-v-121d360c],.mrtn-rating-row[data-v-121d360c]:hover{background:var(--hover-color)}.mrtn-rating-row--active[data-v-121d360c]{box-shadow:0 0 0 2px var(--hover-color);transform:scale(1.02);z-index:10}.mrtn-rating-breakdown--has-active .mrtn-rating-row[data-v-121d360c]:not(.mrtn-rating-row--active){filter:grayscale(.8);opacity:.4}.mrtn-rating-stars[data-v-121d360c]{display:flex;gap:2px;min-width:80px}.mrtn-rating-star[data-v-121d360c]{color:#e5e5e5;font-size:14px}.mrtn-rating-star--filled[data-v-121d360c]{color:#000}.mrtn-rating-bar[data-v-121d360c]{background:#f0f0f0;border-radius:4px;flex:1;height:8px;overflow:hidden;position:relative;transition:all .2s ease}.mrtn-rating-bar__fill[data-v-121d360c]{border-radius:4px;height:100%;transition:width .3s ease}.mrtn-rating-count[data-v-121d360c]{color:#666;font-size:12px;min-width:40px;text-align:right}\", \"\"]);\n// Exports\nmodule.exports = exports;\n","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./SortDropdown.vue?vue&type=style&index=0&id=2b3eeb35&prod&lang=scss&scoped=true\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../../../../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"a1278eac\", content, true, {});","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"mrtn-rating-breakdown\",class:{ 'mrtn-rating-breakdown--has-active': _vm.currentActive !== null },style:('--hover-color: ' + _vm.houverColor)},_vm._l((_vm.ratingBreakdown),function(count,stars){return _c('div',{key:stars,staticClass:\"mrtn-rating-row\",class:{ 'mrtn-rating-row--active': _vm.currentActive === stars },on:{\"click\":function($event){return _vm.selectRating(stars)}}},[_c('div',{staticClass:\"mrtn-rating-stars\"},[_c('Rating',{attrs:{\"rating\":parseInt(stars),\"color\":_vm.config.widget_review.star_color}})],1),_c('div',{staticClass:\"mrtn-rating-bar\"},[_c('div',{staticClass:\"mrtn-rating-bar__fill\",style:({\n width: _vm.getBarWidth(count) + '%',\n backgroundColor: _vm.config.widget_review.star_color\n })})]),_c('span',{staticClass:\"mrtn-rating-count\"},[_vm._v(\"(\"+_vm._s(count)+\")\")])])}),0)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import mod from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./RatingBreakdown.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./RatingBreakdown.vue?vue&type=script&lang=js\"","<template>\n <div class=\"mrtn-rating-breakdown\" :style=\"'--hover-color: ' + houverColor\" :class=\"{ 'mrtn-rating-breakdown--has-active': currentActive !== null }\">\n <div v-for=\"(count, stars) in ratingBreakdown\" :key=\"stars\" class=\"mrtn-rating-row\"\n :class=\"{ 'mrtn-rating-row--active': currentActive === stars }\" @click=\"selectRating(stars)\">\n <div class=\"mrtn-rating-stars\">\n <Rating :rating=\"parseInt(stars)\" :color=\"config.widget_review.star_color\" />\n </div>\n\n <div class=\"mrtn-rating-bar\">\n <div class=\"mrtn-rating-bar__fill\" :style=\"{\n width: getBarWidth(count) + '%',\n backgroundColor: config.widget_review.star_color\n }\"></div>\n </div>\n\n <span class=\"mrtn-rating-count\">({{ count }})</span>\n </div>\n </div>\n</template>\n\n<script>\nimport { configProp } from \"../../../utils/configProps\";\nimport Rating from \"./Rating.vue\";\nimport { lightenColor } from \"../../../utils/lighten-color\";\n\nexport default {\n name: 'RatingBreakdown',\n\n props: {\n ...configProp,\n rating: {\n type: Object,\n default: () => ({\n five: 0,\n four: 0,\n three: 0,\n two: 0,\n one: 0\n })\n },\n\n totalRating: {\n type: Number,\n default: 0\n },\n\n\n average: {\n type: Number,\n default: 0\n }\n },\n\n data() {\n return {\n currentActive: null\n }\n },\n\n computed: {\n ratingBreakdown() {\n return {\n 5: this.rating.five,\n 4: this.rating.four,\n 3: this.rating.three,\n 2: this.rating.two,\n 1: this.rating.one\n }\n },\n\n houverColor() {\n if (!this.config.widget_review.star_color) return null\n return lightenColor(this.config.widget_review.star_color, 0.9)\n }\n },\n\n methods: {\n lightenColor,\n getBarWidth(count) {\n if (this.totalRating === 0) return 0\n return (count / this.totalRating) * 100\n },\n\n selectRating(rating) {\n if (this.currentActive === rating) {\n this.currentActive = null\n } else {\n this.currentActive = rating\n }\n this.$emit('rating-selected', this.currentActive)\n }\n },\n\n components: {\n Rating\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.mrtn-rating-breakdown {\n display: flex;\n flex-direction: column;\n width: 100%;\n}\n\n.mrtn-rating-row {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 8px;\n border-radius: 6px;\n cursor: pointer;\n transition: all 0.2s ease;\n position: relative;\n\n &:hover {\n background: var(--hover-color);\n }\n\n &--active {\n background: var(--hover-color);\n box-shadow: 0 0 0 2px var(--hover-color);\n transform: scale(1.02);\n z-index: 10;\n }\n}\n\n.mrtn-rating-breakdown--has-active .mrtn-rating-row:not(.mrtn-rating-row--active) {\n opacity: 0.4;\n filter: grayscale(0.8);\n}\n\n.mrtn-rating-stars {\n display: flex;\n gap: 2px;\n min-width: 80px;\n}\n\n.mrtn-rating-star {\n font-size: 14px;\n color: #e5e5e5;\n\n &--filled {\n color: #000000;\n }\n}\n\n.mrtn-rating-bar {\n flex: 1;\n height: 8px;\n background: #f0f0f0;\n border-radius: 4px;\n overflow: hidden;\n position: relative;\n transition: all 0.2s ease;\n}\n\n.mrtn-rating-bar__fill {\n height: 100%;\n border-radius: 4px;\n transition: width 0.3s ease;\n}\n\n.mrtn-rating-count {\n font-size: 12px;\n color: #666666;\n min-width: 40px;\n text-align: right;\n}\n</style>\n","import { render, staticRenderFns } from \"./RatingBreakdown.vue?vue&type=template&id=121d360c&scoped=true\"\nimport script from \"./RatingBreakdown.vue?vue&type=script&lang=js\"\nexport * from \"./RatingBreakdown.vue?vue&type=script&lang=js\"\nimport style0 from \"./RatingBreakdown.vue?vue&type=style&index=0&id=121d360c&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 \"121d360c\",\n null\n \n)\n\nexport default component.exports","export * from \"-!../../../../../../node_modules/vue-style-loader/index.js!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./SortDropdown.vue?vue&type=style&index=0&id=2b3eeb35&prod&lang=scss&scoped=true\"","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../../../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \".mrtn-sort-dropdown[data-v-2b3eeb35]{background:#fff;border:1px solid #e5e5e5;border-radius:8px;box-shadow:0 4px 12px rgba(0,0,0,.1);margin-top:8px;min-width:200px;padding:16px;position:absolute;right:0;top:100%;z-index:1000}.mrtn-sort-dropdown__header[data-v-2b3eeb35]{margin-bottom:12px}.mrtn-sort-dropdown__title[data-v-2b3eeb35]{color:#000;font-size:16px;font-weight:600;margin:0}.mrtn-sort-dropdown__options[data-v-2b3eeb35]{display:flex;flex-direction:column;gap:4px}.mrtn-sort-option[data-v-2b3eeb35]{align-items:center;border-radius:4px;cursor:pointer;display:flex;justify-content:space-between;padding:8px 12px;transition:background-color .2s ease}.mrtn-sort-option[data-v-2b3eeb35]:hover{background:#f8f8f8}.mrtn-sort-option--active[data-v-2b3eeb35]{background:#f0f0f0}.mrtn-sort-option__text[data-v-2b3eeb35]{color:#000;font-size:14px;font-weight:400}.mrtn-sort-option__check[data-v-2b3eeb35]{color:#000;flex-shrink:0}.mrtn-sort-dropdown__footer[data-v-2b3eeb35]{margin-top:12px;text-align:right}.mrtn-sort-dropdown__powered[data-v-2b3eeb35]{color:#999;font-size:11px}\", \"\"]);\n// Exports\nmodule.exports = exports;\n","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return (_vm.visible)?_c('div',{ref:\"dropdown\",staticClass:\"mrtn-sort-dropdown\"},[_vm._m(0),_c('div',{staticClass:\"mrtn-sort-dropdown__options\"},_vm._l((_vm.sortOptions),function(option){return _c('div',{key:option.value,staticClass:\"mrtn-sort-option\",class:{ 'mrtn-sort-option--active': _vm.currentSort === option.value },on:{\"click\":function($event){return _vm.selectSort(option.value)}}},[_c('span',{staticClass:\"mrtn-sort-option__text\"},[_vm._v(_vm._s(option.label))]),(_vm.currentSort === option.value)?_c('svg',{staticClass:\"mrtn-sort-option__check\",attrs:{\"width\":\"16\",\"height\":\"16\",\"viewBox\":\"0 0 16 16\",\"fill\":\"none\"}},[_c('path',{attrs:{\"d\":\"M13.5 4.5L6 12L2.5 8.5\",\"stroke\":\"currentColor\",\"stroke-width\":\"2\",\"stroke-linecap\":\"round\",\"stroke-linejoin\":\"round\"}})]):_vm._e()])}),0),_vm._m(1)]):_vm._e()}\nvar staticRenderFns = [function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"mrtn-sort-dropdown__header\"},[_c('h3',{staticClass:\"mrtn-sort-dropdown__title\"},[_vm._v(\"Ordenar por\")])])},function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"mrtn-sort-dropdown__footer\"},[_c('span',{staticClass:\"mrtn-sort-dropdown__powered\"},[_vm._v(\"Powered by MARTAN.app\")])])}]\n\nexport { render, staticRenderFns }","import mod from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./SortDropdown.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./SortDropdown.vue?vue&type=script&lang=js\"","<template>\n <div v-if=\"visible\" ref=\"dropdown\" class=\"mrtn-sort-dropdown\">\n <div class=\"mrtn-sort-dropdown__header\">\n <h3 class=\"mrtn-sort-dropdown__title\">Ordenar por</h3>\n </div>\n\n <div class=\"mrtn-sort-dropdown__options\">\n <div\n v-for=\"option in sortOptions\"\n :key=\"option.value\"\n class=\"mrtn-sort-option\"\n :class=\"{ 'mrtn-sort-option--active': currentSort === option.value }\"\n @click=\"selectSort(option.value)\"\n >\n <span class=\"mrtn-sort-option__text\">{{ option.label }}</span>\n <svg\n v-if=\"currentSort === option.value\"\n class=\"mrtn-sort-option__check\"\n width=\"16\"\n height=\"16\"\n viewBox=\"0 0 16 16\"\n fill=\"none\"\n >\n <path d=\"M13.5 4.5L6 12L2.5 8.5\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/>\n </svg>\n </div>\n </div>\n\n <div class=\"mrtn-sort-dropdown__footer\">\n <span class=\"mrtn-sort-dropdown__powered\">Powered by MARTAN.app</span>\n </div>\n </div>\n</template>\n\n<script>\nexport default {\n name: 'SortDropdown',\n\n props: {\n visible: {\n type: Boolean,\n default: false\n },\n\n currentSort: {\n type: String,\n default: 'most_recent'\n }\n },\n\n data() {\n return {\n sortOptions: [\n { value: 'most_recent', label: 'Recentes' },\n { value: 'most_voted', label: 'Mais úteis' },\n { value: 'most_positive', label: 'Positivas' },\n { value: 'most_negative', label: 'Negativas' }\n ]\n }\n },\n\n mounted() {\n this.addClickOutsideListener()\n },\n\n beforeDestroy() {\n this.removeClickOutsideListener()\n },\n\n watch: {\n visible(newValue) {\n if (newValue) {\n this.$nextTick(() => {\n this.addClickOutsideListener()\n })\n } else {\n this.removeClickOutsideListener()\n }\n }\n },\n\n methods: {\n selectSort(sortValue) {\n this.$emit('sort-selected', sortValue)\n },\n\n addClickOutsideListener() {\n document.addEventListener('click', this.handleClickOutside)\n },\n\n removeClickOutsideListener() {\n document.removeEventListener('click', this.handleClickOutside)\n },\n\n handleClickOutside(event) {\n if (!this.visible) return\n if (\n event.target &&\n event.target.classList &&\n event.target.classList.contains('mrtn-filter-btn') &&\n event.target.nodeName !== 'svg' &&\n event.target.nodeName !== 'SVG'\n ) {\n return\n }\n if (this.$refs.dropdown && !this.$refs.dropdown.contains(event.target)) {\n this.$emit('close')\n }\n }\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.mrtn-sort-dropdown {\n position: absolute;\n top: 100%;\n right: 0;\n background: white;\n border: 1px solid #e5e5e5;\n border-radius: 8px;\n box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);\n z-index: 1000;\n margin-top: 8px;\n padding: 16px;\n min-width: 200px;\n}\n\n.mrtn-sort-dropdown__header {\n margin-bottom: 12px;\n}\n\n.mrtn-sort-dropdown__title {\n font-size: 16px;\n font-weight: 600;\n color: #000000;\n margin: 0;\n}\n\n.mrtn-sort-dropdown__options {\n display: flex;\n flex-direction: column;\n gap: 4px;\n}\n\n.mrtn-sort-option {\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding: 8px 12px;\n border-radius: 4px;\n cursor: pointer;\n transition: background-color 0.2s ease;\n\n &:hover {\n background: #f8f8f8;\n }\n\n &--active {\n background: #f0f0f0;\n }\n}\n\n.mrtn-sort-option__text {\n font-size: 14px;\n color: #000000;\n font-weight: 400;\n}\n\n.mrtn-sort-option__check {\n color: #000000;\n flex-shrink: 0;\n}\n\n.mrtn-sort-dropdown__footer {\n margin-top: 12px;\n text-align: right;\n}\n\n.mrtn-sort-dropdown__powered {\n font-size: 11px;\n color: #999999;\n}\n</style>\n","import { render, staticRenderFns } from \"./SortDropdown.vue?vue&type=template&id=2b3eeb35&scoped=true\"\nimport script from \"./SortDropdown.vue?vue&type=script&lang=js\"\nexport * from \"./SortDropdown.vue?vue&type=script&lang=js\"\nimport style0 from \"./SortDropdown.vue?vue&type=style&index=0&id=2b3eeb35&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 \"2b3eeb35\",\n null\n \n)\n\nexport default component.exports","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Center.vue?vue&type=style&index=0&id=3eefd51d&prod&lang=scss\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../../../../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"23c55671\", content, true, {});","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Center.vue?vue&type=style&index=1&id=3eefd51d&prod&lang=scss&scoped=true\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../../../../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"1bbba03d\", content, true, {});","export * from \"-!../../../../../../node_modules/vue-style-loader/index.js!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Center.vue?vue&type=style&index=0&id=3eefd51d&prod&lang=scss\"","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../../../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \".mrtn-header--center .mrtn-rating-breakdown{max-width:520px;width:100%}\", \"\"]);\n// Exports\nmodule.exports = exports;\n","export * from \"-!../../../../../../node_modules/vue-style-loader/index.js!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Center.vue?vue&type=style&index=1&id=3eefd51d&prod&lang=scss&scoped=true\"","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../../../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \".mrtn-filter-container[data-v-3eefd51d]{position:relative}.mrtn-filter-container .mrtn-filter-btn[data-v-3eefd51d]{background:transparent;border:none;color:#000;cursor:pointer;transition:all .2s ease}.mrtn-filter-container .mrtn-filter-btn[data-v-3eefd51d]:hover{color:#666}.mrtn-filter-container .mrtn-filter-btn[data-v-3eefd51d]:active{transform:scale(.95)}.mrtn-header--center[data-v-3eefd51d]{align-items:center;background:#fff;display:flex;flex-direction:column;gap:12px;position:relative}.mrtn-header__main[data-v-3eefd51d]{align-items:center;display:flex;gap:16px;justify-content:center;max-width:320px;width:100%}.mrtn-average-section[data-v-3eefd51d]{align-items:center;display:flex;gap:12px}.mrtn-average-icon[data-v-3eefd51d]{align-items:center;border-radius:8px;display:flex;height:40px;justify-content:center;width:40px}.mrtn-average-info[data-v-3eefd51d]{align-items:flex-start;display:flex;flex-direction:column}.mrtn-average-score[data-v-3eefd51d]{color:#000;font-size:32px;font-weight:700;line-height:1}.mrtn-total-reviews[data-v-3eefd51d]{color:#666;font-size:14px;margin-top:4px}.mrtn-dropdown-toggle[data-v-3eefd51d]{align-items:center;background:#fff;border:1px solid #e5e5e5;border-radius:6px;color:#000;cursor:pointer;display:flex;height:32px;justify-content:center;transition:all .2s ease;width:32px}.mrtn-dropdown-toggle[data-v-3eefd51d]:hover{background:#f8f8f8;border-color:#ccc}.mrtn-dropdown-toggle[data-v-3eefd51d]:active{transform:scale(.95)}.mrtn-dropdown-toggle svg[data-v-3eefd51d]{height:12px;width:12px}\", \"\"]);\n// Exports\nmodule.exports = exports;\n"],"sourceRoot":""}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
(window.webpackJsonpwidgetMartan=window.webpackJsonpwidgetMartan||[]).push([[5],{82:function(t,a,e){"use strict";e.r(a);var l={name:"AverageTotal",props:{average:{type:Number,default:0}}},r=e(2),s=Object(r.a)(l,(function(){var t=this.$createElement,a=this._self._c||t;return a("div",{staticClass:"mt-rating__resume",attrs:{title:"Nota média "+this.average}},[a("div",{staticClass:"mt-rating__average"},[a("div",{staticClass:"mt-rating__average__wrapper"},[a("svg",{staticClass:"icon icon-tabler icon-tabler-star-filled",attrs:{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"}},[a("path",{attrs:{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}}),a("path",{attrs:{d:"M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z","stroke-width":"0",fill:"currentColor"}})])]),a("div",{staticStyle:{"margin-left":"10px"}},[a("p",{staticClass:"mt-rating__average--total"},[this._v(" "+this._s(this.average)+" ")])])])])}),[],!1,null,null,null);a.default=s.exports}}]);
|
|
1
|
+
(window.webpackJsonpwidgetMartan=window.webpackJsonpwidgetMartan||[]).push([[5],{36:function(e,a,t){"use strict";function i(e){const a=Math.floor((new Date-new Date(e))/1e3),t={ano:31536e3,"mês":2592e3,semana:604800,dia:86400,hora:3600,minuto:60,segundo:1};let i;if(0===a)return"Agora";for(const e in t)if(i=Math.floor(a/t[e]),i>0)return 1===i?`${i} ${e} atrás`:"mês"===e?i+" meses atrás":`${i} ${e}s atrás`}t.d(a,"a",(function(){return i}))},37:function(e,a,t){var i=t(45);i.__esModule&&(i=i.default),"string"==typeof i&&(i=[[e.i,i,""]]),i.locals&&(e.exports=i.locals);(0,t(9).default)("36ac3f8a",i,!0,{})},38:function(e,a,t){var i=t(49);i.__esModule&&(i=i.default),"string"==typeof i&&(i=[[e.i,i,""]]),i.locals&&(e.exports=i.locals);(0,t(9).default)("8c871a26",i,!0,{})},39:function(e,a,t){var i=t(51);i.__esModule&&(i=i.default),"string"==typeof i&&(i=[[e.i,i,""]]),i.locals&&(e.exports=i.locals);(0,t(9).default)("414da60f",i,!0,{})},44:function(e,a,t){"use strict";t(37)},45:function(e,a,t){(a=t(8)(!1)).push([e.i,".mt-reply[data-v-35ae7688]{background:var(--white);border-left:3px solid #e6e6e6;border-radius:12px;border-right:1px solid hsla(0,0%,9%,.102);display:flex;flex-direction:column;font-size:15px;gap:10px;line-height:1.6;margin:10px 0 0;padding:20px;width:100%}@media(max-width:580px){.mt-reply[data-v-35ae7688]{margin:10px 0}}.mt-reply__date[data-v-35ae7688]{color:#475569;color:#777;font-weight:400}.mt-reply__body[data-v-35ae7688],.mt-reply__date[data-v-35ae7688]{font-size:14px;text-decoration:none}.mt-reply__body[data-v-35ae7688]{font-weight:600}.mt-reply__wrapper[data-v-35ae7688]{align-items:center;display:flex}",""]),e.exports=a},46:function(e){e.exports=JSON.parse('{"a":"@ecomplus/storefront-twbs","b":"7.3.6"}')},48:function(e,a,t){"use strict";t(38)},49:function(e,a,t){(a=t(8)(!1)).push([e.i,".mt-rating__verified{align-items:center;color:#9e9e9e;display:flex;font-size:10px;font-weight:400;gap:3px}.mt-rating__verified svg{color:var(--success);width:15px}",""]),e.exports=a},50:function(e,a,t){"use strict";t(39)},51:function(e,a,t){(a=t(8)(!1)).push([e.i,".review-card[data-v-3da2753a]{background-color:#f3f3f3;border-radius:8px;height:-moz-max-content;height:max-content;padding:16px;width:100%}.review-card__header[data-v-3da2753a]{align-items:flex-start;display:flex;justify-content:space-between;margin-bottom:1rem}.review-card__author[data-v-3da2753a]{display:flex;flex-direction:column}.review-card__name[data-v-3da2753a]{font-weight:700;margin-bottom:.25rem}.review-card__date[data-v-3da2753a]{color:#71717a;font-size:70%}.review-card__rating[data-v-3da2753a]{display:flex;gap:.25rem}.review-card__content[data-v-3da2753a]{font-size:.9375rem}.review-card__text[data-v-3da2753a]{line-height:1.5;margin-bottom:1rem}.review-card__text-toggle[data-v-3da2753a]{color:#047857;cursor:pointer;font-size:.875rem;line-height:1.25rem}.review-card__images[data-v-3da2753a]{display:flex;flex-wrap:wrap;gap:.5rem}.review-card__images img[data-v-3da2753a]{border-radius:.25rem;cursor:pointer;height:80px;-o-object-fit:cover;object-fit:cover;width:80px}.review-card__text-empty[data-v-3da2753a]{color:#71717a;font-size:70%}.review-card__title[data-v-3da2753a]{font-size:1.125rem;font-weight:500;line-height:1.75rem;margin-bottom:.5rem}.review-card__recommendation[data-v-3da2753a]{color:#047857;font-size:.875rem;line-height:1.25rem;margin-top:1rem}.i-happy-line[data-v-3da2753a]{--un-icon:url(\"data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' margin-bottom='0.22rem' width='1em' height='1em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cpath d='m12.594 23.258l-.012.002l-.071.035l-.02.004l-.014-.004l-.071-.036q-.016-.004-.024.006l-.004.01l-.017.428l.005.02l.01.013l.104.074l.015.004l.012-.004l.104-.074l.012-.016l.004-.017l-.017-.427q-.004-.016-.016-.018m.264-.113l-.014.002l-.184.093l-.01.01l-.003.011l.018.43l.005.012l.008.008l.201.092q.019.005.029-.008l.004-.014l-.034-.614q-.005-.019-.02-.022m-.715.002a.02.02 0 0 0-.027.006l-.006.014l-.034.614q.001.018.017.024l.015-.002l.201-.093l.01-.008l.003-.011l.018-.43l-.003-.012l-.01-.01z'/%3E%3Cpath fill='currentColor' d='M12 4a8 8 0 1 0 0 16a8 8 0 0 0 0-16M2 12C2 6.477 6.477 2 12 2s10 4.477 10 10s-4.477 10-10 10S2 17.523 2 12m6.5-2c-.195 0-.444.124-.606.448a1 1 0 0 1-1.788-.896C6.542 8.68 7.413 8 8.5 8s1.957.68 2.394 1.552a1 1 0 0 1-1.788.896C8.944 10.124 8.696 10 8.5 10m7 0c-.195 0-.444.124-.606.448a1 1 0 1 1-1.788-.896C13.543 8.68 14.413 8 15.5 8s1.957.68 2.394 1.552a1 1 0 0 1-1.788.896c-.162-.324-.41-.448-.606-.448m-6.896 4.338a1 1 0 0 1 1.412-.088c.53.468 1.223.75 1.984.75s1.455-.282 1.984-.75a1 1 0 1 1 1.324 1.5A4.98 4.98 0 0 1 12 17a4.98 4.98 0 0 1-3.308-1.25a1 1 0 0 1-.088-1.412'/%3E%3C/g%3E%3C/svg%3E\");background-color:#047857;color:inherit;display:inline-block;height:1em;margin-bottom:.22rem;-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;vertical-align:middle;width:1em}",""]),e.exports=a},75:function(e,a,t){"use strict";t.r(a);var i=t(36),r=t(27),s={name:"ReviewReply",props:{reply:{type:Object}},computed:{i19storeResponse:()=>"Resposta da loja"},methods:{formatDate:r.formatDate,timeAgo:i.a}},o=(t(44),t(3)),l=Object(o.a)(s,(function(){var e=this,a=e.$createElement,t=e._self._c||a;return e.reply?t("div",{staticClass:"mt-reply__wrapper"},[t("div",{staticStyle:{"margin-right":"10px"}},[t("svg",{staticStyle:{transform:"rotate(180deg)"},attrs:{width:"24px",height:"24px",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"}},[t("path",{attrs:{d:"M10.53 5.03a.75.75 0 10-1.06-1.06l-6.25 6.25a.75.75 0 000 1.06l6.25 6.25a.75.75 0 101.06-1.06L5.56 11.5H17a3.248 3.248 0 013.25 3.248v4.502a.75.75 0 001.5 0v-4.502A4.748 4.748 0 0017 10H5.56l4.97-4.97z"}})])]),t("div",{staticClass:"mt-reply"},[t("span",{staticClass:"mt-reply__body"},[e._v(e._s(e.i19storeResponse)+" · "),t("span",{staticClass:"mt-reply__date",attrs:{title:"Respondido em "+e.formatDate(e.reply.created_at)}},[e._v(e._s(e.timeAgo(e.reply.created_at)))])]),t("span",[e._v(e._s(e.reply.body))])])]):e._e()}),[],!1,null,"35ae7688",null).exports,n=t(46),d=t(26),c=t.n(d);"object"==typeof window&&(window.$=window.jQuery=c.a);var m=c.a,u=function(e,a){return new Promise((function(t){function i(){e.classList.remove("animated",a),t(),clearTimeout(r),e.removeEventListener("animationend",i)}e.classList.add("animated",a);var r=setTimeout(i,e.classList.contains("slower")?800:500);e.addEventListener("animationend",i)}))};"object"==typeof window&&(window.animateCss=u);t(55),t(56),t(57),t(58),t(59),t(60),t(61),t(62),t(47),t(32);const{userAgent:v}=navigator,p=(document.body?document.body.offsetWidth:window.screen.width,v.includes("Safari")&&!v.includes("Chrome")&&/Version\/1[4-9]/i.test(v),/iPad|iPhone|iPod/.test(v)&&!window.MSStream);document.documentMode,p||/Android|webOS|BlackBerry|IEMobile|Opera Mini/i.test(v),n.a,n.b;var w=m,h={name:"VerifiedPurchase",props:{showVerified:{type:Boolean,default:!1}},data:()=>({collapseId:null}),computed:{i19verifiedBuyer:()=>"Comprador verificado",i19howProcessVerifiedMsg:()=>Object(r.i18n)({en_us:"How we verify and process reviews",pt_br:"Como verificamos e processamos avaliações"}),i19useMartanPrivacyMsg:()=>Object(r.i18n)({en_us:"We use Martan, a web-based application that provides an online reviews and marketing solution, to collect, source, process and display reviews on our website.",pt_br:"Utilizamos o Martan, uma aplicação baseada na web que oferece uma solução de avaliações online e marketing, para coletar, originar, processar e exibir avaliações em nosso site."}),i19howWeCollectMsg:()=>Object(r.i18n)({en_us:'We automatically send review requests through Martan to customers for whom we have a record of purchasing products directly from our website. This allows us to verify the reliability of the review through technical means such as the customers email address. Reviews submitted directly through these requests are marked as "Verified Purchase", and the following statement will be displayed in the interface where the review is published: "This review was collected from a verified customer who purchased this item."',pt_br:'Enviamos automaticamente solicitações de avaliações por meio do Martan aos clientes para os quais temos registro de que compraram produtos diretamente em nosso site. Isso nos permite verificar a confiabilidade da avaliação por meio de meios técnicos, como o endereço de e-mail do cliente. As avaliações enviadas diretamente por essas solicitações são marcadas como "Compra verificada", e a seguinte declaração será exibida na interface em que a avaliação for publicada: "Esta avaliação foi coletada de um cliente verificado que comprou este item".'}),i19howClientsReviewMsg:()=>Object(r.i18n)({en_us:"Customers can choose how to rate reviewed products with a score between 1 and 5. The average review score is calculated using a simple mathematical average, which is then rounded to a half or full star rating using standard rounding rules. The average review score includes reviews for which customers received discounts on future purchases for adding a photo or video to their review.",pt_br:"Os clientes podem escolher como avaliar os produtos avaliados com uma pontuação entre 1 e 5. A pontuação média das avaliações é calculada usando uma média matemática simples, que é então arredondada para uma meia ou uma avaliação de estrela completa usando regras padrão de arredondamento. A pontuação média das avaliações inclui avaliações para as quais os clientes receberam descontos em compras futuras por adicionar uma foto ou um vídeo à sua avaliação."})},methods:{open:function(){w("#"+this.collapseId).collapse("toggle")}},mounted:function(){this.collapseId="mt-verified-"+Date.now()}},f=(t(48),{name:"ReviewCard",components:{ReviewReply:l,VerifiedPurchase:Object(o.a)(h,(function(){var e=this,a=e.$createElement,t=e._self._c||a;return t("div",[t("div",{staticClass:"mt-rating__verified"},[t("svg",{staticClass:"icon icon-tabler icon-tabler-discount-check-filled",attrs:{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"}},[t("path",{attrs:{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}}),t("path",{attrs:{d:"M12.01 2.011a3.2 3.2 0 0 1 2.113 .797l.154 .145l.698 .698a1.2 1.2 0 0 0 .71 .341l.135 .008h1a3.2 3.2 0 0 1 3.195 3.018l.005 .182v1c0 .27 .092 .533 .258 .743l.09 .1l.697 .698a3.2 3.2 0 0 1 .147 4.382l-.145 .154l-.698 .698a1.2 1.2 0 0 0 -.341 .71l-.008 .135v1a3.2 3.2 0 0 1 -3.018 3.195l-.182 .005h-1a1.2 1.2 0 0 0 -.743 .258l-.1 .09l-.698 .697a3.2 3.2 0 0 1 -4.382 .147l-.154 -.145l-.698 -.698a1.2 1.2 0 0 0 -.71 -.341l-.135 -.008h-1a3.2 3.2 0 0 1 -3.195 -3.018l-.005 -.182v-1a1.2 1.2 0 0 0 -.258 -.743l-.09 -.1l-.697 -.698a3.2 3.2 0 0 1 -.147 -4.382l.145 -.154l.698 -.698a1.2 1.2 0 0 0 .341 -.71l.008 -.135v-1l.005 -.182a3.2 3.2 0 0 1 3.013 -3.013l.182 -.005h1a1.2 1.2 0 0 0 .743 -.258l.1 -.09l.698 -.697a3.2 3.2 0 0 1 2.269 -.944zm3.697 7.282a1 1 0 0 0 -1.414 0l-3.293 3.292l-1.293 -1.292l-.094 -.083a1 1 0 0 0 -1.32 1.497l2 2l.094 .083a1 1 0 0 0 1.32 -.083l4 -4l.083 -.094a1 1 0 0 0 -.083 -1.32z","stroke-width":"0",fill:"currentColor"}})]),t("span",{attrs:{title:"Esta compra foi auditada por Martan.app"}},[e._v(" "+e._s(e.i19verifiedBuyer)+" ")])]),t("div",{staticClass:"collapse multi-collapse",attrs:{id:e.collapseId}},[t("div",{staticClass:"card card-body"},[t("h5",[e._v(e._s(e.i19howProcessVerifiedMsg))]),t("p",[e._v(" "+e._s(e.i19useMartanPrivacyMsg)+" ")]),t("p",[e._v(" "+e._s(e.i19howWeCollectMsg)+" ")]),t("p",[e._v(" "+e._s(e.i19howClientsReviewMsg)+" ")])])])])}),[],!1,null,null,null).exports},data:()=>({showFullText:!1}),props:{review:{type:Object,required:!0},starColor:{type:String,default:"#212529"},truncateBody:{type:Boolean,default:!0}},methods:{timeAgo:i.a,formatDate:e=>new Date(e).toLocaleDateString("pt-BR",{timeZone:"America/Sao_Paulo"})},computed:{truncatedText(){return this.review.body.substring(0,200)+"..."}},mounted(){const e=Array.from(document.querySelectorAll(".mt-lazy-image")),a=new IntersectionObserver((e,t)=>{e.forEach(e=>{if(e.isIntersecting&&"false"===e.target.dataset.loaded){const t=e.target;t.dataset.loaded=!0,t.src=t.dataset.src,a.unobserve(t)}})});e.forEach(e=>a.observe(e)),this.showFullText=!this.truncateBody}}),_=(t(50),Object(o.a)(f,(function(){var e=this,a=e.$createElement,t=e._self._c||a;return e.review?t("div",{staticClass:"review-card"},[t("div",{staticClass:"review-card__header"},[t("div",{staticClass:"review-card__author"},[t("span",{staticClass:"review-card__name"},[e._v(e._s(e.review.display_name))]),t("span",{staticClass:"review-card__date",attrs:{title:e.timeAgo(e.review.created_at)}},[e._v(e._s(e.formatDate(e.review.created_at)))]),e.review.verified_purchase?t("VerifiedPurchase"):e._e()],1),t("div",{staticClass:"review-card__rating"},e._l(5,(function(a){return t("div",{key:a,staticClass:"review-card__star"},[t("svg",{attrs:{xmlns:"http://www.w3.org/2000/svg",width:"14",height:"14",viewBox:"0 0 24 24",stroke:a<=e.review.rating?e.starColor:"#E6E3E3",fill:a<=e.review.rating?e.starColor:"none","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}},[t("path",{attrs:{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}}),t("path",{attrs:{d:"M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z"}})])])})),0)]),t("div",{staticClass:"review-card__content"},[e.review.title?t("p",{staticClass:"review-card__title"},[e._v(" "+e._s(e.review.title)+" ")]):e._e(),e.review.body?t("p",{staticClass:"review-card__text"},[e._v(" "+e._s(e.showFullText?e.review.body:e.truncatedText)+" "),e.review.body.length>200?t("span",{staticClass:"review-card__text-toggle",on:{click:function(a){e.showFullText=!e.showFullText}}},[e._v(" "+e._s(e.showFullText?"Ver menos":"Ver mais")+" ")]):e._e()]):t("p",{staticClass:"review-card__text-empty"},[e._v("(Avaliação sem comentário)")]),e.review.pictures&&e.review.pictures.length?t("div",{staticClass:"review-card__images"},e._l(e.review.pictures,(function(a,i){return t("img",{directives:[{name:"show",rawName:"v-show",value:a.thumb,expression:"image.thumb"}],key:i,staticClass:"mt-lazy-image",attrs:{"data-loaded":"false","data-src":a.thumb,alt:"Review image "+(i+1)},on:{click:function(a){return e.$emit("openQuickview",{review:e.review,imageIndex:i})}}})})),0):e._e(),e._m(0)]),e.review.reply?t("div",{staticClass:"review-card-reply"},[t("ReviewReply",{attrs:{reply:e.review.reply}})],1):e._e()]):e._e()}),[function(){var e=this.$createElement,a=this._self._c||e;return a("div",{staticClass:"review-card__recommendation"},[a("i",{staticClass:"i-happy-line"}),a("span",{staticClass:"text-sm"},[this._v("Eu comprei e recomendo esse produto")])])}],!1,null,"3da2753a",null));a.default=_.exports}}]);
|
|
2
2
|
//# sourceMappingURL=widget-martan.5.min.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack://widgetMartan/./src/widgets/reviews/AverageTotal.vue?2e5e","webpack://widgetMartan/./src/widgets/reviews/AverageTotal.vue?8a78","webpack://widgetMartan/src/widgets/reviews/AverageTotal.vue","webpack://widgetMartan/./src/widgets/reviews/AverageTotal.vue"],"names":["name","props","average","type","Number","default","component","_h","this","$createElement","_c","_self","staticClass","attrs","staticStyle","_v","_s"],"mappings":"wHAAA,ICA6M,ECC9L,CACfA,KAAA,eAEAC,MAAA,CACAC,QAAA,CACAC,KAAAC,OACAC,QAAA,K,OCAIC,EAAY,YACd,GHRW,WAAa,IAAiBC,EAATC,KAAgBC,eAAmBC,EAAnCF,KAA0CG,MAAMD,IAAIH,EAAG,OAAOG,EAAG,MAAM,CAACE,YAAY,oBAAoBC,MAAM,CAAC,MAAQ,cAAvHL,KAA2IN,UAAU,CAACQ,EAAG,MAAM,CAACE,YAAY,sBAAsB,CAACF,EAAG,MAAM,CAACE,YAAY,+BAA+B,CAACF,EAAG,MAAM,CAACE,YAAY,2CAA2CC,MAAM,CAAC,MAAQ,6BAA6B,MAAQ,KAAK,OAAS,KAAK,QAAU,YAAY,eAAe,IAAI,OAAS,eAAe,KAAO,OAAO,iBAAiB,QAAQ,kBAAkB,UAAU,CAACH,EAAG,OAAO,CAACG,MAAM,CAAC,OAAS,OAAO,EAAI,gBAAgB,KAAO,UAAUH,EAAG,OAAO,CAACG,MAAM,CAAC,EAAI,iRAAiR,eAAe,IAAI,KAAO,sBAAsBH,EAAG,MAAM,CAACI,YAAY,CAAC,cAAc,SAAS,CAACJ,EAAG,IAAI,CAACE,YAAY,6BAA6B,CAApgCJ,KAAygCO,GAAG,IAA5gCP,KAAohCQ,GAAphCR,KAA2hCN,SAAS,eAChjC,IGUpB,EACA,KACA,KACA,MAIa,UAAAI,E","file":"widget-martan.5.min.js","sourcesContent":["var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"mt-rating__resume\",attrs:{\"title\":'Nota média ' + _vm.average}},[_c('div',{staticClass:\"mt-rating__average\"},[_c('div',{staticClass:\"mt-rating__average__wrapper\"},[_c('svg',{staticClass:\"icon icon-tabler icon-tabler-star-filled\",attrs:{\"xmlns\":\"http://www.w3.org/2000/svg\",\"width\":\"24\",\"height\":\"24\",\"viewBox\":\"0 0 24 24\",\"stroke-width\":\"2\",\"stroke\":\"currentColor\",\"fill\":\"none\",\"stroke-linecap\":\"round\",\"stroke-linejoin\":\"round\"}},[_c('path',{attrs:{\"stroke\":\"none\",\"d\":\"M0 0h24v24H0z\",\"fill\":\"none\"}}),_c('path',{attrs:{\"d\":\"M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z\",\"stroke-width\":\"0\",\"fill\":\"currentColor\"}})])]),_c('div',{staticStyle:{\"margin-left\":\"10px\"}},[_c('p',{staticClass:\"mt-rating__average--total\"},[_vm._v(\" \"+_vm._s(_vm.average)+\" \")])])])])}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import mod from \"-!../../../../../node_modules/babel-loader/lib/index.js!../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./AverageTotal.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../../node_modules/babel-loader/lib/index.js!../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./AverageTotal.vue?vue&type=script&lang=js\"","<script>\nexport default {\n name: 'AverageTotal',\n\n props: {\n average: {\n type: Number,\n default: 0\n }\n },\n};\n</script>\n\n<template>\n <div class=\"mt-rating__resume\" :title=\"'Nota média ' + average\">\n <div class=\"mt-rating__average\">\n <div class=\"mt-rating__average__wrapper\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"icon icon-tabler icon-tabler-star-filled\" width=\"24\" height=\"24\"\n viewBox=\"0 0 24 24\" stroke-width=\"2\" stroke=\"currentColor\" fill=\"none\" stroke-linecap=\"round\"\n stroke-linejoin=\"round\">\n <path stroke=\"none\" d=\"M0 0h24v24H0z\" fill=\"none\" />\n <path\n d=\"M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z\"\n stroke-width=\"0\" fill=\"currentColor\" />\n </svg>\n </div>\n\n <div style=\"margin-left: 10px\">\n <p class=\"mt-rating__average--total\">\n {{ average }}\n </p>\n </div>\n </div>\n </div>\n</template>\n","import { render, staticRenderFns } from \"./AverageTotal.vue?vue&type=template&id=5aa088fe\"\nimport script from \"./AverageTotal.vue?vue&type=script&lang=js\"\nexport * from \"./AverageTotal.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":""}
|
|
1
|
+
{"version":3,"sources":["webpack://widgetMartan/./src/utils/time-ago.js","webpack://widgetMartan/./src/widgets/reviews/components/ReviewReply.vue?1552","webpack://widgetMartan/./src/widgets/reviews/components/VerifiedPurchase.vue?97c2","webpack://widgetMartan/./src/widgets/reviews/components/ReviewCard.vue?86c8","webpack://widgetMartan/./src/widgets/reviews/components/ReviewReply.vue?7b6c","webpack://widgetMartan/./src/widgets/reviews/components/ReviewReply.vue?734e","webpack://widgetMartan/./src/widgets/reviews/components/VerifiedPurchase.vue?07cb","webpack://widgetMartan/./src/widgets/reviews/components/VerifiedPurchase.vue?f501","webpack://widgetMartan/./src/widgets/reviews/components/ReviewCard.vue?69aa","webpack://widgetMartan/./src/widgets/reviews/components/ReviewCard.vue?9d98","webpack://widgetMartan/./src/widgets/reviews/components/ReviewCard.vue?95f5","webpack://widgetMartan/./src/widgets/reviews/components/ReviewReply.vue?852f","webpack://widgetMartan/src/widgets/reviews/components/ReviewReply.vue","webpack://widgetMartan/./src/widgets/reviews/components/ReviewReply.vue","webpack://widgetMartan/./src/widgets/reviews/components/ReviewReply.vue?0133","webpack://widgetMartan/../storefront-twbs/src/$.js","webpack://widgetMartan/../storefront-twbs/src/animate-css.js","webpack://widgetMartan/../storefront-twbs/src/_env.js","webpack://widgetMartan/../storefront-twbs/src/index.js","webpack://widgetMartan/./src/widgets/reviews/components/VerifiedPurchase.vue?1474","webpack://widgetMartan/src/widgets/reviews/components/VerifiedPurchase.vue","webpack://widgetMartan/./src/widgets/reviews/components/ReviewCard.vue?2843","webpack://widgetMartan/src/widgets/reviews/components/ReviewCard.vue","webpack://widgetMartan/./src/widgets/reviews/components/VerifiedPurchase.vue","webpack://widgetMartan/./src/widgets/reviews/components/VerifiedPurchase.vue?e0c3","webpack://widgetMartan/./src/widgets/reviews/components/ReviewCard.vue"],"names":["timeAgo","date","segundos","Math","floor","Date","intervalos","ano","mês","semana","dia","hora","minuto","segundo","contador","intervalo","content","__esModule","default","module","i","locals","exports","add","___CSS_LOADER_API_IMPORT___","push","name","props","reply","type","Object","computed","i19storeResponse","methods","formatDate","_vm","this","_h","$createElement","_c","_self","staticClass","staticStyle","attrs","_v","_s","created_at","body","_e","window","$","jQuery","animateCss","$el","animationName","Promise","resolve","handleAnimationEnd","classList","remove","clearTimeout","fallbackTimer","removeEventListener","setTimeout","contains","addEventListener","userAgent","navigator","isIOS","document","offsetWidth","screen","width","includes","test","MSStream","documentMode","version","showVerified","Boolean","data","collapseId","i19verifiedBuyer","i19howProcessVerifiedMsg","i18n","en_us","pt_br","i19useMartanPrivacyMsg","i19howWeCollectMsg","i19howClientsReviewMsg","open","collapse","mounted","now","components","ReviewReply","VerifiedPurchase","showFullText","review","required","starColor","String","truncateBody","toLocaleDateString","timeZone","truncatedText","substring","images","Array","from","querySelectorAll","imageObserver","IntersectionObserver","entries","observer","forEach","entry","isIntersecting","target","dataset","loaded","image","src","unobserve","img","observe","display_name","_l","star","key","rating","title","length","on","$event","pictures","index","directives","rawName","value","expression","thumb","$emit","imageIndex","_m"],"mappings":"iHACO,SAASA,EAASC,GACvB,MAAMC,EAAWC,KAAKC,OAAO,IAAIC,KAAS,IAAIA,KAAKJ,IAAS,KAEtDK,EAAa,CACjBC,IAAK,QACLC,MAAK,OACLC,OAAQ,OACRC,IAAK,MACLC,KAAM,KACNC,OAAQ,GACRC,QAAS,GAGX,IAAIC,EAEJ,GAAiB,IAAbZ,EACF,MAAO,QAGT,IAAK,MAAMa,KAAaT,EAGtB,GAFAQ,EAAWX,KAAKC,MAAMF,EAAWI,EAAWS,IAExCD,EAAW,EACb,OAAiB,IAAbA,EACK,GAAGA,KAAYC,UAEJ,QAAdA,EAC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,EAAG,MAAM,CAACE,YAAY,+BAA+B,CAACF,EAAG,IAAI,CAACE,YAAY,iBAAiBF,EAAG,OAAO,CAACE,YAAY,WAAW,CAA3LL,KAAgMQ,GAAG,8CeW7O,EACA,KACA,WACA,OAIa,Y","file":"widget-martan.5.min.js","sourcesContent":["// Retorna uma hora em formato humanizade\nexport function timeAgo (date) {\n const segundos = Math.floor((new Date() - new Date(date)) / 1000)\n\n const intervalos = {\n ano: 31536000,\n mês: 2592000,\n semana: 604800,\n dia: 86400,\n hora: 3600,\n minuto: 60,\n segundo: 1\n }\n\n let contador\n\n if (segundos === 0) {\n return 'Agora'\n }\n\n for (const intervalo in intervalos) {\n contador = Math.floor(segundos / intervalos[intervalo])\n\n if (contador > 0) {\n if (contador === 1) {\n return `${contador} ${intervalo} atrás`\n } else {\n if (intervalo === 'mês') {\n return `${contador} meses atrás`\n }\n return `${contador} ${intervalo}s atrás`\n }\n }\n }\n}\n","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ReviewReply.vue?vue&type=style&index=0&id=35ae7688&prod&lang=css&scoped=true\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../../../../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"36ac3f8a\", content, true, {});","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./VerifiedPurchase.vue?vue&type=style&index=0&id=74c2f4be&prod&lang=scss\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../../../../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"8c871a26\", content, true, {});","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ReviewCard.vue?vue&type=style&index=0&id=3da2753a&prod&lang=scss&scoped=true\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../../../../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"414da60f\", content, true, {});","export * from \"-!../../../../../../node_modules/vue-style-loader/index.js!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ReviewReply.vue?vue&type=style&index=0&id=35ae7688&prod&lang=css&scoped=true\"","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../../../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \".mt-reply[data-v-35ae7688]{background:var(--white);border-left:3px solid #e6e6e6;border-radius:12px;border-right:1px solid hsla(0,0%,9%,.102);display:flex;flex-direction:column;font-size:15px;gap:10px;line-height:1.6;margin:10px 0 0;padding:20px;width:100%}@media(max-width:580px){.mt-reply[data-v-35ae7688]{margin:10px 0}}.mt-reply__date[data-v-35ae7688]{color:#475569;color:#777;font-weight:400}.mt-reply__body[data-v-35ae7688],.mt-reply__date[data-v-35ae7688]{font-size:14px;text-decoration:none}.mt-reply__body[data-v-35ae7688]{font-weight:600}.mt-reply__wrapper[data-v-35ae7688]{align-items:center;display:flex}\", \"\"]);\n// Exports\nmodule.exports = exports;\n","export * from \"-!../../../../../../node_modules/vue-style-loader/index.js!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./VerifiedPurchase.vue?vue&type=style&index=0&id=74c2f4be&prod&lang=scss\"","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../../../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \".mt-rating__verified{align-items:center;color:#9e9e9e;display:flex;font-size:10px;font-weight:400;gap:3px}.mt-rating__verified svg{color:var(--success);width:15px}\", \"\"]);\n// Exports\nmodule.exports = exports;\n","export * from \"-!../../../../../../node_modules/vue-style-loader/index.js!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ReviewCard.vue?vue&type=style&index=0&id=3da2753a&prod&lang=scss&scoped=true\"","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../../../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \".review-card[data-v-3da2753a]{background-color:#f3f3f3;border-radius:8px;height:-moz-max-content;height:max-content;padding:16px;width:100%}.review-card__header[data-v-3da2753a]{align-items:flex-start;display:flex;justify-content:space-between;margin-bottom:1rem}.review-card__author[data-v-3da2753a]{display:flex;flex-direction:column}.review-card__name[data-v-3da2753a]{font-weight:700;margin-bottom:.25rem}.review-card__date[data-v-3da2753a]{color:#71717a;font-size:70%}.review-card__rating[data-v-3da2753a]{display:flex;gap:.25rem}.review-card__content[data-v-3da2753a]{font-size:.9375rem}.review-card__text[data-v-3da2753a]{line-height:1.5;margin-bottom:1rem}.review-card__text-toggle[data-v-3da2753a]{color:#047857;cursor:pointer;font-size:.875rem;line-height:1.25rem}.review-card__images[data-v-3da2753a]{display:flex;flex-wrap:wrap;gap:.5rem}.review-card__images img[data-v-3da2753a]{border-radius:.25rem;cursor:pointer;height:80px;-o-object-fit:cover;object-fit:cover;width:80px}.review-card__text-empty[data-v-3da2753a]{color:#71717a;font-size:70%}.review-card__title[data-v-3da2753a]{font-size:1.125rem;font-weight:500;line-height:1.75rem;margin-bottom:.5rem}.review-card__recommendation[data-v-3da2753a]{color:#047857;font-size:.875rem;line-height:1.25rem;margin-top:1rem}.i-happy-line[data-v-3da2753a]{--un-icon:url(\\\"data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' margin-bottom='0.22rem' width='1em' height='1em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cpath d='m12.594 23.258l-.012.002l-.071.035l-.02.004l-.014-.004l-.071-.036q-.016-.004-.024.006l-.004.01l-.017.428l.005.02l.01.013l.104.074l.015.004l.012-.004l.104-.074l.012-.016l.004-.017l-.017-.427q-.004-.016-.016-.018m.264-.113l-.014.002l-.184.093l-.01.01l-.003.011l.018.43l.005.012l.008.008l.201.092q.019.005.029-.008l.004-.014l-.034-.614q-.005-.019-.02-.022m-.715.002a.02.02 0 0 0-.027.006l-.006.014l-.034.614q.001.018.017.024l.015-.002l.201-.093l.01-.008l.003-.011l.018-.43l-.003-.012l-.01-.01z'/%3E%3Cpath fill='currentColor' d='M12 4a8 8 0 1 0 0 16a8 8 0 0 0 0-16M2 12C2 6.477 6.477 2 12 2s10 4.477 10 10s-4.477 10-10 10S2 17.523 2 12m6.5-2c-.195 0-.444.124-.606.448a1 1 0 0 1-1.788-.896C6.542 8.68 7.413 8 8.5 8s1.957.68 2.394 1.552a1 1 0 0 1-1.788.896C8.944 10.124 8.696 10 8.5 10m7 0c-.195 0-.444.124-.606.448a1 1 0 1 1-1.788-.896C13.543 8.68 14.413 8 15.5 8s1.957.68 2.394 1.552a1 1 0 0 1-1.788.896c-.162-.324-.41-.448-.606-.448m-6.896 4.338a1 1 0 0 1 1.412-.088c.53.468 1.223.75 1.984.75s1.455-.282 1.984-.75a1 1 0 1 1 1.324 1.5A4.98 4.98 0 0 1 12 17a4.98 4.98 0 0 1-3.308-1.25a1 1 0 0 1-.088-1.412'/%3E%3C/g%3E%3C/svg%3E\\\");background-color:#047857;color:inherit;display:inline-block;height:1em;margin-bottom:.22rem;-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;vertical-align:middle;width:1em}\", \"\"]);\n// Exports\nmodule.exports = exports;\n","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return (_vm.review)?_c('div',{staticClass:\"review-card\"},[_c('div',{staticClass:\"review-card__header\"},[_c('div',{staticClass:\"review-card__author\"},[_c('span',{staticClass:\"review-card__name\"},[_vm._v(_vm._s(_vm.review.display_name))]),_c('span',{staticClass:\"review-card__date\",attrs:{\"title\":_vm.timeAgo(_vm.review.created_at)}},[_vm._v(_vm._s(_vm.formatDate(_vm.review.created_at)))]),(_vm.review.verified_purchase)?_c('VerifiedPurchase'):_vm._e()],1),_c('div',{staticClass:\"review-card__rating\"},_vm._l((5),function(star){return _c('div',{key:star,staticClass:\"review-card__star\"},[_c('svg',{attrs:{\"xmlns\":\"http://www.w3.org/2000/svg\",\"width\":\"14\",\"height\":\"14\",\"viewBox\":\"0 0 24 24\",\"stroke\":star <= _vm.review.rating ? _vm.starColor : '#E6E3E3',\"fill\":star <= _vm.review.rating ? _vm.starColor : 'none',\"stroke-width\":\"2\",\"stroke-linecap\":\"round\",\"stroke-linejoin\":\"round\"}},[_c('path',{attrs:{\"stroke\":\"none\",\"d\":\"M0 0h24v24H0z\",\"fill\":\"none\"}}),_c('path',{attrs:{\"d\":\"M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z\"}})])])}),0)]),_c('div',{staticClass:\"review-card__content\"},[(_vm.review.title)?_c('p',{staticClass:\"review-card__title\"},[_vm._v(\" \"+_vm._s(_vm.review.title)+\" \")]):_vm._e(),(_vm.review.body)?_c('p',{staticClass:\"review-card__text\"},[_vm._v(\" \"+_vm._s(_vm.showFullText ? _vm.review.body : _vm.truncatedText)+\" \"),(_vm.review.body.length > 200)?_c('span',{staticClass:\"review-card__text-toggle\",on:{\"click\":function($event){_vm.showFullText = !_vm.showFullText}}},[_vm._v(\" \"+_vm._s(_vm.showFullText ? \"Ver menos\" : \"Ver mais\")+\" \")]):_vm._e()]):_c('p',{staticClass:\"review-card__text-empty\"},[_vm._v(\"(Avaliação sem comentário)\")]),(_vm.review.pictures && _vm.review.pictures.length)?_c('div',{staticClass:\"review-card__images\"},_vm._l((_vm.review.pictures),function(image,index){return _c('img',{directives:[{name:\"show\",rawName:\"v-show\",value:(image.thumb),expression:\"image.thumb\"}],key:index,staticClass:\"mt-lazy-image\",attrs:{\"data-loaded\":\"false\",\"data-src\":image.thumb,\"alt\":(\"Review image \" + (index + 1))},on:{\"click\":function($event){return _vm.$emit('openQuickview', { review: _vm.review, imageIndex: index })}}})}),0):_vm._e(),_vm._m(0)]),(_vm.review.reply)?_c('div',{staticClass:\"review-card-reply\"},[_c('ReviewReply',{attrs:{\"reply\":_vm.review.reply}})],1):_vm._e()]):_vm._e()}\nvar staticRenderFns = [function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"review-card__recommendation\"},[_c('i',{staticClass:\"i-happy-line\"}),_c('span',{staticClass:\"text-sm\"},[_vm._v(\"Eu comprei e recomendo esse produto\")])])}]\n\nexport { render, staticRenderFns }","import mod from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ReviewReply.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ReviewReply.vue?vue&type=script&lang=js\"","<template>\n <div\n v-if=\"reply\"\n class=\"mt-reply__wrapper\"\n >\n <div style=\"margin-right: 10px\">\n <svg\n width=\"24px\"\n height=\"24px\"\n viewBox=\"0 0 24 24\"\n xmlns=\"http://www.w3.org/2000/svg\"\n style=\"transform: rotate(180deg)\"\n >\n <path\n d=\"M10.53 5.03a.75.75 0 10-1.06-1.06l-6.25 6.25a.75.75 0 000 1.06l6.25 6.25a.75.75 0 101.06-1.06L5.56 11.5H17a3.248 3.248 0 013.25 3.248v4.502a.75.75 0 001.5 0v-4.502A4.748 4.748 0 0017 10H5.56l4.97-4.97z\"\n />\n </svg>\n </div>\n\n <div class=\"mt-reply\">\n <span class=\"mt-reply__body\"\n >{{ i19storeResponse }} ·\n <span\n class=\"mt-reply__date\"\n :title=\"'Respondido em ' + formatDate(reply.created_at)\"\n >{{ timeAgo(reply.created_at) }}</span\n ></span\n >\n <span>{{ reply.body }}</span>\n </div>\n </div>\n</template>\n\n<script>\nimport { formatDate } from \"@ecomplus/utils\";\nimport { timeAgo } from \"../../../utils/time-ago\";\n\nexport default {\n\n name: \"ReviewReply\",\n\n props: {\n reply: {\n type: Object,\n }\n },\n\n computed: {\n i19storeResponse: () => 'Resposta da loja'\n },\n\n methods: {\n formatDate,\n timeAgo\n }\n};\n</script>\n<style lang=\"css\" scoped>\n.mt-reply {\n margin: 10px 0 0;\n display: flex;\n flex-direction: column;\n background: var(--white);\n padding: 20px;\n border-radius: 12px;\n font-size: 15px;\n line-height: 1.6;\n gap: 10px;\n border-right: 1px solid #1717171a;\n border-left: 3px solid rgb(230, 230, 230);\n width: 100%;\n}\n\n@media (max-width: 580px) {\n .mt-reply {\n margin: 10px 0;\n }\n}\n\n.mt-reply__date {\n font-weight: normal;\n font-size: 14px;\n text-decoration: none;\n color: #475569;\n color: #777;\n}\n\n.mt-reply__body {\n font-weight: 600;\n font-size: 14px;\n text-decoration: none;\n}\n\n.mt-reply__wrapper {\n display: flex;\n align-items: center;\n}\n</style>\n","import { render, staticRenderFns } from \"./ReviewReply.vue?vue&type=template&id=35ae7688&scoped=true\"\nimport script from \"./ReviewReply.vue?vue&type=script&lang=js\"\nexport * from \"./ReviewReply.vue?vue&type=script&lang=js\"\nimport style0 from \"./ReviewReply.vue?vue&type=style&index=0&id=35ae7688&prod&lang=css&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 \"35ae7688\",\n null\n \n)\n\nexport default component.exports","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return (_vm.reply)?_c('div',{staticClass:\"mt-reply__wrapper\"},[_c('div',{staticStyle:{\"margin-right\":\"10px\"}},[_c('svg',{staticStyle:{\"transform\":\"rotate(180deg)\"},attrs:{\"width\":\"24px\",\"height\":\"24px\",\"viewBox\":\"0 0 24 24\",\"xmlns\":\"http://www.w3.org/2000/svg\"}},[_c('path',{attrs:{\"d\":\"M10.53 5.03a.75.75 0 10-1.06-1.06l-6.25 6.25a.75.75 0 000 1.06l6.25 6.25a.75.75 0 101.06-1.06L5.56 11.5H17a3.248 3.248 0 013.25 3.248v4.502a.75.75 0 001.5 0v-4.502A4.748 4.748 0 0017 10H5.56l4.97-4.97z\"}})])]),_c('div',{staticClass:\"mt-reply\"},[_c('span',{staticClass:\"mt-reply__body\"},[_vm._v(_vm._s(_vm.i19storeResponse)+\" · \"),_c('span',{staticClass:\"mt-reply__date\",attrs:{\"title\":'Respondido em ' + _vm.formatDate(_vm.reply.created_at)}},[_vm._v(_vm._s(_vm.timeAgo(_vm.reply.created_at)))])]),_c('span',[_vm._v(_vm._s(_vm.reply.body))])])]):_vm._e()}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import $ from 'jquery'\n\nif (typeof window === 'object') {\n window.$ = window.jQuery = $\n}\n\nexport default $\n","var animateCss = function ($el, animationName) {\n return new Promise(function (resolve) {\n function handleAnimationEnd () {\n $el.classList.remove('animated', animationName)\n resolve()\n clearTimeout(fallbackTimer)\n $el.removeEventListener('animationend', handleAnimationEnd)\n }\n\n $el.classList.add('animated', animationName)\n var fallbackTimer = setTimeout(handleAnimationEnd, $el.classList.contains('slower') ? 800 : 500)\n $el.addEventListener('animationend', handleAnimationEnd)\n })\n}\n\nif (typeof window === 'object') {\n window.animateCss = animateCss\n}\n\nexport default animateCss\n","const { userAgent } = navigator\nconst screenWidth = document.body ? document.body.offsetWidth : window.screen.width\n\nexport const isSafari = userAgent.includes('Safari') && !userAgent.includes('Chrome')\n\nexport const isSafariNew = isSafari && /Version\\/1[4-9]/i.test(userAgent)\n\nexport const isIOS = /iPad|iPhone|iPod/.test(userAgent) && !window.MSStream\n\nexport const isIE = !!document.documentMode\n\nexport const isMobile = isIOS || /Android|webOS|BlackBerry|IEMobile|Opera Mini/i.test(userAgent)\n\nexport const isScreenXs = screenWidth <= 575.98\n\nexport const isScreenLg = screenWidth >= 992\n","/*!\n * @ecomplus/storefront-twbs\n * (c) E-Com Club <ti@e-com.club>\n * Released under the MIT License.\n */\n\nimport { name, version } from './../package.json'\n\nimport $ from './$'\nimport animateCss from './animate-css'\nimport './bootstrap'\n\nconst _self = name + '@' + version\n\nexport * from './_env'\n\nexport {\n _self,\n $,\n animateCss\n}\n\nexport default $\n","import mod from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./VerifiedPurchase.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./VerifiedPurchase.vue?vue&type=script&lang=js\"","<template>\n <div>\n <div class=\"mt-rating__verified\">\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n class=\"icon icon-tabler icon-tabler-discount-check-filled\"\n width=\"24\"\n height=\"24\"\n viewBox=\"0 0 24 24\"\n stroke-width=\"2\"\n stroke=\"currentColor\"\n fill=\"none\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n >\n <path stroke=\"none\" d=\"M0 0h24v24H0z\" fill=\"none\" />\n <path\n d=\"M12.01 2.011a3.2 3.2 0 0 1 2.113 .797l.154 .145l.698 .698a1.2 1.2 0 0 0 .71 .341l.135 .008h1a3.2 3.2 0 0 1 3.195 3.018l.005 .182v1c0 .27 .092 .533 .258 .743l.09 .1l.697 .698a3.2 3.2 0 0 1 .147 4.382l-.145 .154l-.698 .698a1.2 1.2 0 0 0 -.341 .71l-.008 .135v1a3.2 3.2 0 0 1 -3.018 3.195l-.182 .005h-1a1.2 1.2 0 0 0 -.743 .258l-.1 .09l-.698 .697a3.2 3.2 0 0 1 -4.382 .147l-.154 -.145l-.698 -.698a1.2 1.2 0 0 0 -.71 -.341l-.135 -.008h-1a3.2 3.2 0 0 1 -3.195 -3.018l-.005 -.182v-1a1.2 1.2 0 0 0 -.258 -.743l-.09 -.1l-.697 -.698a3.2 3.2 0 0 1 -.147 -4.382l.145 -.154l.698 -.698a1.2 1.2 0 0 0 .341 -.71l.008 -.135v-1l.005 -.182a3.2 3.2 0 0 1 3.013 -3.013l.182 -.005h1a1.2 1.2 0 0 0 .743 -.258l.1 -.09l.698 -.697a3.2 3.2 0 0 1 2.269 -.944zm3.697 7.282a1 1 0 0 0 -1.414 0l-3.293 3.292l-1.293 -1.292l-.094 -.083a1 1 0 0 0 -1.32 1.497l2 2l.094 .083a1 1 0 0 0 1.32 -.083l4 -4l.083 -.094a1 1 0 0 0 -.083 -1.32z\"\n stroke-width=\"0\"\n fill=\"currentColor\"\n />\n </svg>\n\n <span title=\"Esta compra foi auditada por Martan.app\"> {{ i19verifiedBuyer }} </span>\n </div>\n <div class=\"collapse multi-collapse\" :id=\"collapseId\">\n <div class=\"card card-body\">\n <h5>{{ i19howProcessVerifiedMsg }}</h5>\n\n <p>\n {{ i19useMartanPrivacyMsg }}\n </p>\n\n <p>\n {{ i19howWeCollectMsg }}\n </p>\n\n <p>\n {{ i19howClientsReviewMsg }}\n </p>\n </div>\n </div>\n </div>\n</template>\n\n<script>\nimport { i18n } from \"@ecomplus/utils\";\nimport $ from \"../../../../../storefront-twbs/src\";\n\nexport default {\n name: \"VerifiedPurchase\",\n\n props: {\n showVerified: {\n type: Boolean,\n default: false,\n },\n },\n\n data() {\n return {\n collapseId: null,\n };\n },\n\n computed: {\n i19verifiedBuyer: () => \"Comprador verificado\",\n i19howProcessVerifiedMsg: () =>\n i18n({\n en_us: \"How we verify and process reviews\",\n pt_br: \"Como verificamos e processamos avaliações\",\n }),\n i19useMartanPrivacyMsg: () =>\n i18n({\n en_us:\n \"We use Martan, a web-based application that provides an online reviews and marketing solution, to collect, source, process and display reviews on our website.\",\n pt_br:\n \"Utilizamos o Martan, uma aplicação baseada na web que oferece uma solução de avaliações online e marketing, para coletar, originar, processar e exibir avaliações em nosso site.\",\n }),\n i19howWeCollectMsg: () =>\n i18n({\n en_us:\n 'We automatically send review requests through Martan to customers for whom we have a record of purchasing products directly from our website. This allows us to verify the reliability of the review through technical means such as the customers email address. Reviews submitted directly through these requests are marked as \"Verified Purchase\", and the following statement will be displayed in the interface where the review is published: \"This review was collected from a verified customer who purchased this item.\"',\n pt_br:\n 'Enviamos automaticamente solicitações de avaliações por meio do Martan aos clientes para os quais temos registro de que compraram produtos diretamente em nosso site. Isso nos permite verificar a confiabilidade da avaliação por meio de meios técnicos, como o endereço de e-mail do cliente. As avaliações enviadas diretamente por essas solicitações são marcadas como \"Compra verificada\", e a seguinte declaração será exibida na interface em que a avaliação for publicada: \"Esta avaliação foi coletada de um cliente verificado que comprou este item\".',\n }),\n i19howClientsReviewMsg: () =>\n i18n({\n en_us:\n \"Customers can choose how to rate reviewed products with a score between 1 and 5. The average review score is calculated using a simple mathematical average, which is then rounded to a half or full star rating using standard rounding rules. The average review score includes reviews for which customers received discounts on future purchases for adding a photo or video to their review.\",\n pt_br:\n \"Os clientes podem escolher como avaliar os produtos avaliados com uma pontuação entre 1 e 5. A pontuação média das avaliações é calculada usando uma média matemática simples, que é então arredondada para uma meia ou uma avaliação de estrela completa usando regras padrão de arredondamento. A pontuação média das avaliações inclui avaliações para as quais os clientes receberam descontos em compras futuras por adicionar uma foto ou um vídeo à sua avaliação.\",\n }),\n },\n\n methods: {\n open: function () {\n $(\"#\" + this.collapseId).collapse(\"toggle\");\n },\n },\n\n mounted: function () {\n this.collapseId = \"mt-verified-\" + Date.now();\n },\n};\n</script>\n\n<style lang=\"scss\">\n.mt-rating__verified {\n color: #9e9e9e;\n font-size: 10px;\n font-weight: 400;\n display: flex;\n align-items: center;\n gap: 3px;\n svg {\n width: 15px;\n color: var(--success);\n }\n}\n</style>\n","import mod from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ReviewCard.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./ReviewCard.vue?vue&type=script&lang=js\"","x<template>\n <div class=\"review-card\" v-if=\"review\">\n <div class=\"review-card__header\">\n <div class=\"review-card__author\">\n <span class=\"review-card__name\">{{ review.display_name }}</span>\n <span class=\"review-card__date\" :title=\"timeAgo(review.created_at)\">{{\n formatDate(review.created_at)\n }}</span>\n\n <VerifiedPurchase v-if=\"review.verified_purchase\" />\n </div>\n <div class=\"review-card__rating\">\n <div v-for=\"star in 5\" :key=\"star\" class=\"review-card__star\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"14\" height=\"14\" viewBox=\"0 0 24 24\"\n :stroke=\"star <= review.rating ? starColor : '#E6E3E3'\" :fill=\"star <= review.rating ? starColor : 'none'\"\n stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\">\n <path stroke=\"none\" d=\"M0 0h24v24H0z\" fill=\"none\" />\n <path\n d=\"M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z\" />\n </svg>\n </div>\n </div>\n </div>\n\n <div class=\"review-card__content\">\n <p class=\"review-card__title\" v-if=\"review.title\">\n {{ review.title }}\n </p>\n\n <p class=\"review-card__text\" v-if=\"review.body\">\n {{ showFullText ? review.body : truncatedText }}\n <span v-if=\"review.body.length > 200\" class=\"review-card__text-toggle\" @click=\"showFullText = !showFullText\">\n {{ showFullText ? \"Ver menos\" : \"Ver mais\" }}\n </span>\n </p>\n <p class=\"review-card__text-empty\" v-else>(Avaliação sem comentário)</p>\n\n <div v-if=\"review.pictures && review.pictures.length\" class=\"review-card__images\">\n <img v-for=\"(image, index) in review.pictures\" :key=\"index\" data-loaded=\"false\" :data-src=\"image.thumb\"\n :alt=\"`Review image ${index + 1}`\" @click=\"$emit('openQuickview', { review, imageIndex: index })\"\n v-show=\"image.thumb\" class=\"mt-lazy-image\" />\n </div>\n\n <div class=\"review-card__recommendation\">\n <i class=\"i-happy-line\"></i>\n <span class=\"text-sm\">Eu comprei e recomendo esse produto</span>\n </div>\n </div>\n\n <div class=\"review-card-reply\" v-if=\"review.reply\">\n <ReviewReply :reply=\"review.reply\" />\n </div>\n </div>\n</template>\n\n<script>\nimport { timeAgo } from \"../../../utils/time-ago\";\nimport ReviewReply from \"./ReviewReply.vue\";\nimport VerifiedPurchase from \"./VerifiedPurchase.vue\";\n\nexport default {\n name: \"ReviewCard\",\n\n components: {\n ReviewReply,\n VerifiedPurchase,\n },\n\n data() {\n return {\n showFullText: false,\n };\n },\n\n props: {\n review: {\n type: Object,\n required: true,\n },\n starColor: {\n type: String,\n default: \"#212529\",\n },\n truncateBody: {\n type: Boolean,\n default: true,\n },\n },\n\n methods: {\n timeAgo,\n formatDate(date) {\n return new Date(date).toLocaleDateString(\"pt-BR\", {\n timeZone: \"America/Sao_Paulo\",\n });\n },\n },\n\n computed: {\n truncatedText() {\n return this.review.body.substring(0, 200) + \"...\";\n },\n },\n\n mounted() {\n const images = Array.from(document.querySelectorAll(\".mt-lazy-image\"));\n const imageObserver = new IntersectionObserver((entries, observer) => {\n entries.forEach((entry) => {\n if (entry.isIntersecting && entry.target.dataset.loaded === \"false\") {\n const image = entry.target;\n image.dataset.loaded = true;\n image.src = image.dataset.src;\n imageObserver.unobserve(image);\n }\n });\n });\n\n images.forEach((img) => imageObserver.observe(img));\n this.showFullText = !this.truncateBody;\n },\n};\n</script>\n\n<style lang=\"scss\" scoped>\n.review-card {\n background-color: #F3F3F3;\n border-radius: 8px;\n padding: 16px;\n width: 100%;\n height: max-content;\n\n &__header {\n display: flex;\n justify-content: space-between;\n align-items: flex-start;\n margin-bottom: 1rem;\n }\n\n &__author {\n display: flex;\n flex-direction: column;\n }\n\n &__name {\n font-weight: bold;\n margin-bottom: 0.25rem;\n }\n\n &__date {\n font-size: 70%;\n color: rgb(113 113 122 / 1);\n }\n\n &__rating {\n display: flex;\n gap: 0.25rem;\n }\n\n &__content {\n font-size: 0.9375rem;\n }\n\n &__text {\n margin-bottom: 1rem;\n line-height: 1.5;\n }\n\n &__text-toggle {\n cursor: pointer;\n color: #047857;\n font-size: 0.875rem;\n line-height: 1.25rem;\n }\n\n &__images {\n display: flex;\n gap: 0.5rem;\n flex-wrap: wrap;\n\n img {\n width: 80px;\n height: 80px;\n object-fit: cover;\n border-radius: 0.25rem;\n cursor: pointer;\n }\n }\n\n &__text-empty {\n font-size: 70%;\n color: rgb(113 113 122 / 1);\n }\n\n &__title {\n font-size: 1.125rem;\n line-height: 1.75rem;\n font-weight: 500;\n margin-bottom: 0.5rem;\n }\n\n &__recommendation {\n margin-top: 1rem;\n color: #047857;\n font-size: 0.875rem;\n line-height: 1.25rem;\n }\n}\n\n.i-happy-line {\n --un-icon: url(\"data:image/svg+xml;utf8,%3Csvg viewBox='0 0 24 24' display='inline-block' vertical-align='middle' margin-bottom='0.22rem' width='1em' height='1em' xmlns='http://www.w3.org/2000/svg' %3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cpath d='m12.594 23.258l-.012.002l-.071.035l-.02.004l-.014-.004l-.071-.036q-.016-.004-.024.006l-.004.01l-.017.428l.005.02l.01.013l.104.074l.015.004l.012-.004l.104-.074l.012-.016l.004-.017l-.017-.427q-.004-.016-.016-.018m.264-.113l-.014.002l-.184.093l-.01.01l-.003.011l.018.43l.005.012l.008.008l.201.092q.019.005.029-.008l.004-.014l-.034-.614q-.005-.019-.02-.022m-.715.002a.02.02 0 0 0-.027.006l-.006.014l-.034.614q.001.018.017.024l.015-.002l.201-.093l.01-.008l.003-.011l.018-.43l-.003-.012l-.01-.01z'/%3E%3Cpath fill='currentColor' d='M12 4a8 8 0 1 0 0 16a8 8 0 0 0 0-16M2 12C2 6.477 6.477 2 12 2s10 4.477 10 10s-4.477 10-10 10S2 17.523 2 12m6.5-2c-.195 0-.444.124-.606.448a1 1 0 0 1-1.788-.896C6.542 8.68 7.413 8 8.5 8s1.957.68 2.394 1.552a1 1 0 0 1-1.788.896C8.944 10.124 8.696 10 8.5 10m7 0c-.195 0-.444.124-.606.448a1 1 0 1 1-1.788-.896C13.543 8.68 14.413 8 15.5 8s1.957.68 2.394 1.552a1 1 0 0 1-1.788.896c-.162-.324-.41-.448-.606-.448m-6.896 4.338a1 1 0 0 1 1.412-.088c.53.468 1.223.75 1.984.75s1.455-.282 1.984-.75a1 1 0 1 1 1.324 1.5A4.98 4.98 0 0 1 12 17a4.98 4.98 0 0 1-3.308-1.25a1 1 0 0 1-.088-1.412'/%3E%3C/g%3E%3C/svg%3E\");\n -webkit-mask: var(--un-icon) no-repeat;\n mask: var(--un-icon) no-repeat;\n -webkit-mask-size: 100% 100%;\n mask-size: 100% 100%;\n background-color: #047857;\n color: inherit;\n display: inline-block;\n vertical-align: middle;\n margin-bottom: 0.22rem;\n width: 1em;\n height: 1em;\n}\n</style>\n","import { render, staticRenderFns } from \"./VerifiedPurchase.vue?vue&type=template&id=74c2f4be\"\nimport script from \"./VerifiedPurchase.vue?vue&type=script&lang=js\"\nexport * from \"./VerifiedPurchase.vue?vue&type=script&lang=js\"\nimport style0 from \"./VerifiedPurchase.vue?vue&type=style&index=0&id=74c2f4be&prod&lang=scss\"\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 () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',[_c('div',{staticClass:\"mt-rating__verified\"},[_c('svg',{staticClass:\"icon icon-tabler icon-tabler-discount-check-filled\",attrs:{\"xmlns\":\"http://www.w3.org/2000/svg\",\"width\":\"24\",\"height\":\"24\",\"viewBox\":\"0 0 24 24\",\"stroke-width\":\"2\",\"stroke\":\"currentColor\",\"fill\":\"none\",\"stroke-linecap\":\"round\",\"stroke-linejoin\":\"round\"}},[_c('path',{attrs:{\"stroke\":\"none\",\"d\":\"M0 0h24v24H0z\",\"fill\":\"none\"}}),_c('path',{attrs:{\"d\":\"M12.01 2.011a3.2 3.2 0 0 1 2.113 .797l.154 .145l.698 .698a1.2 1.2 0 0 0 .71 .341l.135 .008h1a3.2 3.2 0 0 1 3.195 3.018l.005 .182v1c0 .27 .092 .533 .258 .743l.09 .1l.697 .698a3.2 3.2 0 0 1 .147 4.382l-.145 .154l-.698 .698a1.2 1.2 0 0 0 -.341 .71l-.008 .135v1a3.2 3.2 0 0 1 -3.018 3.195l-.182 .005h-1a1.2 1.2 0 0 0 -.743 .258l-.1 .09l-.698 .697a3.2 3.2 0 0 1 -4.382 .147l-.154 -.145l-.698 -.698a1.2 1.2 0 0 0 -.71 -.341l-.135 -.008h-1a3.2 3.2 0 0 1 -3.195 -3.018l-.005 -.182v-1a1.2 1.2 0 0 0 -.258 -.743l-.09 -.1l-.697 -.698a3.2 3.2 0 0 1 -.147 -4.382l.145 -.154l.698 -.698a1.2 1.2 0 0 0 .341 -.71l.008 -.135v-1l.005 -.182a3.2 3.2 0 0 1 3.013 -3.013l.182 -.005h1a1.2 1.2 0 0 0 .743 -.258l.1 -.09l.698 -.697a3.2 3.2 0 0 1 2.269 -.944zm3.697 7.282a1 1 0 0 0 -1.414 0l-3.293 3.292l-1.293 -1.292l-.094 -.083a1 1 0 0 0 -1.32 1.497l2 2l.094 .083a1 1 0 0 0 1.32 -.083l4 -4l.083 -.094a1 1 0 0 0 -.083 -1.32z\",\"stroke-width\":\"0\",\"fill\":\"currentColor\"}})]),_c('span',{attrs:{\"title\":\"Esta compra foi auditada por Martan.app\"}},[_vm._v(\" \"+_vm._s(_vm.i19verifiedBuyer)+\" \")])]),_c('div',{staticClass:\"collapse multi-collapse\",attrs:{\"id\":_vm.collapseId}},[_c('div',{staticClass:\"card card-body\"},[_c('h5',[_vm._v(_vm._s(_vm.i19howProcessVerifiedMsg))]),_c('p',[_vm._v(\" \"+_vm._s(_vm.i19useMartanPrivacyMsg)+\" \")]),_c('p',[_vm._v(\" \"+_vm._s(_vm.i19howWeCollectMsg)+\" \")]),_c('p',[_vm._v(\" \"+_vm._s(_vm.i19howClientsReviewMsg)+\" \")])])])])}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import { render, staticRenderFns } from \"./ReviewCard.vue?vue&type=template&id=3da2753a&scoped=true\"\nimport script from \"./ReviewCard.vue?vue&type=script&lang=js\"\nexport * from \"./ReviewCard.vue?vue&type=script&lang=js\"\nimport style0 from \"./ReviewCard.vue?vue&type=style&index=0&id=3da2753a&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 \"3da2753a\",\n null\n \n)\n\nexport default component.exports"],"sourceRoot":""}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
(window.webpackJsonpwidgetMartan=window.webpackJsonpwidgetMartan||[]).push([[6],{106:function(t,a,r){"use strict";r.r(a);var e=r(31),i=r(43),n=r(4),o={name:"Summary",components:{Rating:e.a,RatingBreakdown:i.a},props:{...n.a,rating:{type:Object,default:()=>({five:0,four:0,three:0,two:0,one:0})},recommended:{type:Number,default:0},average:{type:Number,default:0},totalRating:{type:Number,default:0}},data:()=>({currentActive:null}),computed:{ratingBreakdown(){return{5:this.rating.five,4:this.rating.four,3:this.rating.three,2:this.rating.two,1:this.rating.one}},formatReviewsCount(){return this.totalRating>=1e3?(this.totalRating/1e3).toFixed(1).replace(".0","")+"k":this.totalRating.toLocaleString()}},methods:{getBarWidth(t){return 0===this.totalRating?0:t/this.totalRating*100},onRatingSelected(t){this.currentActive=t,this.$emit("rating-selected",t)}}},s=(r(90),r(3)),l=Object(s.a)(o,(function(){var t=this,a=t.$createElement,r=t._self._c||a;return r("div",{staticClass:"mrtn-header--summary"},[r("RatingBreakdown",{attrs:{config:t.config,rating:t.rating,"total-rating":t.totalRating,"current-active":t.currentActive},on:{"rating-selected":t.onRatingSelected}}),r("div",{staticClass:"mrtn-summary-container"},[r("div",{staticClass:"mrtn-summary-title"},[r("div",{staticClass:"mrtn-total-responses"},[t._v(t._s(t.formatReviewsCount)+" "+t._s(this.totalRating>1?"Avaliações":"Avaliação"))]),t.recommended>0?r("div",{staticClass:"mrtn-recommendation"},[t._v(" "+t._s(Math.round(t.recommended))+"% dos clientes recomendam esse produto ")]):t._e()]),r("div",{staticClass:"mrtn-average-section"},[r("div",{staticClass:"mrtn-average-display"},[r("div",{staticClass:"mrtn-stars-container"},[r("Rating",{attrs:{rating:t.average,color:t.config.widget_review.star_color}})],1),r("div",{staticClass:"mrtn-average-badge",style:{backgroundColor:t.config.widget_review.star_color}},[t._v(" "+t._s(t.average.toFixed(1))+" / 5 ")])])])])],1)}),[],!1,null,"a03cf414",null);a.default=l.exports},30:function(t,a,r){var e=r(35);e.__esModule&&(e=e.default),"string"==typeof e&&(e=[[t.i,e,""]]),e.locals&&(t.exports=e.locals);(0,r(9).default)("5a552598",e,!0,{})},31:function(t,a,r){"use strict";var e={name:"Rating",props:{rating:{type:Number,default:5},color:{type:String,default:"#000000"}},data:()=>({stars:Array(5).fill(0)}),mounted(){this.updateStars()},methods:{updateStars(){const t=Math.max(0,Math.min(5,this.rating));this.stars=Array(5).fill(0).map((a,r)=>t>=r+1?1:t>r?.5:0)},getStarClass:t=>1===t?"icon-tabler-star-filled":.5===t?"icon-tabler-star-half":"icon-tabler-star",getStarFill:(t,a)=>1===t?"currentColor":.5===t?`url(#gradient-${a})`:"none"},watch:{rating:"updateStars"}},i=(r(34),r(3)),n=Object(i.a)(e,(function(){var t=this,a=t.$createElement,r=t._self._c||a;return r("span",{staticClass:"martan-rating"},t._l(t.stars,(function(a,e){return r("svg",{key:e,staticClass:"icon icon-tabler",class:t.getStarClass(a),style:{color:t.color},attrs:{xmlns:"http://www.w3.org/2000/svg",width:"14",height:"14",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"}},[.5===a?r("defs",[r("linearGradient",{attrs:{id:"gradient-"+e,x1:"0%",y1:"0%",x2:"100%",y2:"0%"}},[r("stop",{style:"stop-color:"+t.color+";stop-opacity:1",attrs:{offset:"50%"}}),r("stop",{style:"stop-color:"+t.color+";stop-opacity:0",attrs:{offset:"50%"}})],1)],1):t._e(),r("path",{attrs:{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}}),r("path",{attrs:{d:"M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z",fill:t.getStarFill(a,e)}})])})),0)}),[],!1,null,null,null);a.a=n.exports},33:function(t,a,r){var e=r(41);e.__esModule&&(e=e.default),"string"==typeof e&&(e=[[t.i,e,""]]),e.locals&&(t.exports=e.locals);(0,r(9).default)("8c4908ae",e,!0,{})},34:function(t,a,r){"use strict";r(30)},35:function(t,a,r){(a=r(8)(!1)).push([t.i,".martan-rating{display:flex;gap:4px}",""]),t.exports=a},40:function(t,a,r){"use strict";r(33)},41:function(t,a,r){(a=r(8)(!1)).push([t.i,".mrtn-rating-breakdown[data-v-121d360c]{display:flex;flex-direction:column;width:100%}.mrtn-rating-row[data-v-121d360c]{align-items:center;border-radius:6px;cursor:pointer;display:flex;gap:12px;padding:8px;position:relative;transition:all .2s ease}.mrtn-rating-row--active[data-v-121d360c],.mrtn-rating-row[data-v-121d360c]:hover{background:var(--hover-color)}.mrtn-rating-row--active[data-v-121d360c]{box-shadow:0 0 0 2px var(--hover-color);transform:scale(1.02);z-index:10}.mrtn-rating-breakdown--has-active .mrtn-rating-row[data-v-121d360c]:not(.mrtn-rating-row--active){filter:grayscale(.8);opacity:.4}.mrtn-rating-stars[data-v-121d360c]{display:flex;gap:2px;min-width:80px}.mrtn-rating-star[data-v-121d360c]{color:#e5e5e5;font-size:14px}.mrtn-rating-star--filled[data-v-121d360c]{color:#000}.mrtn-rating-bar[data-v-121d360c]{background:#f0f0f0;border-radius:4px;flex:1;height:8px;overflow:hidden;position:relative;transition:all .2s ease}.mrtn-rating-bar__fill[data-v-121d360c]{border-radius:4px;height:100%;transition:width .3s ease}.mrtn-rating-count[data-v-121d360c]{color:#666;font-size:12px;min-width:40px;text-align:right}",""]),t.exports=a},43:function(t,a,r){"use strict";var e=r(4),i=r(31),n=r(10),o={name:"RatingBreakdown",props:{...e.a,rating:{type:Object,default:()=>({five:0,four:0,three:0,two:0,one:0})},totalRating:{type:Number,default:0},average:{type:Number,default:0}},data:()=>({currentActive:null}),computed:{ratingBreakdown(){return{5:this.rating.five,4:this.rating.four,3:this.rating.three,2:this.rating.two,1:this.rating.one}},houverColor(){return this.config.widget_review.star_color?Object(n.a)(this.config.widget_review.star_color,.9):null}},methods:{lightenColor:n.a,getBarWidth(t){return 0===this.totalRating?0:t/this.totalRating*100},selectRating(t){this.currentActive===t?this.currentActive=null:this.currentActive=t,this.$emit("rating-selected",this.currentActive)}},components:{Rating:i.a}},s=(r(40),r(3)),l=Object(s.a)(o,(function(){var t=this,a=t.$createElement,r=t._self._c||a;return r("div",{staticClass:"mrtn-rating-breakdown",class:{"mrtn-rating-breakdown--has-active":null!==t.currentActive},style:"--hover-color: "+t.houverColor},t._l(t.ratingBreakdown,(function(a,e){return r("div",{key:e,staticClass:"mrtn-rating-row",class:{"mrtn-rating-row--active":t.currentActive===e},on:{click:function(a){return t.selectRating(e)}}},[r("div",{staticClass:"mrtn-rating-stars"},[r("Rating",{attrs:{rating:parseInt(e),color:t.config.widget_review.star_color}})],1),r("div",{staticClass:"mrtn-rating-bar"},[r("div",{staticClass:"mrtn-rating-bar__fill",style:{width:t.getBarWidth(a)+"%",backgroundColor:t.config.widget_review.star_color}})]),r("span",{staticClass:"mrtn-rating-count"},[t._v("("+t._s(a)+")")])])})),0)}),[],!1,null,"121d360c",null);a.a=l.exports},70:function(t,a,r){var e=r(91);e.__esModule&&(e=e.default),"string"==typeof e&&(e=[[t.i,e,""]]),e.locals&&(t.exports=e.locals);(0,r(9).default)("1bbb3a2b",e,!0,{})},90:function(t,a,r){"use strict";r(70)},91:function(t,a,r){(a=r(8)(!1)).push([t.i,".mrtn-summary-container[data-v-a03cf414]{align-items:center;display:flex;justify-content:space-between;margin-top:1rem}.mrtn-summary-title[data-v-a03cf414]{margin-bottom:20px}.mrtn-summary-title .mrtn-title[data-v-a03cf414]{color:#000;font-size:24px;font-weight:700;margin:0 0 8px}.mrtn-summary-title .mrtn-total-responses[data-v-a03cf414]{color:#333;font-size:20px;font-weight:300}.mrtn-recommendation[data-v-a03cf414]{color:#666;font-size:16px;font-weight:100}@media(max-width:580px){.mrtn-recommendation[data-v-a03cf414]{font-size:12px}}.mrtn-average-section[data-v-a03cf414]{display:flex;justify-content:center;margin-bottom:16px}.mrtn-average-display[data-v-a03cf414]{gap:12px}.mrtn-average-display[data-v-a03cf414],.mrtn-stars-container[data-v-a03cf414]{align-items:center;display:flex}@media(max-width:580px){.mrtn-stars-container[data-v-a03cf414]{display:none}}.mrtn-average-badge[data-v-a03cf414]{background:#ff6b35;border-radius:20px;color:#fff;font-size:14px;font-weight:600;padding:8px 16px}.mrtn-rating-breakdown[data-v-a03cf414]{display:flex;flex-direction:column;gap:8px}.mrtn-rating-row[data-v-a03cf414]{align-items:center;display:flex;gap:12px;padding:4px 0}.mrtn-rating-label[data-v-a03cf414]{color:#666;font-size:12px;min-width:70px;text-align:left}.mrtn-rating-bar[data-v-a03cf414]{background:#f0f0f0;border-radius:6px;flex:1;height:12px;overflow:hidden;position:relative}.mrtn-rating-bar__fill[data-v-a03cf414]{border-radius:6px;height:100%;transition:width .3s ease}.mrtn-rating-count[data-v-a03cf414]{color:#666;font-size:12px;font-weight:500;min-width:40px;text-align:right}",""]),t.exports=a}}]);
|
|
2
|
+
//# sourceMappingURL=widget-martan.6.min.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["webpack://widgetMartan/./src/widgets/reviews/headers/Summary.vue?49d1","webpack://widgetMartan/./src/widgets/reviews/headers/Summary.vue?4791","webpack://widgetMartan/src/widgets/reviews/headers/Summary.vue","webpack://widgetMartan/./src/widgets/reviews/headers/Summary.vue","webpack://widgetMartan/./src/widgets/reviews/components/Rating.vue?a507","webpack://widgetMartan/./src/widgets/reviews/components/Rating.vue?cca9","webpack://widgetMartan/./src/widgets/reviews/components/Rating.vue?34e3","webpack://widgetMartan/src/widgets/reviews/components/Rating.vue","webpack://widgetMartan/./src/widgets/reviews/components/Rating.vue","webpack://widgetMartan/./src/widgets/reviews/components/RatingBreakdown.vue?98ff","webpack://widgetMartan/./src/widgets/reviews/components/Rating.vue?6f6d","webpack://widgetMartan/./src/widgets/reviews/components/Rating.vue?4189","webpack://widgetMartan/./src/widgets/reviews/components/RatingBreakdown.vue?eff2","webpack://widgetMartan/./src/widgets/reviews/components/RatingBreakdown.vue?4ab9","webpack://widgetMartan/./src/widgets/reviews/components/RatingBreakdown.vue?d63f","webpack://widgetMartan/./src/widgets/reviews/components/RatingBreakdown.vue?03ac","webpack://widgetMartan/src/widgets/reviews/components/RatingBreakdown.vue","webpack://widgetMartan/./src/widgets/reviews/components/RatingBreakdown.vue","webpack://widgetMartan/./src/widgets/reviews/headers/Summary.vue?3748","webpack://widgetMartan/./src/widgets/reviews/headers/Summary.vue?0a7d","webpack://widgetMartan/./src/widgets/reviews/headers/Summary.vue?9954"],"names":["name","components","Rating","RatingBreakdown","props","configProp","rating","type","Object","default","five","four","three","two","one","recommended","Number","average","totalRating","data","currentActive","computed","ratingBreakdown","formatReviewsCount","toFixed","replace","toLocaleString","methods","getBarWidth","count","onRatingSelected","$emit","component","_vm","this","_h","$createElement","_c","_self","staticClass","attrs","config","on","_v","_s","Math","round","_e","widget_review","star_color","style","backgroundColor","content","__esModule","module","i","locals","exports","add","color","String","stars","Array","fill","mounted","updateStars","max","min","map","_","index","getStarClass","star","getStarFill","watch","_l","key","class","___CSS_LOADER_API_IMPORT___","push","houverColor","lightenColor","selectRating","$event","parseInt","width"],"mappings":"yHAAA,I,uBCA8M,ECgC/L,CACfA,KAAA,UAEAC,WAAA,CACAC,WACAC,qBAGAC,MAAA,IACAC,IAEAC,OAAA,CACAC,KAAAC,OACAC,aAAA,CACAC,KAAA,EACAC,KAAA,EACAC,MAAA,EACAC,IAAA,EACAC,IAAA,KAIAC,YAAA,CACAR,KAAAS,OACAP,QAAA,GAGAQ,QAAA,CACAV,KAAAS,OACAP,QAAA,GAGAS,YAAA,CACAX,KAAAS,OACAP,QAAA,IAIAU,UACA,CACAC,cAAA,OAIAC,SAAA,CACAC,kBACA,OACA,OAAAhB,OAAAI,KACA,OAAAJ,OAAAK,KACA,OAAAL,OAAAM,MACA,OAAAN,OAAAO,IACA,OAAAP,OAAAQ,MAIAS,qBACA,YAAAL,aAAA,KACA,KAAAA,YAAA,KAAAM,QAAA,GAAAC,QAAA,aAEA,KAAAP,YAAAQ,mBAIAC,QAAA,CACAC,YAAAC,GACA,gBAAAX,YAAA,EACAW,EAAA,KAAAX,YAAA,KAGAY,iBAAAxB,GACA,KAAAc,cAAAd,EACA,KAAAyB,MAAA,kBAAAzB,M,eC/FI0B,EAAY,YACd,GHTW,WAAa,IAAIC,EAAIC,KAASC,EAAGF,EAAIG,eAAmBC,EAAGJ,EAAIK,MAAMD,IAAIF,EAAG,OAAOE,EAAG,MAAM,CAACE,YAAY,wBAAwB,CAACF,EAAG,kBAAkB,CAACG,MAAM,CAAC,OAASP,EAAIQ,OAAO,OAASR,EAAI3B,OAAO,eAAe2B,EAAIf,YAAY,iBAAiBe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AAM,K,gCCT5C,O,oBCEAK,EADkC,EAAQ,EAChCqB,EAA4B,IAE9BC,KAAK,CAACzB,EAAOC,EAAI,ikDAAkkD,KAE3lDD,EAAOG,QAAUA","file":"widget-martan.6.min.js","sourcesContent":["var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"mrtn-header--summary\"},[_c('RatingBreakdown',{attrs:{\"config\":_vm.config,\"rating\":_vm.rating,\"total-rating\":_vm.totalRating,\"current-active\":_vm.currentActive},on:{\"rating-selected\":_vm.onRatingSelected}}),_c('div',{staticClass:\"mrtn-summary-container\"},[_c('div',{staticClass:\"mrtn-summary-title\"},[_c('div',{staticClass:\"mrtn-total-responses\"},[_vm._v(_vm._s(_vm.formatReviewsCount)+\" \"+_vm._s(this.totalRating > 1 ? 'Avaliações' : 'Avaliação'))]),(_vm.recommended > 0)?_c('div',{staticClass:\"mrtn-recommendation\"},[_vm._v(\" \"+_vm._s(Math.round(_vm.recommended))+\"% dos clientes recomendam esse produto \")]):_vm._e()]),_c('div',{staticClass:\"mrtn-average-section\"},[_c('div',{staticClass:\"mrtn-average-display\"},[_c('div',{staticClass:\"mrtn-stars-container\"},[_c('Rating',{attrs:{\"rating\":_vm.average,\"color\":_vm.config.widget_review.star_color}})],1),_c('div',{staticClass:\"mrtn-average-badge\",style:({ backgroundColor: _vm.config.widget_review.star_color })},[_vm._v(\" \"+_vm._s(_vm.average.toFixed(1))+\" / 5 \")])])])])],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import mod from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Summary.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Summary.vue?vue&type=script&lang=js\"","<template>\n <div class=\"mrtn-header--summary\">\n <RatingBreakdown :config=\"config\" :rating=\"rating\" :total-rating=\"totalRating\" :current-active=\"currentActive\"\n @rating-selected=\"onRatingSelected\" />\n\n <div class=\"mrtn-summary-container\">\n <div class=\"mrtn-summary-title\">\n <div class=\"mrtn-total-responses\">{{ formatReviewsCount }} {{ this.totalRating > 1 ? 'Avaliações' : 'Avaliação' }}</div>\n <div v-if=\"recommended > 0\" class=\"mrtn-recommendation\">\n {{ Math.round(recommended) }}% dos clientes recomendam esse produto\n </div>\n </div>\n\n <div class=\"mrtn-average-section\">\n <div class=\"mrtn-average-display\">\n <div class=\"mrtn-stars-container\">\n <Rating :rating=\"average\" :color=\"config.widget_review.star_color\" />\n </div>\n <div class=\"mrtn-average-badge\" :style=\"{ backgroundColor: config.widget_review.star_color }\">\n {{ average.toFixed(1) }} / 5\n </div>\n </div>\n </div>\n </div>\n </div>\n</template>\n\n<script>\nimport Rating from '../components/Rating.vue'\nimport RatingBreakdown from '../components/RatingBreakdown.vue'\nimport { configProp } from \"../../../utils/configProps\";\n\nexport default {\n name: 'Summary',\n\n components: {\n Rating,\n RatingBreakdown\n },\n\n props: {\n ...configProp,\n\n rating: {\n type: Object,\n default: () => ({\n five: 0,\n four: 0,\n three: 0,\n two: 0,\n one: 0\n })\n },\n\n recommended: {\n type: Number,\n default: 0\n },\n\n average: {\n type: Number,\n default: 0\n },\n\n totalRating: {\n type: Number,\n default: 0\n }\n },\n\n data() {\n return {\n currentActive: null\n }\n },\n\n computed: {\n ratingBreakdown() {\n return {\n 5: this.rating.five,\n 4: this.rating.four,\n 3: this.rating.three,\n 2: this.rating.two,\n 1: this.rating.one\n }\n },\n\n formatReviewsCount() {\n if (this.totalRating >= 1000) {\n return (this.totalRating / 1000).toFixed(1).replace('.0', '') + 'k'\n }\n return this.totalRating.toLocaleString()\n }\n },\n\n methods: {\n getBarWidth(count) {\n if (this.totalRating === 0) return 0\n return (count / this.totalRating) * 100\n },\n\n onRatingSelected(rating) {\n this.currentActive = rating\n this.$emit('rating-selected', rating)\n }\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.mrtn-summary-container {\n display: flex;\n align-items: center;\n justify-content: space-between;\n margin-top: 1rem;\n}\n\n.mrtn-summary-title {\n margin-bottom: 20px;\n\n .mrtn-title {\n font-size: 24px;\n font-weight: 700;\n color: #000000;\n margin: 0 0 8px 0;\n }\n\n .mrtn-total-responses {\n font-size: 20px;\n color: #333333;\n font-weight: 300;\n }\n}\n\n.mrtn-recommendation {\n font-size: 16px;\n color: #666666;\n font-weight: 100;\n\n @media (max-width: 580px) {\n font-size: 12px;\n }\n}\n\n.mrtn-average-section {\n display: flex;\n justify-content: center;\n margin-bottom: 16px;\n}\n\n.mrtn-average-display {\n display: flex;\n align-items: center;\n gap: 12px;\n}\n\n.mrtn-stars-container {\n display: flex;\n align-items: center;\n\n @media (max-width: 580px) {\n display: none;\n }\n}\n\n.mrtn-average-badge {\n background: #ff6b35;\n color: white;\n padding: 8px 16px;\n border-radius: 20px;\n font-weight: 600;\n font-size: 14px;\n}\n\n.mrtn-rating-breakdown {\n display: flex;\n flex-direction: column;\n gap: 8px;\n}\n\n.mrtn-rating-row {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 4px 0;\n}\n\n.mrtn-rating-label {\n font-size: 12px;\n color: #666666;\n min-width: 70px;\n text-align: left;\n}\n\n.mrtn-rating-bar {\n flex: 1;\n height: 12px;\n background: #f0f0f0;\n border-radius: 6px;\n overflow: hidden;\n position: relative;\n}\n\n.mrtn-rating-bar__fill {\n height: 100%;\n border-radius: 6px;\n transition: width 0.3s ease;\n}\n\n.mrtn-rating-count {\n font-size: 12px;\n color: #666666;\n min-width: 40px;\n text-align: right;\n font-weight: 500;\n}\n</style>\n","import { render, staticRenderFns } from \"./Summary.vue?vue&type=template&id=a03cf414&scoped=true\"\nimport script from \"./Summary.vue?vue&type=script&lang=js\"\nexport * from \"./Summary.vue?vue&type=script&lang=js\"\nimport style0 from \"./Summary.vue?vue&type=style&index=0&id=a03cf414&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 \"a03cf414\",\n null\n \n)\n\nexport default component.exports","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Rating.vue?vue&type=style&index=0&id=39af319e&prod&lang=css\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../../../../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"5a552598\", content, true, {});","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('span',{staticClass:\"martan-rating\"},_vm._l((_vm.stars),function(star,index){return _c('svg',{key:index,staticClass:\"icon icon-tabler\",class:_vm.getStarClass(star),style:({ color: _vm.color }),attrs:{\"xmlns\":\"http://www.w3.org/2000/svg\",\"width\":\"14\",\"height\":\"14\",\"viewBox\":\"0 0 24 24\",\"stroke-width\":\"2\",\"stroke\":\"currentColor\",\"fill\":\"none\",\"stroke-linecap\":\"round\",\"stroke-linejoin\":\"round\"}},[(star === 0.5)?_c('defs',[_c('linearGradient',{attrs:{\"id\":(\"gradient-\" + index),\"x1\":\"0%\",\"y1\":\"0%\",\"x2\":\"100%\",\"y2\":\"0%\"}},[_c('stop',{style:((\"stop-color:\" + _vm.color + \";stop-opacity:1\")),attrs:{\"offset\":\"50%\"}}),_c('stop',{style:((\"stop-color:\" + _vm.color + \";stop-opacity:0\")),attrs:{\"offset\":\"50%\"}})],1)],1):_vm._e(),_c('path',{attrs:{\"stroke\":\"none\",\"d\":\"M0 0h24v24H0z\",\"fill\":\"none\"}}),_c('path',{attrs:{\"d\":\"M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z\",\"fill\":_vm.getStarFill(star, index)}})])}),0)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import mod from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Rating.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Rating.vue?vue&type=script&lang=js\"","<template>\n <span class=\"martan-rating\">\n <svg\n v-for=\"(star, index) in stars\"\n :key=\"index\"\n xmlns=\"http://www.w3.org/2000/svg\"\n class=\"icon icon-tabler\"\n :class=\"getStarClass(star)\"\n width=\"14\"\n height=\"14\"\n viewBox=\"0 0 24 24\"\n stroke-width=\"2\"\n stroke=\"currentColor\"\n fill=\"none\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n :style=\"{ color }\"\n >\n <defs v-if=\"star === 0.5\">\n <linearGradient :id=\"`gradient-${index}`\" x1=\"0%\" y1=\"0%\" x2=\"100%\" y2=\"0%\">\n <stop offset=\"50%\" :style=\"`stop-color:${color};stop-opacity:1`\" />\n <stop offset=\"50%\" :style=\"`stop-color:${color};stop-opacity:0`\" />\n </linearGradient>\n </defs>\n <path stroke=\"none\" d=\"M0 0h24v24H0z\" fill=\"none\" />\n <path\n d=\"M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z\"\n :fill=\"getStarFill(star, index)\" />\n </svg>\n </span>\n</template>\n\n<script>\nexport default {\n name: 'Rating',\n\n props: {\n rating: {\n type: Number,\n default: 5\n },\n\n color: {\n type: String,\n default: \"#000000\"\n },\n },\n\n data() {\n return {\n stars: Array(5).fill(0)\n };\n },\n\n mounted() {\n this.updateStars();\n },\n\n methods: {\n updateStars() {\n const rating = Math.max(0, Math.min(5, this.rating));\n this.stars = Array(5).fill(0).map((_, index) => {\n const starPosition = index + 1;\n if (rating >= starPosition) {\n return 1;\n } else if (rating > index) {\n return 0.5;\n } else {\n return 0;\n }\n });\n },\n\n getStarClass(star) {\n if (star === 1) {\n return 'icon-tabler-star-filled';\n } else if (star === 0.5) {\n return 'icon-tabler-star-half';\n } else {\n return 'icon-tabler-star';\n }\n },\n\n getStarFill(star, index) {\n if (star === 1) {\n return 'currentColor';\n } else if (star === 0.5) {\n return `url(#gradient-${index})`;\n } else {\n return 'none';\n }\n }\n },\n\n watch: {\n rating: 'updateStars'\n }\n};\n</script>\n\n<style lang=\"css\">\n.martan-rating {\n display: flex;\n gap: 4px;\n}\n</style>\n","import { render, staticRenderFns } from \"./Rating.vue?vue&type=template&id=39af319e\"\nimport script from \"./Rating.vue?vue&type=script&lang=js\"\nexport * from \"./Rating.vue?vue&type=script&lang=js\"\nimport style0 from \"./Rating.vue?vue&type=style&index=0&id=39af319e&prod&lang=css\"\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","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./RatingBreakdown.vue?vue&type=style&index=0&id=121d360c&prod&lang=scss&scoped=true\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../../../../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"8c4908ae\", content, true, {});","export * from \"-!../../../../../../node_modules/vue-style-loader/index.js!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Rating.vue?vue&type=style&index=0&id=39af319e&prod&lang=css\"","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../../../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \".martan-rating{display:flex;gap:4px}\", \"\"]);\n// Exports\nmodule.exports = exports;\n","export * from \"-!../../../../../../node_modules/vue-style-loader/index.js!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./RatingBreakdown.vue?vue&type=style&index=0&id=121d360c&prod&lang=scss&scoped=true\"","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../../../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \".mrtn-rating-breakdown[data-v-121d360c]{display:flex;flex-direction:column;width:100%}.mrtn-rating-row[data-v-121d360c]{align-items:center;border-radius:6px;cursor:pointer;display:flex;gap:12px;padding:8px;position:relative;transition:all .2s ease}.mrtn-rating-row--active[data-v-121d360c],.mrtn-rating-row[data-v-121d360c]:hover{background:var(--hover-color)}.mrtn-rating-row--active[data-v-121d360c]{box-shadow:0 0 0 2px var(--hover-color);transform:scale(1.02);z-index:10}.mrtn-rating-breakdown--has-active .mrtn-rating-row[data-v-121d360c]:not(.mrtn-rating-row--active){filter:grayscale(.8);opacity:.4}.mrtn-rating-stars[data-v-121d360c]{display:flex;gap:2px;min-width:80px}.mrtn-rating-star[data-v-121d360c]{color:#e5e5e5;font-size:14px}.mrtn-rating-star--filled[data-v-121d360c]{color:#000}.mrtn-rating-bar[data-v-121d360c]{background:#f0f0f0;border-radius:4px;flex:1;height:8px;overflow:hidden;position:relative;transition:all .2s ease}.mrtn-rating-bar__fill[data-v-121d360c]{border-radius:4px;height:100%;transition:width .3s ease}.mrtn-rating-count[data-v-121d360c]{color:#666;font-size:12px;min-width:40px;text-align:right}\", \"\"]);\n// Exports\nmodule.exports = exports;\n","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"mrtn-rating-breakdown\",class:{ 'mrtn-rating-breakdown--has-active': _vm.currentActive !== null },style:('--hover-color: ' + _vm.houverColor)},_vm._l((_vm.ratingBreakdown),function(count,stars){return _c('div',{key:stars,staticClass:\"mrtn-rating-row\",class:{ 'mrtn-rating-row--active': _vm.currentActive === stars },on:{\"click\":function($event){return _vm.selectRating(stars)}}},[_c('div',{staticClass:\"mrtn-rating-stars\"},[_c('Rating',{attrs:{\"rating\":parseInt(stars),\"color\":_vm.config.widget_review.star_color}})],1),_c('div',{staticClass:\"mrtn-rating-bar\"},[_c('div',{staticClass:\"mrtn-rating-bar__fill\",style:({\n width: _vm.getBarWidth(count) + '%',\n backgroundColor: _vm.config.widget_review.star_color\n })})]),_c('span',{staticClass:\"mrtn-rating-count\"},[_vm._v(\"(\"+_vm._s(count)+\")\")])])}),0)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import mod from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./RatingBreakdown.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../../../../node_modules/babel-loader/lib/index.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./RatingBreakdown.vue?vue&type=script&lang=js\"","<template>\n <div class=\"mrtn-rating-breakdown\" :style=\"'--hover-color: ' + houverColor\" :class=\"{ 'mrtn-rating-breakdown--has-active': currentActive !== null }\">\n <div v-for=\"(count, stars) in ratingBreakdown\" :key=\"stars\" class=\"mrtn-rating-row\"\n :class=\"{ 'mrtn-rating-row--active': currentActive === stars }\" @click=\"selectRating(stars)\">\n <div class=\"mrtn-rating-stars\">\n <Rating :rating=\"parseInt(stars)\" :color=\"config.widget_review.star_color\" />\n </div>\n\n <div class=\"mrtn-rating-bar\">\n <div class=\"mrtn-rating-bar__fill\" :style=\"{\n width: getBarWidth(count) + '%',\n backgroundColor: config.widget_review.star_color\n }\"></div>\n </div>\n\n <span class=\"mrtn-rating-count\">({{ count }})</span>\n </div>\n </div>\n</template>\n\n<script>\nimport { configProp } from \"../../../utils/configProps\";\nimport Rating from \"./Rating.vue\";\nimport { lightenColor } from \"../../../utils/lighten-color\";\n\nexport default {\n name: 'RatingBreakdown',\n\n props: {\n ...configProp,\n rating: {\n type: Object,\n default: () => ({\n five: 0,\n four: 0,\n three: 0,\n two: 0,\n one: 0\n })\n },\n\n totalRating: {\n type: Number,\n default: 0\n },\n\n\n average: {\n type: Number,\n default: 0\n }\n },\n\n data() {\n return {\n currentActive: null\n }\n },\n\n computed: {\n ratingBreakdown() {\n return {\n 5: this.rating.five,\n 4: this.rating.four,\n 3: this.rating.three,\n 2: this.rating.two,\n 1: this.rating.one\n }\n },\n\n houverColor() {\n if (!this.config.widget_review.star_color) return null\n return lightenColor(this.config.widget_review.star_color, 0.9)\n }\n },\n\n methods: {\n lightenColor,\n getBarWidth(count) {\n if (this.totalRating === 0) return 0\n return (count / this.totalRating) * 100\n },\n\n selectRating(rating) {\n if (this.currentActive === rating) {\n this.currentActive = null\n } else {\n this.currentActive = rating\n }\n this.$emit('rating-selected', this.currentActive)\n }\n },\n\n components: {\n Rating\n }\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.mrtn-rating-breakdown {\n display: flex;\n flex-direction: column;\n width: 100%;\n}\n\n.mrtn-rating-row {\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 8px;\n border-radius: 6px;\n cursor: pointer;\n transition: all 0.2s ease;\n position: relative;\n\n &:hover {\n background: var(--hover-color);\n }\n\n &--active {\n background: var(--hover-color);\n box-shadow: 0 0 0 2px var(--hover-color);\n transform: scale(1.02);\n z-index: 10;\n }\n}\n\n.mrtn-rating-breakdown--has-active .mrtn-rating-row:not(.mrtn-rating-row--active) {\n opacity: 0.4;\n filter: grayscale(0.8);\n}\n\n.mrtn-rating-stars {\n display: flex;\n gap: 2px;\n min-width: 80px;\n}\n\n.mrtn-rating-star {\n font-size: 14px;\n color: #e5e5e5;\n\n &--filled {\n color: #000000;\n }\n}\n\n.mrtn-rating-bar {\n flex: 1;\n height: 8px;\n background: #f0f0f0;\n border-radius: 4px;\n overflow: hidden;\n position: relative;\n transition: all 0.2s ease;\n}\n\n.mrtn-rating-bar__fill {\n height: 100%;\n border-radius: 4px;\n transition: width 0.3s ease;\n}\n\n.mrtn-rating-count {\n font-size: 12px;\n color: #666666;\n min-width: 40px;\n text-align: right;\n}\n</style>\n","import { render, staticRenderFns } from \"./RatingBreakdown.vue?vue&type=template&id=121d360c&scoped=true\"\nimport script from \"./RatingBreakdown.vue?vue&type=script&lang=js\"\nexport * from \"./RatingBreakdown.vue?vue&type=script&lang=js\"\nimport style0 from \"./RatingBreakdown.vue?vue&type=style&index=0&id=121d360c&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 \"121d360c\",\n null\n \n)\n\nexport default component.exports","// style-loader: Adds some css to the DOM by adding a <style> tag\n\n// load the styles\nvar content = require(\"!!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Summary.vue?vue&type=style&index=0&id=a03cf414&prod&lang=scss&scoped=true\");\nif(content.__esModule) content = content.default;\nif(typeof content === 'string') content = [[module.id, content, '']];\nif(content.locals) module.exports = content.locals;\n// add the styles to the DOM\nvar add = require(\"!../../../../../../node_modules/vue-style-loader/lib/addStylesClient.js\").default\nvar update = add(\"1bbb3a2b\", content, true, {});","export * from \"-!../../../../../../node_modules/vue-style-loader/index.js!../../../../../../node_modules/css-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../../../node_modules/postcss-loader/dist/cjs.js??ref--2-2!../../../../../../node_modules/sass-loader/dist/cjs.js!../../../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Summary.vue?vue&type=style&index=0&id=a03cf414&prod&lang=scss&scoped=true\"","// Imports\nvar ___CSS_LOADER_API_IMPORT___ = require(\"../../../../../../node_modules/css-loader/dist/runtime/api.js\");\nexports = ___CSS_LOADER_API_IMPORT___(false);\n// Module\nexports.push([module.id, \".mrtn-summary-container[data-v-a03cf414]{align-items:center;display:flex;justify-content:space-between;margin-top:1rem}.mrtn-summary-title[data-v-a03cf414]{margin-bottom:20px}.mrtn-summary-title .mrtn-title[data-v-a03cf414]{color:#000;font-size:24px;font-weight:700;margin:0 0 8px}.mrtn-summary-title .mrtn-total-responses[data-v-a03cf414]{color:#333;font-size:20px;font-weight:300}.mrtn-recommendation[data-v-a03cf414]{color:#666;font-size:16px;font-weight:100}@media(max-width:580px){.mrtn-recommendation[data-v-a03cf414]{font-size:12px}}.mrtn-average-section[data-v-a03cf414]{display:flex;justify-content:center;margin-bottom:16px}.mrtn-average-display[data-v-a03cf414]{gap:12px}.mrtn-average-display[data-v-a03cf414],.mrtn-stars-container[data-v-a03cf414]{align-items:center;display:flex}@media(max-width:580px){.mrtn-stars-container[data-v-a03cf414]{display:none}}.mrtn-average-badge[data-v-a03cf414]{background:#ff6b35;border-radius:20px;color:#fff;font-size:14px;font-weight:600;padding:8px 16px}.mrtn-rating-breakdown[data-v-a03cf414]{display:flex;flex-direction:column;gap:8px}.mrtn-rating-row[data-v-a03cf414]{align-items:center;display:flex;gap:12px;padding:4px 0}.mrtn-rating-label[data-v-a03cf414]{color:#666;font-size:12px;min-width:70px;text-align:left}.mrtn-rating-bar[data-v-a03cf414]{background:#f0f0f0;border-radius:6px;flex:1;height:12px;overflow:hidden;position:relative}.mrtn-rating-bar__fill[data-v-a03cf414]{border-radius:6px;height:100%;transition:width .3s ease}.mrtn-rating-count[data-v-a03cf414]{color:#666;font-size:12px;font-weight:500;min-width:40px;text-align:right}\", \"\"]);\n// Exports\nmodule.exports = exports;\n"],"sourceRoot":""}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
(window.webpackJsonpwidgetMartan=window.webpackJsonpwidgetMartan||[]).push([[7],{104:function(t,a,e){"use strict";e.r(a);var r=e(31),i=e(4),n=e(10),o={name:"RatingHistogram",props:{...i.a,rating:{type:Object,default:()=>({five:0,four:0,three:0,two:0,one:0})},totalRating:{type:Number,default:0},average:{type:Number,default:0}},data:()=>({currentActive:null,tooltip:{visible:!1,stars:0,count:0,percentage:0,x:0,y:0}}),computed:{ratingBreakdown(){return{1:this.rating.one,2:this.rating.two,3:this.rating.three,4:this.rating.four,5:this.rating.five}},hoverColor(){return this.config.widget_review.star_color?Object(n.a)(this.config.widget_review.star_color,.9):"#4CAF50"},tooltipStyle(){return{left:this.tooltip.x+"px",top:this.tooltip.y+"px"}}},methods:{lightenColor:n.a,getBarHeight(t){if(0===this.totalRating)return 0;const a=Math.max(...Object.values(this.ratingBreakdown));return 0===a?0:t/a*100},selectRating(t){this.currentActive===t?this.currentActive=null:this.currentActive=t,this.$emit("rating-selected",t)},showTooltip(t,a,e){const r=this.totalRating>0?Math.round(a/this.totalRating*100):0,i=e.target.getBoundingClientRect(),n=this.$el.getBoundingClientRect();this.tooltip={visible:!0,stars:parseInt(t),count:a,percentage:r,x:i.left-n.left+i.width/2,y:i.top-n.top-5-5}},hideTooltip(){this.tooltip.visible=!1}},components:{Rating:r.a}},s=(e(96),e(3)),l=Object(s.a)(o,(function(){var t=this,a=t.$createElement,e=t._self._c||a;return e("div",{staticClass:"mrtn-rating-histogram",style:"--hover-color: "+t.hoverColor},[e("div",{staticClass:"mrtn-histogram-container"},[e("div",{staticClass:"mrtn-histogram-bars",class:{"mrtn-histogram-bars--has-active":null!==t.currentActive}},t._l(t.ratingBreakdown,(function(a,r){return e("div",{key:r,staticClass:"mrtn-histogram-bar",class:{"mrtn-histogram-bar--active":t.currentActive===r},style:{height:t.getBarHeight(a)+"%",backgroundColor:a>0?t.config.widget_review.star_color:"#f0f0f0"},on:{click:function(a){return t.selectRating(r)},mouseenter:function(e){return t.showTooltip(r,a,e)},mouseleave:t.hideTooltip}},[e("div",{staticClass:"mrtn-histogram-bar__fill"})])})),0),e("div",{staticClass:"mrtn-histogram-labels"},t._l([1,2,3,4,5],(function(a){return e("div",{key:a,staticClass:"mrtn-histogram-label"},[t._v(" "+t._s(a)+" ")])})),0)]),t.tooltip.visible?e("div",{staticClass:"mrtn-histogram-tooltip",style:t.tooltipStyle},[e("div",{staticClass:"mrtn-tooltip-content"},[e("div",{staticClass:"mrtn-tooltip-stars"},[e("Rating",{attrs:{rating:t.tooltip.stars,color:t.config.widget_review.star_color}})],1),e("div",{staticClass:"mrtn-tooltip-text"},[t._v(" "+t._s(t.tooltip.count)+" avaliações ("+t._s(t.tooltip.percentage)+"%) ")])]),e("div",{staticClass:"mrtn-tooltip-arrow"})]):t._e()])}),[],!1,null,"d35f3a0e",null).exports,d={name:"Histogram",components:{Rating:r.a,RatingHistogram:l},props:{...i.a,rating:{type:Object,default:()=>({five:0,four:0,three:0,two:0,one:0})},recommended:{type:Number,default:0},average:{type:Number,default:0},totalRating:{type:Number,default:0}},data:()=>({}),computed:{ratingBreakdown(){return{5:this.rating.five,4:this.rating.four,3:this.rating.three,2:this.rating.two,1:this.rating.one}},formatReviewsCount(){return this.totalRating>=1e3?(this.totalRating/1e3).toFixed(1).replace(".0","")+"k":this.totalRating.toLocaleString()}},methods:{getBarWidth(t){return 0===this.totalRating?0:t/this.totalRating*100},onRatingSelected(t){this.currentActive=t,this.$emit("rating-selected",t)}}},c=(e(98),Object(s.a)(d,(function(){var t=this,a=t.$createElement,e=t._self._c||a;return e("div",{staticClass:"mrtn-header--histogram"},[e("div",{staticClass:"mrtn-summary-container"},[e("div",{staticClass:"mrtn-summary-title"},[e("div",{staticClass:"mrtn-total-responses"},[t._v(t._s(t.formatReviewsCount)+" Avaliações")]),t.recommended>0?e("div",{staticClass:"mrtn-recommendation"},[t._v(" "+t._s(Math.round(t.recommended))+"% dos clientes recomendam esse produto ")]):t._e()]),e("div",{staticClass:"mrtn-average-section"},[e("div",{staticClass:"mrtn-average-display"},[e("div",{staticClass:"mrtn-stars-container"},[e("Rating",{attrs:{rating:t.average,color:t.config.widget_review.star_color}})],1),e("div",{staticClass:"mrtn-average-badge",style:{backgroundColor:t.config.widget_review.star_color}},[t._v(" "+t._s(t.average.toFixed(1))+" / 5 ")])])])]),e("RatingHistogram",{attrs:{config:t.config,rating:t.rating,"total-rating":t.totalRating,average:t.average},on:{"rating-selected":t.onRatingSelected}})],1)}),[],!1,null,"80f10b92",null));a.default=c.exports},30:function(t,a,e){var r=e(35);r.__esModule&&(r=r.default),"string"==typeof r&&(r=[[t.i,r,""]]),r.locals&&(t.exports=r.locals);(0,e(9).default)("5a552598",r,!0,{})},31:function(t,a,e){"use strict";var r={name:"Rating",props:{rating:{type:Number,default:5},color:{type:String,default:"#000000"}},data:()=>({stars:Array(5).fill(0)}),mounted(){this.updateStars()},methods:{updateStars(){const t=Math.max(0,Math.min(5,this.rating));this.stars=Array(5).fill(0).map((a,e)=>t>=e+1?1:t>e?.5:0)},getStarClass:t=>1===t?"icon-tabler-star-filled":.5===t?"icon-tabler-star-half":"icon-tabler-star",getStarFill:(t,a)=>1===t?"currentColor":.5===t?`url(#gradient-${a})`:"none"},watch:{rating:"updateStars"}},i=(e(34),e(3)),n=Object(i.a)(r,(function(){var t=this,a=t.$createElement,e=t._self._c||a;return e("span",{staticClass:"martan-rating"},t._l(t.stars,(function(a,r){return e("svg",{key:r,staticClass:"icon icon-tabler",class:t.getStarClass(a),style:{color:t.color},attrs:{xmlns:"http://www.w3.org/2000/svg",width:"14",height:"14",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"}},[.5===a?e("defs",[e("linearGradient",{attrs:{id:"gradient-"+r,x1:"0%",y1:"0%",x2:"100%",y2:"0%"}},[e("stop",{style:"stop-color:"+t.color+";stop-opacity:1",attrs:{offset:"50%"}}),e("stop",{style:"stop-color:"+t.color+";stop-opacity:0",attrs:{offset:"50%"}})],1)],1):t._e(),e("path",{attrs:{stroke:"none",d:"M0 0h24v24H0z",fill:"none"}}),e("path",{attrs:{d:"M8.243 7.34l-6.38 .925l-.113 .023a1 1 0 0 0 -.44 1.684l4.622 4.499l-1.09 6.355l-.013 .11a1 1 0 0 0 1.464 .944l5.706 -3l5.693 3l.1 .046a1 1 0 0 0 1.352 -1.1l-1.091 -6.355l4.624 -4.5l.078 -.085a1 1 0 0 0 -.633 -1.62l-6.38 -.926l-2.852 -5.78a1 1 0 0 0 -1.794 0l-2.853 5.78z",fill:t.getStarFill(a,r)}})])})),0)}),[],!1,null,null,null);a.a=n.exports},34:function(t,a,e){"use strict";e(30)},35:function(t,a,e){(a=e(8)(!1)).push([t.i,".martan-rating{display:flex;gap:4px}",""]),t.exports=a},73:function(t,a,e){var r=e(97);r.__esModule&&(r=r.default),"string"==typeof r&&(r=[[t.i,r,""]]),r.locals&&(t.exports=r.locals);(0,e(9).default)("76bee262",r,!0,{})},74:function(t,a,e){var r=e(99);r.__esModule&&(r=r.default),"string"==typeof r&&(r=[[t.i,r,""]]),r.locals&&(t.exports=r.locals);(0,e(9).default)("7a1c0b6e",r,!0,{})},96:function(t,a,e){"use strict";e(73)},97:function(t,a,e){(a=e(8)(!1)).push([t.i,".mrtn-rating-histogram[data-v-d35f3a0e]{color:#333;display:flex;flex-direction:column;position:relative;width:100%}.mrtn-histogram-title[data-v-d35f3a0e]{color:#666;font-size:14px;font-weight:600;letter-spacing:.5px;margin-bottom:16px;text-transform:uppercase}.mrtn-histogram-container[data-v-d35f3a0e]{display:flex;flex-direction:column;gap:8px;margin-bottom:20px}.mrtn-histogram-bars[data-v-d35f3a0e]{gap:8px;height:120px;justify-content:space-between}.mrtn-histogram-bar[data-v-d35f3a0e],.mrtn-histogram-bars[data-v-d35f3a0e]{align-items:end;display:flex;position:relative}.mrtn-histogram-bar[data-v-d35f3a0e]{background:#f0f0f0;border-radius:4px 4px 0 0;cursor:pointer;flex:1;height:100%;min-height:8px;transition:all .3s ease}.mrtn-histogram-bar[data-v-d35f3a0e]:hover{transform:scaleY(1.05)}.mrtn-histogram-bar--active[data-v-d35f3a0e]{box-shadow:0 0 0 3px var(--hover-color);transform:scaleY(1.1);z-index:10}.mrtn-histogram-bars--has-active .mrtn-histogram-bar[data-v-d35f3a0e]:not(.mrtn-histogram-bar--active){filter:grayscale(.8);opacity:.4}.mrtn-histogram-bar__fill[data-v-d35f3a0e]{border-radius:4px 4px 0 0;min-height:8px;transition:all .3s ease;width:100%}.mrtn-histogram-labels[data-v-d35f3a0e]{display:flex;justify-content:space-between;padding:0 4px}.mrtn-histogram-label[data-v-d35f3a0e]{color:#666;flex:1;font-size:12px;font-weight:500;text-align:center}.mrtn-histogram-tooltip[data-v-d35f3a0e]{background:#333;border-radius:6px;box-shadow:0 4px 12px rgba(0,0,0,.3);color:#fff;min-width:120px;padding:12px;pointer-events:none;position:absolute;transform:translateX(-50%) translateY(-100%);white-space:nowrap;z-index:1000}.mrtn-tooltip-content[data-v-d35f3a0e]{align-items:center;display:flex;flex-direction:column;gap:4px}.mrtn-tooltip-stars[data-v-d35f3a0e]{display:flex;gap:2px}.mrtn-tooltip-text[data-v-d35f3a0e]{color:#fff;font-size:11px;text-align:center;white-space:nowrap}.mrtn-tooltip-arrow[data-v-d35f3a0e]{border-left:6px solid transparent;border-right:6px solid transparent;border-top:6px solid #333;height:0;left:50%;position:absolute;top:100%;transform:translateX(-50%);width:0}.mrtn-histogram-average[data-v-d35f3a0e]{align-items:center;display:flex;justify-content:flex-end}.mrtn-average-number[data-v-d35f3a0e]{color:#333;font-size:24px;font-weight:700;line-height:1}@media(max-width:768px){.mrtn-histogram-bars[data-v-d35f3a0e]{height:100px}.mrtn-average-number[data-v-d35f3a0e]{font-size:20px}}",""]),t.exports=a},98:function(t,a,e){"use strict";e(74)},99:function(t,a,e){(a=e(8)(!1)).push([t.i,".mrtn-header--histogram[data-v-80f10b92]{background-color:#f3f3f3;border-radius:8px;margin-bottom:1rem;padding:8px 16px;width:100%}.mrtn-summary-container[data-v-80f10b92]{align-items:center;display:flex;justify-content:space-between;margin-top:1rem}.mrtn-summary-title[data-v-80f10b92]{margin-bottom:20px}.mrtn-summary-title .mrtn-title[data-v-80f10b92]{color:#000;font-size:24px;font-weight:700;margin:0 0 8px}.mrtn-summary-title .mrtn-total-responses[data-v-80f10b92]{color:#333;font-size:20px;font-weight:300}.mrtn-recommendation[data-v-80f10b92]{color:#666;font-size:16px;font-weight:100}@media(max-width:580px){.mrtn-recommendation[data-v-80f10b92]{font-size:12px}}.mrtn-average-section[data-v-80f10b92]{display:flex;justify-content:center;margin-bottom:16px}.mrtn-average-display[data-v-80f10b92]{gap:12px}.mrtn-average-display[data-v-80f10b92],.mrtn-stars-container[data-v-80f10b92]{align-items:center;display:flex}@media(max-width:580px){.mrtn-stars-container[data-v-80f10b92]{display:none}}.mrtn-average-badge[data-v-80f10b92]{background:#ff6b35;border-radius:20px;color:#fff;font-size:14px;font-weight:600;padding:8px 16px}.mrtn-rating-breakdown[data-v-80f10b92]{display:flex;flex-direction:column;gap:8px}.mrtn-rating-row[data-v-80f10b92]{align-items:center;display:flex;gap:12px;padding:4px 0}.mrtn-rating-label[data-v-80f10b92]{color:#666;font-size:12px;min-width:70px;text-align:left}.mrtn-rating-bar[data-v-80f10b92]{background:#f0f0f0;border-radius:6px;flex:1;height:12px;overflow:hidden;position:relative}.mrtn-rating-bar__fill[data-v-80f10b92]{border-radius:6px;height:100%;transition:width .3s ease}.mrtn-rating-count[data-v-80f10b92]{color:#666;font-size:12px;font-weight:500;min-width:40px;text-align:right}",""]),t.exports=a}}]);
|
|
2
|
+
//# sourceMappingURL=widget-martan.7.min.js.map
|