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(ion-content): Position fixed slot relatively #19382

Closed
wants to merge 2 commits into from

Conversation

matthewdenobrega
Copy link

@matthewdenobrega matthewdenobrega commented Sep 18, 2019

Pull request checklist

Please check if your PR fulfills the following requirements:

  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been reviewed and added / updated if needed (for bug fixes / features)
  • Build (npm run build) was run locally and any changes were pushed
  • Lint (npm run lint) has passed locally and any fixes were made for failures

Pull request type

Please check the type of change your PR introduces:

  • Bugfix
  • Feature
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • Documentation content changes
  • Other (please describe):

What is the current behavior?

Issue Number: #17754

What is the new behavior?

The issue here was that the .inner-scroll class on main positions it absolutely, and main fills the whole screen. The fixed slot was not positioned (ie static) which means that it was hidden by main, even when main didn't have any content. Positioning the fixed slot relatively resolves this, and as far as I can see won't break anything, as the slot has no size when it does not have content.

Positioning the slot itself relatively didn't work, presumably because it is display:contents - so I put a wrapper. I'm happy to tweak this if there is a more elegant solution. I'm also not 100% sure on the naming, this is my first contribution to ionic.

Does this introduce a breaking change?

  • Yes
  • No

Other information

Copy link
Member

@brandyscarney brandyscarney left a comment

Choose a reason for hiding this comment

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

Thank you for the PR! Unfortunately this causes issues with the positioning of fab buttons, see /src/components/fab/test/basic:

vs master:

@brandyscarney
Copy link
Member

Thanks again for the PR! I am going to close this as this proposed solution breaks fab, however I did find what I think works for all cases and created a PR here: #19867

I'll add you as a co-author!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
package: core @ionic/core package
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants