Skip to content

PORTALS-3651: Portals FileEntity Page: Header card #2024

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

Open
wants to merge 12 commits into
base: main
Choose a base branch
from

Conversation

kianamcc
Copy link
Collaborator

@kianamcc kianamcc commented Jul 8, 2025

Comment on lines 77 to 78
<DetailsPageLayout>
<DetailsPageMenu menuSections={fileEntityPageSections} />
Copy link
Collaborator

@nickgros nickgros Jul 15, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Taking a look at these again since your last refactor, and I think it might be slightly cleaner to use the DetailsPageContent component and pass it a list of sections. It will render the menu and section headers for you, and ensure the style is more consistent with existing details pages.

Or will we need more customization than that component provides?

“kianamcc” added 2 commits July 15, 2025 13:13
@kianamcc
Copy link
Collaborator Author

kianamcc commented Jul 15, 2025

Screenshot 2025-07-15 at 1 43 12 PM

I will let Adam know about the font size and spacing differences

@@ -24,6 +24,10 @@ const DetailsPageMenu = ({
}
}

const filteredMenuSections = menuSections.filter(
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I need a component in here alongside the other sections without it actually showing up as an option in the menu (SynapseFileEntityLinkCard)

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do all of our existing details page sections have a truthy id and title? If so, then this works

@@ -24,6 +24,10 @@ const DetailsPageMenu = ({
}
}

const filteredMenuSections = menuSections.filter(
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do all of our existing details page sections have a truthy id and title? If so, then this works

import DetailsPageLayout from '@/components/DetailsPageLayout'
import HeaderCard from 'synapse-react-client/components/HeaderCard'
import CitationPopover from 'synapse-react-client/components/CitationPopover'
import { DetailsPageContent } from '../../components/DetailsPage/DetailsPageContentLayout'
import SynapseFileEntityLinkCard from './SynapseFileEntityLinkCard'

function FileEntityPage() {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we need to change the styles (but not the layout/DOM) of the header card, e.g. to give the title a different font size, we could apply styles to this component that target those elements.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants