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

Fix gallery close button being hidden behind the title #1181

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Conversation

julianlam
Copy link
Contributor

@julianlam julianlam commented Oct 21, 2024

Current behaviour on openbeta.io:

image

The close button is visible, and not clickable.

Noting that alternating the order of elements resolves the overlap issue.

Seems related (regression?) from fdb64aa which ironically was trying to fix the same thing.

Reproduction Steps

  1. Browse to a climb (e.g. Super Solenoid), click on the uploaded image.
  2. Note that the close button is hidden behind the header.

Devices, etc.

  • Fedora Linux, Firefox and Chromium — Reproduces
  • Android, Firefox and Chrome — reproduces

Copy link

vercel bot commented Oct 21, 2024

@julianlam is attempting to deploy a commit to the openbeta-dev Team on Vercel.

A member of the Team first needs to authorize it.

@julianlam julianlam changed the title fix: regression from fdb64aa049e37ee0128942d0e21ca3982e1d28ac which caused gallery close button to be behind the title Fix gallery close button being hidden behind the title Oct 21, 2024
@clintonlunn
Copy link
Collaborator

Hi @julianlam I am not able to reproduce this issue. Can add some steps to reproduce this and include the some details on device and browser?

@vnugent am I able to add @julianlam to the openbeta organization (or whatever capacity it requires) so he doesn't need to PR from a fork?

Copy link

vercel bot commented Oct 31, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
open-tacos ✅ Ready (Inspect) Visit Preview Oct 31, 2024 6:03pm

@vnugent
Copy link
Contributor

vnugent commented Oct 31, 2024

am I able to add @julianlam to the openbeta organization (or whatever capacity it requires) so he doesn't need to PR from a fork?

I just added him

@julianlam
Copy link
Contributor Author

@clintonlunn Done

@clintonlunn clintonlunn self-requested a review November 2, 2024 20:02
@@ -23,14 +23,14 @@ export const DialogContent = React.forwardRef<any, Props>(
className={clx(fullScreen ? 'dialog-wide' : 'dialog-default')} {...props} ref={forwardedRef}
>
<div className='flex items-center px-2'>
<DialogPrimitive.Title className='dialog-title'>
Copy link
Collaborator

@clintonlunn clintonlunn Nov 2, 2024

Choose a reason for hiding this comment

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

@julianlam after some investigation, I believe the issue is actually that the <PhotoGalleryModal /> component is using the defaults.css css rules, versus what was being tested in fdb64aa, that was referencing the global.css file.

I think some evidence to point to this is the new /climb//climbId page when updated to Next13 in #1195, the DialogClose button is correctly showing. This new page would be referencing global.css.

So while your fix works, maybe the fix is instead to alter the css in defaults.css to match global.css so we aren't relying on order, but instead restricting the title from overlapping with the close button:

  .dialog-title {
    @apply flex-grow text-center bg-base-100 leading-none;
  }

  .dialog-close-button {
    @apply mx-auto z-auto;
  }

What do you think?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Given that the PhotoGalleryModal is only invoked by the climbs page (I don't actually know if this is true), and that it is being refactored, might be this PR is moot and can be closed 😄

Copy link
Collaborator

Choose a reason for hiding this comment

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

For sure, I do think it's still valid to fix though because it definitely is an issue during the transition period of old climb page to new climb page.

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.

3 participants