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

[v4-beta.15] Toast middle = top #16271

Closed
peterpeterparker opened this issue Nov 8, 2018 · 2 comments
Closed

[v4-beta.15] Toast middle = top #16271

peterpeterparker opened this issue Nov 8, 2018 · 2 comments

Comments

@peterpeterparker
Copy link
Contributor

Bug Report

Ionic Info

Ionic v4-beta.15

Describe the Bug
It looks like the toast "middle" is actually displayed at the top.

Steps to Reproduce

  1. Go to documentation https://beta.ionicframework.com/docs/api/toast
  2. Click on 'Show toast middle'

P.S.: I observe the same behavior with my app

Expected Behavior
Toast middle = middle of the screen

Additional Context
Not sure but it might happens since beta.15 only

@ionitron-bot ionitron-bot bot added the triage label Nov 8, 2018
@peterpeterparker peterpeterparker changed the title Toast middle = top [v4-beta.15] Toast middle = top Nov 8, 2018
@ionitron-bot ionitron-bot bot removed the triage label Nov 8, 2018
@brandyscarney
Copy link
Member

Thank you for the issue! I am able to reproduce this.

Note to team: I had to downgrade to beta.11 in order to see toast working properly. The style for top is not being applied from here:

const topPosition = Math.floor(
  baseEl.clientHeight / 2 - wrapperEle.clientHeight / 2
);
wrapperEle.style.top = `${topPosition}px`;
wrapperAnimation.fromTo('opacity', 0.01, 1);

This is because baseEl is being read in as a shadow root. cc @manucorporat

@ionitron-bot
Copy link

ionitron-bot bot commented Dec 14, 2018

Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out.

@ionitron-bot ionitron-bot bot locked and limited conversation to collaborators Dec 14, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants