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

[g-plugin-svg-renderer] 生成的 <foreignObject> 上丢失了 className #1485

Closed
xiaoiver opened this issue Aug 15, 2023 · 0 comments
Closed
Assignees
Labels

Comments

@xiaoiver
Copy link
Contributor

xiaoiver commented Aug 15, 2023

截屏2023-08-15 上午11 13 23
const p2 = new HTML({
  id: 'p1',
  name: 'p2-name',
  className: 'p2-classname',
  style: {
    x: 400,
    y: 100,
    width: 60,
    height: 30,
    innerHTML: 'p2',
  },
});

另外在 Safari 中测试时发现 width / height 放在 <foreignObject> 的 style 中是无效的,必须要作为 attribute,但 Chrome 是支持的,因此是一个兼容性问题。

@xiaoiver xiaoiver self-assigned this Aug 15, 2023
@xiaoiver xiaoiver added the bug label Aug 15, 2023
xiaoiver added a commit that referenced this issue Aug 15, 2023
…1486)

* fix: move width & height from style to attribute in <foreignObject> #1485

* chore: commit changeset
xiaoiver added a commit that referenced this issue Aug 15, 2023
* fix: move width & height from style to attribute in <foreignObject> (#1486)

* fix: move width & height from style to attribute in <foreignObject> #1485

* chore: commit changeset

* chore(release): bump version (#1488)

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant