@abi-software/map-side-bar 1.1.5-beta-0 → 1.1.5-beta-1
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/README.md +11 -2
- package/dist/map-side-bar.common.js +607 -318
- package/dist/map-side-bar.common.js.map +1 -1
- package/dist/map-side-bar.css +1 -1
- package/dist/map-side-bar.umd.js +607 -318
- package/dist/map-side-bar.umd.js.map +1 -1
- package/dist/map-side-bar.umd.min.js +1 -1
- package/dist/map-side-bar.umd.min.js.map +1 -1
- package/package-lock.json +384 -146
- package/package.json +3 -1
- package/src/App.vue +13 -10
- package/src/algolia/algolia.js +98 -0
- package/src/algolia/utils.js +52 -0
- package/src/components/DatasetCard.vue +25 -14
- package/src/components/SearchFilters.vue +137 -128
- package/src/components/SideBar.vue +11 -6
- package/src/components/SidebarContent.vue +58 -70
|
@@ -129,6 +129,13 @@ module.exports = require("element-ui/lib/theme-chalk/select.css");
|
|
|
129
129
|
|
|
130
130
|
/***/ }),
|
|
131
131
|
|
|
132
|
+
/***/ "12bc":
|
|
133
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
134
|
+
|
|
135
|
+
// extracted by mini-css-extract-plugin
|
|
136
|
+
|
|
137
|
+
/***/ }),
|
|
138
|
+
|
|
132
139
|
/***/ "139f":
|
|
133
140
|
/***/ (function(module, exports) {
|
|
134
141
|
|
|
@@ -284,18 +291,7 @@ module.exports = require("core-js/modules/es.regexp.exec");
|
|
|
284
291
|
|
|
285
292
|
/***/ }),
|
|
286
293
|
|
|
287
|
-
/***/ "
|
|
288
|
-
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
289
|
-
|
|
290
|
-
"use strict";
|
|
291
|
-
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_DatasetCard_vue_vue_type_style_index_0_id_7989efa8_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("5b3d");
|
|
292
|
-
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_DatasetCard_vue_vue_type_style_index_0_id_7989efa8_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_vue_cli_service_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_DatasetCard_vue_vue_type_style_index_0_id_7989efa8_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__);
|
|
293
|
-
/* unused harmony reexport * */
|
|
294
|
-
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_DatasetCard_vue_vue_type_style_index_0_id_7989efa8_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default.a);
|
|
295
|
-
|
|
296
|
-
/***/ }),
|
|
297
|
-
|
|
298
|
-
/***/ "5b3d":
|
|
294
|
+
/***/ "5835":
|
|
299
295
|
/***/ (function(module, exports, __webpack_require__) {
|
|
300
296
|
|
|
301
297
|
// extracted by mini-css-extract-plugin
|
|
@@ -323,17 +319,6 @@ module.exports = require("core-js/modules/es.symbol");
|
|
|
323
319
|
|
|
324
320
|
/***/ }),
|
|
325
321
|
|
|
326
|
-
/***/ "625c":
|
|
327
|
-
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
328
|
-
|
|
329
|
-
"use strict";
|
|
330
|
-
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_SideBar_vue_vue_type_style_index_0_id_a53cebae_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("a2e0");
|
|
331
|
-
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_SideBar_vue_vue_type_style_index_0_id_a53cebae_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_vue_cli_service_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_SideBar_vue_vue_type_style_index_0_id_a53cebae_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__);
|
|
332
|
-
/* unused harmony reexport * */
|
|
333
|
-
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_SideBar_vue_vue_type_style_index_0_id_a53cebae_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default.a);
|
|
334
|
-
|
|
335
|
-
/***/ }),
|
|
336
|
-
|
|
337
322
|
/***/ "6579":
|
|
338
323
|
/***/ (function(module, exports) {
|
|
339
324
|
|
|
@@ -390,7 +375,7 @@ module.exports = require("core-js/modules/es.number.constructor");
|
|
|
390
375
|
|
|
391
376
|
/***/ }),
|
|
392
377
|
|
|
393
|
-
/***/ "
|
|
378
|
+
/***/ "7919":
|
|
394
379
|
/***/ (function(module, exports, __webpack_require__) {
|
|
395
380
|
|
|
396
381
|
// extracted by mini-css-extract-plugin
|
|
@@ -446,6 +431,13 @@ module.exports = require("core-js/modules/es.object.to-string");
|
|
|
446
431
|
|
|
447
432
|
/***/ }),
|
|
448
433
|
|
|
434
|
+
/***/ "88eb":
|
|
435
|
+
/***/ (function(module, exports) {
|
|
436
|
+
|
|
437
|
+
module.exports = require("algoliasearch");
|
|
438
|
+
|
|
439
|
+
/***/ }),
|
|
440
|
+
|
|
449
441
|
/***/ "8bbf":
|
|
450
442
|
/***/ (function(module, exports) {
|
|
451
443
|
|
|
@@ -474,6 +466,13 @@ module.exports = require("core-js/modules/es.string.iterator");
|
|
|
474
466
|
|
|
475
467
|
/***/ }),
|
|
476
468
|
|
|
469
|
+
/***/ "9861":
|
|
470
|
+
/***/ (function(module, exports) {
|
|
471
|
+
|
|
472
|
+
module.exports = require("core-js/modules/es.map");
|
|
473
|
+
|
|
474
|
+
/***/ }),
|
|
475
|
+
|
|
477
476
|
/***/ "9a25":
|
|
478
477
|
/***/ (function(module, exports) {
|
|
479
478
|
|
|
@@ -481,17 +480,17 @@ module.exports = require("element-ui/lib/theme-chalk/base.css");
|
|
|
481
480
|
|
|
482
481
|
/***/ }),
|
|
483
482
|
|
|
484
|
-
/***/ "
|
|
485
|
-
/***/ (function(module, exports
|
|
483
|
+
/***/ "9a3c":
|
|
484
|
+
/***/ (function(module, exports) {
|
|
486
485
|
|
|
487
|
-
module.exports =
|
|
486
|
+
module.exports = require("core-js/modules/es.array.flat");
|
|
488
487
|
|
|
489
488
|
/***/ }),
|
|
490
489
|
|
|
491
|
-
/***/ "
|
|
490
|
+
/***/ "9b53":
|
|
492
491
|
/***/ (function(module, exports, __webpack_require__) {
|
|
493
492
|
|
|
494
|
-
|
|
493
|
+
module.exports = __webpack_require__.p + "img/missing-image.1878d8b8.svg";
|
|
495
494
|
|
|
496
495
|
/***/ }),
|
|
497
496
|
|
|
@@ -530,6 +529,17 @@ module.exports = require("element-ui/lib/icon");
|
|
|
530
529
|
|
|
531
530
|
/***/ }),
|
|
532
531
|
|
|
532
|
+
/***/ "bc5f":
|
|
533
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
534
|
+
|
|
535
|
+
"use strict";
|
|
536
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_SideBar_vue_vue_type_style_index_0_id_3d831a8e_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("5835");
|
|
537
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_SideBar_vue_vue_type_style_index_0_id_3d831a8e_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_vue_cli_service_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_SideBar_vue_vue_type_style_index_0_id_3d831a8e_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__);
|
|
538
|
+
/* unused harmony reexport * */
|
|
539
|
+
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_SideBar_vue_vue_type_style_index_0_id_3d831a8e_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default.a);
|
|
540
|
+
|
|
541
|
+
/***/ }),
|
|
542
|
+
|
|
533
543
|
/***/ "bcd8":
|
|
534
544
|
/***/ (function(module, exports) {
|
|
535
545
|
|
|
@@ -544,6 +554,24 @@ module.exports = require("core-js/modules/web.dom-collections.for-each");
|
|
|
544
554
|
|
|
545
555
|
/***/ }),
|
|
546
556
|
|
|
557
|
+
/***/ "be47":
|
|
558
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
559
|
+
|
|
560
|
+
"use strict";
|
|
561
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_SidebarContent_vue_vue_type_style_index_0_id_2e1db9a4_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("efa2");
|
|
562
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_SidebarContent_vue_vue_type_style_index_0_id_2e1db9a4_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_vue_cli_service_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_SidebarContent_vue_vue_type_style_index_0_id_2e1db9a4_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__);
|
|
563
|
+
/* unused harmony reexport * */
|
|
564
|
+
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_SidebarContent_vue_vue_type_style_index_0_id_2e1db9a4_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default.a);
|
|
565
|
+
|
|
566
|
+
/***/ }),
|
|
567
|
+
|
|
568
|
+
/***/ "be6e":
|
|
569
|
+
/***/ (function(module, exports) {
|
|
570
|
+
|
|
571
|
+
module.exports = require("core-js/modules/es.string.search");
|
|
572
|
+
|
|
573
|
+
/***/ }),
|
|
574
|
+
|
|
547
575
|
/***/ "bfab":
|
|
548
576
|
/***/ (function(module, exports) {
|
|
549
577
|
|
|
@@ -558,25 +586,21 @@ module.exports = require("element-ui/lib/option");
|
|
|
558
586
|
|
|
559
587
|
/***/ }),
|
|
560
588
|
|
|
561
|
-
/***/ "
|
|
589
|
+
/***/ "c3dd":
|
|
562
590
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
563
591
|
|
|
564
592
|
"use strict";
|
|
565
|
-
/* harmony import */ var
|
|
566
|
-
/* harmony import */ var
|
|
593
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_DatasetCard_vue_vue_type_style_index_0_id_eaeba60a_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("7919");
|
|
594
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_DatasetCard_vue_vue_type_style_index_0_id_eaeba60a_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_vue_cli_service_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_DatasetCard_vue_vue_type_style_index_0_id_eaeba60a_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__);
|
|
567
595
|
/* unused harmony reexport * */
|
|
568
|
-
/* unused harmony default export */ var _unused_webpack_default_export = (
|
|
596
|
+
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_DatasetCard_vue_vue_type_style_index_0_id_eaeba60a_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default.a);
|
|
569
597
|
|
|
570
598
|
/***/ }),
|
|
571
599
|
|
|
572
|
-
/***/ "
|
|
573
|
-
/***/ (function(module,
|
|
600
|
+
/***/ "dc05":
|
|
601
|
+
/***/ (function(module, exports) {
|
|
574
602
|
|
|
575
|
-
|
|
576
|
-
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_SearchFilters_vue_vue_type_style_index_0_id_cf619ba6_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("7851");
|
|
577
|
-
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_SearchFilters_vue_vue_type_style_index_0_id_cf619ba6_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_vue_cli_service_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_SearchFilters_vue_vue_type_style_index_0_id_cf619ba6_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__);
|
|
578
|
-
/* unused harmony reexport * */
|
|
579
|
-
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_SearchFilters_vue_vue_type_style_index_0_id_cf619ba6_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default.a);
|
|
603
|
+
module.exports = require("core-js/modules/es.array.last-index-of");
|
|
580
604
|
|
|
581
605
|
/***/ }),
|
|
582
606
|
|
|
@@ -587,6 +611,17 @@ module.exports = require("current-script-polyfill");
|
|
|
587
611
|
|
|
588
612
|
/***/ }),
|
|
589
613
|
|
|
614
|
+
/***/ "e026":
|
|
615
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
616
|
+
|
|
617
|
+
"use strict";
|
|
618
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_SearchFilters_vue_vue_type_style_index_0_id_d4e05720_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__("12bc");
|
|
619
|
+
/* harmony import */ var _node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_SearchFilters_vue_vue_type_style_index_0_id_d4e05720_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_vue_cli_service_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_SearchFilters_vue_vue_type_style_index_0_id_d4e05720_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0__);
|
|
620
|
+
/* unused harmony reexport * */
|
|
621
|
+
/* unused harmony default export */ var _unused_webpack_default_export = (_node_modules_mini_css_extract_plugin_dist_loader_js_ref_6_oneOf_1_0_node_modules_vue_cli_service_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_SearchFilters_vue_vue_type_style_index_0_id_d4e05720_scoped_true_lang_css___WEBPACK_IMPORTED_MODULE_0___default.a);
|
|
622
|
+
|
|
623
|
+
/***/ }),
|
|
624
|
+
|
|
590
625
|
/***/ "e42b":
|
|
591
626
|
/***/ (function(module, exports) {
|
|
592
627
|
|
|
@@ -608,6 +643,20 @@ module.exports = require("core-js/modules/es.object.entries");
|
|
|
608
643
|
|
|
609
644
|
/***/ }),
|
|
610
645
|
|
|
646
|
+
/***/ "ee85":
|
|
647
|
+
/***/ (function(module, exports) {
|
|
648
|
+
|
|
649
|
+
module.exports = require("core-js/modules/es.array.unscopables.flat");
|
|
650
|
+
|
|
651
|
+
/***/ }),
|
|
652
|
+
|
|
653
|
+
/***/ "efa2":
|
|
654
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
655
|
+
|
|
656
|
+
// extracted by mini-css-extract-plugin
|
|
657
|
+
|
|
658
|
+
/***/ }),
|
|
659
|
+
|
|
611
660
|
/***/ "f705":
|
|
612
661
|
/***/ (function(module, exports) {
|
|
613
662
|
|
|
@@ -615,6 +664,13 @@ module.exports = require("core-js/modules/es.array.map");
|
|
|
615
664
|
|
|
616
665
|
/***/ }),
|
|
617
666
|
|
|
667
|
+
/***/ "f96d":
|
|
668
|
+
/***/ (function(module, exports) {
|
|
669
|
+
|
|
670
|
+
module.exports = require("core-js/modules/es.promise.finally");
|
|
671
|
+
|
|
672
|
+
/***/ }),
|
|
673
|
+
|
|
618
674
|
/***/ "fae3":
|
|
619
675
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
620
676
|
|
|
@@ -642,12 +698,12 @@ if (typeof window !== 'undefined') {
|
|
|
642
698
|
// Indicate to webpack that this file can be concatenated
|
|
643
699
|
/* harmony default export */ var setPublicPath = (null);
|
|
644
700
|
|
|
645
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
646
|
-
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{ref:"container"},[(!_vm.drawerOpen)?_c('div',{staticClass:"open-tab",on:{"click":_vm.toggleDrawer}},[_c('i',{staticClass:"el-icon-arrow-left"})]):_vm._e(),_c('el-drawer',{staticClass:"side-bar",attrs:{"custom-class":"my-drawer","visible":_vm.drawerOpen,"appendToBody":false,"modal-append-to-body":false,"size":"550","with-header":false,"wrapperClosable":false,"modal":false},on:{"update:visible":function($event){_vm.drawerOpen=$event}}},[_c('div',{staticClass:"box-card"},[(_vm.drawerOpen)?_c('div',{staticClass:"close-tab",on:{"click":_vm.close}},[_c('i',{staticClass:"el-icon-arrow-right"})]):_vm._e(),_c('div',{staticClass:"sidebar-container"},[(_vm.tabs.length > 1)?_c('tabs',{attrs:{"tabTitles":_vm.tabs,"activeId":_vm.activeId},on:{"titleClicked":_vm.tabClicked}}):_vm._e(),_vm._l((_vm.tabs),function(tab){return [_c('sidebar-content',{directives:[{name:"show",rawName:"v-show",value:(tab.id===_vm.activeId),expression:"tab.id===activeId"}],key:tab.id,ref:tab.id,refInFor:true,staticClass:"sidebar-content-container",attrs:{"contextCardEntry":tab.contextCard,"
|
|
701
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"52eab1bf-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!./src/components/SideBar.vue?vue&type=template&id=3d831a8e&scoped=true&
|
|
702
|
+
var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{ref:"container"},[(!_vm.drawerOpen)?_c('div',{staticClass:"open-tab",on:{"click":_vm.toggleDrawer}},[_c('i',{staticClass:"el-icon-arrow-left"})]):_vm._e(),_c('el-drawer',{staticClass:"side-bar",attrs:{"custom-class":"my-drawer","visible":_vm.drawerOpen,"appendToBody":false,"modal-append-to-body":false,"size":"550","with-header":false,"wrapperClosable":false,"modal":false},on:{"update:visible":function($event){_vm.drawerOpen=$event}}},[_c('div',{staticClass:"box-card"},[(_vm.drawerOpen)?_c('div',{staticClass:"close-tab",on:{"click":_vm.close}},[_c('i',{staticClass:"el-icon-arrow-right"})]):_vm._e(),_c('div',{staticClass:"sidebar-container"},[(_vm.tabs.length > 1)?_c('tabs',{attrs:{"tabTitles":_vm.tabs,"activeId":_vm.activeId},on:{"titleClicked":_vm.tabClicked}}):_vm._e(),_vm._l((_vm.tabs),function(tab){return [_c('sidebar-content',{directives:[{name:"show",rawName:"v-show",value:(tab.id===_vm.activeId),expression:"tab.id===activeId"}],key:tab.id,ref:tab.id,refInFor:true,staticClass:"sidebar-content-container",attrs:{"contextCardEntry":tab.contextCard,"envVars":_vm.envVars},on:{"search-changed":function($event){return _vm.searchChanged(tab.id, $event)}}})]})],2)])])],1)}
|
|
647
703
|
var staticRenderFns = []
|
|
648
704
|
|
|
649
705
|
|
|
650
|
-
// CONCATENATED MODULE: ./src/components/SideBar.vue?vue&type=template&id=
|
|
706
|
+
// CONCATENATED MODULE: ./src/components/SideBar.vue?vue&type=template&id=3d831a8e&scoped=true&
|
|
651
707
|
|
|
652
708
|
// EXTERNAL MODULE: external "core-js/modules/es.symbol"
|
|
653
709
|
var es_symbol_ = __webpack_require__("6049");
|
|
@@ -717,12 +773,12 @@ var en_default = /*#__PURE__*/__webpack_require__.n(en_);
|
|
|
717
773
|
var locale_ = __webpack_require__("7f9f");
|
|
718
774
|
var locale_default = /*#__PURE__*/__webpack_require__.n(locale_);
|
|
719
775
|
|
|
720
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
721
|
-
var
|
|
722
|
-
var
|
|
776
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"52eab1bf-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!./src/components/SidebarContent.vue?vue&type=template&id=2e1db9a4&scoped=true&
|
|
777
|
+
var SidebarContentvue_type_template_id_2e1db9a4_scoped_true_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('el-card',{staticClass:"content-card",attrs:{"body-style":_vm.bodyStyle}},[_c('div',{staticClass:"header",attrs:{"slot":"header"},slot:"header"},[(_vm.contextCardEntry)?_c('context-card',{attrs:{"entry":_vm.contextCardEntry}}):_vm._e(),_c('el-input',{staticClass:"search-input",attrs:{"placeholder":"Search","clearable":""},on:{"clear":_vm.clearSearchClicked},nativeOn:{"keyup":function($event){return _vm.searchEvent($event)}},model:{value:(_vm.searchInput),callback:function ($$v) {_vm.searchInput=$$v},expression:"searchInput"}}),_c('el-button',{staticClass:"button",on:{"click":_vm.searchEvent}},[_vm._v("Search")])],1),_c('SearchFilters',{ref:"filtersRef",staticClass:"filters",attrs:{"entry":_vm.filterEntry,"envVars":_vm.envVars},on:{"filterResults":_vm.filterUpdate,"numberPerPage":_vm.numberPerPageUpdate,"loading":_vm.filtersLoading}}),_c('div',{directives:[{name:"loading",rawName:"v-loading",value:(_vm.loadingCards),expression:"loadingCards"}],ref:"content",staticClass:"content scrollbar"},[(_vm.results.length === 0 && !_vm.loadingCards && !_vm.sciCrunchError)?_c('div',{staticClass:"error-feedback"},[_vm._v("No results found - Please change your search / filter criteria.")]):_vm._e(),(_vm.sciCrunchError)?_c('div',{staticClass:"error-feedback"},[_vm._v(_vm._s(_vm.sciCrunchError))]):_vm._e(),_vm._l((_vm.results),function(o){return _c('div',{key:o.id,staticClass:"step-item"},[_c('DatasetCard',{attrs:{"entry":o,"envVars":_vm.envVars}})],1)}),_c('el-pagination',{staticClass:"pagination",attrs:{"current-page":_vm.page,"hide-on-single-page":"","large":"","layout":"prev, pager, next","page-size":_vm.numberPerPage,"total":_vm.numberOfHits},on:{"update:currentPage":function($event){_vm.page=$event},"update:current-page":function($event){_vm.page=$event},"current-change":_vm.pageChange}})],2)],1)}
|
|
778
|
+
var SidebarContentvue_type_template_id_2e1db9a4_scoped_true_staticRenderFns = []
|
|
723
779
|
|
|
724
780
|
|
|
725
|
-
// CONCATENATED MODULE: ./src/components/SidebarContent.vue?vue&type=template&id=
|
|
781
|
+
// CONCATENATED MODULE: ./src/components/SidebarContent.vue?vue&type=template&id=2e1db9a4&scoped=true&
|
|
726
782
|
|
|
727
783
|
// EXTERNAL MODULE: external "core-js/modules/es.symbol.description"
|
|
728
784
|
var es_symbol_description_ = __webpack_require__("51e9");
|
|
@@ -736,12 +792,12 @@ var es_array_map_ = __webpack_require__("f705");
|
|
|
736
792
|
// EXTERNAL MODULE: external "core-js/modules/es.function.name"
|
|
737
793
|
var es_function_name_ = __webpack_require__("bcd8");
|
|
738
794
|
|
|
739
|
-
// EXTERNAL MODULE: external "core-js/modules/es.object.entries"
|
|
740
|
-
var es_object_entries_ = __webpack_require__("ece9");
|
|
741
|
-
|
|
742
795
|
// EXTERNAL MODULE: external "core-js/modules/es.object.to-string"
|
|
743
796
|
var es_object_to_string_ = __webpack_require__("850c");
|
|
744
797
|
|
|
798
|
+
// EXTERNAL MODULE: external "core-js/modules/es.parse-int"
|
|
799
|
+
var es_parse_int_ = __webpack_require__("0b28");
|
|
800
|
+
|
|
745
801
|
// EXTERNAL MODULE: external "core-js/modules/es.promise"
|
|
746
802
|
var es_promise_ = __webpack_require__("8495");
|
|
747
803
|
|
|
@@ -757,6 +813,9 @@ var es_set_ = __webpack_require__("47ff");
|
|
|
757
813
|
// EXTERNAL MODULE: external "core-js/modules/es.string.iterator"
|
|
758
814
|
var es_string_iterator_ = __webpack_require__("907b");
|
|
759
815
|
|
|
816
|
+
// EXTERNAL MODULE: external "core-js/modules/es.string.search"
|
|
817
|
+
var es_string_search_ = __webpack_require__("be6e");
|
|
818
|
+
|
|
760
819
|
// EXTERNAL MODULE: external "core-js/modules/es.string.split"
|
|
761
820
|
var es_string_split_ = __webpack_require__("46fa");
|
|
762
821
|
|
|
@@ -883,12 +942,12 @@ var button_css_ = __webpack_require__("26bc");
|
|
|
883
942
|
var button_ = __webpack_require__("5d8c");
|
|
884
943
|
var button_default = /*#__PURE__*/__webpack_require__.n(button_);
|
|
885
944
|
|
|
886
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
887
|
-
var
|
|
888
|
-
var
|
|
945
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"52eab1bf-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!./src/components/SearchFilters.vue?vue&type=template&id=d4e05720&scoped=true&
|
|
946
|
+
var SearchFiltersvue_type_template_id_d4e05720_scoped_true_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"filters"},[_c('SvgSpriteColor'),_c('transition',{attrs:{"name":"el-zoom-in-top"}},[_c('span',{directives:[{name:"show",rawName:"v-show",value:(_vm.showFilters),expression:"showFilters"}],staticClass:"search-filters transition-box"},[_c('custom-cascader',{ref:"cascader",staticClass:"cascader",attrs:{"placeholder":"","collapse-tags":true,"options":_vm.options,"props":_vm.props,"show-all-levels":false,"append-to-body":false},on:{"change":function($event){return _vm.cascadeEvent($event)},"expand-change":_vm.cascadeExpandChange,"tags-changed":_vm.tagsChangedCallback},model:{value:(_vm.cascadeSelected),callback:function ($$v) {_vm.cascadeSelected=$$v},expression:"cascadeSelected"}}),(_vm.showFiltersText)?_c('div',{staticClass:"filter-default-value"},[_c('svg-icon',{staticClass:"filter-icon-inside",attrs:{"icon":"noun-filter"}}),_vm._v("Apply Filters ")],1):_vm._e()],1)]),_c('el-select',{staticClass:"number-shown-select",attrs:{"placeholder":"10"},on:{"change":function($event){return _vm.numberShownChanged($event)}},model:{value:(_vm.numberShown),callback:function ($$v) {_vm.numberShown=$$v},expression:"numberShown"}},_vm._l((_vm.numberDatasetsShown),function(item){return _c('el-option',{key:item,attrs:{"label":item,"value":item}})}),1),_c('span',{staticClass:"dataset-results-feedback"},[_vm._v(_vm._s(this.numberOfResultsText))])],1)}
|
|
947
|
+
var SearchFiltersvue_type_template_id_d4e05720_scoped_true_staticRenderFns = []
|
|
889
948
|
|
|
890
949
|
|
|
891
|
-
// CONCATENATED MODULE: ./src/components/SearchFilters.vue?vue&type=template&id=
|
|
950
|
+
// CONCATENATED MODULE: ./src/components/SearchFilters.vue?vue&type=template&id=d4e05720&scoped=true&
|
|
892
951
|
|
|
893
952
|
// EXTERNAL MODULE: external "core-js/modules/es.array.includes"
|
|
894
953
|
var es_array_includes_ = __webpack_require__("ab7e");
|
|
@@ -902,8 +961,8 @@ var es_array_sort_ = __webpack_require__("6ed7");
|
|
|
902
961
|
// EXTERNAL MODULE: external "core-js/modules/es.array.splice"
|
|
903
962
|
var es_array_splice_ = __webpack_require__("7c81");
|
|
904
963
|
|
|
905
|
-
// EXTERNAL MODULE: external "core-js/modules/es.
|
|
906
|
-
var
|
|
964
|
+
// EXTERNAL MODULE: external "core-js/modules/es.promise.finally"
|
|
965
|
+
var es_promise_finally_ = __webpack_require__("f96d");
|
|
907
966
|
|
|
908
967
|
// EXTERNAL MODULE: external "core-js/modules/es.string.includes"
|
|
909
968
|
var es_string_includes_ = __webpack_require__("fd48");
|
|
@@ -1143,10 +1202,259 @@ var component = normalizeComponent(
|
|
|
1143
1202
|
// EXTERNAL MODULE: external "@abi-software/svg-sprite"
|
|
1144
1203
|
var svg_sprite_ = __webpack_require__("429c");
|
|
1145
1204
|
|
|
1146
|
-
//
|
|
1205
|
+
// EXTERNAL MODULE: external "core-js/modules/es.array.concat"
|
|
1206
|
+
var es_array_concat_ = __webpack_require__("18d2");
|
|
1207
|
+
|
|
1208
|
+
// EXTERNAL MODULE: external "core-js/modules/es.array.flat"
|
|
1209
|
+
var es_array_flat_ = __webpack_require__("9a3c");
|
|
1210
|
+
|
|
1211
|
+
// EXTERNAL MODULE: external "core-js/modules/es.array.unscopables.flat"
|
|
1212
|
+
var es_array_unscopables_flat_ = __webpack_require__("ee85");
|
|
1213
|
+
|
|
1214
|
+
// EXTERNAL MODULE: external "core-js/modules/es.map"
|
|
1215
|
+
var es_map_ = __webpack_require__("9861");
|
|
1216
|
+
|
|
1217
|
+
// EXTERNAL MODULE: external "core-js/modules/es.object.entries"
|
|
1218
|
+
var es_object_entries_ = __webpack_require__("ece9");
|
|
1219
|
+
|
|
1220
|
+
// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/classCallCheck.js
|
|
1221
|
+
function _classCallCheck(instance, Constructor) {
|
|
1222
|
+
if (!(instance instanceof Constructor)) {
|
|
1223
|
+
throw new TypeError("Cannot call a class as a function");
|
|
1224
|
+
}
|
|
1225
|
+
}
|
|
1226
|
+
// CONCATENATED MODULE: ./node_modules/@babel/runtime/helpers/esm/createClass.js
|
|
1227
|
+
function _defineProperties(target, props) {
|
|
1228
|
+
for (var i = 0; i < props.length; i++) {
|
|
1229
|
+
var descriptor = props[i];
|
|
1230
|
+
descriptor.enumerable = descriptor.enumerable || false;
|
|
1231
|
+
descriptor.configurable = true;
|
|
1232
|
+
if ("value" in descriptor) descriptor.writable = true;
|
|
1233
|
+
Object.defineProperty(target, descriptor.key, descriptor);
|
|
1234
|
+
}
|
|
1235
|
+
}
|
|
1236
|
+
|
|
1237
|
+
function _createClass(Constructor, protoProps, staticProps) {
|
|
1238
|
+
if (protoProps) _defineProperties(Constructor.prototype, protoProps);
|
|
1239
|
+
if (staticProps) _defineProperties(Constructor, staticProps);
|
|
1240
|
+
return Constructor;
|
|
1241
|
+
}
|
|
1242
|
+
// EXTERNAL MODULE: external "algoliasearch"
|
|
1243
|
+
var external_algoliasearch_ = __webpack_require__("88eb");
|
|
1244
|
+
var external_algoliasearch_default = /*#__PURE__*/__webpack_require__.n(external_algoliasearch_);
|
|
1245
|
+
|
|
1246
|
+
// CONCATENATED MODULE: ./src/algolia/algolia.js
|
|
1247
|
+
|
|
1248
|
+
|
|
1249
|
+
|
|
1250
|
+
|
|
1251
|
+
|
|
1252
|
+
|
|
1253
|
+
|
|
1254
|
+
|
|
1255
|
+
|
|
1256
|
+
|
|
1257
|
+
|
|
1258
|
+
|
|
1259
|
+
|
|
1260
|
+
|
|
1261
|
+
|
|
1262
|
+
|
|
1263
|
+
|
|
1264
|
+
|
|
1265
|
+
/* eslint-disable no-alert, no-console */
|
|
1266
|
+
// export `createAlgoliaClient` to use it in page components
|
|
1267
|
+
|
|
1268
|
+
var algolia_AlgoliaClient =
|
|
1269
|
+
/*#__PURE__*/
|
|
1270
|
+
function () {
|
|
1271
|
+
function AlgoliaClient(algoliaId, algoliaKey) {
|
|
1272
|
+
var PENNSIEVE_API_LOCATION = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'https://api.pennsieve.io';
|
|
1273
|
+
|
|
1274
|
+
_classCallCheck(this, AlgoliaClient);
|
|
1275
|
+
|
|
1276
|
+
this.client = external_algoliasearch_default()(algoliaId, algoliaKey);
|
|
1277
|
+
this.PENNSIEVE_API_LOCATION = PENNSIEVE_API_LOCATION;
|
|
1278
|
+
}
|
|
1279
|
+
|
|
1280
|
+
_createClass(AlgoliaClient, [{
|
|
1281
|
+
key: "initIndex",
|
|
1282
|
+
value: function initIndex(ALGOLIA_INDEX) {
|
|
1283
|
+
this.index = this.client.initIndex(ALGOLIA_INDEX);
|
|
1284
|
+
}
|
|
1285
|
+
}, {
|
|
1286
|
+
key: "getAlgoliaFacets",
|
|
1287
|
+
value: function getAlgoliaFacets(propPathMapping) {
|
|
1288
|
+
var map = new Map(Object.entries(propPathMapping));
|
|
1289
|
+
var facetPropPaths = Array.from(map.keys());
|
|
1290
|
+
var facetData = [];
|
|
1291
|
+
var facetId = 0;
|
|
1292
|
+
return this.index.search('', {
|
|
1293
|
+
sortFacetValuesBy: 'alpha',
|
|
1294
|
+
facets: facetPropPaths
|
|
1295
|
+
}).then(function (response) {
|
|
1296
|
+
facetPropPaths.map(function (facetPropPath) {
|
|
1297
|
+
var children = [];
|
|
1298
|
+
var responseFacets = response.facets;
|
|
1299
|
+
|
|
1300
|
+
if (responseFacets === undefined) {
|
|
1301
|
+
return;
|
|
1302
|
+
}
|
|
1303
|
+
|
|
1304
|
+
var responseFacetChildren = responseFacets[facetPropPath] == undefined ? {} : responseFacets[facetPropPath];
|
|
1305
|
+
Object.keys(responseFacetChildren).map(function (facet) {
|
|
1306
|
+
children.push({
|
|
1307
|
+
label: facet,
|
|
1308
|
+
id: facetId++,
|
|
1309
|
+
facetPropPath: facetPropPath
|
|
1310
|
+
});
|
|
1311
|
+
});
|
|
1312
|
+
|
|
1313
|
+
if (children.length > 0) {
|
|
1314
|
+
facetData.push({
|
|
1315
|
+
label: map.get(facetPropPath),
|
|
1316
|
+
id: facetId++,
|
|
1317
|
+
children: children,
|
|
1318
|
+
key: facetPropPath
|
|
1319
|
+
});
|
|
1320
|
+
}
|
|
1321
|
+
});
|
|
1322
|
+
return facetData;
|
|
1323
|
+
});
|
|
1324
|
+
} // Returns all DOIs of all versions for a given discover dataset
|
|
1325
|
+
|
|
1326
|
+
}, {
|
|
1327
|
+
key: "_discoverAllDois",
|
|
1328
|
+
value: function _discoverAllDois(discoverId) {
|
|
1329
|
+
var PENNSIEVE_API_LOCATION = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'https://api.pennsieve.io';
|
|
1330
|
+
return new Promise(function (resolve) {
|
|
1331
|
+
fetch("".concat(PENNSIEVE_API_LOCATION, "/discover/datasets/").concat(discoverId, "/versions")).then(function (r) {
|
|
1332
|
+
return r.json();
|
|
1333
|
+
}).then(function (dataset) {
|
|
1334
|
+
resolve(dataset.map(function (version) {
|
|
1335
|
+
return version.doi;
|
|
1336
|
+
}));
|
|
1337
|
+
});
|
|
1338
|
+
});
|
|
1339
|
+
} // Get all dois given a list of discoverIds
|
|
1340
|
+
|
|
1341
|
+
}, {
|
|
1342
|
+
key: "_expandDois",
|
|
1343
|
+
value: function _expandDois(discoverIds) {
|
|
1344
|
+
var _this = this;
|
|
1345
|
+
|
|
1346
|
+
var PENNSIEVE_API_LOCATION = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'https://api.pennsieve.io';
|
|
1347
|
+
return new Promise(function (resolve) {
|
|
1348
|
+
var promiseList = discoverIds.map(function (discoverId) {
|
|
1349
|
+
return _this._discoverAllDois(discoverId, PENNSIEVE_API_LOCATION);
|
|
1350
|
+
});
|
|
1351
|
+
Promise.all(promiseList).then(function (values) {
|
|
1352
|
+
resolve(values.flat());
|
|
1353
|
+
});
|
|
1354
|
+
});
|
|
1355
|
+
}
|
|
1356
|
+
/**
|
|
1357
|
+
* Get Search results
|
|
1358
|
+
* This is using fetch from the Algolia API
|
|
1359
|
+
*/
|
|
1360
|
+
|
|
1361
|
+
}, {
|
|
1362
|
+
key: "search",
|
|
1363
|
+
value: function search(filter) {
|
|
1364
|
+
var _this2 = this;
|
|
1365
|
+
|
|
1366
|
+
var query = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';
|
|
1367
|
+
var hitsperPage = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 10;
|
|
1368
|
+
var page = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 1;
|
|
1369
|
+
return new Promise(function (resolve) {
|
|
1370
|
+
_this2.index.search(query, {
|
|
1371
|
+
facets: ['*'],
|
|
1372
|
+
hitsPerPage: hitsperPage,
|
|
1373
|
+
page: page - 1,
|
|
1374
|
+
filters: filter
|
|
1375
|
+
}).then(function (response) {
|
|
1376
|
+
var searchData = {
|
|
1377
|
+
items: response.hits,
|
|
1378
|
+
total: response.nbHits,
|
|
1379
|
+
discoverIds: response.hits.map(function (r) {
|
|
1380
|
+
return r.pennsieve.identifier;
|
|
1381
|
+
})
|
|
1382
|
+
};
|
|
1383
|
+
resolve(searchData);
|
|
1384
|
+
});
|
|
1385
|
+
});
|
|
1386
|
+
}
|
|
1387
|
+
}]);
|
|
1388
|
+
|
|
1389
|
+
return AlgoliaClient;
|
|
1390
|
+
}();
|
|
1391
|
+
// EXTERNAL MODULE: external "core-js/modules/es.array.last-index-of"
|
|
1392
|
+
var es_array_last_index_of_ = __webpack_require__("dc05");
|
|
1393
|
+
|
|
1394
|
+
// CONCATENATED MODULE: ./src/algolia/utils.js
|
|
1395
|
+
|
|
1396
|
+
|
|
1397
|
+
|
|
1398
|
+
|
|
1399
|
+
|
|
1400
|
+
|
|
1401
|
+
|
|
1402
|
+
|
|
1403
|
+
/* eslint-disable no-alert, no-console */
|
|
1404
|
+
// Mapping between display categories and their Algolia index property path
|
|
1405
|
+
// Used for populating the Dataset Search Results facet menu dynamically
|
|
1406
|
+
var facetPropPathMapping = {
|
|
1407
|
+
'anatomy.organ.name': 'Anatomical Structure',
|
|
1408
|
+
'organisms.primary.species.name': 'Species',
|
|
1409
|
+
'item.modalities.keyword': 'Experimental Approach',
|
|
1410
|
+
'attributes.subject.sex.value': 'Sex',
|
|
1411
|
+
'attributes.subject.ageCategory.value': 'Age Categories'
|
|
1412
|
+
};
|
|
1413
|
+
/* Returns filter for searching algolia. All facets of the same category are joined with OR,
|
|
1414
|
+
* and each of those results is then joined with an AND.
|
|
1415
|
+
* i.e. (color:blue OR color:red) AND (shape:circle OR shape:red) */
|
|
1416
|
+
|
|
1417
|
+
function getFilters() {
|
|
1418
|
+
var selectedFacetArray = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : undefined;
|
|
1419
|
+
|
|
1420
|
+
// return all datasets if no filter
|
|
1421
|
+
if (selectedFacetArray === undefined) {
|
|
1422
|
+
return 'NOT item.published.status:embargo';
|
|
1423
|
+
} // Switch the 'term' attribute to 'label' if 'label' does not exist
|
|
1424
|
+
|
|
1425
|
+
|
|
1426
|
+
selectedFacetArray.forEach(function (f) {
|
|
1427
|
+
return f.label = f.facet;
|
|
1428
|
+
});
|
|
1429
|
+
var facets = removeShowAllFacets(selectedFacetArray);
|
|
1430
|
+
var filters = "NOT item.published.status:embargo";
|
|
1431
|
+
filters = "(".concat(filters, ") AND ");
|
|
1432
|
+
var facetPropPaths = Object.keys(facetPropPathMapping);
|
|
1433
|
+
facetPropPaths.map(function (facetPropPath) {
|
|
1434
|
+
var facetsToOr = facets.filter(function (facet) {
|
|
1435
|
+
return facet.facetPropPath == facetPropPath;
|
|
1436
|
+
});
|
|
1437
|
+
var filter = "";
|
|
1438
|
+
facetsToOr.map(function (facet) {
|
|
1439
|
+
filter += "\"".concat(facetPropPath, "\":\"").concat(facet.label, "\" OR ");
|
|
1440
|
+
});
|
|
1147
1441
|
|
|
1442
|
+
if (filter == "") {
|
|
1443
|
+
return;
|
|
1444
|
+
}
|
|
1148
1445
|
|
|
1446
|
+
filter = "(".concat(filter.substring(0, filter.lastIndexOf(" OR ")), ")");
|
|
1447
|
+
filters += "".concat(filter, " AND ");
|
|
1448
|
+
});
|
|
1449
|
+
return filters.substring(0, filters.lastIndexOf(" AND "));
|
|
1450
|
+
}
|
|
1149
1451
|
|
|
1452
|
+
function removeShowAllFacets(facetArray) {
|
|
1453
|
+
return facetArray.filter(function (f) {
|
|
1454
|
+
return f.label !== 'Show all';
|
|
1455
|
+
});
|
|
1456
|
+
}
|
|
1457
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js??ref--12-0!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/SearchFilters.vue?vue&type=script&lang=js&
|
|
1150
1458
|
|
|
1151
1459
|
|
|
1152
1460
|
|
|
@@ -1168,6 +1476,13 @@ var svg_sprite_ = __webpack_require__("429c");
|
|
|
1168
1476
|
|
|
1169
1477
|
|
|
1170
1478
|
|
|
1479
|
+
|
|
1480
|
+
//
|
|
1481
|
+
//
|
|
1482
|
+
//
|
|
1483
|
+
//
|
|
1484
|
+
//
|
|
1485
|
+
//
|
|
1171
1486
|
//
|
|
1172
1487
|
//
|
|
1173
1488
|
//
|
|
@@ -1214,6 +1529,8 @@ var svg_sprite_ = __webpack_require__("429c");
|
|
|
1214
1529
|
|
|
1215
1530
|
|
|
1216
1531
|
|
|
1532
|
+
|
|
1533
|
+
|
|
1217
1534
|
external_vue_default.a.component("svg-icon", svg_sprite_["SvgIcon"]);
|
|
1218
1535
|
locale_default.a.use(en_default.a);
|
|
1219
1536
|
external_vue_default.a.use(option_default.a);
|
|
@@ -1245,9 +1562,9 @@ var SearchFiltersvue_type_script_lang_js_convertReadableLabel = function convert
|
|
|
1245
1562
|
* the required viewing.
|
|
1246
1563
|
*/
|
|
1247
1564
|
entry: Object,
|
|
1248
|
-
|
|
1249
|
-
type:
|
|
1250
|
-
default:
|
|
1565
|
+
envVars: {
|
|
1566
|
+
type: Object,
|
|
1567
|
+
default: function _default() {}
|
|
1251
1568
|
}
|
|
1252
1569
|
},
|
|
1253
1570
|
data: function data() {
|
|
@@ -1289,65 +1606,31 @@ var SearchFiltersvue_type_script_lang_js_convertReadableLabel = function convert
|
|
|
1289
1606
|
var _this = this;
|
|
1290
1607
|
|
|
1291
1608
|
return new Promise(function (resolve) {
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
_this.options.push({
|
|
1297
|
-
value: _this.createCascaderItemValue(_this.facets[i].toLowerCase(), undefined),
|
|
1298
|
-
label: SearchFiltersvue_type_script_lang_js_convertReadableLabel(_this.facets[i]),
|
|
1299
|
-
children: []
|
|
1300
|
-
});
|
|
1301
|
-
|
|
1302
|
-
promiseList.push(_this.getFacet(_this.facets[i]).then(function (labels) {
|
|
1303
|
-
// Populate children of each facet with scicrunch's facets
|
|
1304
|
-
for (var j in labels) {
|
|
1305
|
-
_this.options[i].children.push({
|
|
1306
|
-
value: _this.createCascaderItemValue(_this.facets[i].toLowerCase(), labels[j].toLowerCase()),
|
|
1307
|
-
label: SearchFiltersvue_type_script_lang_js_convertReadableLabel(labels[j]) // Capitalisation is to match design specs
|
|
1308
|
-
|
|
1309
|
-
});
|
|
1310
|
-
}
|
|
1311
|
-
}));
|
|
1312
|
-
};
|
|
1609
|
+
// Algolia facet serach
|
|
1610
|
+
_this.algoliaClient.getAlgoliaFacets(facetPropPathMapping).then(function (data) {
|
|
1611
|
+
_this.facets = data;
|
|
1612
|
+
_this.options = data; // create top level of options in cascader
|
|
1313
1613
|
|
|
1314
|
-
|
|
1315
|
-
|
|
1316
|
-
|
|
1614
|
+
_this.options.forEach(function (facet, i) {
|
|
1615
|
+
_this.options[i].label = SearchFiltersvue_type_script_lang_js_convertReadableLabel(facet.label);
|
|
1616
|
+
_this.options[i].value = _this.createCascaderItemValue(facet.key, undefined); // put "Show all" as first option
|
|
1317
1617
|
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
},
|
|
1323
|
-
getFacet: function getFacet(facetLabel) {
|
|
1324
|
-
var _this2 = this;
|
|
1618
|
+
_this.options[i].children.unshift({
|
|
1619
|
+
value: _this.createCascaderItemValue("Show all"),
|
|
1620
|
+
label: "Show all"
|
|
1621
|
+
}); // populate second level of options
|
|
1325
1622
|
|
|
1326
|
-
if (facetLabel === "Datasets") {
|
|
1327
|
-
// The datasets facet doesn't exist on SciCrunch yet, so manually set it
|
|
1328
|
-
// for now.
|
|
1329
|
-
return new Promise(function (resolve) {
|
|
1330
|
-
resolve(_toConsumableArray(new Set(["Show all", "Scaffolds", "Simulations"])));
|
|
1331
|
-
});
|
|
1332
|
-
}
|
|
1333
1623
|
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
_this2.callSciCrunch(_this2.apiLocation, _this2.facetEndpoint, facet).then(function (facet_terms) {
|
|
1340
|
-
facet_terms.forEach(function (element) {
|
|
1341
|
-
facets.push(element["key"]); // add facets that scicrunch includes
|
|
1624
|
+
_this.options[i].children.forEach(function (facetItem, j) {
|
|
1625
|
+
_this.options[i].children[j].label = SearchFiltersvue_type_script_lang_js_convertReadableLabel(facetItem.label);
|
|
1626
|
+
_this.options[i].children[j].value = _this.createCascaderItemValue(facet.label, facetItem.label);
|
|
1627
|
+
});
|
|
1342
1628
|
});
|
|
1343
|
-
|
|
1629
|
+
}).finally(function () {
|
|
1630
|
+
resolve();
|
|
1344
1631
|
});
|
|
1345
1632
|
});
|
|
1346
1633
|
},
|
|
1347
|
-
// switchTermToRequest is used to remove the count for sending a request to scicrunch
|
|
1348
|
-
switchTermToRequest: function switchTermToRequest(term) {
|
|
1349
|
-
return term.split(" ")[0].toLowerCase();
|
|
1350
|
-
},
|
|
1351
1634
|
tagsChangedCallback: function tagsChangedCallback(presentTags) {
|
|
1352
1635
|
if (presentTags.length > 0) {
|
|
1353
1636
|
this.showFiltersText = false;
|
|
@@ -1355,32 +1638,34 @@ var SearchFiltersvue_type_script_lang_js_convertReadableLabel = function convert
|
|
|
1355
1638
|
this.showFiltersText = true;
|
|
1356
1639
|
}
|
|
1357
1640
|
},
|
|
1641
|
+
// cascadeEvent: initiate searches based off cascader changes
|
|
1358
1642
|
cascadeEvent: function cascadeEvent(event) {
|
|
1359
|
-
var filters = [];
|
|
1360
|
-
|
|
1361
1643
|
if (event) {
|
|
1362
1644
|
// Check for show all in selected cascade options
|
|
1363
|
-
event = this.showAllEventModifier(event);
|
|
1645
|
+
event = this.showAllEventModifier(event); // Move results from arrays to object
|
|
1646
|
+
|
|
1647
|
+
var filters = event.filter(function (selection) {
|
|
1648
|
+
return selection !== undefined;
|
|
1649
|
+
}).map(function (fs) {
|
|
1650
|
+
return {
|
|
1651
|
+
facetPropPath: fs[0],
|
|
1652
|
+
facet: fs[1].split("/")[1],
|
|
1653
|
+
term: fs[1].split("/")[0]
|
|
1654
|
+
};
|
|
1655
|
+
});
|
|
1656
|
+
this.$emit('loading', true); // let sidebarcontent wait for the requests
|
|
1364
1657
|
|
|
1365
|
-
|
|
1366
|
-
if (event[i] !== undefined) {
|
|
1367
|
-
var value = event[i][1];
|
|
1368
|
-
var data = value.split("/");
|
|
1369
|
-
var output = {};
|
|
1370
|
-
output.term = this.switchTermToRequest(data[0]);
|
|
1371
|
-
output.facet = data[1];
|
|
1372
|
-
filters.push(output);
|
|
1373
|
-
}
|
|
1374
|
-
}
|
|
1375
|
-
}
|
|
1658
|
+
this.$emit("filterResults", filters); // emit filters for apps above sidebar
|
|
1376
1659
|
|
|
1377
|
-
|
|
1378
|
-
this.setCascader(filters); //update our cascader v-model if we modified the event
|
|
1660
|
+
this.setCascader(filters); //update our cascader v-model if we modified the event
|
|
1379
1661
|
|
|
1380
|
-
|
|
1662
|
+
this.makeCascadeLabelsClickable();
|
|
1663
|
+
}
|
|
1381
1664
|
},
|
|
1665
|
+
// showAllEventModifier: Modifies a cascade event to unlick all selections in category if "show all" is clicked. Also unchecks "Show all" if any secection is clicked
|
|
1666
|
+
// *NOTE* Does NOT remove 'Show all' selections from showing in 'cascadeSelected'
|
|
1382
1667
|
showAllEventModifier: function showAllEventModifier(event) {
|
|
1383
|
-
var
|
|
1668
|
+
var _this2 = this;
|
|
1384
1669
|
|
|
1385
1670
|
// check if show all is in the cascader checked option list
|
|
1386
1671
|
var hasShowAll = event.map(function (ev) {
|
|
@@ -1424,15 +1709,15 @@ var SearchFiltersvue_type_script_lang_js_convertReadableLabel = function convert
|
|
|
1424
1709
|
|
|
1425
1710
|
|
|
1426
1711
|
return modifiedEvent.sort(function (a, b) {
|
|
1427
|
-
if (
|
|
1428
|
-
if (a[0] ==
|
|
1429
|
-
if (b[0] ==
|
|
1712
|
+
if (_this2.__expandItem__) {
|
|
1713
|
+
if (a[0] == _this2.__expandItem__) {
|
|
1714
|
+
if (b[0] == _this2.__expandItem__) {
|
|
1430
1715
|
return 0;
|
|
1431
1716
|
} else {
|
|
1432
1717
|
return -1;
|
|
1433
1718
|
}
|
|
1434
|
-
} else if (b[0] ==
|
|
1435
|
-
if (a[0] ==
|
|
1719
|
+
} else if (b[0] == _this2.__expandItem__) {
|
|
1720
|
+
if (a[0] == _this2.__expandItem__) {
|
|
1436
1721
|
return 0;
|
|
1437
1722
|
} else {
|
|
1438
1723
|
return 1;
|
|
@@ -1454,17 +1739,8 @@ var SearchFiltersvue_type_script_lang_js_convertReadableLabel = function convert
|
|
|
1454
1739
|
numberShownChanged: function numberShownChanged(event) {
|
|
1455
1740
|
this.$emit("numberPerPage", parseInt(event));
|
|
1456
1741
|
},
|
|
1457
|
-
callSciCrunch: function callSciCrunch(apiLocation, endpoint, term) {
|
|
1458
|
-
return new Promise(function (resolve) {
|
|
1459
|
-
fetch(apiLocation + endpoint + term).then(function (response) {
|
|
1460
|
-
return response.json();
|
|
1461
|
-
}).then(function (data) {
|
|
1462
|
-
resolve(data);
|
|
1463
|
-
});
|
|
1464
|
-
});
|
|
1465
|
-
},
|
|
1466
1742
|
updatePreviousShowAllChecked: function updatePreviousShowAllChecked(options) {
|
|
1467
|
-
var
|
|
1743
|
+
var _this3 = this;
|
|
1468
1744
|
|
|
1469
1745
|
//Reset the states
|
|
1470
1746
|
for (var facet in this.previousShowAllChecked) {
|
|
@@ -1472,27 +1748,55 @@ var SearchFiltersvue_type_script_lang_js_convertReadableLabel = function convert
|
|
|
1472
1748
|
}
|
|
1473
1749
|
|
|
1474
1750
|
options.forEach(function (element) {
|
|
1475
|
-
if (element[1].toLowerCase().includes("show all"))
|
|
1751
|
+
if (element[1].toLowerCase().includes("show all")) _this3.previousShowAllChecked[element[0]] = true;
|
|
1476
1752
|
});
|
|
1477
1753
|
},
|
|
1754
|
+
// setCascader: Clears previous selections and takes in an array of facets to select: filterFacets
|
|
1755
|
+
// facets are in the form:
|
|
1756
|
+
// {
|
|
1757
|
+
// facetPropPath: 'anatomy.organ.name',
|
|
1758
|
+
// term: 'Sex',
|
|
1759
|
+
// facet: 'Male'
|
|
1760
|
+
// }
|
|
1478
1761
|
setCascader: function setCascader(filterFacets) {
|
|
1479
|
-
var
|
|
1762
|
+
var _this4 = this;
|
|
1480
1763
|
|
|
1481
1764
|
//Do not set the value unless it is ready
|
|
1482
|
-
if (this.cascaderIsReady) {
|
|
1483
|
-
this.cascadeSelected =
|
|
1484
|
-
|
|
1485
|
-
_this5.cascadeSelected.push([e.term.toLowerCase(), _this5.createCascaderItemValue(e.term.toLowerCase(), e.facet.toLowerCase())]);
|
|
1765
|
+
if (this.cascaderIsReady && filterFacets && filterFacets.length != 0) {
|
|
1766
|
+
this.cascadeSelected = filterFacets.map(function (e) {
|
|
1767
|
+
return [e.facetPropPath, _this4.createCascaderItemValue(capitalise(e.term), e.facet)];
|
|
1486
1768
|
});
|
|
1487
1769
|
this.updatePreviousShowAllChecked(this.cascadeSelected);
|
|
1488
1770
|
}
|
|
1489
1771
|
},
|
|
1772
|
+
addFilter: function addFilter(filter) {
|
|
1773
|
+
//Do not set the value unless it is ready
|
|
1774
|
+
if (this.cascaderIsReady && filter) {
|
|
1775
|
+
this.cascadeSelected.filter(function (f) {
|
|
1776
|
+
return f.term != filter.term;
|
|
1777
|
+
});
|
|
1778
|
+
this.cascadeSelected.push([filter.facetPropPath, this.createCascaderItemValue(filter.term, filter.facet)]);
|
|
1779
|
+
}
|
|
1780
|
+
},
|
|
1781
|
+
initiateSearch: function initiateSearch() {
|
|
1782
|
+
this.cascadeEvent(this.cascadeSelected);
|
|
1783
|
+
},
|
|
1784
|
+
// checkShowAllBoxes: Checks each 'Show all' cascade option by using the setCascader function
|
|
1785
|
+
checkShowAllBoxes: function checkShowAllBoxes() {
|
|
1786
|
+
this.setCascader(this.options.map(function (option) {
|
|
1787
|
+
return {
|
|
1788
|
+
facetPropPath: option.value,
|
|
1789
|
+
term: option.label,
|
|
1790
|
+
facet: 'Show all'
|
|
1791
|
+
};
|
|
1792
|
+
}));
|
|
1793
|
+
},
|
|
1490
1794
|
makeCascadeLabelsClickable: function makeCascadeLabelsClickable() {
|
|
1491
|
-
var
|
|
1795
|
+
var _this5 = this;
|
|
1492
1796
|
|
|
1493
1797
|
// Next tick allows the cascader menu to change
|
|
1494
1798
|
this.$nextTick(function () {
|
|
1495
|
-
|
|
1799
|
+
_this5.$refs.cascader.$el.querySelectorAll(".el-cascader-node__label").forEach(function (el) {
|
|
1496
1800
|
// step through each cascade label
|
|
1497
1801
|
el.onclick = function () {
|
|
1498
1802
|
var checkbox = this.previousElementSibling;
|
|
@@ -1508,26 +1812,26 @@ var SearchFiltersvue_type_script_lang_js_convertReadableLabel = function convert
|
|
|
1508
1812
|
});
|
|
1509
1813
|
}
|
|
1510
1814
|
},
|
|
1511
|
-
created: function created() {
|
|
1512
|
-
//Create non-reactive local variables
|
|
1513
|
-
this.facetEndpoint = "get-facets/";
|
|
1514
|
-
},
|
|
1515
1815
|
mounted: function mounted() {
|
|
1516
|
-
var
|
|
1816
|
+
var _this6 = this;
|
|
1517
1817
|
|
|
1818
|
+
this.algoliaClient = new algolia_AlgoliaClient(this.envVars.ALGOLIA_ID, this.envVars.ALGOLIA_KEY, this.envVars.PENNSIEVE_API_LOCATION);
|
|
1819
|
+
this.algoliaClient.initIndex(this.envVars.ALGOLIA_INDEX);
|
|
1518
1820
|
this.populateCascader().then(function () {
|
|
1519
|
-
|
|
1821
|
+
_this6.cascaderIsReady = true;
|
|
1520
1822
|
|
|
1521
|
-
|
|
1823
|
+
_this6.checkShowAllBoxes();
|
|
1522
1824
|
|
|
1523
|
-
|
|
1825
|
+
_this6.setCascader(_this6.entry.filterFacets);
|
|
1826
|
+
|
|
1827
|
+
_this6.makeCascadeLabelsClickable();
|
|
1524
1828
|
});
|
|
1525
1829
|
}
|
|
1526
1830
|
});
|
|
1527
1831
|
// CONCATENATED MODULE: ./src/components/SearchFilters.vue?vue&type=script&lang=js&
|
|
1528
1832
|
/* harmony default export */ var components_SearchFiltersvue_type_script_lang_js_ = (SearchFiltersvue_type_script_lang_js_);
|
|
1529
|
-
// EXTERNAL MODULE: ./src/components/SearchFilters.vue?vue&type=style&index=0&id=
|
|
1530
|
-
var
|
|
1833
|
+
// EXTERNAL MODULE: ./src/components/SearchFilters.vue?vue&type=style&index=0&id=d4e05720&scoped=true&lang=css&
|
|
1834
|
+
var SearchFiltersvue_type_style_index_0_id_d4e05720_scoped_true_lang_css_ = __webpack_require__("e026");
|
|
1531
1835
|
|
|
1532
1836
|
// CONCATENATED MODULE: ./src/components/SearchFilters.vue
|
|
1533
1837
|
|
|
@@ -1540,25 +1844,22 @@ var SearchFiltersvue_type_style_index_0_id_cf619ba6_scoped_true_lang_css_ = __we
|
|
|
1540
1844
|
|
|
1541
1845
|
var SearchFilters_component = normalizeComponent(
|
|
1542
1846
|
components_SearchFiltersvue_type_script_lang_js_,
|
|
1543
|
-
|
|
1544
|
-
|
|
1847
|
+
SearchFiltersvue_type_template_id_d4e05720_scoped_true_render,
|
|
1848
|
+
SearchFiltersvue_type_template_id_d4e05720_scoped_true_staticRenderFns,
|
|
1545
1849
|
false,
|
|
1546
1850
|
null,
|
|
1547
|
-
"
|
|
1851
|
+
"d4e05720",
|
|
1548
1852
|
null
|
|
1549
1853
|
|
|
1550
1854
|
)
|
|
1551
1855
|
|
|
1552
1856
|
/* harmony default export */ var SearchFilters = (SearchFilters_component.exports);
|
|
1553
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
1554
|
-
var
|
|
1555
|
-
var
|
|
1857
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"52eab1bf-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!./src/components/DatasetCard.vue?vue&type=template&id=eaeba60a&scoped=true&
|
|
1858
|
+
var DatasetCardvue_type_template_id_eaeba60a_scoped_true_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{ref:"container",staticClass:"dataset-card-container"},[_c('div',{ref:"card",class:_vm.expanded ? 'dataset-card-expanded' : 'dataset-card'},[_c('div',{staticClass:"seperator-path"}),_c('div',{staticClass:"card"},[_c('span',{staticClass:"card-left"},[_c('img',{staticClass:"banner-img",attrs:{"svg-inline":"","src":_vm.thumbnail},on:{"click":_vm.openDataset}})]),_c('div',{staticClass:"card-right"},[_c('div',{staticClass:"title",on:{"click":_vm.cardClicked}},[_vm._v(_vm._s(_vm.entry.name))]),_c('div',{staticClass:"details"},[_vm._v(_vm._s(_vm.contributors)+" "+_vm._s(_vm.entry.publishDate ? ("(" + _vm.publishYear + ")") : ''))]),_c('div',{staticClass:"details"},[_vm._v(_vm._s(_vm.samples))]),_c('div',{staticClass:"details"},[_vm._v("id: "+_vm._s(_vm.discoverId))]),_c('div',[(!_vm.entry.simulation)?_c('el-button',{staticClass:"button",attrs:{"size":"mini","icon":"el-icon-coin"},on:{"click":_vm.openDataset}},[_vm._v("View dataset")]):_vm._e()],1),_c('div',[(_vm.entry.scaffolds)?_c('el-button',{staticClass:"button",attrs:{"size":"mini","icon":"el-icon-view"},on:{"click":_vm.openScaffold}},[_vm._v("View scaffold")]):_vm._e()],1),_c('div',[(_vm.hasCSVFile)?_c('el-button',{staticClass:"button",attrs:{"size":"mini","icon":"el-icon-view"},on:{"click":_vm.openPlot}},[_vm._v("View plot")]):_vm._e()],1),_c('div',[(_vm.entry.simulation)?_c('el-button',{staticClass:"button",attrs:{"size":"mini","icon":"el-icon-view"},on:{"click":_vm.openRepository}},[_vm._v("View repository")]):_vm._e()],1),_c('div',[(_vm.entry.simulation)?_c('el-button',{staticClass:"button",attrs:{"size":"mini","icon":"el-icon-view"},on:{"click":_vm.openSimulation}},[_vm._v("View simulation")]):_vm._e()],1),_c('div',[(_vm.entry.segmentation)?_c('el-button',{staticClass:"button",attrs:{"size":"mini","icon":"el-icon-view"},on:{"click":_vm.openSegmentation}},[_vm._v("View segmentation")]):_vm._e()],1),_c('div',[(_vm.biolucidaData)?_c('el-button',{staticClass:"button",attrs:{"size":"mini","icon":"el-icon-view"},on:{"click":_vm.openImage}},[_vm._v("View image")]):_vm._e()],1)])]),((_vm.cardOverflow && !_vm.expanded))?_c('p',{staticClass:"read-more"},[_c('el-button',{staticClass:"read-more-button",on:{"click":_vm.expand}},[_vm._v("Read more...")])],1):_vm._e()])])}
|
|
1859
|
+
var DatasetCardvue_type_template_id_eaeba60a_scoped_true_staticRenderFns = []
|
|
1556
1860
|
|
|
1557
1861
|
|
|
1558
|
-
// CONCATENATED MODULE: ./src/components/DatasetCard.vue?vue&type=template&id=
|
|
1559
|
-
|
|
1560
|
-
// EXTERNAL MODULE: external "core-js/modules/es.array.concat"
|
|
1561
|
-
var es_array_concat_ = __webpack_require__("18d2");
|
|
1862
|
+
// CONCATENATED MODULE: ./src/components/DatasetCard.vue?vue&type=template&id=eaeba60a&scoped=true&
|
|
1562
1863
|
|
|
1563
1864
|
// EXTERNAL MODULE: external "core-js/modules/es.string.replace"
|
|
1564
1865
|
var es_string_replace_ = __webpack_require__("bfab");
|
|
@@ -1691,9 +1992,9 @@ var DatasetCardvue_type_script_lang_js_capitalise = function capitalise(string)
|
|
|
1691
1992
|
* the required viewing.
|
|
1692
1993
|
*/
|
|
1693
1994
|
entry: Object,
|
|
1694
|
-
|
|
1695
|
-
type:
|
|
1696
|
-
default:
|
|
1995
|
+
envVars: {
|
|
1996
|
+
type: Object,
|
|
1997
|
+
default: function _default() {}
|
|
1697
1998
|
}
|
|
1698
1999
|
},
|
|
1699
2000
|
data: function data() {
|
|
@@ -1728,18 +2029,30 @@ var DatasetCardvue_type_script_lang_js_capitalise = function capitalise(string)
|
|
|
1728
2029
|
samples: function samples() {
|
|
1729
2030
|
var text = "";
|
|
1730
2031
|
|
|
1731
|
-
if (this.entry.numberSamples === 1) {
|
|
1732
|
-
text = this.entry.numberSamples + " sample";
|
|
1733
|
-
} else if (this.entry.numberSamples > 1) {
|
|
1734
|
-
text = this.entry.numberSamples + " samples";
|
|
1735
|
-
}
|
|
1736
|
-
|
|
1737
2032
|
if (this.entry.species) {
|
|
1738
2033
|
if (species_map[this.entry.species[0].toLowerCase()]) {
|
|
1739
|
-
text
|
|
2034
|
+
text = "".concat(species_map[this.entry.species[0].toLowerCase()]);
|
|
1740
2035
|
} else {
|
|
1741
|
-
text
|
|
2036
|
+
text = "".concat(this.entry.species);
|
|
2037
|
+
}
|
|
2038
|
+
}
|
|
2039
|
+
|
|
2040
|
+
if (this.entry.numberSamples > 0) {
|
|
2041
|
+
text += " (";
|
|
2042
|
+
|
|
2043
|
+
if (this.entry.numberSamples === 1) {
|
|
2044
|
+
text += "".concat(this.entry.numberSamples, " sample");
|
|
2045
|
+
} else if (this.entry.numberSamples > 1) {
|
|
2046
|
+
text += "".concat(this.entry.numberSamples, " samples");
|
|
2047
|
+
}
|
|
2048
|
+
|
|
2049
|
+
if (this.entry.numberSubjects === 1) {
|
|
2050
|
+
text += " from ".concat(this.entry.numberSubjects, " subject");
|
|
2051
|
+
} else if (this.entry.numberSamples > 1) {
|
|
2052
|
+
text += " from ".concat(this.entry.numberSubjects, " subjects");
|
|
1742
2053
|
}
|
|
2054
|
+
|
|
2055
|
+
text += ")";
|
|
1743
2056
|
}
|
|
1744
2057
|
|
|
1745
2058
|
return text;
|
|
@@ -1784,7 +2097,7 @@ var DatasetCardvue_type_script_lang_js_capitalise = function capitalise(string)
|
|
|
1784
2097
|
window.open(this.dataLocation, '_blank');
|
|
1785
2098
|
},
|
|
1786
2099
|
openRepository: function openRepository() {
|
|
1787
|
-
var apiLocation = this.
|
|
2100
|
+
var apiLocation = this.envVars.API_LOCATION;
|
|
1788
2101
|
this.entry.additionalLinks.forEach(function (el) {
|
|
1789
2102
|
if (el.description == "Repository") {
|
|
1790
2103
|
var xmlhttp = new XMLHttpRequest();
|
|
@@ -1886,11 +2199,11 @@ var DatasetCardvue_type_script_lang_js_capitalise = function capitalise(string)
|
|
|
1886
2199
|
},
|
|
1887
2200
|
getScaffoldPath: function getScaffoldPath(discoverId, version, scaffoldPath) {
|
|
1888
2201
|
var id = discoverId;
|
|
1889
|
-
var path = "".concat(this.
|
|
2202
|
+
var path = "".concat(this.envVars.API_LOCATION, "s3-resource/").concat(id, "/").concat(version, "/files/").concat(scaffoldPath);
|
|
1890
2203
|
return path;
|
|
1891
2204
|
},
|
|
1892
2205
|
getFileFromPath: function getFileFromPath(discoverId, version, path) {
|
|
1893
|
-
return "".concat(this.
|
|
2206
|
+
return "".concat(this.envVars.API_LOCATION, "s3-resource/").concat(discoverId, "/").concat(version, "/files/").concat(path);
|
|
1894
2207
|
},
|
|
1895
2208
|
isOverflown: function isOverflown(el) {
|
|
1896
2209
|
return el.clientHeight < el.scrollHeight;
|
|
@@ -1930,7 +2243,8 @@ var DatasetCardvue_type_script_lang_js_capitalise = function capitalise(string)
|
|
|
1930
2243
|
getBiolucidaInfo: function getBiolucidaInfo(id) {
|
|
1931
2244
|
var _this2 = this;
|
|
1932
2245
|
|
|
1933
|
-
var
|
|
2246
|
+
var apiLocation = this.envVars.API_LOCATION;
|
|
2247
|
+
var endpoint = apiLocation + "image_search/" + id; // Add parameters if we are sent them
|
|
1934
2248
|
|
|
1935
2249
|
fetch(endpoint).then(function (response) {
|
|
1936
2250
|
return response.json();
|
|
@@ -1956,8 +2270,8 @@ var DatasetCardvue_type_script_lang_js_capitalise = function capitalise(string)
|
|
|
1956
2270
|
});
|
|
1957
2271
|
// CONCATENATED MODULE: ./src/components/DatasetCard.vue?vue&type=script&lang=js&
|
|
1958
2272
|
/* harmony default export */ var components_DatasetCardvue_type_script_lang_js_ = (DatasetCardvue_type_script_lang_js_);
|
|
1959
|
-
// EXTERNAL MODULE: ./src/components/DatasetCard.vue?vue&type=style&index=0&id=
|
|
1960
|
-
var
|
|
2273
|
+
// EXTERNAL MODULE: ./src/components/DatasetCard.vue?vue&type=style&index=0&id=eaeba60a&scoped=true&lang=css&
|
|
2274
|
+
var DatasetCardvue_type_style_index_0_id_eaeba60a_scoped_true_lang_css_ = __webpack_require__("c3dd");
|
|
1961
2275
|
|
|
1962
2276
|
// CONCATENATED MODULE: ./src/components/DatasetCard.vue
|
|
1963
2277
|
|
|
@@ -1970,17 +2284,17 @@ var DatasetCardvue_type_style_index_0_id_7989efa8_scoped_true_lang_css_ = __webp
|
|
|
1970
2284
|
|
|
1971
2285
|
var DatasetCard_component = normalizeComponent(
|
|
1972
2286
|
components_DatasetCardvue_type_script_lang_js_,
|
|
1973
|
-
|
|
1974
|
-
|
|
2287
|
+
DatasetCardvue_type_template_id_eaeba60a_scoped_true_render,
|
|
2288
|
+
DatasetCardvue_type_template_id_eaeba60a_scoped_true_staticRenderFns,
|
|
1975
2289
|
false,
|
|
1976
2290
|
null,
|
|
1977
|
-
"
|
|
2291
|
+
"eaeba60a",
|
|
1978
2292
|
null
|
|
1979
2293
|
|
|
1980
2294
|
)
|
|
1981
2295
|
|
|
1982
2296
|
/* harmony default export */ var DatasetCard = (DatasetCard_component.exports);
|
|
1983
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
2297
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"52eab1bf-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!./src/components/ContextCard.vue?vue&type=template&id=17e861eb&scoped=true&
|
|
1984
2298
|
var ContextCardvue_type_template_id_17e861eb_scoped_true_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{ref:"container",staticClass:"context-card-container"},[_c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.showDetails),expression:"showDetails"}],staticClass:"hide",on:{"click":function($event){_vm.showDetails = !_vm.showDetails}}},[_vm._v("Hide information"),_c('i',{staticClass:"el-icon-arrow-up"})]),_c('div',{directives:[{name:"show",rawName:"v-show",value:(!_vm.showDetails),expression:"!showDetails"}],staticClass:"hide",on:{"click":function($event){_vm.showDetails = !_vm.showDetails}}},[_vm._v("Show information"),_c('i',{staticClass:"el-icon-arrow-down"})]),_c('el-card',{directives:[{name:"show",rawName:"v-show",value:(_vm.showDetails),expression:"showDetails"}],staticClass:"context-card card",attrs:{"body-style":{ padding: '0px', 'background-color': 'white', display: 'flex', width: '516px'}}},[_c('img',{staticClass:"context-image card-left",attrs:{"src":_vm.entry.bannerImage}}),_c('div',{staticClass:"card-right"},[_c('div',{staticClass:"title"},[_vm._v(_vm._s(_vm.entry.title))]),_c('div',[_vm._v(_vm._s(_vm.entry.description))]),_vm._l((_vm.entry.keys),function(key){return [_c('br',{key:key.text}),_c('span',{key:key.text + 1},[_c('img',{staticStyle:{"height":"20px"},attrs:{"src":key.image}}),_vm._v(" "+_vm._s(key.text))])]})],2)])],1)}
|
|
1985
2299
|
var ContextCardvue_type_template_id_17e861eb_scoped_true_staticRenderFns = []
|
|
1986
2300
|
|
|
@@ -2133,6 +2447,7 @@ var ContextCard_component = normalizeComponent(
|
|
|
2133
2447
|
|
|
2134
2448
|
|
|
2135
2449
|
|
|
2450
|
+
|
|
2136
2451
|
|
|
2137
2452
|
|
|
2138
2453
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; }
|
|
@@ -2185,6 +2500,7 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
|
|
|
2185
2500
|
//
|
|
2186
2501
|
//
|
|
2187
2502
|
//
|
|
2503
|
+
//
|
|
2188
2504
|
|
|
2189
2505
|
/* eslint-disable no-alert, no-console */
|
|
2190
2506
|
|
|
@@ -2193,6 +2509,8 @@ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { va
|
|
|
2193
2509
|
|
|
2194
2510
|
|
|
2195
2511
|
|
|
2512
|
+
|
|
2513
|
+
|
|
2196
2514
|
locale_default.a.use(en_default.a);
|
|
2197
2515
|
external_vue_default.a.use(button_default.a);
|
|
2198
2516
|
external_vue_default.a.use(card_default.a);
|
|
@@ -2291,9 +2609,9 @@ var initial_state = {
|
|
|
2291
2609
|
type: Object,
|
|
2292
2610
|
default: undefined
|
|
2293
2611
|
},
|
|
2294
|
-
|
|
2295
|
-
type:
|
|
2296
|
-
default:
|
|
2612
|
+
envVars: {
|
|
2613
|
+
type: Object,
|
|
2614
|
+
default: function _default() {}
|
|
2297
2615
|
},
|
|
2298
2616
|
firstSearch: {
|
|
2299
2617
|
type: String,
|
|
@@ -2319,77 +2637,97 @@ var initial_state = {
|
|
|
2319
2637
|
}
|
|
2320
2638
|
},
|
|
2321
2639
|
methods: {
|
|
2322
|
-
openSearch: function openSearch(
|
|
2323
|
-
var
|
|
2324
|
-
var endpoint = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : undefined;
|
|
2325
|
-
var params = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : undefined;
|
|
2640
|
+
openSearch: function openSearch(filter) {
|
|
2641
|
+
var search = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';
|
|
2326
2642
|
this.searchInput = search;
|
|
2327
2643
|
this.resetPageNavigation();
|
|
2328
|
-
this.
|
|
2644
|
+
this.searchAlgolia(filter, search);
|
|
2329
2645
|
|
|
2330
2646
|
if (filter) {
|
|
2331
2647
|
this.filter = _toConsumableArray(filter);
|
|
2332
2648
|
this.$refs.filtersRef.setCascader(this.filter);
|
|
2333
2649
|
}
|
|
2334
2650
|
},
|
|
2651
|
+
addFilter: function addFilter(filter) {
|
|
2652
|
+
this.resetPageNavigation();
|
|
2653
|
+
|
|
2654
|
+
if (filter) {
|
|
2655
|
+
this.$refs.filtersRef.addFilter(filter);
|
|
2656
|
+
this.$refs.filtersRef.initiateSearch();
|
|
2657
|
+
}
|
|
2658
|
+
},
|
|
2335
2659
|
clearSearchClicked: function clearSearchClicked() {
|
|
2336
2660
|
this.searchInput = "";
|
|
2337
2661
|
this.resetPageNavigation();
|
|
2338
|
-
this.
|
|
2662
|
+
this.searchAlgolia(this.filters, this.searchInput);
|
|
2339
2663
|
},
|
|
2340
2664
|
searchEvent: function searchEvent() {
|
|
2341
2665
|
var event = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
|
|
2342
2666
|
|
|
2343
2667
|
if (event.keyCode === 13 || event instanceof MouseEvent) {
|
|
2344
2668
|
this.resetPageNavigation();
|
|
2345
|
-
this.
|
|
2669
|
+
this.searchAlgolia(this.filters, this.searchInput);
|
|
2346
2670
|
}
|
|
2347
2671
|
},
|
|
2348
|
-
filterUpdate: function filterUpdate(
|
|
2672
|
+
filterUpdate: function filterUpdate(filters) {
|
|
2673
|
+
this.filters = _toConsumableArray(filters);
|
|
2349
2674
|
this.resetPageNavigation();
|
|
2350
|
-
this.
|
|
2351
|
-
this.filter = _toConsumableArray(filter);
|
|
2675
|
+
this.searchAlgolia(filters, this.searchInput);
|
|
2352
2676
|
this.$emit("search-changed", {
|
|
2353
2677
|
value: this.filter,
|
|
2354
2678
|
type: "filter-update"
|
|
2355
2679
|
});
|
|
2356
2680
|
},
|
|
2681
|
+
searchAlgolia: function searchAlgolia(filters) {
|
|
2682
|
+
var _this = this;
|
|
2683
|
+
|
|
2684
|
+
var query = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';
|
|
2685
|
+
// Algolia search
|
|
2686
|
+
this.algoliaClient.search(getFilters(filters), query, this.numberPerPage, this.page).then(function (searchData) {
|
|
2687
|
+
_this.numberOfHits = searchData.total;
|
|
2688
|
+
_this.discoverIds = searchData.discoverIds;
|
|
2689
|
+
_this.results = searchData.items;
|
|
2690
|
+
|
|
2691
|
+
_this.searchSciCrunch({
|
|
2692
|
+
'discoverIds': _this.discoverIds
|
|
2693
|
+
});
|
|
2694
|
+
});
|
|
2695
|
+
},
|
|
2696
|
+
filtersLoading: function filtersLoading(val) {
|
|
2697
|
+
this.loadingCards = val;
|
|
2698
|
+
},
|
|
2357
2699
|
numberPerPageUpdate: function numberPerPageUpdate(val) {
|
|
2358
2700
|
this.numberPerPage = val;
|
|
2359
2701
|
this.pageChange(1);
|
|
2360
2702
|
},
|
|
2361
2703
|
pageChange: function pageChange(page) {
|
|
2362
2704
|
this.start = (page - 1) * this.numberPerPage;
|
|
2363
|
-
this.
|
|
2705
|
+
this.page = page;
|
|
2706
|
+
this.searchAlgolia(this.filters, this.searchInput, this.numberPerPage, this.page);
|
|
2364
2707
|
},
|
|
2365
|
-
searchSciCrunch: function searchSciCrunch(
|
|
2366
|
-
var
|
|
2708
|
+
searchSciCrunch: function searchSciCrunch(params) {
|
|
2709
|
+
var _this2 = this;
|
|
2367
2710
|
|
|
2368
|
-
var filter = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : undefined;
|
|
2369
|
-
var searchEndpoint = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : undefined;
|
|
2370
|
-
var params = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : undefined;
|
|
2371
2711
|
this.loadingCards = true;
|
|
2372
2712
|
this.results = [];
|
|
2373
2713
|
this.disableCards();
|
|
2374
|
-
if (!searchEndpoint) searchEndpoint = this.searchEndpoint;
|
|
2375
|
-
if (!params) params = this.createParams(filter, this.start, this.numberPerPage);
|
|
2376
2714
|
this.$emit("search-changed", {
|
|
2377
|
-
value:
|
|
2715
|
+
value: this.searchInput,
|
|
2378
2716
|
type: "query-update"
|
|
2379
2717
|
});
|
|
2380
|
-
this.callSciCrunch(this.
|
|
2718
|
+
this.callSciCrunch(this.envVars.API_LOCATION, params).then(function (result) {
|
|
2381
2719
|
//Only process if the search term is the same as the last search term.
|
|
2382
2720
|
//This avoid old search being displayed.
|
|
2383
|
-
|
|
2721
|
+
_this2.sciCrunchError = false;
|
|
2384
2722
|
|
|
2385
|
-
|
|
2723
|
+
_this2.resultsProcessing(result);
|
|
2386
2724
|
|
|
2387
|
-
|
|
2388
|
-
|
|
2725
|
+
_this2.$refs.content.style["overflow-y"] = "scroll";
|
|
2726
|
+
_this2.loadingCards = false;
|
|
2389
2727
|
}).catch(function (result) {
|
|
2390
2728
|
if (result.name !== 'AbortError') {
|
|
2391
|
-
|
|
2392
|
-
|
|
2729
|
+
_this2.loadingCards = false;
|
|
2730
|
+
_this2.sciCrunchError = result.message;
|
|
2393
2731
|
}
|
|
2394
2732
|
});
|
|
2395
2733
|
},
|
|
@@ -2406,35 +2744,8 @@ var initial_state = {
|
|
|
2406
2744
|
this.start = 0;
|
|
2407
2745
|
this.page = 1;
|
|
2408
2746
|
},
|
|
2409
|
-
createParams: function createParams(filter, start, size) {
|
|
2410
|
-
//Deconstruct list of fitlers to list of term
|
|
2411
|
-
//and facet.
|
|
2412
|
-
var params = {};
|
|
2413
|
-
var term = [];
|
|
2414
|
-
var facet = [];
|
|
2415
|
-
var f = undefined;
|
|
2416
|
-
|
|
2417
|
-
if (filter !== undefined) {
|
|
2418
|
-
f = filter;
|
|
2419
|
-
} else {
|
|
2420
|
-
f = this.filter;
|
|
2421
|
-
}
|
|
2422
|
-
|
|
2423
|
-
if (f) f.forEach(function (e) {
|
|
2424
|
-
//Do not ask for any "show all" request
|
|
2425
|
-
if (e.facet !== "show all") {
|
|
2426
|
-
term.push(e.term);
|
|
2427
|
-
facet.push(e.facet);
|
|
2428
|
-
}
|
|
2429
|
-
});
|
|
2430
|
-
params.term = term;
|
|
2431
|
-
params.facet = facet;
|
|
2432
|
-
params.start = start;
|
|
2433
|
-
params.size = size;
|
|
2434
|
-
return params;
|
|
2435
|
-
},
|
|
2436
2747
|
resultsProcessing: function resultsProcessing(data) {
|
|
2437
|
-
var
|
|
2748
|
+
var _this3 = this;
|
|
2438
2749
|
|
|
2439
2750
|
this.lastSearch = this.searchInput;
|
|
2440
2751
|
this.results = [];
|
|
@@ -2450,7 +2761,8 @@ var initial_state = {
|
|
|
2450
2761
|
name: element.name,
|
|
2451
2762
|
description: element.description,
|
|
2452
2763
|
contributors: element.contributors,
|
|
2453
|
-
numberSamples:
|
|
2764
|
+
numberSamples: element.sampleSize ? parseInt(element.sampleSize) : 0,
|
|
2765
|
+
numberSubjects: element.subjectSize ? parseInt(element.subjectSize) : 0,
|
|
2454
2766
|
updated: element.updated[0].timestamp.split("T")[0],
|
|
2455
2767
|
url: element.uri[0],
|
|
2456
2768
|
datasetId: element.dataset_identifier,
|
|
@@ -2473,7 +2785,7 @@ var initial_state = {
|
|
|
2473
2785
|
s3uri: element.s3uri
|
|
2474
2786
|
};
|
|
2475
2787
|
|
|
2476
|
-
|
|
2788
|
+
_this3.results.push(datasetInfo);
|
|
2477
2789
|
});
|
|
2478
2790
|
},
|
|
2479
2791
|
createfilterParams: function createfilterParams(params) {
|
|
@@ -2495,25 +2807,20 @@ var initial_state = {
|
|
|
2495
2807
|
|
|
2496
2808
|
return p.toString();
|
|
2497
2809
|
},
|
|
2498
|
-
callSciCrunch: function callSciCrunch(apiLocation
|
|
2499
|
-
var
|
|
2810
|
+
callSciCrunch: function callSciCrunch(apiLocation) {
|
|
2811
|
+
var _this4 = this;
|
|
2500
2812
|
|
|
2501
|
-
var params = arguments.length >
|
|
2813
|
+
var params = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
2502
2814
|
return new Promise(function (resolve, reject) {
|
|
2503
2815
|
// the following controller will abort current search
|
|
2504
2816
|
// if a new one has been started
|
|
2505
|
-
if (
|
|
2506
|
-
|
|
2507
|
-
var signal =
|
|
2508
|
-
var endpoint = apiLocation + searchEndpoint; // Add parameters if we are sent them
|
|
2817
|
+
if (_this4._controller) _this4._controller.abort();
|
|
2818
|
+
_this4._controller = new AbortController();
|
|
2819
|
+
var signal = _this4._controller.signal; // Add parameters if we are sent them
|
|
2509
2820
|
|
|
2510
|
-
|
|
2511
|
-
endpoint = endpoint + search + "/?" + _this3.createfilterParams(params);
|
|
2512
|
-
} else {
|
|
2513
|
-
endpoint = endpoint + "?" + _this3.createfilterParams(params);
|
|
2514
|
-
}
|
|
2821
|
+
var fullEndpoint = _this4.envVars.API_LOCATION + _this4.searchEndpoint + "?" + _this4.createfilterParams(params);
|
|
2515
2822
|
|
|
2516
|
-
fetch(
|
|
2823
|
+
fetch(fullEndpoint, {
|
|
2517
2824
|
signal: signal
|
|
2518
2825
|
}).then(handleErrors).then(function (response) {
|
|
2519
2826
|
return response.json();
|
|
@@ -2526,46 +2833,26 @@ var initial_state = {
|
|
|
2526
2833
|
}
|
|
2527
2834
|
},
|
|
2528
2835
|
mounted: function mounted() {
|
|
2529
|
-
//
|
|
2836
|
+
// initialise algolia
|
|
2837
|
+
this.algoliaClient = new algolia_AlgoliaClient(this.envVars.ALGOLIA_ID, this.envVars.ALGOLIA_KEY, this.envVars.PENNSIEVE_API_LOCATION);
|
|
2838
|
+
this.algoliaClient.initIndex(this.envVars.ALGOLIA_INDEX);
|
|
2839
|
+
console.log('Algolia initialised in sidebar'); // temporarily disable flatmap search since there are no datasets
|
|
2840
|
+
|
|
2530
2841
|
if (this.firstSearch === "Flatmap" || this.firstSearch === "flatmap") {
|
|
2531
|
-
this.openSearch(''
|
|
2532
|
-
facet: "show all",
|
|
2533
|
-
term: 'species'
|
|
2534
|
-
}, {
|
|
2535
|
-
facet: "show all",
|
|
2536
|
-
term: 'gender'
|
|
2537
|
-
}, {
|
|
2538
|
-
facet: "show all",
|
|
2539
|
-
term: 'organ'
|
|
2540
|
-
}, {
|
|
2541
|
-
facet: "show all",
|
|
2542
|
-
term: 'datasets'
|
|
2543
|
-
}]);
|
|
2842
|
+
this.openSearch(undefined, '');
|
|
2544
2843
|
} else {
|
|
2545
|
-
this.openSearch(
|
|
2546
|
-
facet: "show all",
|
|
2547
|
-
term: 'species'
|
|
2548
|
-
}, {
|
|
2549
|
-
facet: "show all",
|
|
2550
|
-
term: 'gender'
|
|
2551
|
-
}, {
|
|
2552
|
-
facet: "show all",
|
|
2553
|
-
term: 'organ'
|
|
2554
|
-
}, {
|
|
2555
|
-
facet: "show all",
|
|
2556
|
-
term: 'datasets'
|
|
2557
|
-
}]);
|
|
2844
|
+
this.openSearch(undefined, '');
|
|
2558
2845
|
}
|
|
2559
2846
|
},
|
|
2560
2847
|
created: function created() {
|
|
2561
2848
|
//Create non-reactive local variables
|
|
2562
|
-
this.searchEndpoint = "
|
|
2849
|
+
this.searchEndpoint = "dataset_info/using_multiple_discoverIds/";
|
|
2563
2850
|
}
|
|
2564
2851
|
});
|
|
2565
2852
|
// CONCATENATED MODULE: ./src/components/SidebarContent.vue?vue&type=script&lang=js&
|
|
2566
2853
|
/* harmony default export */ var components_SidebarContentvue_type_script_lang_js_ = (SidebarContentvue_type_script_lang_js_);
|
|
2567
|
-
// EXTERNAL MODULE: ./src/components/SidebarContent.vue?vue&type=style&index=0&id=
|
|
2568
|
-
var
|
|
2854
|
+
// EXTERNAL MODULE: ./src/components/SidebarContent.vue?vue&type=style&index=0&id=2e1db9a4&scoped=true&lang=css&
|
|
2855
|
+
var SidebarContentvue_type_style_index_0_id_2e1db9a4_scoped_true_lang_css_ = __webpack_require__("be47");
|
|
2569
2856
|
|
|
2570
2857
|
// CONCATENATED MODULE: ./src/components/SidebarContent.vue
|
|
2571
2858
|
|
|
@@ -2578,17 +2865,17 @@ var SidebarContentvue_type_style_index_0_id_ef9395fe_scoped_true_lang_css_ = __w
|
|
|
2578
2865
|
|
|
2579
2866
|
var SidebarContent_component = normalizeComponent(
|
|
2580
2867
|
components_SidebarContentvue_type_script_lang_js_,
|
|
2581
|
-
|
|
2582
|
-
|
|
2868
|
+
SidebarContentvue_type_template_id_2e1db9a4_scoped_true_render,
|
|
2869
|
+
SidebarContentvue_type_template_id_2e1db9a4_scoped_true_staticRenderFns,
|
|
2583
2870
|
false,
|
|
2584
2871
|
null,
|
|
2585
|
-
"
|
|
2872
|
+
"2e1db9a4",
|
|
2586
2873
|
null
|
|
2587
2874
|
|
|
2588
2875
|
)
|
|
2589
2876
|
|
|
2590
2877
|
/* harmony default export */ var SidebarContent = (SidebarContent_component.exports);
|
|
2591
|
-
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"
|
|
2878
|
+
// CONCATENATED MODULE: ./node_modules/cache-loader/dist/cjs.js?{"cacheDirectory":"node_modules/.cache/vue-loader","cacheIdentifier":"52eab1bf-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!./src/components/Tabs.vue?vue&type=template&id=5d1b9484&scoped=true&
|
|
2592
2879
|
var Tabsvue_type_template_id_5d1b9484_scoped_true_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:"tab-container"},_vm._l((_vm.tabTitles),function(title){return _c('div',{key:title.id,staticClass:"title"},[_c('div',{staticClass:"title-text-table",class:{ highlightText : (title.id==_vm.activeId) },on:{"click":function($event){return _vm.titleClicked(title.id)}}},[_c('div',{staticClass:"title-text"},[_vm._v(" "+_vm._s(title.title)+" ")])])])}),0)}
|
|
2593
2880
|
var Tabsvue_type_template_id_5d1b9484_scoped_true_staticRenderFns = []
|
|
2594
2881
|
|
|
@@ -2759,9 +3046,9 @@ var SideBarvue_type_script_lang_js_initial_state = {
|
|
|
2759
3046
|
return SideBarvue_type_script_lang_js_initial_state;
|
|
2760
3047
|
}
|
|
2761
3048
|
},
|
|
2762
|
-
|
|
2763
|
-
type:
|
|
2764
|
-
default:
|
|
3049
|
+
envVars: {
|
|
3050
|
+
type: Object,
|
|
3051
|
+
default: function _default() {}
|
|
2765
3052
|
},
|
|
2766
3053
|
tabs: {
|
|
2767
3054
|
type: Array,
|
|
@@ -2796,22 +3083,31 @@ var SideBarvue_type_script_lang_js_initial_state = {
|
|
|
2796
3083
|
toggleDrawer: function toggleDrawer() {
|
|
2797
3084
|
this.drawerOpen = !this.drawerOpen;
|
|
2798
3085
|
},
|
|
2799
|
-
openSearch: function openSearch(
|
|
3086
|
+
openSearch: function openSearch(facets, query) {
|
|
2800
3087
|
var _this = this;
|
|
2801
3088
|
|
|
2802
3089
|
this.drawerOpen = true; // Because refs are in v-for, nextTick is needed here
|
|
2803
3090
|
|
|
2804
3091
|
external_vue_default.a.nextTick(function () {
|
|
2805
|
-
_this.$refs[_this.activeId][0].openSearch(
|
|
3092
|
+
_this.$refs[_this.activeId][0].openSearch(facets, query);
|
|
2806
3093
|
});
|
|
2807
3094
|
},
|
|
2808
|
-
|
|
3095
|
+
addFilter: function addFilter(filter) {
|
|
2809
3096
|
var _this2 = this;
|
|
2810
3097
|
|
|
2811
3098
|
this.drawerOpen = true; // Because refs are in v-for, nextTick is needed here
|
|
2812
3099
|
|
|
2813
3100
|
external_vue_default.a.nextTick(function () {
|
|
2814
|
-
_this2.$refs[_this2.activeId][0].
|
|
3101
|
+
_this2.$refs[_this2.activeId][0].addFilter(filter);
|
|
3102
|
+
});
|
|
3103
|
+
},
|
|
3104
|
+
openNeuronSearch: function openNeuronSearch(neuron) {
|
|
3105
|
+
var _this3 = this;
|
|
3106
|
+
|
|
3107
|
+
this.drawerOpen = true; // Because refs are in v-for, nextTick is needed here
|
|
3108
|
+
|
|
3109
|
+
external_vue_default.a.nextTick(function () {
|
|
3110
|
+
_this3.$refs[_this3.activeId][0].openSearch('', undefined, 'scicrunch-query-string/', {
|
|
2815
3111
|
'field': '*organ.curie',
|
|
2816
3112
|
'curie': neuron
|
|
2817
3113
|
});
|
|
@@ -2825,17 +3121,17 @@ var SideBarvue_type_script_lang_js_initial_state = {
|
|
|
2825
3121
|
this.drawerOpen = this.openAtStart;
|
|
2826
3122
|
},
|
|
2827
3123
|
mounted: function mounted() {
|
|
2828
|
-
var
|
|
3124
|
+
var _this4 = this;
|
|
2829
3125
|
|
|
2830
3126
|
components_EventBus.$on("PopoverActionClick", function (payLoad) {
|
|
2831
|
-
|
|
3127
|
+
_this4.$emit("actionClick", payLoad);
|
|
2832
3128
|
});
|
|
2833
3129
|
}
|
|
2834
3130
|
});
|
|
2835
3131
|
// CONCATENATED MODULE: ./src/components/SideBar.vue?vue&type=script&lang=js&
|
|
2836
3132
|
/* harmony default export */ var components_SideBarvue_type_script_lang_js_ = (SideBarvue_type_script_lang_js_);
|
|
2837
|
-
// EXTERNAL MODULE: ./src/components/SideBar.vue?vue&type=style&index=0&id=
|
|
2838
|
-
var
|
|
3133
|
+
// EXTERNAL MODULE: ./src/components/SideBar.vue?vue&type=style&index=0&id=3d831a8e&scoped=true&lang=css&
|
|
3134
|
+
var SideBarvue_type_style_index_0_id_3d831a8e_scoped_true_lang_css_ = __webpack_require__("bc5f");
|
|
2839
3135
|
|
|
2840
3136
|
// CONCATENATED MODULE: ./src/components/SideBar.vue
|
|
2841
3137
|
|
|
@@ -2852,7 +3148,7 @@ var SideBar_component = normalizeComponent(
|
|
|
2852
3148
|
staticRenderFns,
|
|
2853
3149
|
false,
|
|
2854
3150
|
null,
|
|
2855
|
-
"
|
|
3151
|
+
"3d831a8e",
|
|
2856
3152
|
null
|
|
2857
3153
|
|
|
2858
3154
|
)
|
|
@@ -2873,13 +3169,6 @@ var SideBar_component = normalizeComponent(
|
|
|
2873
3169
|
|
|
2874
3170
|
module.exports = require("core-js/modules/es.string.includes");
|
|
2875
3171
|
|
|
2876
|
-
/***/ }),
|
|
2877
|
-
|
|
2878
|
-
/***/ "feaa":
|
|
2879
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
2880
|
-
|
|
2881
|
-
// extracted by mini-css-extract-plugin
|
|
2882
|
-
|
|
2883
3172
|
/***/ })
|
|
2884
3173
|
|
|
2885
3174
|
/******/ });
|