@openneuro/app 4.33.4 → 4.34.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +4 -3
- package/src/client.jsx +2 -1
- package/src/scripts/authentication/signOut.ts +1 -1
- package/src/scripts/common/containers/footer.tsx +1 -1
- package/src/scripts/common/containers/header.tsx +3 -2
- package/src/scripts/common/content/affiliate-content.jsx +72 -0
- package/src/scripts/common/content/assets/affiliates/bids.jpg +0 -0
- package/src/scripts/common/content/assets/affiliates/datalad.jpg +0 -0
- package/src/scripts/common/content/assets/affiliates/nih-bi-logo.png +0 -0
- package/src/scripts/common/content/assets/front-page/brand_mark.png +0 -0
- package/src/scripts/common/content/assets/front-page/cube-get.png +0 -0
- package/src/scripts/common/content/assets/front-page/cube-share.png +0 -0
- package/src/scripts/common/content/assets/front-page/cube-use.png +0 -0
- package/src/scripts/common/content/assets/front-page/ljaf.png +0 -0
- package/src/scripts/common/content/assets/front-page/logo_app.png +0 -0
- package/src/scripts/common/content/assets/front-page/logo_cube.png +0 -0
- package/src/scripts/common/content/assets/front-page/logo_data.png +0 -0
- package/src/scripts/common/content/assets/front-page/logo_users.png +0 -0
- package/src/scripts/common/content/assets/front-page/novo-logo.png +0 -0
- package/src/scripts/common/content/assets/front-page/nru-logo.png +0 -0
- package/src/scripts/common/content/assets/front-page/nsf.png +0 -0
- package/src/scripts/common/content/assets/front-page/sqm-logo.png +0 -0
- package/src/scripts/common/content/assets/front-page/squishymedia.png +0 -0
- package/src/scripts/common/content/assets/front-page/stanford.png +0 -0
- package/src/scripts/common/content/assets/modality-cubes/brain-initiative.jpg +0 -0
- package/src/scripts/common/content/assets/modality-cubes/eeg.jpg +0 -0
- package/src/scripts/common/content/assets/modality-cubes/ieeg.jpg +0 -0
- package/src/scripts/common/content/assets/modality-cubes/meg.jpg +0 -0
- package/src/scripts/common/content/assets/modality-cubes/mri.jpg +0 -0
- package/src/scripts/common/content/assets/modality-cubes/nih_cube.jpg +0 -0
- package/src/scripts/common/content/assets/modality-cubes/nirs.jpg +0 -0
- package/src/scripts/common/content/assets/modality-cubes/pet-scan.jpg +0 -0
- package/src/scripts/common/content/assets/portal-content/nih-bi-brand.png +0 -0
- package/src/scripts/common/content/facet-content.jsx +186 -0
- package/src/scripts/common/content/front-page-content.jsx +177 -0
- package/src/scripts/common/content/image-attribution.tsx +3 -3
- package/src/scripts/common/content/modality-cube-content.jsx +92 -0
- package/src/scripts/common/content/portal-content.jsx +149 -0
- package/src/scripts/common/content/portal-grant-content.jsx +30 -0
- package/src/scripts/common/content/sortby-list.jsx +18 -0
- package/src/scripts/common/forms/warn-button.jsx +1 -1
- package/src/scripts/components/accordion/AccordionTab.tsx +68 -0
- package/src/scripts/components/accordion/AccordionWrap.tsx +22 -0
- package/src/scripts/components/accordion/__tests__/AccordionTab.spec.tsx +35 -0
- package/src/scripts/components/accordion/accordion.scss +68 -0
- package/src/scripts/components/activity-slider/ActivitySlider.tsx +121 -0
- package/src/scripts/components/activity-slider/slider.scss +130 -0
- package/src/scripts/components/affiliate-article/AffiliateArticle.tsx +26 -0
- package/src/scripts/components/affiliate-article/affiliate.scss +32 -0
- package/src/scripts/components/aggregate-count/AggregateCount.tsx +20 -0
- package/src/scripts/components/assets/activity-icon.png +0 -0
- package/src/scripts/components/assets/close-button.png +0 -0
- package/src/scripts/components/assets/favicon copy.ico +0 -0
- package/src/scripts/components/assets/favicon.ico +0 -0
- package/src/scripts/components/assets/get_data_browse.png +0 -0
- package/src/scripts/components/assets/get_data_download.png +0 -0
- package/src/scripts/components/assets/ljaf copy.png +0 -0
- package/src/scripts/components/assets/logo_app copy.png +0 -0
- package/src/scripts/components/assets/logo_cube copy.png +0 -0
- package/src/scripts/components/assets/logo_data copy.png +0 -0
- package/src/scripts/components/assets/logo_users copy.png +0 -0
- package/src/scripts/components/assets/mri-scan.jpg +0 -0
- package/src/scripts/components/assets/nih copy.png +0 -0
- package/src/scripts/components/assets/nih-bi-brand.jpg +0 -0
- package/src/scripts/components/assets/nih-stanford.jpg +0 -0
- package/src/scripts/components/assets/nih.png +0 -0
- package/src/scripts/components/assets/nimh.png +0 -0
- package/src/scripts/components/assets/nsf copy.png +0 -0
- package/src/scripts/components/assets/on-dark-horz.svg +1 -0
- package/src/scripts/components/assets/on-dark.svg +1 -0
- package/src/scripts/components/assets/on-light-horz.svg +1 -0
- package/src/scripts/components/assets/on-light.svg +1 -0
- package/src/scripts/components/assets/orcid_24x24 copy.png +0 -0
- package/src/scripts/components/assets/orcid_24x24.png +0 -0
- package/src/scripts/components/assets/share_data_collaborate.png +0 -0
- package/src/scripts/components/assets/share_data_publish.png +0 -0
- package/src/scripts/components/assets/share_data_validate.png +0 -0
- package/src/scripts/components/assets/squishymedia copy.png +0 -0
- package/src/scripts/components/assets/stanford copy.png +0 -0
- package/src/scripts/components/assets/tab-get_data.png +0 -0
- package/src/scripts/components/assets/tab-share_data.png +0 -0
- package/src/scripts/components/assets/tab-use_data.png +0 -0
- package/src/scripts/components/assets/use_data_analyze.png +0 -0
- package/src/scripts/components/assets/use_data_snapshot.png +0 -0
- package/src/scripts/components/button/Button.tsx +113 -0
- package/src/scripts/components/button/__tests__/Button.spec.tsx +21 -0
- package/src/scripts/components/button/button.scss +140 -0
- package/src/scripts/components/count-toggle/CountToggle.tsx +65 -0
- package/src/scripts/components/count-toggle/__tests__/CountToggle.spec.tsx +31 -0
- package/src/scripts/components/count-toggle/count-toggle.scss +34 -0
- package/src/scripts/components/dropdown/Dropdown.tsx +38 -0
- package/src/scripts/components/dropdown/dropdown.scss +29 -0
- package/src/scripts/components/facets/FacetRadio.tsx +43 -0
- package/src/scripts/components/facets/FacetRange.tsx +35 -0
- package/src/scripts/components/facets/FacetSearch.tsx +66 -0
- package/src/scripts/components/facets/FacetSelect.tsx +87 -0
- package/src/scripts/components/facets/SingleSelect.tsx +39 -0
- package/src/scripts/components/facets/__tests__/FacetSelect.spec.tsx +14 -0
- package/src/scripts/components/facets/__tests__/SingleSelect.spec.tsx +58 -0
- package/src/scripts/components/facets/facet.scss +244 -0
- package/src/scripts/components/footer/Footer.tsx +52 -0
- package/src/scripts/components/footer/footer.scss +20 -0
- package/src/scripts/components/formatting/__tests__/modality-label.spec.tsx +34 -0
- package/src/scripts/components/formatting/modality-label.tsx +34 -0
- package/src/scripts/components/front-page/ActivityHeader.tsx +12 -0
- package/src/scripts/components/front-page/AffiliateBlock.tsx +22 -0
- package/src/scripts/components/front-page/Contributors.tsx +28 -0
- package/src/scripts/components/front-page/GetUpdates.tsx +99 -0
- package/src/scripts/components/front-page/Infographic.tsx +36 -0
- package/src/scripts/components/front-page/front-page.scss +295 -0
- package/src/scripts/components/header/Header.tsx +151 -0
- package/src/scripts/components/header/LandingExpandedHeader.tsx +110 -0
- package/src/scripts/components/header/header.scss +409 -0
- package/src/scripts/components/icon/Icon.tsx +55 -0
- package/src/scripts/components/icon/__tests__/Icon.spec.tsx +10 -0
- package/src/scripts/components/icon/icon.scss +8 -0
- package/src/scripts/components/input/Input.tsx +137 -0
- package/src/scripts/components/input/TermSearch.tsx +101 -0
- package/src/scripts/components/input/input.scss +147 -0
- package/src/scripts/components/input/term-search.scss +68 -0
- package/src/scripts/components/json-tree/ExpandableProperty.tsx +35 -0
- package/src/scripts/components/json-tree/RecursiveProperty.tsx +67 -0
- package/src/scripts/components/json-tree/json-tree.scss +19 -0
- package/src/scripts/components/loading/Loading.tsx +19 -0
- package/src/scripts/components/loading/__tests__/Loading.spec.tsx +12 -0
- package/src/scripts/components/loading/loading.scss +141 -0
- package/src/scripts/components/logo/Logo.tsx +44 -0
- package/src/scripts/components/logo/__tests__/Logo.spec.tsx +22 -0
- package/src/scripts/components/modal/Modal.tsx +51 -0
- package/src/scripts/components/modal/ModalExample.tsx +25 -0
- package/src/scripts/components/modal/UserLoginModal.tsx +74 -0
- package/src/scripts/components/modal/__tests__/UserLoginModal.spec.tsx +37 -0
- package/src/scripts/components/modal/modal.scss +60 -0
- package/src/scripts/components/modality-cube/ModalityCube.tsx +60 -0
- package/src/scripts/components/modality-cube/modality-cube.scss +303 -0
- package/src/scripts/components/page/Page.tsx +61 -0
- package/src/scripts/components/page/page.scss +408 -0
- package/src/scripts/components/progress-bar/ProgressBar.tsx +16 -0
- package/src/scripts/components/progress-bar/progress-bar.scss +34 -0
- package/src/scripts/components/radio/Radio.tsx +33 -0
- package/src/scripts/components/radio/RadioGroup.tsx +45 -0
- package/src/scripts/components/radio/__tests__/RadioGroup.spec.tsx +31 -0
- package/src/scripts/components/radio/radio.scss +335 -0
- package/src/scripts/components/range/TwoHandleRange.scss +108 -0
- package/src/scripts/components/range/TwoHandleRange.tsx +128 -0
- package/src/scripts/components/range/__tests__/TwoHandleRange.spec.tsx +34 -0
- package/src/scripts/components/read-more/ReadMore.tsx +50 -0
- package/src/scripts/components/read-more/__tests__/ReadMore.spec.tsx +14 -0
- package/src/scripts/components/read-more/read-more.scss +79 -0
- package/src/scripts/components/scss/_flex-grid.scss +216 -0
- package/src/scripts/components/scss/_helper-classes.scss +162 -0
- package/src/scripts/components/scss/_normalize.scss +614 -0
- package/src/scripts/components/scss/_variables.scss +245 -0
- package/src/scripts/components/scss/global.scss +124 -0
- package/src/scripts/components/scss/toasts.scss +33 -0
- package/src/scripts/components/scss/upload-modal.scss +479 -0
- package/src/scripts/components/search-page/CommunityHeader.tsx +27 -0
- package/src/scripts/components/search-page/FacetBlockContainerExample.tsx +6 -0
- package/src/scripts/components/search-page/FilterDateItem.tsx +44 -0
- package/src/scripts/components/search-page/FilterListItem.tsx +62 -0
- package/src/scripts/components/search-page/FiltersBlock.tsx +277 -0
- package/src/scripts/components/search-page/ModalityHeader.tsx +64 -0
- package/src/scripts/components/search-page/NeurobagelSearch.tsx +59 -0
- package/src/scripts/components/search-page/SearchPage.tsx +114 -0
- package/src/scripts/components/search-page/SearchResultItem.tsx +417 -0
- package/src/scripts/components/search-page/SearchResultsList.tsx +48 -0
- package/src/scripts/components/search-page/SearchSort.tsx +52 -0
- package/src/scripts/components/search-page/SearchSortContainerExample.tsx +9 -0
- package/src/scripts/components/search-page/TermListItem.tsx +41 -0
- package/src/scripts/components/search-page/__tests__/NuerobagelSearch.spec.tsx +17 -0
- package/src/scripts/components/search-page/filters-block.scss +99 -0
- package/src/scripts/components/search-page/neurobagel_logo.svg +75 -0
- package/src/scripts/components/search-page/search-page.scss +505 -0
- package/src/scripts/components/search-page/search-result.scss +117 -0
- package/src/scripts/components/search-page/search-sort.scss +56 -0
- package/src/scripts/components/select/SelectGroup.tsx +41 -0
- package/src/scripts/components/select/__tests__/SelectGroup.spec.tsx +43 -0
- package/src/scripts/components/select/select.scss +40 -0
- package/src/scripts/components/textarea/Textarea.tsx +68 -0
- package/src/scripts/components/textarea/__tests__/Textarea.spec.tsx +53 -0
- package/src/scripts/components/tooltip/Tooltip.tsx +30 -0
- package/src/scripts/components/tooltip/__tests__/Tooltip.spec.tsx +14 -0
- package/src/scripts/components/tooltip/tooltip.scss +159 -0
- package/src/scripts/components/user/UserMenu.tsx +72 -0
- package/src/scripts/components/user/user-menu.scss +88 -0
- package/src/scripts/components/warn-button/WarnButton.tsx +97 -0
- package/src/scripts/components/warn-button/warn-button.scss +39 -0
- package/src/scripts/datalad/dataset/dataset-query-context.js +2 -0
- package/src/scripts/dataset/comments/comment.jsx +1 -1
- package/src/scripts/dataset/components/AnalyzeDropdown.tsx +2 -2
- package/src/scripts/dataset/components/CloneDropdown.tsx +2 -2
- package/src/scripts/dataset/components/DatasetEventItem.tsx +105 -0
- package/src/scripts/dataset/components/DatasetGitAccess.tsx +2 -2
- package/src/scripts/dataset/components/DatasetToolButton.tsx +2 -2
- package/src/scripts/dataset/components/ModalitiesMetaDataBlock.tsx +2 -10
- package/src/scripts/dataset/components/ValidationBlock.tsx +37 -2
- package/src/scripts/dataset/components/VersionList.tsx +1 -1
- package/src/scripts/dataset/components/scss/dataset-events.module.scss +41 -0
- package/src/scripts/dataset/dataset-query.jsx +12 -11
- package/src/scripts/dataset/download/__tests__/__snapshots__/download-command-line.spec.jsx.snap +7 -1
- package/src/scripts/dataset/download/__tests__/download-command-line.spec.jsx +2 -2
- package/src/scripts/dataset/download/download-command-line.jsx +17 -13
- package/src/scripts/dataset/download/download-datalad.jsx +6 -3
- package/src/scripts/dataset/download/download-link.jsx +1 -1
- package/src/scripts/dataset/download/download-s3.jsx +0 -4
- package/src/scripts/dataset/files/file-display.jsx +1 -1
- package/src/scripts/dataset/files/file-tree-unloaded-directory.jsx +1 -1
- package/src/scripts/dataset/files/file-tree.tsx +1 -1
- package/src/scripts/dataset/files/file-view.jsx +1 -1
- package/src/scripts/dataset/files/file-viewer-type.jsx +5 -1
- package/src/scripts/dataset/files/file.tsx +2 -2
- package/src/scripts/dataset/files/files.tsx +3 -3
- package/src/scripts/dataset/files/viewers/file-viewer-json.jsx +1 -1
- package/src/scripts/dataset/files/viewers/file-viewer-markdown.tsx +13 -0
- package/src/scripts/dataset/fragments/cancel-button.tsx +1 -1
- package/src/scripts/dataset/fragments/dataset-citation.jsx +2 -2
- package/src/scripts/dataset/fragments/edit-button.tsx +1 -1
- package/src/scripts/dataset/fragments/edit-list.jsx +1 -1
- package/src/scripts/dataset/fragments/save-button.tsx +1 -1
- package/src/scripts/dataset/mutations/admin-exports.jsx +1 -1
- package/src/scripts/dataset/mutations/cache-clear.jsx +1 -1
- package/src/scripts/dataset/mutations/create-anonymous-reviewer.tsx +2 -2
- package/src/scripts/dataset/mutations/dataset-events.tsx +187 -0
- package/src/scripts/dataset/mutations/dataset-relations.tsx +1 -1
- package/src/scripts/dataset/mutations/delete-anonymous-reviewer.tsx +1 -1
- package/src/scripts/dataset/mutations/delete-comment.jsx +1 -1
- package/src/scripts/dataset/mutations/delete-file.jsx +1 -1
- package/src/scripts/dataset/mutations/deprecate-version.tsx +1 -1
- package/src/scripts/dataset/mutations/flag-annex-object.jsx +2 -2
- package/src/scripts/dataset/mutations/follow.tsx +1 -1
- package/src/scripts/dataset/mutations/import-dataset.tsx +1 -1
- package/src/scripts/dataset/mutations/publish.jsx +1 -1
- package/src/scripts/dataset/mutations/remove-annex-object.jsx +2 -2
- package/src/scripts/dataset/mutations/remove-permissions.tsx +1 -1
- package/src/scripts/dataset/mutations/revalidate.jsx +2 -2
- package/src/scripts/dataset/mutations/snapshot.tsx +1 -1
- package/src/scripts/dataset/mutations/star.tsx +1 -1
- package/src/scripts/dataset/mutations/submit-metadata.jsx +1 -1
- package/src/scripts/dataset/mutations/undo-deprecate-version.tsx +2 -2
- package/src/scripts/dataset/mutations/update-permissions.tsx +1 -1
- package/src/scripts/dataset/routes/admin-datalad.jsx +4 -0
- package/src/scripts/dataset/routes/dataset-default.tsx +1 -1
- package/src/scripts/dataset/routes/delete-page.tsx +7 -3
- package/src/scripts/dataset/routes/deprecate-snapshot-page.tsx +1 -1
- package/src/scripts/dataset/routes/manage-permissions.jsx +1 -1
- package/src/scripts/dataset/routes/snapshot-default.tsx +1 -1
- package/src/scripts/dataset/routes/snapshot.tsx +1 -1
- package/src/scripts/dataset/snapshot-container.tsx +14 -8
- package/src/scripts/pages/admin/flagged-files.jsx +1 -1
- package/src/scripts/pages/admin/user-tools.tsx +1 -1
- package/src/scripts/pages/admin/users.tsx +2 -2
- package/src/scripts/pages/api.jsx +2 -2
- package/src/scripts/pages/front-page/aggregate-queries/aggregate-counts-container.tsx +6 -7
- package/src/scripts/pages/front-page/front-page.tsx +7 -9
- package/src/scripts/pages/metadata/dataset-metadata.tsx +1 -1
- package/src/scripts/search/__tests__/search-container.spec.tsx +7 -7
- package/src/scripts/search/filters-block-container.tsx +66 -9
- package/src/scripts/search/initial-search-params.tsx +7 -7
- package/src/scripts/search/inputs/__tests__/sort-by-select.spec.tsx +1 -1
- package/src/scripts/search/inputs/admin-allDatasets-toggle.tsx +1 -1
- package/src/scripts/search/inputs/age-range-input.tsx +3 -2
- package/src/scripts/search/inputs/author-input.tsx +3 -2
- package/src/scripts/search/inputs/dataset-type-select.tsx +3 -2
- package/src/scripts/search/inputs/date-radios.tsx +3 -2
- package/src/scripts/search/inputs/diagnosis-select.tsx +3 -2
- package/src/scripts/search/inputs/initiative-select.tsx +12 -6
- package/src/scripts/search/inputs/keyword-input.tsx +2 -2
- package/src/scripts/search/inputs/modality-select.tsx +28 -26
- package/src/scripts/search/inputs/pet/bodyParts_input.tsx +4 -3
- package/src/scripts/search/inputs/pet/scannerManufacturersModelNames_input.tsx +4 -3
- package/src/scripts/search/inputs/pet/scannerManufacturers_input.tsx +4 -3
- package/src/scripts/search/inputs/pet/tracerNames_input.tsx +4 -3
- package/src/scripts/search/inputs/pet/tracerRadionuclides_input.tsx +4 -3
- package/src/scripts/search/inputs/section-select.tsx +3 -2
- package/src/scripts/search/inputs/sex-radios.tsx +3 -2
- package/src/scripts/search/inputs/show-datasets-radios.tsx +4 -3
- package/src/scripts/search/inputs/sort-by-select.tsx +1 -1
- package/src/scripts/search/inputs/species-select.tsx +3 -2
- package/src/scripts/search/inputs/study-domain-input.tsx +4 -3
- package/src/scripts/search/inputs/subject-count-range-input.tsx +3 -2
- package/src/scripts/search/inputs/task-input.tsx +4 -3
- package/src/scripts/search/search-container.tsx +14 -17
- package/src/scripts/search/search-params-ctx.tsx +28 -5
- package/src/scripts/search/search-routes.tsx +2 -4
- package/src/scripts/search/use-search-results.tsx +14 -13
- package/src/scripts/uploader/upload-issues.tsx +1 -1
- package/src/scripts/uploader/upload-progress.jsx +1 -1
- package/src/scripts/uploader/uploader-modal.jsx +1 -1
- package/src/scripts/users/components/close-button.tsx +1 -1
- package/src/scripts/users/components/edit-button.tsx +1 -1
- package/src/scripts/users/components/edit-list.tsx +1 -1
- package/src/scripts/users/components/edit-string.tsx +1 -1
- package/src/scripts/users/dataset-card.tsx +2 -2
- package/src/scripts/users/user-notification-accordion.tsx +1 -1
- package/src/scripts/utils/user-login-modal-ctx.tsx +1 -1
- package/src/scripts/validation/validation-issues.tsx +2 -1
- package/src/scripts/validation/validation-panel.tsx +2 -1
- package/src/scripts/validation/validation-results.tsx +4 -3
- package/src/scripts/validation-legacy/validation-panel.jsx +2 -1
- package/src/scripts/validation-legacy/validation-results.issues.jsx +2 -3
- package/src/scripts/validation-legacy/validation-results.tsx +3 -4
- package/tsconfig.json +1 -4
|
@@ -0,0 +1,244 @@
|
|
|
1
|
+
@import '../scss/variables';
|
|
2
|
+
|
|
3
|
+
.facet-accordion.on-accordion-wrapper {
|
|
4
|
+
padding: 0 15px;
|
|
5
|
+
border-bottom: 1px solid #ddd;
|
|
6
|
+
|
|
7
|
+
.accordion-title {
|
|
8
|
+
font-size: 14px;
|
|
9
|
+
font-weight: 400;
|
|
10
|
+
letter-spacing: 0.05em;
|
|
11
|
+
padding: 10px 0;
|
|
12
|
+
display: flex;
|
|
13
|
+
justify-content: space-between;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.facet-list {
|
|
17
|
+
ul {
|
|
18
|
+
margin: 0;
|
|
19
|
+
padding: 0;
|
|
20
|
+
list-style: none;
|
|
21
|
+
li {
|
|
22
|
+
cursor: pointer;
|
|
23
|
+
font-weight: 300;
|
|
24
|
+
color: #666;
|
|
25
|
+
font-size: 14px;
|
|
26
|
+
&.selected-facet {
|
|
27
|
+
> .label,
|
|
28
|
+
> .label span {
|
|
29
|
+
color: var(--current-theme-primary);
|
|
30
|
+
font-weight: 600;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
.label {
|
|
34
|
+
display: flex;
|
|
35
|
+
align-items: center;
|
|
36
|
+
span {
|
|
37
|
+
margin-left: 10px;
|
|
38
|
+
display: flex;
|
|
39
|
+
color: #666;
|
|
40
|
+
font-size: 14px;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
.level-1 > li {
|
|
46
|
+
border-top: 1px solid #dfdfdf;
|
|
47
|
+
> span:hover {
|
|
48
|
+
background-color: var(--current-theme-primary-light);
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
> .label {
|
|
52
|
+
padding: 10px 10px 10px 20px;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
.level-2 {
|
|
56
|
+
margin-bottom: 10px;
|
|
57
|
+
display: block;
|
|
58
|
+
width: 100%;
|
|
59
|
+
> li {
|
|
60
|
+
display: flex;
|
|
61
|
+
justify-content: flex-start;
|
|
62
|
+
&:hover {
|
|
63
|
+
background-color: var(--current-theme-primary-light);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
.label {
|
|
67
|
+
margin-left: 15px;
|
|
68
|
+
}
|
|
69
|
+
&:before {
|
|
70
|
+
content: '-';
|
|
71
|
+
margin-left: 30px;
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
.facet-list ul li {
|
|
78
|
+
> .label {
|
|
79
|
+
font-weight: 500;
|
|
80
|
+
}
|
|
81
|
+
&.selected-facet > .label {
|
|
82
|
+
color: var(--current-theme-primary);
|
|
83
|
+
font-weight: 600;
|
|
84
|
+
|
|
85
|
+
span {
|
|
86
|
+
color: var(--current-theme-primary);
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
&.selected-facet:hover {
|
|
90
|
+
background-color: none;
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
.facet-range {
|
|
96
|
+
margin: 20px 0;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.facet-date-picker.on-accordion-wrapper .accordion-item {
|
|
100
|
+
overflow: visible;
|
|
101
|
+
.range-input {
|
|
102
|
+
padding: 0 0 20px 0;
|
|
103
|
+
.react-daterange-picker {
|
|
104
|
+
width: 100%;
|
|
105
|
+
}
|
|
106
|
+
.react-daterange-picker__wrapper {
|
|
107
|
+
border: 0;
|
|
108
|
+
width: 100%;
|
|
109
|
+
.react-daterange-picker__range-divider {
|
|
110
|
+
margin: 0 15px;
|
|
111
|
+
display: inline-block;
|
|
112
|
+
}
|
|
113
|
+
.react-daterange-picker__inputGroup {
|
|
114
|
+
min-width: auto;
|
|
115
|
+
flex-grow: 0;
|
|
116
|
+
padding: 0;
|
|
117
|
+
input {
|
|
118
|
+
cursor: pointer;
|
|
119
|
+
line-height: 20px;
|
|
120
|
+
display: inline-block;
|
|
121
|
+
color: #666;
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
.react-daterange-picker__clear-button {
|
|
125
|
+
margin-left: auto;
|
|
126
|
+
}
|
|
127
|
+
.react-daterange-picker__button {
|
|
128
|
+
color: var(--current-theme-primary);
|
|
129
|
+
&:hover {
|
|
130
|
+
color: var(--current-theme-primary-hover);
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
.react-calendar__month-view__days__day,
|
|
137
|
+
.react-calendar__month-view__days__day--weekend {
|
|
138
|
+
color: $charcoal;
|
|
139
|
+
}
|
|
140
|
+
.react-calendar__tile--now {
|
|
141
|
+
background-color: #eee;
|
|
142
|
+
}
|
|
143
|
+
.react-calendar__tile--active {
|
|
144
|
+
background-color: var(--current-theme-primary);
|
|
145
|
+
color: #fff;
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
.fade-out-facet {
|
|
150
|
+
max-height: 0;
|
|
151
|
+
height: auto;
|
|
152
|
+
transition: max-height 1s;
|
|
153
|
+
overflow: hidden;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.fade-in-facet {
|
|
157
|
+
height: auto;
|
|
158
|
+
max-height: 800px;
|
|
159
|
+
transition: max-height 1s;
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
.dataset-status.facet-accordion.on-accordion-wrapper {
|
|
163
|
+
border-bottom: 0;
|
|
164
|
+
}
|
|
165
|
+
.search-nav .facet-open.modality-facet {
|
|
166
|
+
margin: 20px 0;
|
|
167
|
+
border: 0;
|
|
168
|
+
background: #e5f4f7;
|
|
169
|
+
border-radius: $border-radius-default;
|
|
170
|
+
padding: 10px;
|
|
171
|
+
|
|
172
|
+
h2 {
|
|
173
|
+
margin: 10px 0 15px;
|
|
174
|
+
font-size: 19px;
|
|
175
|
+
font-weight: 600;
|
|
176
|
+
color: var(--current-theme-primary);
|
|
177
|
+
}
|
|
178
|
+
.facet-list {
|
|
179
|
+
padding: 0 0 10px;
|
|
180
|
+
color: var(--current-theme-primary);
|
|
181
|
+
ul {
|
|
182
|
+
padding: 0;
|
|
183
|
+
margin: 0;
|
|
184
|
+
list-style: none;
|
|
185
|
+
li {
|
|
186
|
+
cursor: pointer;
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
.label {
|
|
190
|
+
display: flex;
|
|
191
|
+
align-items: center;
|
|
192
|
+
justify-content: flex-start;
|
|
193
|
+
|
|
194
|
+
span {
|
|
195
|
+
margin-left: 10px;
|
|
196
|
+
display: inline-block;
|
|
197
|
+
font-size: 14px;
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
.level-1 > li {
|
|
202
|
+
border-top: 1px solid $newspaper;
|
|
203
|
+
|
|
204
|
+
> .label {
|
|
205
|
+
padding: 10px;
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
.level-2 {
|
|
209
|
+
margin-bottom: 10px;
|
|
210
|
+
font-size: 14px;
|
|
211
|
+
> li {
|
|
212
|
+
display: flex;
|
|
213
|
+
justify-content: flex-start;
|
|
214
|
+
|
|
215
|
+
.label {
|
|
216
|
+
margin-left: 15px;
|
|
217
|
+
}
|
|
218
|
+
&:before {
|
|
219
|
+
content: '-';
|
|
220
|
+
margin-left: 12px;
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
.facet-list ul li {
|
|
226
|
+
> .label {
|
|
227
|
+
font-weight: 500;
|
|
228
|
+
}
|
|
229
|
+
&.selected-facet > .label {
|
|
230
|
+
color: var(--current-theme-primary);
|
|
231
|
+
font-weight: 600;
|
|
232
|
+
span {
|
|
233
|
+
color: var(--current-theme-primary);
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
|
|
239
|
+
.facet-search {
|
|
240
|
+
padding-bottom: 30px;
|
|
241
|
+
.term-block {
|
|
242
|
+
margin: 30px 0 0;
|
|
243
|
+
}
|
|
244
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import React from "react"
|
|
2
|
+
import { Link } from "react-router-dom"
|
|
3
|
+
import { frontPage } from "../../common/content/front-page-content"
|
|
4
|
+
import "./footer.scss"
|
|
5
|
+
|
|
6
|
+
export interface FooterProps {
|
|
7
|
+
version: string
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export const Footer: React.FC<FooterProps> = ({ version }) => {
|
|
11
|
+
const versionLink =
|
|
12
|
+
`https://github.com/OpenNeuroOrg/openneuro/releases/tag/v${version}`
|
|
13
|
+
return (
|
|
14
|
+
<footer className="on-foot">
|
|
15
|
+
<div className="grid grid-between align-center">
|
|
16
|
+
<div className="col col-4 version">
|
|
17
|
+
<span>
|
|
18
|
+
OpenNeuro
|
|
19
|
+
<a href={versionLink}>
|
|
20
|
+
{" "}v{version}
|
|
21
|
+
</a>
|
|
22
|
+
</span>
|
|
23
|
+
</div>
|
|
24
|
+
<div className="col col-4 privacy-policy">
|
|
25
|
+
<span>
|
|
26
|
+
<a href={frontPage.titlePanel.privacyLink}>
|
|
27
|
+
Privacy Policy
|
|
28
|
+
</a>
|
|
29
|
+
</span>
|
|
30
|
+
{", "}
|
|
31
|
+
<span>
|
|
32
|
+
<Link to="/terms">
|
|
33
|
+
Terms
|
|
34
|
+
</Link>
|
|
35
|
+
</span>
|
|
36
|
+
{", "}
|
|
37
|
+
&{" "}
|
|
38
|
+
<span>
|
|
39
|
+
<Link to="/image-attribution">
|
|
40
|
+
Image Attribution
|
|
41
|
+
</Link>
|
|
42
|
+
</span>
|
|
43
|
+
</div>
|
|
44
|
+
<div className="col col-4 copy">
|
|
45
|
+
<span>
|
|
46
|
+
© {new Date().getFullYear()} {frontPage.copyright.holder}
|
|
47
|
+
</span>
|
|
48
|
+
</div>
|
|
49
|
+
</div>
|
|
50
|
+
</footer>
|
|
51
|
+
)
|
|
52
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
@import '../scss/variables';
|
|
2
|
+
|
|
3
|
+
footer {
|
|
4
|
+
background: $charcoal;
|
|
5
|
+
color: #ffffff;
|
|
6
|
+
padding: 10px;
|
|
7
|
+
a,
|
|
8
|
+
a:link {
|
|
9
|
+
color: $on-light-aqua;
|
|
10
|
+
}
|
|
11
|
+
.grid {
|
|
12
|
+
font-size: 12px;
|
|
13
|
+
.col:nth-child(2) {
|
|
14
|
+
text-align: center;
|
|
15
|
+
}
|
|
16
|
+
.col:last-child {
|
|
17
|
+
text-align: right;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import React from "react"
|
|
2
|
+
import { render } from "@testing-library/react"
|
|
3
|
+
import { ModalityLabel, modalityShortMapping } from "../modality-label"
|
|
4
|
+
|
|
5
|
+
describe("modalityShortMapping", () => {
|
|
6
|
+
it("maps ieeg to iEEG", () => {
|
|
7
|
+
expect(modalityShortMapping("ieeg")).toBe("iEEG")
|
|
8
|
+
})
|
|
9
|
+
it("maps iEEG to iEEG", () => {
|
|
10
|
+
expect(modalityShortMapping("iEEG")).toBe("iEEG")
|
|
11
|
+
})
|
|
12
|
+
it("maps beh to Behavioral", () => {
|
|
13
|
+
expect(modalityShortMapping("beh")).toBe("Behavioral")
|
|
14
|
+
})
|
|
15
|
+
it("maps motion to Motion", () => {
|
|
16
|
+
expect(modalityShortMapping("motion")).toBe("Motion")
|
|
17
|
+
})
|
|
18
|
+
it("maps undefined to undefined", () => {
|
|
19
|
+
expect(modalityShortMapping(undefined)).toBe(undefined)
|
|
20
|
+
})
|
|
21
|
+
it("maps null to null", () => {
|
|
22
|
+
expect(modalityShortMapping(null)).toBe(null)
|
|
23
|
+
})
|
|
24
|
+
it("maps other to uppercase", () => {
|
|
25
|
+
expect(modalityShortMapping("other")).toBe("OTHER")
|
|
26
|
+
})
|
|
27
|
+
})
|
|
28
|
+
|
|
29
|
+
describe("ModalityLabel", () => {
|
|
30
|
+
it("renders the short name", () => {
|
|
31
|
+
const { getByText } = render(<ModalityLabel modality="ieeg" />)
|
|
32
|
+
expect(getByText("iEEG")).toBeInTheDocument()
|
|
33
|
+
})
|
|
34
|
+
})
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Provide a mapping from the schema names to an expected short name used for OpenNeuro display
|
|
3
|
+
*/
|
|
4
|
+
export function modalityShortMapping(modality) {
|
|
5
|
+
switch (modality) {
|
|
6
|
+
case "ieeg":
|
|
7
|
+
case "iEEG":
|
|
8
|
+
return "iEEG"
|
|
9
|
+
case "beh":
|
|
10
|
+
return "Behavioral"
|
|
11
|
+
case "motion":
|
|
12
|
+
return "Motion"
|
|
13
|
+
case "micro":
|
|
14
|
+
return "Microscopy"
|
|
15
|
+
case undefined:
|
|
16
|
+
return undefined
|
|
17
|
+
case null:
|
|
18
|
+
return null
|
|
19
|
+
default:
|
|
20
|
+
return modality.toUpperCase()
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
interface ModalityLabelProps {
|
|
25
|
+
// TODO: type could be schema.objects.modalities if it had a type definition
|
|
26
|
+
modality: string
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
/**
|
|
30
|
+
* String mapping component that renders schema modality labels as human readable labels
|
|
31
|
+
*/
|
|
32
|
+
export function ModalityLabel({ modality }: ModalityLabelProps) {
|
|
33
|
+
return modalityShortMapping(modality)
|
|
34
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from "react"
|
|
2
|
+
import { Icon } from "../icon/Icon"
|
|
3
|
+
import activityIcon from "../assets/activity-icon.png"
|
|
4
|
+
import "./front-page.scss"
|
|
5
|
+
|
|
6
|
+
export const ActivityHeader: React.FC = () => {
|
|
7
|
+
return (
|
|
8
|
+
<h2>
|
|
9
|
+
<Icon label="Activity" imgSrc={activityIcon} iconSize="40px" />
|
|
10
|
+
</h2>
|
|
11
|
+
)
|
|
12
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import React from "react"
|
|
2
|
+
|
|
3
|
+
import { affiliateContent } from "../../common/content/affiliate-content.jsx"
|
|
4
|
+
import { AffiliateArticle } from "../affiliate-article/AffiliateArticle"
|
|
5
|
+
|
|
6
|
+
import "./front-page.scss"
|
|
7
|
+
|
|
8
|
+
export const AffiliateBlock: React.FC = () => {
|
|
9
|
+
return (
|
|
10
|
+
<div className=" affiliate-wrap">
|
|
11
|
+
{affiliateContent.map((item, index) => (
|
|
12
|
+
<AffiliateArticle
|
|
13
|
+
logo={item.logo}
|
|
14
|
+
key={index}
|
|
15
|
+
header={item.header}
|
|
16
|
+
contentOne={item.contentOne}
|
|
17
|
+
contentTwo={item.contentTwo}
|
|
18
|
+
/>
|
|
19
|
+
))}
|
|
20
|
+
</div>
|
|
21
|
+
)
|
|
22
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import React from "react"
|
|
2
|
+
import { Logo } from "../logo/Logo"
|
|
3
|
+
|
|
4
|
+
import { frontPage } from "../../common/content/front-page-content"
|
|
5
|
+
import "./front-page.scss"
|
|
6
|
+
|
|
7
|
+
export const Contributors: React.FC = () => {
|
|
8
|
+
return (
|
|
9
|
+
<div className="contributors">
|
|
10
|
+
<div className="container">
|
|
11
|
+
<div className="contributor-logo-header">
|
|
12
|
+
<Logo dark horizontal={false} />
|
|
13
|
+
|
|
14
|
+
<h3>Support for {frontPage.pageTitle} provided by</h3>
|
|
15
|
+
</div>
|
|
16
|
+
<div className="contributors-wrap">
|
|
17
|
+
{frontPage.support.map((item, index) => (
|
|
18
|
+
<div key={index} className="contributor">
|
|
19
|
+
<a href={item.link} title={item.title}>
|
|
20
|
+
<img src={item.logo} alt={item.alt} loading="lazy" />
|
|
21
|
+
</a>
|
|
22
|
+
</div>
|
|
23
|
+
))}
|
|
24
|
+
</div>
|
|
25
|
+
</div>
|
|
26
|
+
</div>
|
|
27
|
+
)
|
|
28
|
+
}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
import React from "react"
|
|
2
|
+
import { Button } from "../button/Button"
|
|
3
|
+
import { Input } from "../input/Input"
|
|
4
|
+
import "./front-page.scss"
|
|
5
|
+
|
|
6
|
+
export const modes = {
|
|
7
|
+
// display prompt / email input / submit button
|
|
8
|
+
GET: Symbol("get"),
|
|
9
|
+
// display success message / done
|
|
10
|
+
SUCCESS: Symbol("success"),
|
|
11
|
+
// display error message / try again button
|
|
12
|
+
ERROR: Symbol("error"),
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export const submitHandler = (subscribe, mode, setMode, value) => (e) => {
|
|
16
|
+
e.preventDefault()
|
|
17
|
+
switch (mode) {
|
|
18
|
+
case modes.SUCCESS:
|
|
19
|
+
break
|
|
20
|
+
case modes.ERROR:
|
|
21
|
+
setMode(modes.GET)
|
|
22
|
+
break
|
|
23
|
+
case modes.GET:
|
|
24
|
+
default:
|
|
25
|
+
subscribe(value, (result) => {
|
|
26
|
+
if (result.data) {
|
|
27
|
+
setMode(
|
|
28
|
+
result.data.subscribeToNewsletter ? modes.SUCCESS : modes.ERROR,
|
|
29
|
+
)
|
|
30
|
+
}
|
|
31
|
+
})
|
|
32
|
+
break
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
const getText = (mode) => {
|
|
37
|
+
switch (mode) {
|
|
38
|
+
case modes.ERROR:
|
|
39
|
+
return {
|
|
40
|
+
headingText: "Whoops.",
|
|
41
|
+
messageText:
|
|
42
|
+
"We were unable to sign you up for updates. Please try again.",
|
|
43
|
+
buttonText: "Try Again",
|
|
44
|
+
}
|
|
45
|
+
case modes.SUCCESS:
|
|
46
|
+
return {
|
|
47
|
+
headingText: "Success!",
|
|
48
|
+
messageText: "You are now signed up to receive news updates.",
|
|
49
|
+
buttonText: "Done",
|
|
50
|
+
}
|
|
51
|
+
case modes.GET:
|
|
52
|
+
default:
|
|
53
|
+
return {
|
|
54
|
+
headingText: "Get Updates",
|
|
55
|
+
buttonText: "Subscribe",
|
|
56
|
+
messageText: "Find out about new version and future releases",
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
export const GetUpdates = ({ subscribe, initialMode = modes.GET }) => {
|
|
62
|
+
const [mode, setMode] = React.useState(initialMode)
|
|
63
|
+
const [value, setValue] = React.useState("")
|
|
64
|
+
const { headingText, messageText, buttonText } = getText(mode)
|
|
65
|
+
return (
|
|
66
|
+
<div className="get-updates-bar">
|
|
67
|
+
<div className="get-updates-label">
|
|
68
|
+
<h2>{headingText}</h2>
|
|
69
|
+
<h3>{messageText}</h3>
|
|
70
|
+
</div>
|
|
71
|
+
<form
|
|
72
|
+
onSubmit={submitHandler(subscribe, mode, setMode, value)}
|
|
73
|
+
className="get-updates-form"
|
|
74
|
+
>
|
|
75
|
+
<>
|
|
76
|
+
<div className="">{}</div>
|
|
77
|
+
{mode === modes.GET && (
|
|
78
|
+
<Input
|
|
79
|
+
type="email"
|
|
80
|
+
label="Email Address"
|
|
81
|
+
placeholder="email@openneuro.com"
|
|
82
|
+
labelStyle="float"
|
|
83
|
+
name="float-example"
|
|
84
|
+
value={value}
|
|
85
|
+
setValue={setValue}
|
|
86
|
+
/>
|
|
87
|
+
)}
|
|
88
|
+
<Button
|
|
89
|
+
type="submit"
|
|
90
|
+
size="small"
|
|
91
|
+
secondary
|
|
92
|
+
label={buttonText}
|
|
93
|
+
disabled={mode === modes.SUCCESS}
|
|
94
|
+
/>
|
|
95
|
+
</>
|
|
96
|
+
</form>
|
|
97
|
+
</div>
|
|
98
|
+
)
|
|
99
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import React from "react"
|
|
2
|
+
|
|
3
|
+
import { frontPage } from "../../common/content/front-page-content"
|
|
4
|
+
import "./front-page.scss"
|
|
5
|
+
|
|
6
|
+
export const Infographic: React.FC = () => {
|
|
7
|
+
return (
|
|
8
|
+
<div className="front-infographic">
|
|
9
|
+
<span className="bg-circle"></span>
|
|
10
|
+
{frontPage.infographic.map((item, index) => (
|
|
11
|
+
<div key={index} className="infograph-block" id={item.htmlID}>
|
|
12
|
+
<span>
|
|
13
|
+
<img
|
|
14
|
+
src={item.image}
|
|
15
|
+
alt=""
|
|
16
|
+
loading="lazy"
|
|
17
|
+
width="312"
|
|
18
|
+
height="349"
|
|
19
|
+
/>
|
|
20
|
+
</span>
|
|
21
|
+
<div className="info-card">
|
|
22
|
+
<h3>{item.name}</h3>
|
|
23
|
+
<div>{item.content}</div>
|
|
24
|
+
</div>
|
|
25
|
+
</div>
|
|
26
|
+
))}
|
|
27
|
+
<div className="view-docs">
|
|
28
|
+
<h3>Want to get started?</h3>
|
|
29
|
+
Check out the{" "}
|
|
30
|
+
<a href="https://docs.openneuro.org/user-guide">
|
|
31
|
+
OpenNeuro User Documentation
|
|
32
|
+
</a>
|
|
33
|
+
</div>
|
|
34
|
+
</div>
|
|
35
|
+
)
|
|
36
|
+
}
|