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: 使用innerHTML赋值后转小程序时,a标签转view标签+img转image标签时,把width和height写入style属性【latest】 #16781

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

zhengyanan1
Copy link
Contributor

这个 PR 做了什么? (简要描述所做更改)

  1. 对于innerHTML生成的小程序, a=>text 变成 a=>view
  2. 对于innerHTML生成的小程序, img=>image时,如果有width和height,把这2个值写入style属性内

这个 PR 是什么类型? (至少选择一个)

  • 错误修复(Bugfix) issue: fix #
  • 新功能(Feature)
  • 代码重构(Refactor)
  • TypeScript 类型定义修改(Typings)
  • 文档修改(Docs)
  • 代码风格更新(Code style update)
  • 其他,请描述(Other, please describe):

这个 PR 涉及以下平台:

  • 所有小程序
  • 微信小程序
  • 支付宝小程序
  • 百度小程序
  • 字节跳动小程序
  • QQ 轻应用
  • 京东小程序
  • 快应用平台(QuickApp)
  • Web 平台(H5)
  • 移动端(React-Native)
  • 鸿蒙(harmony)

Copy link

codecov bot commented Nov 1, 2024

Codecov Report

Attention: Patch coverage is 25.00000% with 9 lines in your changes missing coverage. Please review.

Project coverage is 58.50%. Comparing base (c17123d) to head (b81a8f9).
Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
...taro-runtime/src/dom-external/inner-html/parser.ts 10.00% 9 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main   #16781      +/-   ##
==========================================
- Coverage   58.52%   58.50%   -0.02%     
==========================================
  Files         466      466              
  Lines       27099    27109      +10     
  Branches     5908     5959      +51     
==========================================
+ Hits        15860    15861       +1     
+ Misses       9895     9773     -122     
- Partials     1344     1475     +131     
Flag Coverage Δ
taro-cli 73.67% <ø> (ø)
taro-runtime 59.47% <25.00%> (-0.40%) ⬇️
taro-web 52.68% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
...s/taro-runtime/src/dom-external/inner-html/tags.ts 100.00% <100.00%> (ø)
...taro-runtime/src/dom-external/inner-html/parser.ts 75.16% <10.00%> (-4.56%) ⬇️

... and 20 files with indirect coverage changes

This was referenced Nov 2, 2024
@skyclouds2001
Copy link
Contributor

这个和 #16780 冲突了吧

@zhengyanan1 zhengyanan1 changed the title fix: 使用innerHTML赋值后转小程序时,a标签转view标签+img转image标签时,把width和height写入style属性 fix: 使用innerHTML赋值后转小程序时,a标签转view标签+img转image标签时,把width和height写入style属性【latest】 Nov 29, 2024
This was referenced Nov 30, 2024
@tutuxxx tutuxxx removed this from the 4.0.8 milestone Dec 2, 2024
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.

3 participants