Skip to content

Commit

Permalink
Reuse datasetimage display for appropriate datatypes
Browse files Browse the repository at this point in the history
Minor tweaking of pre
  • Loading branch information
dannon committed Apr 11, 2024
1 parent dd9af46 commit ea455b3
Showing 1 changed file with 9 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,16 +61,13 @@
<div v-else-if="error">{{ error }}</div>
<div v-else :class="contentClass">
<b-embed
v-if="
isSubTypeOfAny(
datasetType,
['pdf', 'html', 'galaxy.datatypes.images.Image'],
datatypesModel
)
"
v-if="isSubTypeOfAny(datasetType, ['pdf', 'html'], datatypesModel)"
type="iframe"
aspect="16by9"
:src="displayUrl" />
<HistoryDatasetAsImage
v-else-if="isSubTypeOfAny(datasetType, ['galaxy.datatypes.images.Image'], datatypesModel)"
:args="args" />
<div v-else-if="itemContent.item_data">
<div v-if="isSubTypeOfAny(datasetType, ['tabular'], datatypesModel)">
<UrlDataProvider
Expand All @@ -87,8 +84,8 @@
</UrlDataProvider>
</div>
<pre v-else>
<code class="word-wrap-normal">{{ itemContent.item_data }}</code>
</pre>
<code class="word-wrap-normal">{{ itemContent.item_data }}</code>
</pre>
</div>
<div v-else>No content found.</div>
<b-link v-if="itemContent.truncated" :href="itemContent.item_url"> Show More... </b-link>
Expand All @@ -105,10 +102,13 @@ import LoadingSpan from "components/LoadingSpan";
import { UrlDataProvider } from "components/providers/UrlDataProvider";
import { getAppRoot } from "onload/loadConfig";
import HistoryDatasetAsImage from "./HistoryDatasetAsImage.vue";
export default {
components: {
LoadingSpan,
UrlDataProvider,
HistoryDatasetAsImage,
},
props: {
args: {
Expand Down

0 comments on commit ea455b3

Please sign in to comment.