Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • mdm-lab/wiki
  • hvaysset/wiki
  • jsousa/wiki
  • tclabby/wiki
4 results
Show changes
Commits on Source (14)
Showing
with 333 additions and 76 deletions
......@@ -17,8 +17,8 @@ stages:
.build:
stage: build
image: docker:24
needs:
- format-pfam
# needs:
# - format-pfam
variables:
CONTEXT: "."
DOCKERFILE: "Dockerfile"
......@@ -56,6 +56,8 @@ get-pfam:
artifacts:
paths:
- Pfam-A.hmm.dat
rules:
- if: $CI_COMMIT_BRANCH == "main"
format-pfam:
image: python:3.11
......@@ -72,6 +74,8 @@ format-pfam:
artifacts:
paths:
- content/_partials/_pfam-a-hmm.csv
rules:
- if: $CI_COMMIT_BRANCH == "main"
build:dev:
extends: .build
......
<script setup lang="ts">
const { surround } = useContent();
const { mobile } = useDisplay();
</script>
<template>
......
......@@ -26,53 +26,42 @@ function constructPfamUrl(pfam: string) {
}
</script>
<template>
<v-card flat class="d-flex justify-start align-center">
<template v-for="(pfam, index) in pfams" :key="pfam">
<v-chip
v-if="index < itemsToDisplay || itemsToDisplay < 0"
:href="constructPfamUrl(pfam)"
target="_blank"
color="info"
class="mr-1"
>
{{ pfam }}
<v-tooltip activator="parent" location="top">{{
pfamStore.get(pfam)?.DE ?? "none"
}}</v-tooltip></v-chip
>
<!-- class="d-inline-flex justify-start align-center" -->
<v-row>
<v-col>
<v-card flat color="transparent" density="compact" rounded="false">
<template v-for="(pfam, index) in pfams" :key="pfam">
<v-chip v-if="index < itemsToDisplay || itemsToDisplay < 0" :href="constructPfamUrl(pfam)" target="_blank"
color="info" class="mr-1 mb-1">
{{ pfam }}
<v-tooltip activator="parent" location="top">{{
pfamStore.get(pfam)?.DE ?? "none"
}}</v-tooltip></v-chip>
<template v-if="index === itemsToDisplay">
<v-chip
v-if="!show"
variant="text"
class="text-grey text-caption align-self-center px-1"
@click="show = !show"
>
(+{{ pfams.length - itemsToDisplay }} others)
</v-chip>
</template>
</template>
<template v-if="pfams.length > itemsToDisplay && show">
<template v-for="(pfam, index) in pfams" :key="pfam">
<v-chip
v-if="index >= itemsToDisplay"
:href="constructPfamUrl(pfam)"
target="_blank"
color="info"
class="mr-1"
>
{{ pfam }}
<v-tooltip activator="parent" location="top">{{
pfamStore.get(pfam)?.DE ?? "none"
}}</v-tooltip></v-chip
>
</template>
</template>
<v-btn
v-if="itemsToDisplay < pfams.length"
variant="text"
:icon="show ? 'mdi-chevron-up' : 'mdi-chevron-down'"
@click="show = !show"
></v-btn>
</v-card>
<template v-if="index === itemsToDisplay">
<span>
<v-chip v-if="!show" variant="text" class="text-grey text-caption align-self-center px-1 "
@click="show = !show">
(+{{ pfams.length - itemsToDisplay }} others)
</v-chip>
<v-btn v-if="itemsToDisplay < pfams.length && !show" variant="text" :icon="'mdi-chevron-down'"
@click="show = !show"></v-btn>
</span>
</template>
</template>
<template v-if="pfams.length > itemsToDisplay && show">
<template v-for="(pfam, index) in pfams" :key="pfam">
<v-chip v-if="index >= itemsToDisplay" :href="constructPfamUrl(pfam)" target="_blank" color="info"
class="mr-1 mb-1">
{{ pfam }}
<v-tooltip activator="parent" location="top">{{
pfamStore.get(pfam)?.DE ?? "none"
}}</v-tooltip></v-chip>
</template>
</template>
<v-btn v-if="itemsToDisplay < pfams.length && show" variant="text" :icon="'mdi-chevron-up'"
@click="show = !show"></v-btn>
</v-card>
</v-col>
</v-row>
</template>
\ No newline at end of file
......@@ -37,7 +37,7 @@ const { initPfam } = usePfamStore();
initPfam();
</script>
<template>
<v-card>
<v-card >
<v-toolbar density="compact">
<v-toolbar-title>Defense Systems</v-toolbar-title>
......@@ -58,14 +58,7 @@ initPfam();
</template>
<template #[`item.PFAM`]="{ item }">
<pfam-chips v-if="item.columns?.PFAM" :pfam-string="item.columns.PFAM"></pfam-chips>
</template>
<template #expanded-row="{ columns, item }">
<tr>
<td :colspan="columns.length" class="v-data-table__td v-data-table-column--align-start">
<pfam-chips :pfam-string="item.columns.PFAM" :items-to-display="-1"></pfam-chips>
</td>
</tr>
<pfam-chips v-if="item?.PFAM" :pfam-string="item.PFAM"></pfam-chips>
</template>
</v-data-table-virtual>
</v-card>
......
......@@ -3,34 +3,66 @@ import { withTrailingSlash, withLeadingSlash, joinURL } from 'ufo'
import { useRuntimeConfig, computed } from '#imports'
export interface Props {
height?: number
dataUrl: string
dataUrls?: string[]
dataUrl?: string
}
// const selectedPdb = ref('')
const refinedDataUrls = computed(() => {
const refinedDataUrl = computed(() => {
if (props.dataUrl?.startsWith('/') && !props.dataUrl.startsWith('//')) {
const _base = withLeadingSlash(withTrailingSlash(useRuntimeConfig().app.baseURL))
if (_base !== '/' && !props.dataUrl.startsWith(_base)) {
return joinURL(_base, props.dataUrl)
function refinedUrl(url: string) {
if (url?.startsWith('/') && !url.startsWith('//')) {
const _base = withLeadingSlash(withTrailingSlash(useRuntimeConfig().app.baseURL))
if (_base !== '/' && !url.startsWith(_base)) {
return joinURL(_base, url)
}
}
return url
}
return props.dataUrl
let urls: string[] = []
if (props?.dataUrls && props?.dataUrls?.length > 0) {
urls = [...props.dataUrls.map((dataUrl) => {
return refinedUrl(dataUrl)
})]
}
if (props?.dataUrl) {
urls = [...urls, refinedUrl(props.dataUrl)]
}
return urls
})
// const selectedPdb = ref(refinedDataUrls.value?.length > 0 ? refinedDataUrls.value[0] : null)
const props = withDefaults(defineProps<Props>(), {
height: 600,
})
const { width } = useDisplay()
const { width, height } = useDisplay()
const maxWidth = ref(1300)
const dialog = ref(false)
// const show = ref(false)
const computedWidth = computed(() => {
if (width > maxWidth) return maxWidth
return width
})
const computedHeight = computed(() => {
return height.value - 250
})
function closeStructure() {
selectedPdb.value = null
dialog.value = false
}
useHead({
link: [
{
......@@ -54,15 +86,62 @@ useHead({
]
})
const pdbeMolstarComponent = ref(null)
// const selectedPdb = ref("/wiki/avs/AVAST_I,AVAST_I__Avs1A,0,V-plddts_85.07081.pdb")
const selectedPdb = ref(null)
watch(selectedPdb, (selectedPdb, prevSelectPdb) => {
if (selectedPdb !== null) {
dialog.value = true
if (pdbeMolstarComponent.value?.viewerInstance) {
const viewerInstance = pdbeMolstarComponent.value.viewerInstance
// show.value = true
const customData = { url: selectedPdb, format: "pdb", binary: false }
viewerInstance.visual.update({ customData })
}
}
})
</script>
<template>
<v-sheet class="d-flex align-center justify-center flex-wrap text-center mx-auto px-4 my-3" height="500"
:max-width="1300" :width="computedWidth - 950" position="relative">
<pdbe-molstar :custom-data-url="refinedDataUrl" custom-data-format="pdb" hide-expand-icon="true"
hide-controls="true" landscape="true" sequence-panel></pdbe-molstar>
</v-sheet>
<v-row><v-col><v-select v-model="selectedPdb" label="Select PDB" :items="refinedDataUrls"
hide-details="auto"></v-select></v-col></v-row>
<v-row justify="center">
<v-dialog v-model="dialog" transition="dialog-bottom-transition" fullscreen :scrim="false">
<v-card flat :rounded="false">
<v-toolbar>
<v-toolbar-title>Strucutures</v-toolbar-title>
<v-select v-model="selectedPdb" label="Select PDB" :items="refinedDataUrls"
hide-details="auto"></v-select>
<v-spacer></v-spacer>
<v-btn :disabled="!selectedPdb" icon="md:download" :href="selectedPdb"></v-btn>
<v-btn icon @click="closeStructure">
<v-icon>mdi-close</v-icon>
</v-btn>
</v-toolbar>
<v-card-text>
<v-sheet v-if="selectedPdb"
class="d-flex align-center justify-center flex-wrap text-center mx-auto px-4 my-3"
:height="computedHeight" :max-width="1300" :width="computedWidth" position="relative">
<pdbe-molstar ref="pdbeMolstarComponent" hide-controls :custom-data-url="selectedPdb"
custom-data-format="pdb"></pdbe-molstar>
</v-sheet>
</v-card-text>
</v-card>
</v-dialog>
</v-row>
</template>
......
......@@ -89,14 +89,14 @@ export function useFetchArticle(doi: string) {
if (store.articles.size === 0) {
const localArticles = await queryContent('/_partials/_articles').where({ _partial: true }).findOne()
if (localArticles.body && store.articles.size <= 0) {
for (const article of localArticles.body) {
console.log(localArticles)
if (localArticles?.articles && store.articles.size <= 0) {
for (const article of localArticles.articles) {
store.add(article)
}
}
}
if (store.articles.has(doi)) {
srcArticle.value = store.articles.get(doi)
return
......
......@@ -34,6 +34,33 @@ Among the 22k complete genomes of RefSeq, this system is present in 50 genomes (
*Proportion of genome encoding the AbiA system for the 14 phyla with more than 50 genomes in the RefSeq database.* *Pie chart of the repartition of all the subsystems found in the RefSeq database.*
## Structure
### AbiA_large
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abia/AbiA_large__AbiA_large-plddts_90.82916.pdb
---
::
### AbiA_small
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abia/AbiA_small,AbiA_small__AbiA_SLATT,0,DF-plddts_94.13374.pdb
---
::
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abia/AbiA_small,AbiA_small__AbiA_small,0,DF-plddts_89.82347.pdb
---
::
## Experimental validation
AbiA systems were experimentally validated using:
......
......@@ -29,6 +29,17 @@ Among the 22k complete genomes of RefSeq, this system is present in 13 genomes (
*Proportion of genome encoding the AbiB system for the 14 phyla with more than 50 genomes in the RefSeq database.*
## Structure
### AbiB
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abib/AbiB__AbiB-plddts_74.5545.pdb
---
::
## Experimental validation
AbiB systems were experimentally validated using:
......
......@@ -30,6 +30,17 @@ Among the 22k complete genomes of RefSeq, this system is present in 196 genomes
*Proportion of genome encoding the AbiC system for the 14 phyla with more than 50 genomes in the RefSeq database.*
## Structure
### AbiC
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abic/AbiC__AbiC-plddts_83.80335.pdb
---
::
## Experimental validation
AbiC systems were experimentally validated using:
......
......@@ -30,6 +30,17 @@ Among the 22k complete genomes of RefSeq, this system is present in 2748 genomes
*Proportion of genome encoding the AbiD system for the 14 phyla with more than 50 genomes in the RefSeq database.*
## Structure
### AbiD
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abid/AbiD__AbiD-plddts_91.87407.pdb
---
::
## Experimental validation
AbiD systems were experimentally validated using:
......
......@@ -42,6 +42,24 @@ Among the 22k complete genomes of RefSeq, this system is present in 3742 genomes
*Proportion of genome encoding the AbiE system for the 14 phyla with more than 50 genomes in the RefSeq database.*
## Structure
### AbiE
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abie/AbiE,AbiE__AbiEi,0,V-plddts_85.81224.pdb
---
::
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abie/AbiE,AbiE__AbiEii,0,V-plddts_90.73768.pdb
---
::
## Experimental validation
AbiE systems were experimentally validated using:
......
......@@ -30,6 +30,24 @@ Among the 22k complete genomes of RefSeq, this system is present in 33 genomes (
*Proportion of genome encoding the AbiG system for the 14 phyla with more than 50 genomes in the RefSeq database.*
## Structure
### AbiG
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abig/AbiG,AbiG__AbiGi,0,V-plddts_92.08021.pdb
---
::
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abig/AbiG,AbiG__AbiGii,0,V-plddts_88.01846.pdb
---
::
## Experimental validation
AbiG systems were experimentally validated using:
......
......@@ -32,6 +32,17 @@ Among the 22k complete genomes of RefSeq, this system is present in 1277 genomes
*Proportion of genome encoding the AbiH system for the 14 phyla with more than 50 genomes in the RefSeq database.*
## Structure
### AbiH
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abih/AbiH__AbiH-plddts_91.3485.pdb
---
::
## Experimental validation
AbiH systems were experimentally validated using:
......
......@@ -31,6 +31,17 @@ Among the 22k complete genomes of RefSeq, this system is present in 8 genomes (0
*Proportion of genome encoding the AbiI system for the 14 phyla with more than 50 genomes in the RefSeq database.*
## Structure
### AbiI
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abii/AbiI__AbiI-plddts_90.31131.pdb
---
::
## Experimental validation
AbiI systems were experimentally validated using:
......
......@@ -32,6 +32,17 @@ Among the 22k complete genomes of RefSeq, this system is present in 807 genomes
*Proportion of genome encoding the AbiJ system for the 14 phyla with more than 50 genomes in the RefSeq database.*
## Structure
### AbiJ
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abij/AbiJ__AbiJ-plddts_85.12535.pdb
---
::
## Experimental validation
AbiJ systems were experimentally validated using:
......
......@@ -32,6 +32,17 @@ Among the 22k complete genomes of RefSeq, this system is present in 107 genomes
*Proportion of genome encoding the AbiK system for the 14 phyla with more than 50 genomes in the RefSeq database.*
## Structure
### AbiK
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abik/AbiK__AbiK-plddts_91.42521.pdb
---
::
## Experimental validation
AbiK systems were experimentally validated using:
......
......@@ -32,6 +32,24 @@ Among the 22k complete genomes of RefSeq, this system is present in 783 genomes
*Proportion of genome encoding the AbiL system for the 14 phyla with more than 50 genomes in the RefSeq database.*
## Structure
### AbiL
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abil/AbiL,AbiL__AbiLi,0,V-plddts_89.17612.pdb
---
::
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abil/AbiL,AbiL__AbiLii,0,V-plddts_86.69766.pdb
---
::
## Experimental validation
AbiL systems were experimentally validated using:
......
......@@ -31,6 +31,17 @@ Among the 22k complete genomes of RefSeq, this system is present in 167 genomes
*Proportion of genome encoding the AbiN system for the 14 phyla with more than 50 genomes in the RefSeq database.*
## Structure
### AbiN
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abin/AbiN__AbiN-plddts_84.27216.pdb
---
::
## Experimental validation
AbiN systems were experimentally validated using:
......
......@@ -32,6 +32,17 @@ Among the 22k complete genomes of RefSeq, this system is present in 109 genomes
*Proportion of genome encoding the AbiO system for the 14 phyla with more than 50 genomes in the RefSeq database.*
## Structure
### AbiO
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abio/AbiO__AbiO-plddts_87.43501.pdb
---
::
## Experimental validation
AbiO systems were experimentally validated using:
......
......@@ -32,6 +32,17 @@ Among the 22k complete genomes of RefSeq, this system is present in 299 genomes
*Proportion of genome encoding the AbiP2 system for the 14 phyla with more than 50 genomes in the RefSeq database.*
## Structure
### AbiP2
::molstar-pdbe-plugin
---
height: 700
dataUrl: /abip2/AbiP2__AbiP2-plddts_93.08218.pdb
---
::
## Experimental validation
AbiP2 systems were experimentally validated using:
......