Skip to content

Commit

Permalink
Improve app mode, v0.14.0-beta.4
Browse files Browse the repository at this point in the history
  • Loading branch information
m-mohr committed Jan 2, 2025
1 parent 076cc33 commit 279c649
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 6 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@openeo/web-editor",
"version": "0.14.0-beta.3",
"version": "0.14.0-beta.4",
"apiVersions": [
"1.0.0-rc.2",
"1.0.0",
Expand Down
5 changes: 4 additions & 1 deletion src/Page.vue
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,10 @@ export default {
this.setCollectionPreview(Utils.param('preview-collection'));
const resultUrl = Utils.param('result');
const resultType = Utils.param('result-type') || 'job';
let resultType = 'job';
if (Utils.param('app~service')) {
resultType = 'service';
}
if (resultUrl) {
this.setAppMode({
resultUrl,
Expand Down
1 change: 0 additions & 1 deletion src/components/share/ShareEditor.vue
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ export default {
editorUrl() {
const url = new URL(window.location.href);
const query = new URLSearchParams(url.search);
query.set('result-type', this.type);
query.set('result', this.url); // Pass canonical link, implies discover = 1
if (this.type === 'service') {
query.set('app~service', this.context.type);
Expand Down
10 changes: 7 additions & 3 deletions src/components/viewer/MetadataViewer.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
<div class="metadataViewer">
<Collection v-if="isCollection" :data="data">
<template #spatial-extents="p">
<MapExtentViewer class="jobMap" :footprint="p.extents"></MapExtentViewer>
<MapExtentViewer class="resultMap" :footprint="p.extents"></MapExtentViewer>
</template>
</Collection>
<Item v-else-if="isItem" :data="data">
<template #location="p">
<MapExtentViewer class="jobMap" :footprint="p.geometry || p.bbox"></MapExtentViewer>
<MapExtentViewer class="resultMap" :footprint="p.geometry || p.bbox"></MapExtentViewer>
</template>
</Item>
<ul class="list">
<ul v-else class="list">
<StacAsset v-for="(asset, id) in data.assets" :key="id" :asset="asset" :id="id" :context="data" />
</ul>
</div>
Expand Down Expand Up @@ -58,4 +58,8 @@ export default {
height: 98%;
padding: 1%;
}
.resultMap {
height: 300px;
max-width: 600px;
}
</style>

0 comments on commit 279c649

Please sign in to comment.