@phoenix-cg/v-tabs 0.1.32 → 0.1.34

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.
@@ -5821,15 +5821,15 @@ if (typeof window !== 'undefined') {
5821
5821
  // Indicate to webpack that this file can be concatenated
5822
5822
  /* harmony default export */ var setPublicPath = (null);
5823
5823
 
5824
- // CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"3c2a0523-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--1-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/VTabs.vue?vue&type=template&id=2f7c9911&
5825
- var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"v-tabs-wrap"},[_c('div',{ref:"tabsEl",staticClass:"v-tabs",class:[("__" + _vm.direction)]},[_c('div',{staticClass:"v-tabs_inner"},_vm._l((_vm.list),function(tab){return _c('div',{key:tab[_vm.trackBy],ref:"tabs",refInFor:true,staticClass:"v-tabs_tab",class:{
5824
+ // CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"93691d22-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--1-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/VTabs.vue?vue&type=template&id=c6822a6a&
5825
+ var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"v-tabs-wrap"},[_c('div',{ref:"tabsEl",staticClass:"v-tabs",class:[("__" + _vm.direction)]},[_c('div',{staticClass:"v-tabs_inner"},_vm._l((_vm.list),function(tab){return _c(_vm.tabComponent,_vm._b({key:tab[_vm.trackBy],ref:"tabs",refInFor:true,tag:"component",staticClass:"v-tabs_tab",class:{
5826
5826
  __active: _vm.value && _vm.value[_vm.trackBy] === tab[_vm.trackBy],
5827
5827
  _disabled: tab && tab._disabled
5828
- },attrs:{"data-id":tab[_vm.trackBy]},on:{"click":function($event){return _vm.handleTabSelect(tab, $event)}}},[_vm._t("single-tab",function(){return [(_vm.wrapTitle)?[_c('div',{staticClass:"v-tabs_tab_title"},[_vm._v(" "+_vm._s(tab[_vm.label] || "")+" ")])]:[_vm._v(" "+_vm._s(tab[_vm.label] || "")+" ")]]},{"tab":tab})],2)}),0),(_vm.withSlider)?_c('div',{staticClass:"v-tabs_slider",style:(_vm.sliderStyle)}):_vm._e()]),_c(_vm.mobileHintComponent,{tag:"component",staticClass:"v-tabs-hint",class:{ __visible: _vm.isHintVisible }})],1)}
5828
+ },attrs:{"data-id":tab[_vm.trackBy]},on:{"click":function($event){return _vm.handleTabSelect(tab, $event)}}},'component',_vm.tabProps(tab),false),[_vm._t("single-tab",function(){return [(_vm.wrapTitle)?[_c('div',{staticClass:"v-tabs_tab_title"},[_vm._v(" "+_vm._s(tab[_vm.label] || "")+" ")])]:[_vm._v(" "+_vm._s(tab[_vm.label] || "")+" ")]]},{"tab":tab})],2)}),1),(_vm.withSlider)?_c('div',{staticClass:"v-tabs_slider",style:(_vm.sliderStyle)}):_vm._e()]),_c(_vm.mobileHintComponent,{tag:"component",staticClass:"v-tabs-hint",class:{ __visible: _vm.isHintVisible }})],1)}
5829
5829
  var staticRenderFns = []
5830
5830
 
5831
5831
 
5832
- // CONCATENATED MODULE: ./src/components/VTabs.vue?vue&type=template&id=2f7c9911&
5832
+ // CONCATENATED MODULE: ./src/components/VTabs.vue?vue&type=template&id=c6822a6a&
5833
5833
 
5834
5834
  // CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js
5835
5835
  function _arrayWithHoles(arr) {
@@ -6048,6 +6048,7 @@ var web_dom_collections_for_each = __webpack_require__("159b");
6048
6048
  //
6049
6049
  //
6050
6050
  //
6051
+ //
6051
6052
  /* harmony default export */ var VTabsvue_type_script_lang_js_ = ({
6052
6053
  props: {
6053
6054
  direction: {
@@ -6095,6 +6096,16 @@ var web_dom_collections_for_each = __webpack_require__("159b");
6095
6096
  mobileHintHideDelay: {
6096
6097
  type: Number,
6097
6098
  default: 2000
6099
+ },
6100
+ tabComponent: {
6101
+ type: String,
6102
+ default: 'div'
6103
+ },
6104
+ tabProps: {
6105
+ type: Function,
6106
+ default: function _default() {
6107
+ return {};
6108
+ }
6098
6109
  }
6099
6110
  },
6100
6111
  data: function data() {
@@ -6105,6 +6116,11 @@ var web_dom_collections_for_each = __webpack_require__("159b");
6105
6116
  hintObserver: null
6106
6117
  };
6107
6118
  },
6119
+ computed: {
6120
+ hintShowCondition: function hintShowCondition() {
6121
+ return this.mobileHintComponent;
6122
+ }
6123
+ },
6108
6124
  watch: {
6109
6125
  value: function value() {
6110
6126
  this.withSlider && this.calcSlider();
@@ -6116,11 +6132,6 @@ var web_dom_collections_for_each = __webpack_require__("159b");
6116
6132
  this.createHintObserver();
6117
6133
  }
6118
6134
  },
6119
- computed: {
6120
- hintShowCondition: function hintShowCondition() {
6121
- return this.mobileHintComponent;
6122
- }
6123
- },
6124
6135
  mounted: function mounted() {
6125
6136
  var _this = this;
6126
6137
 
@@ -6150,20 +6161,18 @@ var web_dom_collections_for_each = __webpack_require__("159b");
6150
6161
  var _this2 = this;
6151
6162
 
6152
6163
  if (this.hintShowCondition) {
6153
- this.hintObserver = new IntersectionObserver(function (entries) {
6164
+ this.hintObserver = new IntersectionObserver(function (entries, observer) {
6154
6165
  entries.forEach(function (entry) {
6155
6166
  if (entry.isIntersecting) {
6156
6167
  _this2.queueShowHint();
6157
6168
 
6158
- _this2.hintObserver.disconnect();
6159
-
6169
+ observer.disconnect();
6160
6170
  _this2.hintObserver = null;
6161
6171
  }
6162
6172
  });
6163
6173
  }, {
6164
6174
  threshold: 1.0
6165
- });
6166
- this.hintObserver.observe(this.$el);
6175
+ }); // this.hintObserver.observe(this.$el)
6167
6176
  }
6168
6177
  },
6169
6178
  queueShowHint: function queueShowHint() {
@@ -6190,7 +6199,9 @@ var web_dom_collections_for_each = __webpack_require__("159b");
6190
6199
  _this5.calcSlider();
6191
6200
  });
6192
6201
  this.$refs.tabs.forEach(function (tabEl) {
6193
- _this5.resizeObserver.observe(tabEl);
6202
+ var el = tabEl.$el || tabEl;
6203
+
6204
+ _this5.resizeObserver.observe(el);
6194
6205
  });
6195
6206
  }
6196
6207
  },