-
Notifications
You must be signed in to change notification settings - Fork 0
/
bubbleplot.html
54 lines (53 loc) · 1.8 KB
/
bubbleplot.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
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
51
52
53
54
<html>
<head>
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.4.1/css/bootstrap.min.css">
<link rel="stylesheet" href="../dist/css/style.min.css"/>
<link rel="stylesheet" href="https://unpkg.com/leaflet@1.6.0/dist/leaflet.css" />
<title>Vue Bubble plot</title>
</head>
<body>
<div id="app" class="container mt-5">
<h1 class="my-5">Vue Bubble plot</h1>
<div class="row">
<bubble-plot :labels="labels"
:features="features"
:feature-levels="featureLevels"
:indicators="indicators"
:chartdata="chartData"
:filters="filters"
:selections="selections"
area-filter-id="area"
@update="updateSelections"></bubble-plot>
</div>
</div>
<script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
<script src="../dist/js/vue-maps.min.js"></script>
<script src="./data.js"></script>
<script src="./features.js"></script>
<script src="./metadata.js"></script>
<script>
const labels = {
filtersLabel: "Filters",
colorIndicatorLabel: "Colour Indicator",
sizeIndicatorLabel: "Size Indicator",
detailLabel: "Detail"
};
new Vue({
el: "#app",
data: {
labels: labels,
features: features,
featureLevels: featureLevels,
indicators: indicators,
chartData: data,
filters: filters,
selections: selections
},
methods: {
updateSelections: function(updated) {
this.selections = {...this.selections, ...updated}
}
}
});
</script>
</body>