@abi-software/gallery 0.3.1 → 0.3.2-beta
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/.browserslistrc +3 -3
- package/.eslintrc.js +36 -31
- package/.prettierrc +6 -6
- package/LICENSE +201 -201
- package/Meeting-plan.txt +4 -0
- package/README.md +35 -35
- package/babel.config.js +12 -12
- package/dist/gallery.common.js +64 -61
- package/dist/gallery.common.js.map +1 -1
- package/dist/gallery.css +1 -1
- package/dist/gallery.umd.js +64 -61
- package/dist/gallery.umd.js.map +1 -1
- package/dist/gallery.umd.min.js +1 -1
- package/dist/gallery.umd.min.js.map +1 -1
- package/jest.config.js +3 -3
- package/package.json +43 -43
- package/public/index.html +17 -17
- package/src/App.vue +28 -28
- package/src/components/Card.vue +324 -319
- package/src/components/Gallery.vue +250 -250
- package/src/components/IndexIndicator.vue +45 -45
- package/src/delete.json +39 -0
- package/src/index.js +2 -2
- package/src/main.js +2 -2
- package/src/mixins/GalleryHelpers.js +104 -104
- package/tests/unit/example.spec.js +12 -12
- package/vue.config.js +23 -23
- package/src/assets/data-icon.png +0 -0
- package/src/assets/flatmap-thumbnail.png +0 -0
- package/src/assets/scaffold-light.png +0 -0
- package/src/assets/video-default.png +0 -0
package/dist/gallery.umd.js
CHANGED
|
@@ -2195,6 +2195,17 @@ var getBuiltIn = __webpack_require__("d066");
|
|
|
2195
2195
|
module.exports = getBuiltIn('navigator', 'userAgent') || '';
|
|
2196
2196
|
|
|
2197
2197
|
|
|
2198
|
+
/***/ }),
|
|
2199
|
+
|
|
2200
|
+
/***/ "3587":
|
|
2201
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
2202
|
+
|
|
2203
|
+
"use strict";
|
|
2204
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_node_modules_vue_svg_inline_loader_src_index_js_Card_vue_vue_type_style_index_0_id_3bfc85a8_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("8689");
|
|
2205
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_node_modules_vue_svg_inline_loader_src_index_js_Card_vue_vue_type_style_index_0_id_3bfc85a8_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_node_modules_vue_svg_inline_loader_src_index_js_Card_vue_vue_type_style_index_0_id_3bfc85a8_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__);
|
|
2206
|
+
/* unused harmony reexport * */
|
|
2207
|
+
|
|
2208
|
+
|
|
2198
2209
|
/***/ }),
|
|
2199
2210
|
|
|
2200
2211
|
/***/ "35a1":
|
|
@@ -2586,17 +2597,6 @@ module.exports = function settle(resolve, reject, response) {
|
|
|
2586
2597
|
};
|
|
2587
2598
|
|
|
2588
2599
|
|
|
2589
|
-
/***/ }),
|
|
2590
|
-
|
|
2591
|
-
/***/ "469f":
|
|
2592
|
-
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
2593
|
-
|
|
2594
|
-
"use strict";
|
|
2595
|
-
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_node_modules_vue_svg_inline_loader_src_index_js_Card_vue_vue_type_style_index_0_id_82fea1fc_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("7a98");
|
|
2596
|
-
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_node_modules_vue_svg_inline_loader_src_index_js_Card_vue_vue_type_style_index_0_id_82fea1fc_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_css_loader_dist_cjs_js_ref_6_oneOf_1_1_node_modules_vue_loader_lib_loaders_stylePostLoader_js_node_modules_postcss_loader_src_index_js_ref_6_oneOf_1_2_node_modules_cache_loader_dist_cjs_js_ref_0_0_node_modules_vue_loader_lib_index_js_vue_loader_options_node_modules_vue_svg_inline_loader_src_index_js_Card_vue_vue_type_style_index_0_id_82fea1fc_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__);
|
|
2597
|
-
/* unused harmony reexport * */
|
|
2598
|
-
|
|
2599
|
-
|
|
2600
2600
|
/***/ }),
|
|
2601
2601
|
|
|
2602
2602
|
/***/ "4840":
|
|
@@ -6363,13 +6363,6 @@ Cancel.prototype.__CANCEL__ = true;
|
|
|
6363
6363
|
module.exports = Cancel;
|
|
6364
6364
|
|
|
6365
6365
|
|
|
6366
|
-
/***/ }),
|
|
6367
|
-
|
|
6368
|
-
/***/ "7a98":
|
|
6369
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
6370
|
-
|
|
6371
|
-
// extracted by mini-css-extract-plugin
|
|
6372
|
-
|
|
6373
6366
|
/***/ }),
|
|
6374
6367
|
|
|
6375
6368
|
/***/ "7aac":
|
|
@@ -7178,6 +7171,13 @@ module.exports = function (it) {
|
|
|
7178
7171
|
};
|
|
7179
7172
|
|
|
7180
7173
|
|
|
7174
|
+
/***/ }),
|
|
7175
|
+
|
|
7176
|
+
/***/ "8689":
|
|
7177
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
7178
|
+
|
|
7179
|
+
// extracted by mini-css-extract-plugin
|
|
7180
|
+
|
|
7181
7181
|
/***/ }),
|
|
7182
7182
|
|
|
7183
7183
|
/***/ "8875":
|
|
@@ -12564,7 +12564,7 @@ if (typeof window !== 'undefined') {
|
|
|
12564
12564
|
// Indicate to webpack that this file can be concatenated
|
|
12565
12565
|
/* harmony default export */ var setPublicPath = (null);
|
|
12566
12566
|
|
|
12567
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
12567
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"5ec2d5a4-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./node_modules/vue-svg-inline-loader/src!./src/components/Gallery.vue?vue&type=template&id=2d26752e&scoped=true&
|
|
12568
12568
|
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{ref:"myButton",staticClass:"gallery"},[_c('div',{staticClass:"gallery-strip"},[(_vm.items.length > 1)?_c('a',{class:['oval', 'prev', { disabled: !_vm.isPrevPossible }],attrs:{"href":"#"},on:{"click":function($event){$event.preventDefault();return _vm.goPrev.apply(null, arguments)}}},[_c('span',{staticClass:"progress-button"},[_vm._v("‹")])]):_c('div',{staticStyle:{"width":"2rem"}}),_c('div',{staticClass:"filler"}),_c('div',{staticClass:"card-line"},_vm._l((_vm.windowedItems),function(item,index){return _c('span',{key:'card_' + index,class:['key-image-span', { active: _vm.isActive(index) }]},[(item)?_c('card',{attrs:{"data":item,"body-style":_vm.bodyStyle,"image-container-style":_vm.imageContainerStyle,"image-style":_vm.imageStyle,"width":_vm.cardWidth,"height":_vm.cardHeight,"shadow":_vm.shadow,"show-card-details":_vm.showCardDetails},on:{"card-clicked":_vm.cardClicked}}):_vm._e()],1)}),0),_c('div',{staticClass:"filler"}),(_vm.items.length > 1)?_c('a',{class:['oval', 'next', { disabled: !_vm.isNextPossible }],attrs:{"href":"#"},on:{"click":function($event){$event.preventDefault();return _vm.goNext.apply(null, arguments)}}},[_c('span',{staticClass:"progress-button"},[_vm._v("›")])]):_c('div',{staticStyle:{"width":"2rem"}})]),_c('div',{style:(_vm.bottomSpacer)}),(_vm.canShowIndicatorBar)?_c('index-indicator',{attrs:{"count":_vm.itemCount,"current":_vm.currentIndex},on:{"clicked":_vm.indicatorClicked}}):_vm._e()],1)}
|
|
12569
12569
|
var staticRenderFns = []
|
|
12570
12570
|
|
|
@@ -12574,7 +12574,7 @@ var staticRenderFns = []
|
|
|
12574
12574
|
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.number.constructor.js
|
|
12575
12575
|
var es_number_constructor = __webpack_require__("a9e3");
|
|
12576
12576
|
|
|
12577
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
12577
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"5ec2d5a4-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./node_modules/vue-svg-inline-loader/src!./src/components/IndexIndicator.vue?vue&type=template&id=162e33aa&scoped=true&
|
|
12578
12578
|
var IndexIndicatorvue_type_template_id_162e33aa_scoped_true_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"indicator-container"},_vm._l((_vm.count),function(number,index){return _c('div',{key:'indicator_' + number,class:['indicator', { active: _vm.current === index }],on:{"click":function($event){return _vm.$emit('clicked', index)}}})}),0)}
|
|
12579
12579
|
var IndexIndicatorvue_type_template_id_162e33aa_scoped_true_staticRenderFns = []
|
|
12580
12580
|
|
|
@@ -12733,12 +12733,12 @@ var component = normalizeComponent(
|
|
|
12733
12733
|
)
|
|
12734
12734
|
|
|
12735
12735
|
/* harmony default export */ var IndexIndicator = (component.exports);
|
|
12736
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
12737
|
-
var
|
|
12738
|
-
var
|
|
12736
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"5ec2d5a4-vue-loader-template"}!./node_modules/vue-loader/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./node_modules/vue-svg-inline-loader/src!./src/components/Card.vue?vue&type=template&id=3bfc85a8&scoped=true&
|
|
12737
|
+
var Cardvue_type_template_id_3bfc85a8_scoped_true_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('el-card',{staticClass:"card",style:({ padding: '0px', maxWidth: _vm.width + 'rem' }),attrs:{"shadow":_vm.shadow,"body-style":_vm.bodyStyle}},[_c('div',{directives:[{name:"loading",rawName:"v-loading",value:(!_vm.isReady),expression:"!isReady"}]},[_c('div',{style:(_vm.imageContainerStyle)},[(_vm.useDefaultImg)?_c('svg',{style:(_vm.imageStyle),attrs:{"data-name":"logo-sparc-wave-primary","xmlns":"http://www.w3.org/2000/svg","viewBox":"0 0 400 190.585","svg-inline":'',"role":'presentation',"focusable":'false',"tabindex":'-1'}},[_c('defs',[_c('linearGradient',{attrs:{"id":"a","y1":"96.35","x2":"400","y2":"96.35","gradientUnits":"userSpaceOnUse"}},[_c('stop',{attrs:{"offset":"0","stop-color":"#0b00bf"}}),_c('stop',{attrs:{"offset":"1","stop-color":"#bc00fc"}})],1)],1),_c('path',{attrs:{"d":"M396.698 128.625l-146.274-3.38a6.536 6.536 0 00-6.138 3.923l-.06.141-13.674 31.448-27.61-151.224-.01-.068a8.982 8.982 0 00-17.663-.012l-21.596 115.929-160.375 3.907a3.38 3.38 0 00.027 6.759l166.015 2.715a6.594 6.594 0 006.537-5.145l.057-.255 17.854-79.565 27.472 131.326.026.124a6.76 6.76 0 0012.806 1.272l20.808-47.86 141.798-3.276a3.38 3.38 0 000-6.76z","fill":"url(#a)"}}),_c('path',{attrs:{"d":"M25.68 0c15.716 0 25.377 10.093 25.377 26.097v9.516H36.205v-9.516c0-7.353-3.894-11.822-10.526-11.822-6.776 0-10.669 4.469-10.669 11.822 0 3.895 1.298 7.353 5.479 11.391l19.754 18.601C46.586 62.144 52.21 68.778 52.21 79.88c0 16.005-9.95 26.097-25.954 26.097C10.108 105.977.158 95.885.158 79.88v-9.518H15.01v9.518c0 7.353 4.037 11.822 11.245 11.822 7.065 0 11.103-4.469 11.103-11.822 0-4.47-2.163-8.651-6.055-12.258L11.116 48.736C3.043 41.237.159 34.894.159 25.666.159 10.093 9.82 0 25.678 0zM99.797 69.786v35.182H84.945V1.01h25.376c16.005 0 26.097 10.093 26.097 26.097v16.581c0 16.15-10.092 26.098-26.097 26.098zm10.38-13.985c7.209 0 11.392-4.326 11.392-11.68V26.677c0-7.21-4.183-11.681-11.391-11.681h-10.38V55.8zM278.581 108.147H263.73V4.189h26.097c16.005 0 26.098 10.093 26.098 26.098v14.13c0 9.95-4.326 17.736-11.391 22.205 4.182 12.688 10.092 29.991 13.842 41.525h-15.14L290.69 70.37h-12.11zm11.1-51.763c7.21 0 11.39-4.326 11.39-11.534V29.855c0-7.21-4.18-11.68-11.39-11.68h-11.1v38.21zM399.844 73.541v9.519c0 16.005-9.947 26.097-25.952 26.097-16.15 0-26.097-10.092-26.097-26.097V29.277c0-16.005 9.947-26.098 26.097-26.098 16.005 0 25.952 10.093 25.952 26.098v9.516h-14.85v-9.516c0-7.354-4.037-11.822-11.103-11.822-7.21 0-11.247 4.468-11.247 11.822V83.06c0 7.353 4.037 11.822 11.247 11.822 7.066 0 11.103-4.469 11.103-11.822v-9.519z","fill":"#0e0e19"}})]):_c('img',{style:(_vm.imageStyle),attrs:{"src":_vm.thumbnail,"alt":"thumbnail loading ..."}})]),(false)?undefined:_vm._e(),(_vm.showCardDetails)?_c('div',{staticClass:"details"},[(!_vm.data.hideType)?_c('p',[_c('b',[_vm._v(_vm._s(_vm.data.type))])]):_vm._e(),_c('el-popover',{ref:"galleryPopover",attrs:{"disabled":_vm.disableTooltip,"content":_vm.data.title,"placement":"top","trigger":"hover","popper-class":"gallery-popper"}}),_c('p',{directives:[{name:"show",rawName:"v-show",value:(!_vm.data.hideTitle),expression:"!data.hideTitle"},{name:"popover",rawName:"v-popover:galleryPopover",arg:"galleryPopover"}],ref:"titleText",staticClass:"title"},[_vm._v(" "+_vm._s(_vm.data.title)+" ")]),_c('p',{directives:[{name:"show",rawName:"v-show",value:(_vm.data.hideTitle),expression:"data.hideTitle"}],staticClass:"title text-placeholder"}),_c('el-button',{staticClass:"button",on:{"click":function($event){$event.preventDefault();return _vm.cardClicked.apply(null, arguments)}}},[_vm._v(" View "+_vm._s(_vm.data.type))])],1):_vm._e()])])}
|
|
12738
|
+
var Cardvue_type_template_id_3bfc85a8_scoped_true_staticRenderFns = []
|
|
12739
12739
|
|
|
12740
12740
|
|
|
12741
|
-
// CONCATENATED MODULE: ./src/components/Card.vue?vue&type=template&id=
|
|
12741
|
+
// CONCATENATED MODULE: ./src/components/Card.vue?vue&type=template&id=3bfc85a8&scoped=true&
|
|
12742
12742
|
|
|
12743
12743
|
// EXTERNAL MODULE: ./node_modules/element-ui/lib/theme-chalk/popover.css
|
|
12744
12744
|
var popover = __webpack_require__("06f1");
|
|
@@ -12899,20 +12899,20 @@ var axios_default = /*#__PURE__*/__webpack_require__.n(axios);
|
|
|
12899
12899
|
}))();
|
|
12900
12900
|
},
|
|
12901
12901
|
|
|
12902
|
-
/**
|
|
12903
|
-
* Returns a file path for S3.
|
|
12904
|
-
* @param {String} dataset_id dataset id.
|
|
12905
|
-
* @param {String} dataset_version dataset version.
|
|
12906
|
-
* @param {String} file_path file path.
|
|
12907
|
-
* @returns {String} full path to S3 file.
|
|
12902
|
+
/**
|
|
12903
|
+
* Returns a file path for S3.
|
|
12904
|
+
* @param {String} dataset_id dataset id.
|
|
12905
|
+
* @param {String} dataset_version dataset version.
|
|
12906
|
+
* @param {String} file_path file path.
|
|
12907
|
+
* @returns {String} full path to S3 file.
|
|
12908
12908
|
*/
|
|
12909
12909
|
getS3FilePath: function getS3FilePath(dataset_id, dataset_version, file_path) {
|
|
12910
12910
|
var encoded_file_path = encodeURIComponent(file_path);
|
|
12911
12911
|
return "".concat(dataset_id, "/").concat(dataset_version, "/files/").concat(encoded_file_path);
|
|
12912
12912
|
},
|
|
12913
12913
|
|
|
12914
|
-
/**
|
|
12915
|
-
* Find data path in the array that matches the provide path
|
|
12914
|
+
/**
|
|
12915
|
+
* Find data path in the array that matches the provide path
|
|
12916
12916
|
*/
|
|
12917
12917
|
findEntryWithPathInArray: function findEntryWithPathInArray(array, path) {
|
|
12918
12918
|
if (path && array) {
|
|
@@ -12931,9 +12931,9 @@ var axios_default = /*#__PURE__*/__webpack_require__.n(axios);
|
|
|
12931
12931
|
return undefined;
|
|
12932
12932
|
},
|
|
12933
12933
|
|
|
12934
|
-
/**
|
|
12935
|
-
* Use the scaffoldViews to help with finding the correct thumbnails.
|
|
12936
|
-
* Use the index if the workflow stated above fails.
|
|
12934
|
+
/**
|
|
12935
|
+
* Use the scaffoldViews to help with finding the correct thumbnails.
|
|
12936
|
+
* Use the index if the workflow stated above fails.
|
|
12937
12937
|
*/
|
|
12938
12938
|
getThumbnailForScaffold: function getThumbnailForScaffold(scaffold, scaffoldViews, thumbnails, index) {
|
|
12939
12939
|
if (thumbnails && thumbnails.length > 0) {
|
|
@@ -13186,10 +13186,19 @@ function isValidHttpUrl(string) {
|
|
|
13186
13186
|
}
|
|
13187
13187
|
}
|
|
13188
13188
|
},
|
|
13189
|
+
updated: function updated() {
|
|
13190
|
+
var _this2 = this;
|
|
13191
|
+
|
|
13192
|
+
if (!this.tooltipCalculated) {
|
|
13193
|
+
this.$nextTick(function () {
|
|
13194
|
+
_this2.calculateShowTooltip();
|
|
13195
|
+
});
|
|
13196
|
+
}
|
|
13197
|
+
},
|
|
13189
13198
|
methods: {
|
|
13190
|
-
/**
|
|
13191
|
-
* Open a new link if link is provide.
|
|
13192
|
-
* Fire an event if userData is provide.
|
|
13199
|
+
/**
|
|
13200
|
+
* Open a new link if link is provide.
|
|
13201
|
+
* Fire an event if userData is provide.
|
|
13193
13202
|
*/
|
|
13194
13203
|
cardClicked: function cardClicked() {
|
|
13195
13204
|
if (this.data.link) {
|
|
@@ -13206,32 +13215,35 @@ function isValidHttpUrl(string) {
|
|
|
13206
13215
|
}
|
|
13207
13216
|
},
|
|
13208
13217
|
|
|
13209
|
-
/**
|
|
13210
|
-
* handle thumbnail downloading,, it will use a default svg image if fails
|
|
13218
|
+
/**
|
|
13219
|
+
* handle thumbnail downloading,, it will use a default svg image if fails
|
|
13211
13220
|
*/
|
|
13212
13221
|
downloadThumbnail: function downloadThumbnail(url, info) {
|
|
13213
|
-
var
|
|
13222
|
+
var _this3 = this;
|
|
13214
13223
|
|
|
13215
13224
|
this.getRequest(url, {}, 11000).then(function (response) {
|
|
13216
13225
|
var data = response.data;
|
|
13217
13226
|
|
|
13218
13227
|
if (data.startsWith('data:')) {
|
|
13219
|
-
|
|
13228
|
+
_this3.thumbnail = response.data;
|
|
13220
13229
|
} else {
|
|
13221
|
-
if (
|
|
13222
|
-
|
|
13230
|
+
if (_this3.data.mimetype) {
|
|
13231
|
+
_this3.thumbnail = "data:".concat(_this3.data.mimetype, ";base64,").concat(response.data);
|
|
13223
13232
|
} else {
|
|
13224
|
-
|
|
13233
|
+
_this3.thumbnail = response.data;
|
|
13225
13234
|
}
|
|
13226
13235
|
}
|
|
13227
13236
|
}, function (reason) {
|
|
13228
13237
|
if (reason.message.includes('timeout') && reason.message.includes('exceeded') && info.fetchAttempts < 3) {
|
|
13229
13238
|
info.fetchAttempts += 1;
|
|
13230
13239
|
|
|
13231
|
-
|
|
13240
|
+
_this3.downloadThumbnail(url, info);
|
|
13232
13241
|
} else {
|
|
13233
|
-
|
|
13242
|
+
_this3.useDefaultImg = true;
|
|
13234
13243
|
}
|
|
13244
|
+
}).catch(function (error) {
|
|
13245
|
+
console.error(error);
|
|
13246
|
+
_this3.useDefaultImg = true;
|
|
13235
13247
|
});
|
|
13236
13248
|
},
|
|
13237
13249
|
//dynamically calculate if tooltip is required
|
|
@@ -13251,21 +13263,12 @@ function isValidHttpUrl(string) {
|
|
|
13251
13263
|
}
|
|
13252
13264
|
}
|
|
13253
13265
|
}
|
|
13254
|
-
},
|
|
13255
|
-
updated: function updated() {
|
|
13256
|
-
var _this3 = this;
|
|
13257
|
-
|
|
13258
|
-
if (!this.tooltipCalculated) {
|
|
13259
|
-
this.$nextTick(function () {
|
|
13260
|
-
_this3.calculateShowTooltip();
|
|
13261
|
-
});
|
|
13262
|
-
}
|
|
13263
13266
|
}
|
|
13264
13267
|
});
|
|
13265
13268
|
// CONCATENATED MODULE: ./src/components/Card.vue?vue&type=script&lang=js&
|
|
13266
13269
|
/* harmony default export */ var components_Cardvue_type_script_lang_js_ = (Cardvue_type_script_lang_js_);
|
|
13267
|
-
// EXTERNAL MODULE: ./src/components/Card.vue?vue&type=style&index=0&id=
|
|
13268
|
-
var
|
|
13270
|
+
// EXTERNAL MODULE: ./src/components/Card.vue?vue&type=style&index=0&id=3bfc85a8&scoped=true&lang=css&
|
|
13271
|
+
var Cardvue_type_style_index_0_id_3bfc85a8_scoped_true_lang_css_ = __webpack_require__("3587");
|
|
13269
13272
|
|
|
13270
13273
|
// EXTERNAL MODULE: ./src/components/Card.vue?vue&type=style&index=1&lang=css&
|
|
13271
13274
|
var Cardvue_type_style_index_1_lang_css_ = __webpack_require__("529c");
|
|
@@ -13282,11 +13285,11 @@ var Cardvue_type_style_index_1_lang_css_ = __webpack_require__("529c");
|
|
|
13282
13285
|
|
|
13283
13286
|
var Card_component = normalizeComponent(
|
|
13284
13287
|
components_Cardvue_type_script_lang_js_,
|
|
13285
|
-
|
|
13286
|
-
|
|
13288
|
+
Cardvue_type_template_id_3bfc85a8_scoped_true_render,
|
|
13289
|
+
Cardvue_type_template_id_3bfc85a8_scoped_true_staticRenderFns,
|
|
13287
13290
|
false,
|
|
13288
13291
|
null,
|
|
13289
|
-
"
|
|
13292
|
+
"3bfc85a8",
|
|
13290
13293
|
null
|
|
13291
13294
|
|
|
13292
13295
|
)
|