Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sprint 35 QA Fixes #803

Merged
merged 2 commits into from
Mar 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file added assets/heal.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
50 changes: 31 additions & 19 deletions components/RepositoryCard/RepositoryCard.vue
Original file line number Diff line number Diff line change
@@ -1,24 +1,37 @@
<template>
<el-card :style="{ border: 'none', maxWidth: width + 'rem' }" class="card centered">
<div class="image-container">
<img class="thumbnail" :src="thumbnailUrl" alt="thumbnail loading ..." />
<el-card
class="mr-8"
:style="{ border: 'none', maxWidth: width + 'rem', minWidth: width + 'rem' }"
:body-style="{
'height': '90%',
'display': 'flex',
'flex-direction': 'column',
'justify-content': 'space-between',
'text-align': 'center' }"
>
<div>
<div class="image-container">
<img class="thumbnail" :src="thumbnailUrl" alt="thumbnail loading ..." />
</div>
<div class="body1">
{{description}}
</div>
</div>
<div class="body1 mb-16">
{{description}}
<div class="status-container">
<div class="body1 mb-16">
Status: <b>{{ status }}</b>
</div>
<a :href="buttonLink" target="_blank">
<el-button class='secondary'>
Launch Pennsieve <svg-icon icon="icon-open" height="16" width="16" />
</el-button>
</a>
</div>
<div class="body1 mb-16">
Status: <b>{{ status }}</b>
</div>
<a :href="buttonLink" target="_blank">
<el-button class='secondary'>
Launch Pennsieve <svg-icon icon="icon-open" height="16" width="16" />
</el-button>
</a>
</el-card>
</template>
<script>
export default {
name: 'RespositoryCard',
name: 'RepositoryCard',
props: {
width: {
type: Number,
Expand All @@ -44,14 +57,13 @@ export default {
}
</script>
<style lang="scss" scoped>
.centered {
text-align: center;
}
.image-container {
max-width: 75%;
margin: auto;
img {
height: 5rem;
width: 100%;
aspect-ratio: 1;
object-fit: contain;
}
}
</style>
</style>
4 changes: 3 additions & 1 deletion nuxt.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,9 @@ const config = {
SHOW_DATASET_SUBMISSION_FEATURE: process.env.SHOW_DATASET_SUBMISSION_FEATURE || 'false',
GOOGLE_TAG_MANAGER_ID: process.env.GOOGLE_TAG_MANAGER_ID || 'GTM-TPT2CVCS',
SPARC_ORG_ID: process.env.SPARC_ORG_ID || 'N:organization:618e8dd9-f8d2-4dc4-9abb-c6aaab2e78a0',
REJOIN_ORG_ID: process.env.REJOIN_ORG_ID || 'N:organization:f08e188e-2316-4668-ae2c-8a20dc88502f'
REJOIN_ORG_ID: process.env.REJOIN_ORG_ID || 'N:organization:f08e188e-2316-4668-ae2c-8a20dc88502f',
PRECISION_ORG_ID: process.env.PRECISION_ORG_ID || 'N:organization:98d6e84c-9a27-48f8-974f-93c0cca15aae',
PENNSIEVE_URL: process.env.PENNSIEVE_URL || 'https://app.pennsieve.io'
},

serverMiddleware: [
Expand Down
8 changes: 7 additions & 1 deletion pages/user/profile/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
:thumbnailUrl="organization.logo"
:description="getOrganizationDescription(organization)"
:status="organization.status"
buttonLink="https://pennsieve.io"
:buttonLink="getButtonLink(organization)"
/>
</template>
</div>
Expand Down Expand Up @@ -416,6 +416,9 @@ export default {
getOrganizationDescription(org) {
return `Open the ${org.name} workspace in Pennsieve`
},
getButtonLink(org) {
return `${process.env.PENNSIEVE_URL}/${org.id}/datasets`
},
getDownloadsCount(id) {
let numDownloads = 0
this.downloadsSummary.filter(download => download.datasetId == id).forEach(item => {
Expand Down Expand Up @@ -592,6 +595,9 @@ a {
}
.org-container {
display: flex;
@media (max-width: 49em) {
flex-direction: column;
}
}
::v-deep .popover {
background-color: #f9f2fc;
Expand Down
16 changes: 11 additions & 5 deletions static/js/organizations.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import sparcLogo from '@/assets/logo-sparc-wave-primary.svg'
import rejoinLogo from '@/assets/rejoin.jpg'
import precisionLogo from '@/assets/heal.png'

const organizationsData = [
{
Expand All @@ -11,6 +12,11 @@ const organizationsData = [
name: 'RE-JOIN',
id: process.env.REJOIN_ORG_ID,
logo: rejoinLogo
},
{
name: 'HEAL PRECISION',
id: process.env.PRECISION_ORG_ID,
logo: precisionLogo
}
]

Expand All @@ -21,11 +27,11 @@ export const getOrganizationInfo = id => {

export const getOrganizationStatus = org => {
if (org.isOwner)
return 'Owner Access'
return 'Owner'
else if (org.isAdmin)
return 'Admin Access'
return 'Admin'
else if (org.isGuest)
return 'Guest Access'
return 'Guest'
else
return 'Read Access'
}
return 'Collaborator'
}
Loading