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: Fix position style check #19875

Closed
wants to merge 1 commit into from
Closed

Conversation

SadWood
Copy link

@SadWood SadWood commented Apr 29, 2024

Brief Information

This pull request is in the type of:

  • bug fixing
  • new feature
  • others

What does this PR do?

Fixed issues

Details

Before: What was the problem?

Starting from version 6.6.10 of vue-echarts, the style of the container has been modified to include position:absolute. This change results in an update being triggered when switching routes, where an inline style of position:relative is added to the container, causing it to lose its height.

Reproducible Git repository address: https://github.com/SadWood/vue-quick-start-template/tree/echarts_bug

After: How does it behave after the fixing?

The values returned by getComputedStyle are resolved values, so it's straightforward to determine whether getComputedStyle(container, 'position') is 'absolute' or not.

Document Info

One of the following should be checked.

  • This PR doesn't relate to document changes
  • The document should be updated later
  • The document changes have been made in apache/echarts-doc#xxx

Misc

ZRender Changes

  • This PR depends on ZRender changes (ecomfe/zrender#xxx).

Related test cases or examples to use the new APIs

N.A.

Others

Merging options

  • Please squash the commits into a single one when merging.

Other information

@100pah
Copy link
Member

100pah commented May 9, 2024

@SadWood Could we have the more detailed info about how to reproduce the issue or what is the issue caused?

Starting from version 6.6.10 of vue-echarts, the style of the container has been modified to include position:absolute. This change results in an update being triggered when switching routes, where an inline style of position:relative is added to the container, causing it to lose its height.

I am afraid I can not get:

  • what is "modified to include position:absolute"
  • why "an inline style of position:relative is added to the container cause lose height"

@SadWood
Copy link
Author

SadWood commented May 13, 2024

@SadWood Could we have the more detailed info about how to reproduce the issue or what is the issue caused?

Starting from version 6.6.10 of vue-echarts, the style of the container has been modified to include position:absolute. This change results in an update being triggered when switching routes, where an inline style of position:relative is added to the container, causing it to lose its height.

I am afraid I can not get:

  • what is "modified to include position:absolute"
  • why "an inline style of position:relative is added to the container cause lose height"

This issue is fixed in v6.7.2 of vue-echarts, thanks!
#783
commit

@plainheart plainheart closed this May 13, 2024
@SadWood SadWood deleted the fix-position branch May 14, 2024 01:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants