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 tooltip style calculation #123

Merged
merged 2 commits into from
Dec 30, 2024
Merged

Conversation

mitchthorson
Copy link
Contributor

@mitchthorson mitchthorson commented Dec 30, 2024

What's in this pull request

  • Bug fix
  • New component/feature
  • Component update
  • Documentation update
  • Other

Description

Tooltip would throw error when inside of web component. This fix checks if ancestors are instances of Element before calling getComputedStyle on them. This avoids the error.

Before submitting, please check that you've

  • Formatted your code correctly (i.e., prettier cleaned it up)
  • Documented any new components or features
  • Added any changes in this PR to the CHANGELOG.md Next section
  • If this pull request includes a new component or feature, has it been exported from one of the library's entry points?
  • Does the component dispatch relevant interaction events? (ie: on:click, on:change, etc.)
  • Does the component directory include description and usage information in .stories.svelte?

Tooltip would throw error when compiled inside web component without
checking.
@mitchthorson mitchthorson marked this pull request as ready for review December 30, 2024 21:25
@mitchthorson mitchthorson merged commit 8313afa into main Dec 30, 2024
1 check passed
@mitchthorson mitchthorson deleted the fix-tooltip-style-calculation branch December 30, 2024 21:37
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