tab-nav.js 7.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176
  1. exports.ids = [33];
  2. exports.modules = {
  3. /***/ 170:
  4. /***/ (function(module, exports) {
  5. // Exports
  6. module.exports = {
  7. };
  8. /***/ }),
  9. /***/ 183:
  10. /***/ (function(module, __webpack_exports__, __webpack_require__) {
  11. "use strict";
  12. // ESM COMPAT FLAG
  13. __webpack_require__.r(__webpack_exports__);
  14. // CONCATENATED MODULE: ./node_modules/babel-loader/lib??ref--2-0!./node_modules/vue-loader/lib/loaders/templateLoader.js??ref--6!./node_modules/@nuxt/components/dist/loader.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./components/TabNav.vue?vue&type=template&id=8a32da06&scoped=true
  15. var render = function render() {
  16. var _vm = this,
  17. _c = _vm._self._c;
  18. return _c('div', {
  19. staticClass: "tabs",
  20. style: {
  21. marginTop: _vm.marginTop + 'px',
  22. marginBottom: _vm.marginBottom + 'px',
  23. fontSize: _vm.fontSize + 'px'
  24. }
  25. }, [_vm._ssrNode(Array.isArray(_vm.tabList) ? "<ul" + _vm._ssrClass(null, _vm.borderType) + " data-v-8a32da06>" + _vm._ssrList(_vm.tabList, function (item, i) {
  26. return !item.hasOwnProperty('isShow') || item.isShow ? "<li" + _vm._ssrClass(null, {
  27. active: i === _vm.currTab
  28. }) + _vm._ssrStyle(null, {
  29. minWidth: _vm.liWidth + 'px',
  30. height: _vm.liHeight + 'px',
  31. lineHeight: _vm.liHeight + 'px',
  32. marginRight: _vm.marginRight + 'px'
  33. }, null) + " data-v-8a32da06><div data-v-8a32da06>" + _vm._ssrEscape(_vm._s(item.name)) + "</div></li>" : "<!---->";
  34. }) + _vm._ssrList(_vm.comRemaining, function (item) {
  35. return "<li class=\"unclickable\"" + _vm._ssrStyle(null, {
  36. minWidth: _vm.liWidth + 'px',
  37. lineHeight: _vm.liHeight + 'px',
  38. marginRight: _vm.marginRight + 'px'
  39. }, null) + " data-v-8a32da06><div data-v-8a32da06>" + _vm._ssrEscape(_vm._s(item)) + "</div></li>";
  40. }) + "</ul>" : "<ul data-v-8a32da06>" + _vm._ssrList(Object.keys(_vm.tabList), function (val, i) {
  41. return "<li" + _vm._ssrClass(null, {
  42. active: i === _vm.currTab
  43. }) + _vm._ssrStyle(null, {
  44. minWidth: _vm.liWidth + 'px',
  45. marginRight: _vm.marginRight + 'px'
  46. }, null) + " data-v-8a32da06><div data-v-8a32da06>" + _vm._ssrEscape(_vm._s(val)) + "</div></li>";
  47. }) + "</ul>")]);
  48. };
  49. var staticRenderFns = [];
  50. // CONCATENATED MODULE: ./components/TabNav.vue?vue&type=template&id=8a32da06&scoped=true
  51. // CONCATENATED MODULE: ./node_modules/babel-loader/lib??ref--2-0!./node_modules/@nuxt/components/dist/loader.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./components/TabNav.vue?vue&type=script&lang=js
  52. /* harmony default export */ var TabNavvue_type_script_lang_js = ({
  53. props: {
  54. // color: {
  55. // type: String,
  56. // },
  57. borderType: {
  58. type: String,
  59. default: 'noBorder'
  60. },
  61. fontSize: {
  62. type: Number,
  63. default: 14
  64. },
  65. marginTop: {
  66. type: Number,
  67. default: 0
  68. },
  69. marginBottom: {
  70. type: Number,
  71. default: 10
  72. },
  73. liWidth: {
  74. type: Number,
  75. default: 0
  76. },
  77. liHeight: {
  78. type: Number,
  79. default: 28
  80. },
  81. marginRight: {
  82. type: Number,
  83. default: 0
  84. },
  85. currTab: {
  86. type: [Number, String],
  87. default: 0
  88. },
  89. tabList: {
  90. type: [Array, Object],
  91. default: () => {
  92. return [];
  93. }
  94. },
  95. allPrintTab: {
  96. type: [Array, Object],
  97. default: () => {
  98. return [];
  99. }
  100. }
  101. },
  102. data() {
  103. return {
  104. textColor: 'red'
  105. };
  106. },
  107. computed: {
  108. comRemaining() {
  109. const mapTabList = this.tabList.map(i => i.name);
  110. return this.allPrintTab.filter(element => !mapTabList.includes(element));
  111. }
  112. },
  113. methods: {
  114. selTab(i) {
  115. this.$emit('update:currTab', i);
  116. this.$emit('handle');
  117. }
  118. }
  119. });
  120. // CONCATENATED MODULE: ./components/TabNav.vue?vue&type=script&lang=js
  121. /* harmony default export */ var components_TabNavvue_type_script_lang_js = (TabNavvue_type_script_lang_js);
  122. // EXTERNAL MODULE: ./node_modules/vue-loader/lib/runtime/componentNormalizer.js
  123. var componentNormalizer = __webpack_require__(2);
  124. // CONCATENATED MODULE: ./components/TabNav.vue
  125. function injectStyles (context) {
  126. var style0 = __webpack_require__(191)
  127. if (style0.__inject__) style0.__inject__(context)
  128. }
  129. /* normalize component */
  130. var component = Object(componentNormalizer["a" /* default */])(
  131. components_TabNavvue_type_script_lang_js,
  132. render,
  133. staticRenderFns,
  134. false,
  135. injectStyles,
  136. "8a32da06",
  137. "1ce05afc"
  138. )
  139. /* harmony default export */ var TabNav = __webpack_exports__["default"] = (component.exports);
  140. /***/ }),
  141. /***/ 191:
  142. /***/ (function(module, __webpack_exports__, __webpack_require__) {
  143. "use strict";
  144. __webpack_require__.r(__webpack_exports__);
  145. /* harmony import */ var _node_modules_css_loader_dist_cjs_js_ref_7_oneOf_1_0_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_dist_cjs_js_ref_7_oneOf_1_1_node_modules_sass_loader_dist_cjs_js_ref_7_oneOf_1_2_node_modules_nuxt_components_dist_loader_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_TabNav_vue_vue_type_style_index_0_id_8a32da06_prod_lang_scss_scoped_true__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(170);
  146. /* harmony import */ var _node_modules_css_loader_dist_cjs_js_ref_7_oneOf_1_0_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_dist_cjs_js_ref_7_oneOf_1_1_node_modules_sass_loader_dist_cjs_js_ref_7_oneOf_1_2_node_modules_nuxt_components_dist_loader_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_TabNav_vue_vue_type_style_index_0_id_8a32da06_prod_lang_scss_scoped_true__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_cjs_js_ref_7_oneOf_1_0_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_dist_cjs_js_ref_7_oneOf_1_1_node_modules_sass_loader_dist_cjs_js_ref_7_oneOf_1_2_node_modules_nuxt_components_dist_loader_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_TabNav_vue_vue_type_style_index_0_id_8a32da06_prod_lang_scss_scoped_true__WEBPACK_IMPORTED_MODULE_0__);
  147. /* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _node_modules_css_loader_dist_cjs_js_ref_7_oneOf_1_0_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_dist_cjs_js_ref_7_oneOf_1_1_node_modules_sass_loader_dist_cjs_js_ref_7_oneOf_1_2_node_modules_nuxt_components_dist_loader_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_TabNav_vue_vue_type_style_index_0_id_8a32da06_prod_lang_scss_scoped_true__WEBPACK_IMPORTED_MODULE_0__) if(["default"].indexOf(__WEBPACK_IMPORT_KEY__) < 0) (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _node_modules_css_loader_dist_cjs_js_ref_7_oneOf_1_0_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_dist_cjs_js_ref_7_oneOf_1_1_node_modules_sass_loader_dist_cjs_js_ref_7_oneOf_1_2_node_modules_nuxt_components_dist_loader_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_TabNav_vue_vue_type_style_index_0_id_8a32da06_prod_lang_scss_scoped_true__WEBPACK_IMPORTED_MODULE_0__[key]; }) }(__WEBPACK_IMPORT_KEY__));
  148. /***/ })
  149. };;
  150. //# sourceMappingURL=tab-nav.js.map