@abi-software/map-side-bar 2.4.0-alpha-1 → 2.4.0-isan-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.
Files changed (43) hide show
  1. package/.eslintrc.js +12 -12
  2. package/.postcssrc.json +5 -5
  3. package/LICENSE +201 -201
  4. package/README.md +168 -168
  5. package/cypress.config.js +23 -23
  6. package/dist/map-side-bar.js +9352 -15112
  7. package/dist/map-side-bar.umd.cjs +103 -50
  8. package/dist/style.css +1 -1
  9. package/package.json +77 -77
  10. package/reporter-config.json +9 -9
  11. package/src/App.vue +268 -266
  12. package/src/algolia/algolia.js +256 -255
  13. package/src/algolia/utils.js +105 -100
  14. package/src/assets/_variables.scss +43 -43
  15. package/src/assets/styles.scss +6 -6
  16. package/src/components/BadgesGroup.vue +124 -124
  17. package/src/components/ConnectivityInfo.vue +619 -619
  18. package/src/components/DatasetCard.vue +367 -367
  19. package/src/components/EventBus.js +3 -3
  20. package/src/components/ExternalResourceCard.vue +113 -113
  21. package/src/components/ImageGallery.vue +542 -542
  22. package/src/components/PMRDatasetCard.vue +317 -237
  23. package/src/components/SearchFilters.vue +1023 -1023
  24. package/src/components/SearchHistory.vue +175 -175
  25. package/src/components/SideBar.vue +440 -436
  26. package/src/components/SidebarContent.vue +706 -730
  27. package/src/components/Tabs.vue +145 -145
  28. package/src/components/index.js +8 -8
  29. package/src/components/species-map.js +8 -8
  30. package/src/components.d.ts +0 -1
  31. package/src/exampleConnectivityInput.js +291 -291
  32. package/src/flatmapQueries/flatmapQueries.js +220 -168
  33. package/src/main.js +9 -9
  34. package/src/mixins/S3Bucket.vue +37 -37
  35. package/src/mixins/mixedPageCalculation.vue +102 -78
  36. package/static.json +6 -6
  37. package/vite.config.js +55 -55
  38. package/vuese-generator.js +65 -65
  39. package/dist/data/pmr-sample.json +0 -3181
  40. package/public/data/pmr-sample.json +0 -3181
  41. package/src/components/FlatmapDatasetCard.vue +0 -171
  42. package/src/components/allPaths.js +0 -5928
  43. package/src/components/pmrTest.js +0 -4
@@ -1,145 +1,145 @@
1
- <template>
2
- <div class="tab-container">
3
- <div
4
- class="title"
5
- v-for="title in tabTitles"
6
- :key="title.id"
7
- :class="{ 'active-tab': title.id == activeId }"
8
- >
9
- <div
10
- class="title-text-table"
11
- v-bind:class="{ highlightText: title.id == activeId }"
12
- v-on:click="titleClicked(title.id, title.type)"
13
- >
14
- <div class="title-text">
15
- {{ title.title }}
16
- </div>
17
- </div>
18
- <el-button
19
- v-if="title.id === 2"
20
- @click="tabClose(title.id)"
21
- class="button-tab-close"
22
- aria-label="Close"
23
- >
24
- &times;
25
- <span class="visually-hidden">Close</span>
26
- </el-button>
27
- </div>
28
- </div>
29
- </template>
30
-
31
- <script>
32
- /* eslint-disable no-alert, no-console */
33
-
34
- export default {
35
- name: 'Tabs',
36
- props: {
37
- tabTitles: {
38
- type: Array,
39
- default: () => [],
40
- },
41
- activeId: {
42
- type: Number,
43
- default: 1,
44
- },
45
- },
46
- methods: {
47
- titleClicked: function (id, type) {
48
- this.$emit('titleClicked', {id, type})
49
- },
50
- tabClose: function (id) {
51
- this.$emit('tab-close', id);
52
- },
53
- },
54
- }
55
- </script>
56
-
57
- <style lang="scss" scoped>
58
- $tab-height: 30px;
59
-
60
- .tab-container {
61
- height: $tab-height;
62
- display: flex;
63
- flex-direction: row;
64
- }
65
-
66
- .title {
67
- height: $tab-height;
68
- border: 1px solid var(--el-border-color);
69
- border-top-color: transparent;
70
- background-color: white;
71
- display: flex;
72
- width: fit-content;
73
- align-items: center;
74
- position: relative;
75
- cursor: pointer;
76
- }
77
-
78
- .title-text {
79
- text-align: center;
80
- display: table-cell;
81
- vertical-align: middle;
82
- font-size: 14px;
83
- padding: 0 1rem;
84
- }
85
-
86
- .title-text-table {
87
- display: table;
88
- height: 100%;
89
- width: 100%;
90
- }
91
-
92
- .parent-dialog:hover .title-text {
93
- color: $app-primary-color;
94
- }
95
-
96
- .title:hover,
97
- .active-tab {
98
- background-color: #f9f2fc;
99
- border: solid #8300bf;
100
- border-width: 1px 1px .125em;
101
- color: #8300bf;
102
- font-weight: 500;
103
- }
104
-
105
- .highlightText {
106
- color: $app-primary-color;
107
- }
108
-
109
- .button-tab-close {
110
- width: 20px !important;
111
- height: 20px !important;
112
- line-height: 20px !important;
113
- padding: 0 !important;
114
- padding-right: 4px !important;
115
- font-size: 24px !important;
116
- color: $app-primary-color !important;
117
- border: 0 none !important;
118
- box-shadow: none !important;
119
- outline: none !important;
120
- background-color: transparent !important;
121
-
122
- :deep(> span) {
123
- height: $tab-height - 2 !important; // tab height minus border
124
- font-family: Arial !important; // to fix font alignment on different browsers
125
- }
126
-
127
- &:hover,
128
- &:focus {
129
- border: 0 none !important;
130
- outline: none !important;
131
- box-shadow: none !important;
132
- background-color: transparent !important;
133
- }
134
- }
135
-
136
- .visually-hidden {
137
- clip: rect(0 0 0 0);
138
- clip-path: inset(50%);
139
- height: 1px;
140
- overflow: hidden;
141
- position: absolute;
142
- white-space: nowrap;
143
- width: 1px;
144
- }
145
- </style>
1
+ <template>
2
+ <div class="tab-container">
3
+ <div
4
+ class="title"
5
+ v-for="title in tabTitles"
6
+ :key="title.id"
7
+ :class="{ 'active-tab': title.id == activeId }"
8
+ >
9
+ <div
10
+ class="title-text-table"
11
+ v-bind:class="{ highlightText: title.id == activeId }"
12
+ v-on:click="titleClicked(title.id, title.type)"
13
+ >
14
+ <div class="title-text">
15
+ {{ title.title }}
16
+ </div>
17
+ </div>
18
+ <el-button
19
+ v-if="title.id === 2"
20
+ @click="tabClose(title.id)"
21
+ class="button-tab-close"
22
+ aria-label="Close"
23
+ >
24
+ &times;
25
+ <span class="visually-hidden">Close</span>
26
+ </el-button>
27
+ </div>
28
+ </div>
29
+ </template>
30
+
31
+ <script>
32
+ /* eslint-disable no-alert, no-console */
33
+
34
+ export default {
35
+ name: 'Tabs',
36
+ props: {
37
+ tabTitles: {
38
+ type: Array,
39
+ default: () => [],
40
+ },
41
+ activeId: {
42
+ type: Number,
43
+ default: 1,
44
+ },
45
+ },
46
+ methods: {
47
+ titleClicked: function (id, type) {
48
+ this.$emit('titleClicked', {id, type})
49
+ },
50
+ tabClose: function (id) {
51
+ this.$emit('tab-close', id);
52
+ },
53
+ },
54
+ }
55
+ </script>
56
+
57
+ <style lang="scss" scoped>
58
+ $tab-height: 30px;
59
+
60
+ .tab-container {
61
+ height: $tab-height;
62
+ display: flex;
63
+ flex-direction: row;
64
+ }
65
+
66
+ .title {
67
+ height: $tab-height;
68
+ border: 1px solid var(--el-border-color);
69
+ border-top-color: transparent;
70
+ background-color: white;
71
+ display: flex;
72
+ width: fit-content;
73
+ align-items: center;
74
+ position: relative;
75
+ cursor: pointer;
76
+ }
77
+
78
+ .title-text {
79
+ text-align: center;
80
+ display: table-cell;
81
+ vertical-align: middle;
82
+ font-size: 14px;
83
+ padding: 0 1rem;
84
+ }
85
+
86
+ .title-text-table {
87
+ display: table;
88
+ height: 100%;
89
+ width: 100%;
90
+ }
91
+
92
+ .parent-dialog:hover .title-text {
93
+ color: $app-primary-color;
94
+ }
95
+
96
+ .title:hover,
97
+ .active-tab {
98
+ background-color: #f9f2fc;
99
+ border: solid #8300bf;
100
+ border-width: 1px 1px .125em;
101
+ color: #8300bf;
102
+ font-weight: 500;
103
+ }
104
+
105
+ .highlightText {
106
+ color: $app-primary-color;
107
+ }
108
+
109
+ .button-tab-close {
110
+ width: 20px !important;
111
+ height: 20px !important;
112
+ line-height: 20px !important;
113
+ padding: 0 !important;
114
+ padding-right: 4px !important;
115
+ font-size: 24px !important;
116
+ color: $app-primary-color !important;
117
+ border: 0 none !important;
118
+ box-shadow: none !important;
119
+ outline: none !important;
120
+ background-color: transparent !important;
121
+
122
+ :deep(> span) {
123
+ height: $tab-height - 2 !important; // tab height minus border
124
+ font-family: Arial !important; // to fix font alignment on different browsers
125
+ }
126
+
127
+ &:hover,
128
+ &:focus {
129
+ border: 0 none !important;
130
+ outline: none !important;
131
+ box-shadow: none !important;
132
+ background-color: transparent !important;
133
+ }
134
+ }
135
+
136
+ .visually-hidden {
137
+ clip: rect(0 0 0 0);
138
+ clip-path: inset(50%);
139
+ height: 1px;
140
+ overflow: hidden;
141
+ position: absolute;
142
+ white-space: nowrap;
143
+ width: 1px;
144
+ }
145
+ </style>
@@ -1,8 +1,8 @@
1
- import SideBar from "./SideBar.vue"
2
-
3
- export {
4
- SideBar
5
- };
6
-
7
-
8
-
1
+ import SideBar from "./SideBar.vue"
2
+
3
+ export {
4
+ SideBar
5
+ };
6
+
7
+
8
+
@@ -1,8 +1,8 @@
1
- export default {
2
- 'homo sapiens': 'Human',
3
- 'rattus norvegicus': 'Rat',
4
- 'mus musculus': 'Mouse',
5
- 'sus scrofa domesticus': 'Pig',
6
- 'sus scrofa': 'Boar',
7
- 'felis catus': 'Cat'
8
- }
1
+ export default {
2
+ 'homo sapiens': 'Human',
3
+ 'rattus norvegicus': 'Rat',
4
+ 'mus musculus': 'Mouse',
5
+ 'sus scrofa domesticus': 'Pig',
6
+ 'sus scrofa': 'Boar',
7
+ 'felis catus': 'Cat'
8
+ }
@@ -26,7 +26,6 @@ declare module 'vue' {
26
26
  ElSelect: typeof import('element-plus/es')['ElSelect']
27
27
  ElTag: typeof import('element-plus/es')['ElTag']
28
28
  ExternalResourceCard: typeof import('./components/ExternalResourceCard.vue')['default']
29
- FlatmapDatasetCard: typeof import('./components/FlatmapDatasetCard.vue')['default']
30
29
  ImageGallery: typeof import('./components/ImageGallery.vue')['default']
31
30
  PMRDatasetCard: typeof import('./components/PMRDatasetCard.vue')['default']
32
31
  SearchFilters: typeof import('./components/SearchFilters.vue')['default']