Skip to content
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
22 changes: 12 additions & 10 deletions docs/content/finding-data/searching.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,28 +8,30 @@ MaveDB provides a search interface to help users find relevant datasets. You can
## Search interface

<figure markdown="span">
![MaveDB search interface showing target filters and keyword search](../images/search_interface.png)
<figcaption>The MaveDB search interface with target filters and keyword search. Results are grouped by experiment, with matching score sets listed underneath.</figcaption>
![MaveDB search interface showing the filter sidebar and keyword search](../images/search_interface.png)
<figcaption>The MaveDB search interface with target, publication, and keyword filters. Results are grouped by experiment, with matching score sets listed underneath.</figcaption>
</figure>

The search interface allows users to filter datasets based on various criteria.
The search interface presents a filter sidebar on the left (a slide-out drawer on smaller screens) alongside the results. Each filter is a collapsible section; the **Gene** and **Organism** sections are expanded by default, and the rest can be opened as needed.

In the **Target** tab, users can filter datasets by the following fields drawn from user-submitted [target](../submitting-data/targets.md) metadata:
The following sections filter datasets by user-submitted [target](../submitting-data/targets.md) metadata:

- **Target name** -- The name of the target associated with the dataset (usually a gene or protein).
- **Target type** -- The type of target (e.g., protein-coding gene, non-coding RNA, regulatory element).
- **Gene** -- The name of the target associated with the dataset (usually a gene or protein).
- **Organism** -- The organism from which the target is derived.
- **Target type** -- The type of target (e.g., protein-coding gene, non-coding RNA, regulatory element).
- **Target accession** -- The accession number or identifier for the target (e.g., Ensembl ID, RefSeq ID).

In the **Publication** tab, users can filter datasets by the following publication-related fields:
These sections filter by publication metadata:

- **Author** -- The author of any publication associated with a dataset.
- **Database** -- The database of any publication associated with a dataset (e.g., PubMed, CrossRef).
- **Journal** -- The journal in which any publication associated with a dataset was published.
- **Publication database** -- The database that indexes an associated publication (e.g., PubMed, CrossRef).

The **Keywords** section filters by [controlled-vocabulary keywords](../reference/controlled-vocabulary.md), grouped by category, that describe how an assay was performed.

Users may also enter keywords into the search bar to perform a full-text search across all dataset metadata fields, including target metadata, publication metadata, [assay facts](../reference/assay-facts.md), and score set metadata. Note that search filters are additive: datasets must meet **all** specified criteria to appear in the results.
Separately, the **search bar** at the top of the page runs a full-text search across all dataset metadata fields, including target metadata, publication metadata, [assay facts](../reference/assay-facts.md), and score set metadata. Filters and the search term are additive: datasets must meet **all** specified criteria to appear in the results, and any filters you have applied appear as removable chips beneath the search bar.

Results are grouped by [experiment](../getting-started/key-concepts.md#experiments), with all matching [score sets](../getting-started/key-concepts.md#score-sets) listed under each experiment.
Results are grouped by [experiment](../getting-started/key-concepts.md#experiments), with all matching [score sets](../getting-started/key-concepts.md#score-sets) listed under each experiment. Use the **Sort by** control above the results to order them by most recent, most variants, or title (A--Z).

!!! note
Search results update in real time as you modify your criteria, but they are limited to the first 100 results for performance reasons. If your search returns more than 100 results, try refining your criteria further.
Expand Down
Binary file modified docs/content/images/search_interface.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
27 changes: 22 additions & 5 deletions src/components/screens/HomeScreen.vue
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@
</template>

<!-- Paths: Explore + Contribute -->
<div class="mt-9 grid md:grid-cols-1 lg:grid-cols-[3fr_2fr] gap-5">
<div class="mt-9 grid md:grid-cols-1 lg:grid-cols-2 gap-5">
<!-- Explore -->
<div class="flex flex-col rounded-lg border border-border bg-white px-8 py-7">
<h2 class="mb-1.5 text-xl font-bold text-sage">Explore datasets</h2>
Expand All @@ -102,7 +102,7 @@
community-contributed MAVE experiments.
</p>
<div class="mt-auto mb-2 text-sm font-bold uppercase tracking-wide text-text-muted">Browse by</div>
<div class="grid md:grid-cols-3 gap-2.5">
<div class="grid md:grid-cols-2 gap-2.5">
<router-link
v-for="cat in BROWSE_CATEGORIES"
:key="cat.label"
Expand All @@ -114,6 +114,10 @@
<div class="text-xs leading-snug text-text-secondary">{{ cat.description }}</div>
</router-link>
</div>
<p class="mt-2.5 text-xs text-text-secondary">
Learn about dataset search in the
<a class="font-semibold text-link" :href="SEARCH_GUIDE_HREF">search guide &rarr;</a>
</p>
</div>

<!-- Contribute -->
Expand All @@ -122,7 +126,7 @@
<p class="mb-4.5 text-sm leading-relaxed text-text-secondary">
Upload your MAVE assay results to make functional variant data available to the community.
</p>
<div class="mt-auto mb-2 text-sm font-bold uppercase tracking-wide text-text-muted">Start with</div>
<div class="mt-auto mb-2 text-sm font-bold uppercase tracking-wide text-text-muted">Contribute a</div>
<div class="grid md:grid-cols-1 lg:grid-cols-2 gap-2.5">
<router-link
v-for="cat in CONTRIBUTE_CATEGORIES"
Expand All @@ -135,6 +139,10 @@
<div class="text-xs leading-snug text-text-secondary">{{ cat.description }}</div>
</router-link>
</div>
<p class="mt-2.5 text-xs text-text-secondary">
First time submitting data? Start with the
<a class="font-semibold text-link" :href="SUBMISSION_GUIDE_HREF">submission guide &rarr;</a>
</p>
</div>
</div>

Expand Down Expand Up @@ -227,7 +235,14 @@ import Select from 'primevue/select'
import MvLayout from '@/components/layout/MvLayout.vue'
import MvLoader from '@/components/common/MvLoader.vue'
import MvScoreSetRow from '@/components/common/MvScoreSetRow.vue'
import {BROWSE_CATEGORIES, CONTRIBUTE_CATEGORIES, FEATURED_COLLECTIONS, WATERMARK_BARS} from '@/data/home'
import {
BROWSE_CATEGORIES,
CONTRIBUTE_CATEGORIES,
FEATURED_COLLECTIONS,
SEARCH_GUIDE_HREF,
SUBMISSION_GUIDE_HREF,
WATERMARK_BARS
} from '@/data/home'
import {NEWS_ITEMS, NEWS_ITEMS_LIMIT, NEWS_TAG_STYLES} from '@/data/news'
import {SEARCH_COLORS, SEARCH_PLACEHOLDERS, SEARCH_TYPES} from '@/data/search'
import {geneSymbolRegex, geneSymbolSearchTarget} from '@/lib/mavemd'
Expand All @@ -254,7 +269,9 @@ export default defineComponent({
SEARCH_COLORS,
BROWSE_CATEGORIES,
CONTRIBUTE_CATEGORIES,
FEATURED_COLLECTIONS
FEATURED_COLLECTIONS,
SEARCH_GUIDE_HREF,
SUBMISSION_GUIDE_HREF
}
},

Expand Down
27 changes: 20 additions & 7 deletions src/data/home.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
/**
* Static content data for the homepage (HomeScreen).
*
* Constants here are stub/placeholder data. Items marked with TODO should be
* replaced with real API data when available.
* Items marked with TODO should be replaced with real API data when available.
*/

import igvfLogo from '@/assets/igvf-tag.png'
Expand All @@ -28,27 +27,41 @@ export const WATERMARK_BARS = [
{color: 'var(--color-sage)', height: '12%'}
]

/**
* "Browse by" facets, most broadly useful first: the full corpus and the
* human-organism filter.
*/
export const BROWSE_CATEGORIES = [
{label: 'BRCA1', description: 'Browse BRCA1 score sets', icon: 'fa-solid fa-dna', route: '/search?target-name=BRCA1'},
{label: 'Browse all', description: 'Open search, no filters', icon: 'fa-solid fa-magnifying-glass', route: '/search'},
{
label: 'Human',
description: 'Human variant data',
icon: 'fa-solid fa-person',
route: '/search?target-organism-name=Homo+sapiens'
},
{label: 'Browse all', description: 'Open search, no filters', icon: 'fa-solid fa-magnifying-glass', route: '/search'}
}
]

/** Points newcomers from the Explore panel at the searching guide. */
export const SEARCH_GUIDE_HREF = '/docs/mavedb/finding-data/searching.html'

export const CONTRIBUTE_CATEGORIES = [
{
label: 'New Experiment',
description: 'Group related score sets',
description: 'Start uploading a new experiment',
icon: 'fa-solid fa-folder-plus',
route: '/create-experiment'
},
{label: 'New Score Set', description: 'Upload variant scores', icon: 'fa-solid fa-upload', route: '/create-score-set'}
{
label: 'New Score Set',
description: 'Add scores to an existing experiment',
icon: 'fa-solid fa-upload',
route: '/create-score-set'
}
]

/** Points first-time submitters at the submission guide before the ORCID-gated create forms. */
export const SUBMISSION_GUIDE_HREF = '/docs/mavedb/submitting-data/before-you-start.html'

export const FEATURED_COLLECTIONS = [
{
title: 'IGVF Produced',
Expand Down
Loading