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: change z-index of element for compatibility with iOS 18 #2765

Closed
wants to merge 1 commit into from

Conversation

tappert-it
Copy link

@tappert-it tappert-it commented Oct 1, 2024

Changed z-index to unset to avoid overlapping of blocks on mobile displays in iOS 18

1. Why is this change necessary?

Compatibility with iOS 18. Without the change overlapping of blocks can occur on Safari, so the cart button is not clickable anymore.

2. What does this change do, exactly?

The z-index of the div with class "product--image-container" is before set to 1000. This change unsets the z-index.

3. Describe each step to reproduce the issue or behaviour.

Occurs after the update to iOS 18 on Safari and Chrome (and maybe more browsers). The image container overlaps the cart button.

4. Please link to the relevant issues (if any).

https://forum.shopware.com/t/ios-safari-oder-chrome-detailseite-buttons-ohne-funktion/105237/

5. Which documentation changes (if any) need to be made because of this PR?

6. Checklist

  • I have written tests and verified that they fail without my change
  • I have squashed any insignificant commits
  • This change has comments for package types, values, functions, and non-obvious lines of code
  • I have read the contribution requirements and fulfil them.

changed z-index to unset to avoid overlapping of blocks on mobile displays in iOS 18
Copy link

github-actions bot commented Oct 1, 2024


Fails
🚫 The commit title `Update content.tpl

changed z-index to unset to avoid overlapping of blocks on mobile displays in iOS 18` does not match our requirements. Please follow: www.conventionalcommits.org

Warnings
⚠️ The Pull Request doesn't contain any changes to the Upgrade file

@tappert-it tappert-it changed the title Change z-index of element for compatibility with iOS 18 fix: hange z-index of element for compatibility with iOS 18 Oct 1, 2024
@tappert-it tappert-it changed the title fix: hange z-index of element for compatibility with iOS 18 fix: change z-index of element for compatibility with iOS 18 Oct 1, 2024
@aragon999
Copy link
Contributor

I would like to avoid inline CSS. Is this also fixed, if the z-index is defined here:

.product--image-container {
.unitize-margin(0, 0, 20, 0);
width: 100%;
// Fixing the one pixel rounding error occurring when using a percentage based width.
.image-slider--slide {
margin-right: -0.5px;
}
}

To me it still sounds like a issue of floating elements in WebKit. But probably the fix is fine. But it should be added as a comment, that it has been added due to a bug in WebKit, otherwise someone may remove it, as it has no effect in other browser engines.

@mitelg
Copy link
Contributor

mitelg commented Oct 1, 2024

I also would like to avoid specific OS fixes 🤔 for me it still sounds like a bug like @aragon999 already mentioned.

Also inline styles should not be the solution 🙂

@tappert-it
Copy link
Author

Defining the z-index in the detail.less should do the trick, i think.

As we can see in the forum, it's not the perfect solution, as long as iOS 18 seems a bit uncalculatable in this issue. But at least customers can reach the cart button.

@mitelg
Copy link
Contributor

mitelg commented Oct 21, 2024

Hey @tappert-it

This PR was closed due to inactivity. In the meantime some other fixes were proposed in the forum, which sound more applicable. Maybe one of those can be provided instead.

@mitelg mitelg closed this Oct 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants