@abi-software/map-side-bar 1.1.13 → 1.1.16
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/dist/map-side-bar.common.js +294 -162
- 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 +294 -162
- 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 +1 -1
- package/package.json +1 -1
- package/src/App.vue +46 -58
- package/src/components/ContextCard.vue +46 -9
- package/src/components/DatasetCard.vue +38 -5
- package/src/components/SearchFilters.vue +120 -5
- package/src/components/SidebarContent.vue +7 -6
package/package-lock.json
CHANGED
package/package.json
CHANGED
package/src/App.vue
CHANGED
|
@@ -18,36 +18,50 @@
|
|
|
18
18
|
// optionally import default styles
|
|
19
19
|
import SideBar from './components/SideBar'
|
|
20
20
|
|
|
21
|
-
let testContext = {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
21
|
+
// let testContext = {
|
|
22
|
+
// "description": "3D digital tracings of the enteric plexus obtained from seven subjects (M11, M16, M162, M163, M164, M168) are mapped randomly on mouse proximal colon. The data depicts individual neural wiring patterns in enteric microcircuits, and revealed both neuron and fiber units wired in a complex organization.",
|
|
23
|
+
// "heading": "Digital tracings of enteric plexus",
|
|
24
|
+
// "id": "sparc.science.context_data",
|
|
25
|
+
// "samples": [
|
|
26
|
+
// {
|
|
27
|
+
// "annotation": "",
|
|
28
|
+
// "description": "Neuronal soma and fibers in a myenteric ganglion in this subject are annotated into the following groups to highlight their interactions:\n\nNeuron1,2,3 Connex: Connections between 3 neurons and cross-ganglionic fibers\n\nNeuron4_Connex: A small neuron contacts fibers passing the ganglion\n\nNeuron5: Multiple projections of a neuron in an myenteric ganglion\n\nNeuron5,3,7 Connex: Connections between 3 neurons, nerve fibers, IGNEx (complex type of intraganglionic nerve endings) and fibers in the circular muscles.\n\nNeuron8,9,10 Connex: Connections of 3 neurons with each other and with long passing fibers. \n\nIntraganglionic Nerve Ending (IGNE): Digital traces of neurites consist of complex intraganglionic nerve endings. The blue fiber has branched terminals, more likely the afferent nerve endings; the violet and cyan terminals also interweave into the fiber nest; the orange, pink and peach fibers and one process of the neuron cross the IGNE to make 1-2 conjunctions. \n",
|
|
29
|
+
// "doi": "",
|
|
30
|
+
// "heading": "Digital tracing for subject M11",
|
|
31
|
+
// "id": "Sample 1",
|
|
32
|
+
// "path": "files/derivative/sub-M11/sam-pCm11/digital-traces/pC PHPS XFP M11 20XZ 180425_180713_2_NL_20.xml",
|
|
33
|
+
// "view": "View 1"
|
|
34
|
+
// },
|
|
35
|
+
// {
|
|
36
|
+
// "annotation": "",
|
|
37
|
+
// "description": "This digital trace demonstrates some types of wiring. A long process of the green neuron terminates in the intraganglionic nerve endings (IGNE) while in contact with a nerve fiber (cyan), soma of a neuron (peach) and processes of 3 neurons (magenta, yellow and red). Two neurons and one fiber are traced to an IGNE. ",
|
|
38
|
+
// "doi": "",
|
|
39
|
+
// "heading": "Digital tracing for subject M16",
|
|
40
|
+
// "id": "Sample 2",
|
|
41
|
+
// "path": "files/derivative/sub-M16/sam-pCm16/digital-traces/pC PHPS XFP M16 20XZ 180425_180524.xml",
|
|
42
|
+
// "view": "View 2"
|
|
43
|
+
// }
|
|
44
|
+
// ],
|
|
45
|
+
// "version": "0.1.0",
|
|
46
|
+
// "views": [
|
|
47
|
+
// {
|
|
48
|
+
// "annotation": "--",
|
|
49
|
+
// "description": "Digital tracing of neurons for subject M11.",
|
|
50
|
+
// "id": "View 1",
|
|
51
|
+
// "path": "files/derivative/Scaffolds/M11_view.json",
|
|
52
|
+
// "sample": "Sample 1",
|
|
53
|
+
// "thumbnail": "files/derivative/Scaffolds/M11_thumbnail.jpeg"
|
|
54
|
+
// },
|
|
55
|
+
// {
|
|
56
|
+
// "annotation": "--",
|
|
57
|
+
// "description": "Digital tracing of neurons for subject M16.",
|
|
58
|
+
// "id": "View 2",
|
|
59
|
+
// "path": "files/derivative/Scaffolds/M16_view.json",
|
|
60
|
+
// "sample": "Sample 2",
|
|
61
|
+
// "thumbnail": "files/derivative/Scaffolds/M16_thumbnail.jpeg"
|
|
62
|
+
// }
|
|
63
|
+
// ]
|
|
64
|
+
// }
|
|
51
65
|
export default {
|
|
52
66
|
name: 'app',
|
|
53
67
|
components: {
|
|
@@ -65,33 +79,7 @@ export default {
|
|
|
65
79
|
data: function(){
|
|
66
80
|
return {
|
|
67
81
|
tabArray: [{title: 'Flatmap', id:1},{title: 'Heart Scaffold', id:2},{title: 'Stomach Scaffold', id:3}],
|
|
68
|
-
contextArray: [
|
|
69
|
-
title: "Neural paths mapped to a heart scaffold",
|
|
70
|
-
description: "Points are mapped to their positions on a 3d heart that is mapped to the data.",
|
|
71
|
-
bannerImage: 'https://image.prntscr.com/image/aNIksBFARaKwlKhpnDCKbA.png',
|
|
72
|
-
keys: [{
|
|
73
|
-
image: "https://image.prntscr.com/image/VqNcZ8fSQJu5TJEf9ahwvA.png",
|
|
74
|
-
text: "Neural path"
|
|
75
|
-
}],
|
|
76
|
-
},{
|
|
77
|
-
title: "ICN fitted Scaffold",
|
|
78
|
-
description: "Points are mapped to their positions on a 3d heart that is mapped to the data.",
|
|
79
|
-
bannerImage: 'https://image.prntscr.com/image/BKgqmjSaQjK-B9hy_W7haQ.png',
|
|
80
|
-
keys: [{
|
|
81
|
-
image: "https://image.prntscr.com/image/DO_ZZXl7RtOXgVDv-Vw6yA.png",
|
|
82
|
-
text: "Data type 1"
|
|
83
|
-
},{
|
|
84
|
-
image: "https://image.prntscr.com/image/tsnuRyFZTbmYfSjrMHTK8w.png",
|
|
85
|
-
text: "Data type 2"
|
|
86
|
-
},{
|
|
87
|
-
image: "https://image.prntscr.com/image/DO_ZZXl7RtOXgVDv-Vw6yA.png",
|
|
88
|
-
text: "Data type 3"
|
|
89
|
-
},{
|
|
90
|
-
image: "https://image.prntscr.com/image/tsnuRyFZTbmYfSjrMHTK8w.png",
|
|
91
|
-
text: "Data type 4"
|
|
92
|
-
}
|
|
93
|
-
]
|
|
94
|
-
}],
|
|
82
|
+
contextArray: [null,null,null],
|
|
95
83
|
sideBarVisibility: true,
|
|
96
84
|
envVars: {
|
|
97
85
|
API_LOCATION: process.env.VUE_APP_API_LOCATION,
|
|
@@ -120,7 +108,7 @@ export default {
|
|
|
120
108
|
this.$refs.sideBar.addFilter({facet: 'Heart', term:'Anatomical structure', facetPropPath: 'anatomy.organ.name'})
|
|
121
109
|
},
|
|
122
110
|
multiFacets: function(){
|
|
123
|
-
this.$refs.sideBar.openSearch(
|
|
111
|
+
this.$refs.sideBar.openSearch([{facet: 'Male', term:'Sex', facetPropPath:'attributes.subject.sex.value'}, {facet: 'Heart', term:'Anatomical structure', facetPropPath: 'anatomy.organ.name'}], '')
|
|
124
112
|
},
|
|
125
113
|
neuronSearch: function(){
|
|
126
114
|
this.$refs.sideBar.openNeuronSearch('neuron-type-keast-10')
|
|
@@ -2,14 +2,14 @@
|
|
|
2
2
|
<div class="context-card-container" ref="container">
|
|
3
3
|
<div v-show="showDetails" class="hide" @click="showDetails = !showDetails">Hide information<i class="el-icon-arrow-up"></i></div>
|
|
4
4
|
<div v-show="!showDetails" class="hide" @click="showDetails = !showDetails">Show information<i class="el-icon-arrow-down"></i></div>
|
|
5
|
-
<el-card v-
|
|
6
|
-
<img :src="entry.
|
|
5
|
+
<el-card v-if="showDetails && Object.keys(contextData).length !== 0" class="context-card card" :body-style="{ padding: '0px', 'background-color': 'white', display: 'flex', width: '516px'}">
|
|
6
|
+
<img :src="entry.banner" class="context-image card-left">
|
|
7
7
|
<div class="card-right">
|
|
8
|
-
<div class="title">{{
|
|
9
|
-
<div>{{
|
|
10
|
-
<template v-for="
|
|
11
|
-
<br v-bind:key="
|
|
12
|
-
<span v-bind:key="
|
|
8
|
+
<div class="title">{{contextData.heading}}</div>
|
|
9
|
+
<div>{{contextData.description}}</div>
|
|
10
|
+
<template v-for="(view, i) in contextData.views">
|
|
11
|
+
<br v-bind:key="i"/>
|
|
12
|
+
<span v-bind:key="i+'_1'" @click="openViewFile(view)" style="cursor:pointer;"><img :src="getFileFromPath(view.thumbnail)" style="height: 25px;"> {{view.description}}</span>
|
|
13
13
|
</template>
|
|
14
14
|
</div>
|
|
15
15
|
</el-card>
|
|
@@ -23,6 +23,7 @@ import Vue from "vue";
|
|
|
23
23
|
import { Link, Icon, Card, Button, Select, Input } from "element-ui";
|
|
24
24
|
import lang from "element-ui/lib/locale/lang/en";
|
|
25
25
|
import locale from "element-ui/lib/locale";
|
|
26
|
+
import EventBus from "./EventBus"
|
|
26
27
|
|
|
27
28
|
locale.use(lang);
|
|
28
29
|
Vue.use(Link);
|
|
@@ -45,14 +46,50 @@ export default {
|
|
|
45
46
|
},
|
|
46
47
|
data: function () {
|
|
47
48
|
return {
|
|
49
|
+
contextData: {},
|
|
48
50
|
showDetails: true
|
|
49
51
|
};
|
|
50
52
|
},
|
|
51
|
-
|
|
52
|
-
|
|
53
|
+
watch: {
|
|
54
|
+
'entry.contextCardUrl'(val){
|
|
55
|
+
this.getContextFile(val)
|
|
56
|
+
}
|
|
53
57
|
},
|
|
54
58
|
methods: {
|
|
59
|
+
getContextFile: function (contextFileUrl) {
|
|
60
|
+
fetch(contextFileUrl)
|
|
61
|
+
.then((response) =>{
|
|
62
|
+
if (!response.ok){
|
|
63
|
+
throw Error(response.statusText)
|
|
64
|
+
} else {
|
|
65
|
+
return response.json()
|
|
66
|
+
}
|
|
67
|
+
})
|
|
68
|
+
.then((data) => {
|
|
69
|
+
this.contextData = data
|
|
70
|
+
console.log(this.contextData)
|
|
71
|
+
})
|
|
72
|
+
.catch(() => {
|
|
73
|
+
//set defaults if we hit an error
|
|
74
|
+
this.thumbnail = require('@/../assets/missing-image.svg')
|
|
75
|
+
this.discoverId = undefined
|
|
76
|
+
});
|
|
77
|
+
},
|
|
78
|
+
getFileFromPath: function(path){
|
|
79
|
+
return `${this.entry.apiLocation}s3-resource/${this.entry.discoverId}/${this.entry.version}/files/${path}`
|
|
80
|
+
},
|
|
81
|
+
openViewFile: function(view){
|
|
82
|
+
|
|
83
|
+
// note that we assume that the view file is in the same directory as the scaffold (viewUrls take relative paths)
|
|
84
|
+
this.entry.viewUrl = view.path.split('/')[view.path.split('/').length-1]
|
|
85
|
+
this.entry.type = 'Scaffold View'
|
|
86
|
+
EventBus.$emit("PopoverActionClick", this.entry)
|
|
87
|
+
}
|
|
88
|
+
|
|
55
89
|
},
|
|
90
|
+
mounted: function(){
|
|
91
|
+
this.getContextFile(this.entry.contextCardUrl)
|
|
92
|
+
}
|
|
56
93
|
};
|
|
57
94
|
</script>
|
|
58
95
|
|
|
@@ -17,6 +17,9 @@
|
|
|
17
17
|
<div>
|
|
18
18
|
<el-button v-if="entry.scaffolds" @click="openScaffold" size="mini" class="button" icon="el-icon-view">View scaffold</el-button>
|
|
19
19
|
</div>
|
|
20
|
+
<div>
|
|
21
|
+
<el-button v-if="entry.contextualInformation" @click="openContext" size="mini" class="button" icon="el-icon-view">View context data</el-button>
|
|
22
|
+
</div>
|
|
20
23
|
<div>
|
|
21
24
|
<el-button v-if="hasCSVFile" @click="openPlot" size="mini" class="button" icon="el-icon-view">View plot</el-button>
|
|
22
25
|
</div>
|
|
@@ -42,7 +45,6 @@ import { Button, Icon } from "element-ui";
|
|
|
42
45
|
import lang from "element-ui/lib/locale/lang/en";
|
|
43
46
|
import locale from "element-ui/lib/locale";
|
|
44
47
|
import EventBus from "./EventBus"
|
|
45
|
-
import scaffoldMetaMap from './scaffold-meta-map';
|
|
46
48
|
import speciesMap from "./species-map";
|
|
47
49
|
|
|
48
50
|
locale.use(lang);
|
|
@@ -140,9 +142,26 @@ export default {
|
|
|
140
142
|
title: "View 3D scaffold",
|
|
141
143
|
type: "Scaffold",
|
|
142
144
|
discoverId: this.discoverId,
|
|
143
|
-
|
|
145
|
+
apiLocation: this.envVars.API_LOCATION,
|
|
146
|
+
version: this.version,
|
|
147
|
+
contextCardUrl: this.entry.contextualInformation ? this.getFileFromPath(this.discoverId, this.version,this.entry.contextualInformation) : undefined,
|
|
148
|
+
banner: this.thumbnail
|
|
144
149
|
}
|
|
145
|
-
|
|
150
|
+
this.propogateCardAction(action)
|
|
151
|
+
},
|
|
152
|
+
openContext: function(){
|
|
153
|
+
let action = {
|
|
154
|
+
label: capitalise(this.label),
|
|
155
|
+
resource: 'not used',
|
|
156
|
+
title: "View 3D scaffold",
|
|
157
|
+
type: "Scaffold",
|
|
158
|
+
discoverId: this.discoverId,
|
|
159
|
+
apiLocation: this.envVars.API_LOCATION,
|
|
160
|
+
version: this.version,
|
|
161
|
+
contextCardUrl: this.entry.contextualInformation ? this.getFileFromPath(this.discoverId, this.version,this.entry.contextualInformation) : undefined,
|
|
162
|
+
banner: this.thumbnail
|
|
163
|
+
}
|
|
164
|
+
this.propogateCardAction(action)
|
|
146
165
|
},
|
|
147
166
|
openPlot: function(){
|
|
148
167
|
let action = {
|
|
@@ -151,8 +170,12 @@ export default {
|
|
|
151
170
|
title: "View plot",
|
|
152
171
|
type: "Plot",
|
|
153
172
|
discoverId: this.discoverId,
|
|
173
|
+
apiLocation: this.envVars.API_LOCATION,
|
|
174
|
+
version: this.version,
|
|
175
|
+
contextCardUrl: this.entry.contextualInformation ? this.getFileFromPath(this.discoverId, this.version,this.entry.contextualInformation) : undefined,
|
|
176
|
+
banner: this.thumbnail
|
|
154
177
|
}
|
|
155
|
-
|
|
178
|
+
this.propogateCardAction(action)
|
|
156
179
|
},
|
|
157
180
|
openDataset: function(){
|
|
158
181
|
window.open(this.dataLocation,'_blank');
|
|
@@ -195,7 +218,10 @@ export default {
|
|
|
195
218
|
label: undefined,
|
|
196
219
|
resource: resource,
|
|
197
220
|
dataset: this.dataLocation,
|
|
198
|
-
|
|
221
|
+
apiLocation: this.envVars.API_LOCATION,
|
|
222
|
+
version: this.version,
|
|
223
|
+
contextCardUrl: this.entry.contextualInformation ? this.getFileFromPath(this.discoverId, this.version,this.entry.contextualInformation) : undefined,
|
|
224
|
+
banner: this.thumbnail,
|
|
199
225
|
title: "View simulation",
|
|
200
226
|
name: this.entry.name,
|
|
201
227
|
description: this.entry.description,
|
|
@@ -203,6 +229,13 @@ export default {
|
|
|
203
229
|
}
|
|
204
230
|
EventBus.$emit("PopoverActionClick", action)
|
|
205
231
|
},
|
|
232
|
+
propogateCardAction: function(action){
|
|
233
|
+
EventBus.$emit("PopoverActionClick", action)
|
|
234
|
+
if (action.contextCardUrl) {
|
|
235
|
+
this.$emit('contextUpdate', action)
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
},
|
|
206
239
|
getScaffoldPath: function(discoverId, version, scaffoldPath){
|
|
207
240
|
let id = discoverId
|
|
208
241
|
let path = `${this.envVars.API_LOCATION}s3-resource/${id}/${version}/files/${scaffoldPath}`
|
|
@@ -18,9 +18,28 @@
|
|
|
18
18
|
@tags-changed="tagsChangedCallback"
|
|
19
19
|
></custom-cascader>
|
|
20
20
|
<div v-if="showFiltersText" class="filter-default-value">
|
|
21
|
-
<map-svg-icon icon="noun-filter" class="filter-icon-inside" />Apply
|
|
22
21
|
Filters
|
|
23
22
|
</div>
|
|
23
|
+
<el-popover
|
|
24
|
+
title="How do filters work?"
|
|
25
|
+
width="250"
|
|
26
|
+
trigger="click"
|
|
27
|
+
:append-to-body=false
|
|
28
|
+
popper-class="popover"
|
|
29
|
+
>
|
|
30
|
+
<map-svg-icon slot="reference" icon="help" class="help"/>
|
|
31
|
+
<div >
|
|
32
|
+
<strong>Within categories:</strong> OR
|
|
33
|
+
<br/>
|
|
34
|
+
example: 'heart' OR 'colon'
|
|
35
|
+
<br/>
|
|
36
|
+
<br/>
|
|
37
|
+
<strong>Between categories:</strong> AND
|
|
38
|
+
<br/>
|
|
39
|
+
example: 'rat' AND 'lung'
|
|
40
|
+
</div>
|
|
41
|
+
</el-popover>
|
|
42
|
+
|
|
24
43
|
</span>
|
|
25
44
|
</transition>
|
|
26
45
|
|
|
@@ -45,7 +64,7 @@
|
|
|
45
64
|
<script>
|
|
46
65
|
/* eslint-disable no-alert, no-console */
|
|
47
66
|
import Vue from "vue";
|
|
48
|
-
import { Option, Select } from "element-ui";
|
|
67
|
+
import { Option, Select, Popover } from "element-ui";
|
|
49
68
|
import CustomCascader from "./Cascader";
|
|
50
69
|
import lang from "element-ui/lib/locale/lang/en";
|
|
51
70
|
import locale from "element-ui/lib/locale";
|
|
@@ -58,6 +77,7 @@ import { facetPropPathMapping } from "../algolia/utils.js";
|
|
|
58
77
|
locale.use(lang);
|
|
59
78
|
Vue.use(Option);
|
|
60
79
|
Vue.use(Select);
|
|
80
|
+
Vue.use(Popover)
|
|
61
81
|
|
|
62
82
|
const capitalise = function (txt) {
|
|
63
83
|
return txt.charAt(0).toUpperCase() + txt.slice(1);
|
|
@@ -157,6 +177,7 @@ export default {
|
|
|
157
177
|
this.createCascaderItemValue(facet.label, facetItem.label);
|
|
158
178
|
});
|
|
159
179
|
});
|
|
180
|
+
this.createDataTypeFacet()
|
|
160
181
|
})
|
|
161
182
|
.finally(() => {
|
|
162
183
|
resolve();
|
|
@@ -176,17 +197,28 @@ export default {
|
|
|
176
197
|
// Check for show all in selected cascade options
|
|
177
198
|
event = this.showAllEventModifier(event);
|
|
178
199
|
|
|
179
|
-
//
|
|
180
|
-
let
|
|
200
|
+
// Create results for the filter update
|
|
201
|
+
let filterKeys = event.filter( selection => selection !== undefined).map( fs => ({
|
|
181
202
|
facetPropPath: fs[0],
|
|
182
203
|
facet: fs[1].split("/")[1],
|
|
183
204
|
term: fs[1].split("/")[0],
|
|
184
205
|
}))
|
|
185
206
|
|
|
207
|
+
// Move results from arrays to object for use on scicrunch (note that we remove 'duplicate' as that is only needed for filter keys)
|
|
208
|
+
let filters = event.filter( selection => selection !== undefined).map( fs => {
|
|
209
|
+
let propPath = fs[0].includes('duplicate') ? fs[0].split('duplicate')[0] : fs[0]
|
|
210
|
+
return {
|
|
211
|
+
facetPropPath: propPath,
|
|
212
|
+
facet: fs[1].split("/")[1],
|
|
213
|
+
term: fs[1].split("/")[0],
|
|
214
|
+
}
|
|
215
|
+
})
|
|
216
|
+
|
|
217
|
+
|
|
186
218
|
this.$emit('loading', true) // let sidebarcontent wait for the requests
|
|
187
219
|
|
|
188
220
|
this.$emit("filterResults", filters); // emit filters for apps above sidebar
|
|
189
|
-
this.setCascader(
|
|
221
|
+
this.setCascader(filterKeys); //update our cascader v-model if we modified the event
|
|
190
222
|
this.makeCascadeLabelsClickable();
|
|
191
223
|
}
|
|
192
224
|
},
|
|
@@ -255,6 +287,28 @@ export default {
|
|
|
255
287
|
}
|
|
256
288
|
return event;
|
|
257
289
|
},
|
|
290
|
+
createDataTypeFacet: function(){
|
|
291
|
+
let dataFacet = {...this.facets[2]} // copy the 'Experiemental approach' facet
|
|
292
|
+
let count = this.facets.at(-1).id // get the last id count
|
|
293
|
+
|
|
294
|
+
// Step through the children that are valid data types, switch thier values
|
|
295
|
+
let newChildren = dataFacet.children.filter( el=> {
|
|
296
|
+
if (el.label === 'Scaffold' || el.label === 'Simulation' || el.label === 'Show all'){
|
|
297
|
+
el.key = el.label
|
|
298
|
+
el.id = count
|
|
299
|
+
el.value = el.value.replace('Experimental approach', 'Data type')
|
|
300
|
+
count++
|
|
301
|
+
return el
|
|
302
|
+
}
|
|
303
|
+
})
|
|
304
|
+
dataFacet.id = count
|
|
305
|
+
dataFacet.key = 'Data type'
|
|
306
|
+
// Add 'duplicate' so that the key is unique. This is removed in the cascade event for filtering
|
|
307
|
+
dataFacet.value += 'duplicate'
|
|
308
|
+
dataFacet.children = newChildren
|
|
309
|
+
dataFacet.label = 'Data type'
|
|
310
|
+
this.facets.push(dataFacet)
|
|
311
|
+
},
|
|
258
312
|
cascadeExpandChange: function (event) {
|
|
259
313
|
//work around as the expand item may change on modifying the cascade props
|
|
260
314
|
this.__expandItem__ = event;
|
|
@@ -358,6 +412,20 @@ export default {
|
|
|
358
412
|
padding-left: 16px;
|
|
359
413
|
}
|
|
360
414
|
|
|
415
|
+
.help {
|
|
416
|
+
width: 24px !important;
|
|
417
|
+
height: 24px;
|
|
418
|
+
transform: scale(1.1);
|
|
419
|
+
color: #8300bf;
|
|
420
|
+
cursor: pointer;
|
|
421
|
+
}
|
|
422
|
+
|
|
423
|
+
.popover {
|
|
424
|
+
color: rgb(48, 49, 51);
|
|
425
|
+
font-family: Asap;
|
|
426
|
+
margin: 12px;
|
|
427
|
+
}
|
|
428
|
+
|
|
361
429
|
.filter-icon-inside {
|
|
362
430
|
width: 12px !important;
|
|
363
431
|
height: 12px !important;
|
|
@@ -439,4 +507,51 @@ export default {
|
|
|
439
507
|
.cascader >>> .el-cascader-node__label {
|
|
440
508
|
text-align: left;
|
|
441
509
|
}
|
|
510
|
+
|
|
511
|
+
.filters >>> .el-popover {
|
|
512
|
+
background: #f3ecf6 !important;
|
|
513
|
+
border: 1px solid #8300BF;
|
|
514
|
+
border-radius: 4px;
|
|
515
|
+
color: #303133 !important;
|
|
516
|
+
font-size: 12px;
|
|
517
|
+
line-height: 18px;
|
|
518
|
+
|
|
519
|
+
|
|
520
|
+
}
|
|
521
|
+
|
|
522
|
+
.filters >>> .el-popover[x-placement^="top"] .popper__arrow {
|
|
523
|
+
border-top-color: #8300BF;
|
|
524
|
+
border-bottom-width: 0;
|
|
525
|
+
}
|
|
526
|
+
.filters >>> .el-popover[x-placement^="top"] .popper__arrow::after {
|
|
527
|
+
border-top-color: #f3ecf6;
|
|
528
|
+
border-bottom-width: 0;
|
|
529
|
+
}
|
|
530
|
+
|
|
531
|
+
.filters >>> .el-popover[x-placement^="bottom"] .popper__arrow {
|
|
532
|
+
border-top-width: 0;
|
|
533
|
+
border-bottom-color: #8300BF;
|
|
534
|
+
}
|
|
535
|
+
.filters >>> .el-popover[x-placement^="bottom"] .popper__arrow::after {
|
|
536
|
+
border-top-width: 0;
|
|
537
|
+
border-bottom-color: #f3ecf6;
|
|
538
|
+
}
|
|
539
|
+
|
|
540
|
+
.filters >>> .el-popover[x-placement^="right"] .popper__arrow {
|
|
541
|
+
border-right-color: #8300BF;
|
|
542
|
+
border-left-width: 0;
|
|
543
|
+
}
|
|
544
|
+
.filters >>> .el-popover[x-placement^="right"] .popper__arrow::after {
|
|
545
|
+
border-right-color: #f3ecf6;
|
|
546
|
+
border-left-width: 0;
|
|
547
|
+
}
|
|
548
|
+
|
|
549
|
+
.filters >>> .el-popover[x-placement^="left"] .popper__arrow {
|
|
550
|
+
border-right-width: 0;
|
|
551
|
+
border-left-color: #8300BF;
|
|
552
|
+
}
|
|
553
|
+
.filters >>> .el-popover[x-placement^="left"] .popper__arrow::after {
|
|
554
|
+
border-right-width: 0;
|
|
555
|
+
border-left-color: #f3ecf6;
|
|
556
|
+
}
|
|
442
557
|
</style>
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
>No results found - Please change your search / filter criteria.</div>
|
|
29
29
|
<div class="error-feedback" v-if="sciCrunchError">{{sciCrunchError}}</div>
|
|
30
30
|
<div v-for="o in results" :key="o.id" class="step-item">
|
|
31
|
-
<DatasetCard :entry="o" :envVars="envVars"></DatasetCard>
|
|
31
|
+
<DatasetCard :entry="o" :envVars="envVars" @contextUpdate="contextCardUpdate"></DatasetCard>
|
|
32
32
|
</div>
|
|
33
33
|
<el-pagination
|
|
34
34
|
class="pagination"
|
|
@@ -101,7 +101,8 @@ var initial_state = {
|
|
|
101
101
|
pageModel: 1,
|
|
102
102
|
start: 0,
|
|
103
103
|
hasSearched: false,
|
|
104
|
-
sciCrunchError: false
|
|
104
|
+
sciCrunchError: false,
|
|
105
|
+
contextCardEntry: undefined
|
|
105
106
|
};
|
|
106
107
|
|
|
107
108
|
export default {
|
|
@@ -120,10 +121,6 @@ export default {
|
|
|
120
121
|
type: Object,
|
|
121
122
|
default: () => initial_state
|
|
122
123
|
},
|
|
123
|
-
contextCardEntry: {
|
|
124
|
-
type: Object,
|
|
125
|
-
default: undefined
|
|
126
|
-
},
|
|
127
124
|
envVars: {
|
|
128
125
|
type: Object,
|
|
129
126
|
default: () => {}
|
|
@@ -153,6 +150,9 @@ export default {
|
|
|
153
150
|
}
|
|
154
151
|
},
|
|
155
152
|
methods: {
|
|
153
|
+
contextCardUpdate: function(val){
|
|
154
|
+
this.contextCardEntry = val
|
|
155
|
+
},
|
|
156
156
|
openSearch: function(filter, search='') {
|
|
157
157
|
this.searchInput = search;
|
|
158
158
|
this.resetPageNavigation();
|
|
@@ -277,6 +277,7 @@ export default {
|
|
|
277
277
|
doi: element.doi,
|
|
278
278
|
publishDate: element.publishDate,
|
|
279
279
|
scaffolds: element['abi-scaffold-metadata-file'] ? element['abi-scaffold-metadata-file'] : undefined,
|
|
280
|
+
contextualInformation: element['abi-contextual-information'].length > 0 ? element['abi-contextual-information'] : undefined,
|
|
280
281
|
additionalLinks: element.additionalLinks,
|
|
281
282
|
simulation: element.additionalLinks
|
|
282
283
|
? element.additionalLinks[0].description == 'Repository'
|