@abi-software/map-side-bar 2.14.8-demo.5 → 2.14.8-demo.6
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.js +812 -812
- package/dist/map-side-bar.umd.cjs +19 -19
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/src/App.vue +0 -1
- package/src/components/ConnectivityInfo.vue +8 -6
package/package.json
CHANGED
package/src/App.vue
CHANGED
|
@@ -137,7 +137,6 @@ export default {
|
|
|
137
137
|
ROOT_URL: import.meta.env.VITE_APP_ROOT_URL,
|
|
138
138
|
FLATMAPAPI_LOCATION: import.meta.env.VITE_FLATMAPAPI_LOCATION,
|
|
139
139
|
CELL_CARDS_API: import.meta.env.VITE_APP_CELL_CARDS_API,
|
|
140
|
-
CORS_PROXY_API: import.meta.env.VITE_CORS_PROXY_API,
|
|
141
140
|
},
|
|
142
141
|
connectivityEntry: [],
|
|
143
142
|
createData: {
|
|
@@ -899,18 +899,20 @@ export default {
|
|
|
899
899
|
this.expertConsultants = this.expertConsultantURLs.map(url => ({ name: '', url }));
|
|
900
900
|
|
|
901
901
|
for (const url of this.expertConsultantURLs) {
|
|
902
|
-
const
|
|
903
|
-
const
|
|
902
|
+
const scicrunchBase = 'https://scicrunch.org';
|
|
903
|
+
const orcidBase = 'https://orcid.org';
|
|
904
|
+
const orcidAPIBase = 'https://pub.orcid.org/v2.1';
|
|
905
|
+
const apiLocationBase = (this.envVars.API_LOCATION ?? '').replace(/\/?$/, '/');
|
|
906
|
+
const isScicrunchURL = url.startsWith(scicrunchBase);
|
|
907
|
+
const isOrcidURL = url.startsWith(orcidBase);
|
|
904
908
|
|
|
905
909
|
if (!isScicrunchURL && !isOrcidURL) {
|
|
906
910
|
console.warn(`Unsupported expert consultant URL: ${url}`);
|
|
907
911
|
continue;
|
|
908
912
|
}
|
|
909
913
|
|
|
910
|
-
|
|
911
|
-
const
|
|
912
|
-
const scicrunchAPIURL = (targetURL) => `${corsProxy}?target=${targetURL}.json`;
|
|
913
|
-
const orcidAPIURL = (targetURL) => targetURL.replace('orcid.org', 'pub.orcid.org/v2.1');
|
|
914
|
+
const scicrunchAPIURL = (targetURL) => targetURL.replace(scicrunchBase, `${apiLocationBase}scicrunch`);
|
|
915
|
+
const orcidAPIURL = (targetURL) => targetURL.replace(orcidBase, orcidAPIBase);
|
|
914
916
|
const APIURL = isScicrunchURL ? scicrunchAPIURL(url) : orcidAPIURL(url);
|
|
915
917
|
|
|
916
918
|
try {
|