1 |
- {"version":3,"sources":["webpack:///G:/item/appBase/components/uni-countdown/uni-countdowns.vue?fc92","webpack:///G:/item/appBase/components/uni-countdown/uni-countdowns.vue?ea71","webpack:///G:/item/appBase/components/uni-countdown/uni-countdowns.vue?ebe4","webpack:///G:/item/appBase/components/uni-countdown/uni-countdowns.vue?1e69","uni-app:///components/uni-countdown/uni-countdowns.vue","webpack:///G:/item/appBase/components/uni-countdown/uni-countdowns.vue?c89a","webpack:///G:/item/appBase/components/uni-countdown/uni-countdowns.vue?42f3"],"names":[],"mappings":";;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAuI;AACvI;AACkE;AACL;AACsC;;;AAGnG;AAC2K;AAC3K,gBAAgB,oLAAU;AAC1B,EAAE,oFAAM;AACR,EAAE,qGAAM;AACR,EAAE,8GAAe;AACjB;AACA;AACA;AACA;AACA;AACA,EAAE,yGAAU;AACZ;AACA;;AAEA;AACe,gF;;;;;;;;;;;;ACvBf;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;;;;;;;;;;;ACAA;AAAA;AAAA;AAAA;AAAA;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;ACRA;AAAA;AAAA;AAAA;AAAsoB,CAAgB,2pBAAG,EAAC,C;;;;;;;;;;;;;;;;;;;;;;;;;ACa1pB;AACA,sBADA;AAEA;AACA;AACA,mBADA;AAEA,mBAFA,EADA;;AAKA;AACA,mBADA;AAEA,mBAFA,EALA;;AASA;AACA,kBADA;AAEA,wBAFA,EATA;;AAaA;AACA,kBADA;AAEA,wBAFA,EAbA;;AAiBA;AACA,kBADA;AAEA,wBAFA,EAjBA;;AAqBA;AACA,kBADA;AAEA,wBAFA,EArBA;;AAyBA;AACA,kBADA;AAEA,gBAFA,EAzBA;;AA6BA;AACA,kBADA;AAEA,gBAFA,EA7BA;;AAiCA;AACA,kBADA;AAEA,gBAFA,EAjCA;;AAqCA;AACA,kBADA;AAEA,gBAFA,EArCA,EAFA;;;AA4CA,MA5CA,kBA4CA;AACA;AACA,iBADA;AAEA,qBAFA;AAGA,aAHA;AAIA,aAJA;AAKA,aALA;AAMA,aANA;AAOA,iBAPA;AAQA,gBARA;;AAUA,GAvDA;AAwDA;AACA,OADA,eACA,GADA,EACA;AACA;AACA,KAHA;AAIA,QAJA,gBAIA,GAJA,EAIA;AACA;AACA,KANA;AAOA,UAPA,kBAOA,GAPA,EAOA;AACA;AACA,KATA;AAUA,UAVA,kBAUA,GAVA,EAUA;AACA;AACA,KAZA,EAxDA;;AAsEA;AACA;AACA,GAxEA;AAyEA,eAzEA,2BAyEA;AACA;AACA,GA3EA;AA4EA;AACA,aADA,qBACA,GADA,EACA,KADA,EACA,OADA,EACA,OADA,EACA;AACA;AACA,KAHA;AAIA,UAJA,oBAIA;AACA;AACA;AACA,KAPA;AAQA,aARA,uBAQA;AACA,iCADA;AAEA,SAFA,GAEA,CAFA,CAEA,IAFA,GAEA,CAFA,CAEA,MAFA,GAEA,CAFA,CAEA,MAFA,GAEA,CAFA;AAGA;AACA;AACA;AACA;AACA;AACA,OALA,MAKA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAnCA;AAoCA,aApCA,uBAoCA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAPA,EAOA,IAPA;AAQA,KAlDA;AAmDA,cAnDA,wBAmDA;AACA;AACA;AACA;AACA;AACA;AACA,KAzDA,EA5EA,E;;;;;;;;;;;;ACbA;AAAA;AAAA;AAAA;AAAwrC,CAAgB,ypCAAG,EAAC,C;;;;;;;;;;;ACA5sC;AACA,OAAO,KAAU,EAAE,kBAKd","file":"components/uni-countdown/uni-countdowns.js","sourcesContent":["import { render, staticRenderFns, recyclableRender, components } from \"./uni-countdowns.vue?vue&type=template&id=31be4ef5&scoped=true&\"\nvar renderjs\nimport script from \"./uni-countdowns.vue?vue&type=script&lang=js&\"\nexport * from \"./uni-countdowns.vue?vue&type=script&lang=js&\"\nimport style0 from \"./uni-countdowns.vue?vue&type=style&index=0&id=31be4ef5&lang=scss&scoped=true&\"\n\n\n/* normalize component */\nimport normalizer from \"!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\runtime\\\\componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"31be4ef5\",\n null,\n false,\n components,\n renderjs\n)\n\ncomponent.options.__file = \"components/uni-countdown/uni-countdowns.vue\"\nexport default component.exports","export * from \"-!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\loaders\\\\templateLoader.js??vue-loader-options!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--16-0!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\template.js!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-uni-app-loader\\\\page-meta.js!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\index.js??vue-loader-options!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\style.js!./uni-countdowns.vue?vue&type=template&id=31be4ef5&scoped=true&\"","var components\nvar render = function() {\n var _vm = this\n var _h = _vm.$createElement\n var _c = _vm._self._c || _h\n}\nvar recyclableRender = false\nvar staticRenderFns = []\nrender._withStripped = true\n\nexport { render, staticRenderFns, recyclableRender, components }","import mod from \"-!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\babel-loader\\\\lib\\\\index.js!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--12-1!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\script.js!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\index.js??vue-loader-options!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\style.js!./uni-countdowns.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\babel-loader\\\\lib\\\\index.js!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--12-1!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\script.js!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\index.js??vue-loader-options!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\style.js!./uni-countdowns.vue?vue&type=script&lang=js&\"","<template>\r\n\t<view class=\"uni-countdown\">\r\n\t\t<text v-if=\"showDay\" :style=\"{ borderColor: borderColor, color: color, backgroundColor: backgroundColor }\" class=\"uni-countdown__number\">{{ d }}</text>\r\n\t\t<text v-if=\"showDay\" :style=\"{ color: splitorColor }\" class=\"uni-countdown__splitor\">天</text>\r\n\t\t<text :style=\"{ borderColor: borderColor, color: color, backgroundColor: backgroundColor }\" class=\"uni-countdown__number\">{{ h }}</text>\r\n\t\t<text :style=\"{ color: splitorColor }\" class=\"uni-countdown__splitor\">{{ showColon ? ':' : '时' }}</text>\r\n\t\t<text :style=\"{ borderColor: borderColor, color: color, backgroundColor: backgroundColor }\" class=\"uni-countdown__number\">{{ i }}</text>\r\n\t\t<text :style=\"{ color: splitorColor }\" class=\"uni-countdown__splitor\">{{ showColon ? ':' : '分' }}</text>\r\n\t\t<text :style=\"{ borderColor: borderColor, color: color, backgroundColor: backgroundColor }\" class=\"uni-countdown__number\">{{ s }}</text>\r\n\t\t<text v-if=\"!showColon\" :style=\"{ color: splitorColor }\" class=\"uni-countdown__splitor\">秒</text>\r\n\t</view>\r\n</template>\r\n<script>\r\n\texport default {\r\n\t\tname: 'UniCountdown',\r\n\t\tprops: {\r\n\t\t\tshowDay: {\r\n\t\t\t\ttype: Boolean,\r\n\t\t\t\tdefault: true\r\n\t\t\t},\r\n\t\t\tshowColon: {\r\n\t\t\t\ttype: Boolean,\r\n\t\t\t\tdefault: true\r\n\t\t\t},\r\n\t\t\tbackgroundColor: {\r\n\t\t\t\ttype: String,\r\n\t\t\t\tdefault: '#FFFFFF'\r\n\t\t\t},\r\n\t\t\tborderColor: {\r\n\t\t\t\ttype: String,\r\n\t\t\t\tdefault: '#000000'\r\n\t\t\t},\r\n\t\t\tcolor: {\r\n\t\t\t\ttype: String,\r\n\t\t\t\tdefault: '#000000'\r\n\t\t\t},\r\n\t\t\tsplitorColor: {\r\n\t\t\t\ttype: String,\r\n\t\t\t\tdefault: '#000000'\r\n\t\t\t},\r\n\t\t\tday: {\r\n\t\t\t\ttype: Number,\r\n\t\t\t\tdefault: 0\r\n\t\t\t},\r\n\t\t\thour: {\r\n\t\t\t\ttype: Number,\r\n\t\t\t\tdefault: 0\r\n\t\t\t},\r\n\t\t\tminute: {\r\n\t\t\t\ttype: Number,\r\n\t\t\t\tdefault: 0\r\n\t\t\t},\r\n\t\t\tsecond: {\r\n\t\t\t\ttype: Number,\r\n\t\t\t\tdefault: 0\r\n\t\t\t}\r\n\t\t},\r\n\t\tdata() {\r\n\t\t\treturn {\r\n\t\t\t\ttimer: null,\r\n\t\t\t\tsyncFlag: false,\r\n\t\t\t\td: '00',\r\n\t\t\t\th: '00',\r\n\t\t\t\ti: '00',\r\n\t\t\t\ts: '00',\r\n\t\t\t\tleftTime: 0,\r\n\t\t\t\tseconds: 0\r\n\t\t\t}\r\n\t\t},\r\n\t\twatch: {\r\n\t\t\tday(val) {\r\n\t\t\t\tthis.changeFlag()\r\n\t\t\t},\r\n\t\t\thour(val) {\r\n\t\t\t\tthis.changeFlag()\r\n\t\t\t},\r\n\t\t\tminute(val) {\r\n\t\t\t\tthis.changeFlag()\r\n\t\t\t},\r\n\t\t\tsecond(val) {\r\n\t\t\t\tthis.changeFlag()\r\n\t\t\t}\r\n\t\t},\r\n\t\tcreated: function(e) {\r\n\t\t\tthis.startData();\r\n\t\t},\r\n\t\tbeforeDestroy() {\r\n\t\t\tclearInterval(this.timer)\r\n\t\t},\r\n\t\tmethods: {\r\n\t\t\ttoSeconds(day, hours, minutes, seconds) {\r\n\t\t\t\treturn day * 60 * 60 * 24 + hours * 60 * 60 + minutes * 60 + seconds\r\n\t\t\t},\r\n\t\t\ttimeUp() {\r\n\t\t\t\tclearInterval(this.timer)\r\n\t\t\t\tthis.$emit('timeup')\r\n\t\t\t},\r\n\t\t\tcountDown() {\r\n\t\t\t\tlet seconds = this.seconds\r\n\t\t\t\tlet [day, hour, minute, second] = [0, 0, 0, 0]\r\n\t\t\t\tif (seconds > 0) {\r\n\t\t\t\t\tday = Math.floor(seconds / (60 * 60 * 24))\r\n\t\t\t\t\thour = Math.floor(seconds / (60 * 60)) - (day * 24)\r\n\t\t\t\t\tminute = Math.floor(seconds / 60) - (day * 24 * 60) - (hour * 60)\r\n\t\t\t\t\tsecond = Math.floor(seconds) - (day * 24 * 60 * 60) - (hour * 60 * 60) - (minute * 60)\r\n\t\t\t\t} else {\r\n\t\t\t\t\tthis.timeUp()\r\n\t\t\t\t}\r\n\t\t\t\tif (day < 10) {\r\n\t\t\t\t\tday = '0' + day\r\n\t\t\t\t}\r\n\t\t\t\tif (hour < 10) {\r\n\t\t\t\t\thour = '0' + hour\r\n\t\t\t\t}\r\n\t\t\t\tif (minute < 10) {\r\n\t\t\t\t\tminute = '0' + minute\r\n\t\t\t\t}\r\n\t\t\t\tif (second < 10) {\r\n\t\t\t\t\tsecond = '0' + second\r\n\t\t\t\t}\r\n\t\t\t\tthis.d = day\r\n\t\t\t\tthis.h = hour\r\n\t\t\t\tthis.i = minute\r\n\t\t\t\tthis.s = second\r\n\t\t\t},\r\n\t\t\tstartData() {\r\n\t\t\t\tthis.seconds = this.toSeconds(this.day, this.hour, this.minute, this.second)\r\n\t\t\t\tif (this.seconds <= 0) {\r\n\t\t\t\t\treturn\r\n\t\t\t\t}\r\n\t\t\t\tthis.countDown()\r\n\t\t\t\tthis.timer = setInterval(() => {\r\n\t\t\t\t\tthis.seconds--\r\n\t\t\t\t\tif (this.seconds < 0) {\r\n\t\t\t\t\t\tthis.timeUp()\r\n\t\t\t\t\t\treturn\r\n\t\t\t\t\t}\r\n\t\t\t\t\tthis.countDown()\r\n\t\t\t\t}, 1000)\r\n\t\t\t},\r\n\t\t\tchangeFlag() {\r\n\t\t\t\tif (!this.syncFlag) {\r\n\t\t\t\t\tthis.seconds = this.toSeconds(this.day, this.hour, this.minute, this.second)\r\n\t\t\t\t\tthis.startData();\r\n\t\t\t\t\tthis.syncFlag = true;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n</script>\r\n<style lang=\"scss\" scoped>\r\n\t@import '~@/uni.scss';\r\n\t$countdown-height: 48rpx;\r\n\t$countdown-width: 52rpx;\r\n\r\n\t.uni-countdown {\r\n\t\t/* #ifndef APP-NVUE */\r\n\t\tdisplay: flex;\r\n\t\t/* #endif */\r\n\t\tflex-direction: row;\r\n\t\tjustify-content: flex-start;\r\n\t\tpadding: 2rpx 0;\r\n\t}\r\n\r\n\t.uni-countdown__splitor {\r\n\t\t/* #ifndef APP-NVUE */\r\n\t\tdisplay: flex;\r\n\t\t/* #endif */\r\n\t\tjustify-content: center;\r\n\t\tline-height: $countdown-height;\r\n\t\tpadding: 5rpx;\r\n\t\tfont-size: $uni-font-size-sm;\r\n\t}\r\n\r\n\t.uni-countdown__number {\r\n\t\t/* #ifndef APP-NVUE */\r\n\t\tdisplay: flex;\r\n\t\t/* #endif */\r\n\t\tjustify-content: center;\r\n\t\talign-items: center;\r\n\t\twidth: $countdown-width;\r\n\t\theight: $countdown-height;\r\n\t\tline-height: $countdown-height;\r\n\t\tmargin: 5rpx;\r\n\t\ttext-align: center;\r\n\t\tfont-size: $uni-font-size-sm;\r\n\t}\r\n</style>\r\n","import mod from \"-!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\mini-css-extract-plugin\\\\dist\\\\loader.js??ref--8-oneOf-1-0!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\css-loader\\\\dist\\\\cjs.js??ref--8-oneOf-1-1!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\loaders\\\\stylePostLoader.js!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--8-oneOf-1-2!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\postcss-loader\\\\src\\\\index.js??ref--8-oneOf-1-3!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\sass-loader\\\\dist\\\\cjs.js??ref--8-oneOf-1-4!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--8-oneOf-1-5!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\index.js??vue-loader-options!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\style.js!./uni-countdowns.vue?vue&type=style&index=0&id=31be4ef5&lang=scss&scoped=true&\"; export default mod; export * from \"-!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\mini-css-extract-plugin\\\\dist\\\\loader.js??ref--8-oneOf-1-0!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\css-loader\\\\dist\\\\cjs.js??ref--8-oneOf-1-1!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\loaders\\\\stylePostLoader.js!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--8-oneOf-1-2!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\postcss-loader\\\\src\\\\index.js??ref--8-oneOf-1-3!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\sass-loader\\\\dist\\\\cjs.js??ref--8-oneOf-1-4!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\webpack-preprocess-loader\\\\index.js??ref--8-oneOf-1-5!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\vue-cli-plugin-uni\\\\packages\\\\vue-loader\\\\lib\\\\index.js??vue-loader-options!D:\\\\work\\\\HBuilderX\\\\plugins\\\\uniapp-cli\\\\node_modules\\\\@dcloudio\\\\webpack-uni-mp-loader\\\\lib\\\\style.js!./uni-countdowns.vue?vue&type=style&index=0&id=31be4ef5&lang=scss&scoped=true&\"","// extracted by mini-css-extract-plugin\n if(module.hot) {\n // 1618025084843\n var cssReload = require(\"D:/work/HBuilderX/plugins/uniapp-cli/node_modules/mini-css-extract-plugin/dist/hmr/hotModuleReplacement.js\")(module.id, {\"hmr\":true,\"publicPath\":\"../../\",\"locals\":false});\n module.hot.dispose(cssReload);\n module.hot.accept(undefined, cssReload);\n }\n "],"sourceRoot":""}
|