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

feat: 导出组件支持复制 HTML (text/html) 格式的数据 close #2828 #2865

Merged
merged 3 commits into from
Aug 23, 2024

Conversation

lijinke666
Copy link
Member

@lijinke666 lijinke666 commented Aug 16, 2024

👀 PR includes

✨ Feature

  • New feature

📝 Description

  1. asyncGetAllPlainData 的基础上, 透出 asyncGetAllHtmlDataasyncGetAllData, 适配不同场景, 供开发者自由选择

text/plain

image

text/html

image

  1. 优化相关文档

🖼️ Screenshot

image

🔗 Related issue link

closes #2828 #2873

🔍 Self-Check before the merge

  • Add or update relevant docs.
  • Add or update relevant demos.
  • Add or update test case.
  • Add or update relevant TypeScript definitions.

Copy link

vercel bot commented Aug 16, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
antvis-s2 ❌ Failed (Inspect) Aug 23, 2024 9:01am

@github-actions github-actions bot added pr(feature) new feature next 2.0-next 版本的问题 labels Aug 16, 2024
@github-actions github-actions bot requested review from wjgogogo and wuhaiyang August 16, 2024 09:40
Copy link
Contributor

github-actions bot commented Aug 16, 2024

Size Change: +47 B (+0.01%)

Total Size: 329 kB

Filename Size Change
./packages/s2-core/dist/index.min.js 229 kB +17 B (+0.01%)
./packages/s2-react/dist/index.min.js 70.9 kB +30 B (+0.04%)
ℹ️ View Unchanged
Filename Size
./packages/s2-core/dist/style.min.css 388 B
./packages/s2-react/dist/style.min.css 3.88 kB
./packages/s2-vue/dist/index.min.js 22.9 kB
./packages/s2-vue/dist/style.min.css 1.97 kB

compressed-size-action

@codecov-commenter
Copy link

codecov-commenter commented Aug 16, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 80.81%. Comparing base (ecdc9c8) to head (486dcd1).
Report is 427 commits behind head on next.

Additional details and impacted files
@@            Coverage Diff             @@
##             next    #2865      +/-   ##
==========================================
+ Coverage   75.77%   80.81%   +5.03%     
==========================================
  Files         257      180      -77     
  Lines       11994    10412    -1582     
  Branches     2464     2360     -104     
==========================================
- Hits         9088     8414     -674     
+ Misses       1398      553     -845     
+ Partials     1508     1445      -63     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.


return data;
};

const getPlainData = async (split: string, isFormat: boolean) => {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

复制写入 text/plaintext/html
导出写入 text/plain

formatOptions: true,
});
*/
export const asyncGetAllHtmlData = async (params: CopyAllDataParams) => {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

有点纠结叫 asyncGetAllHTMLData 还是 asyncGetAllHtmlData, 前者更符合规范, 后者更符合风格一致性

Copy link
Member Author

@lijinke666 lijinke666 Aug 23, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

还是叫后者好了, XMLHttpRequest 也是类似 Http

@lijinke666 lijinke666 merged commit 444fbf5 into next Aug 23, 2024
10 of 11 checks passed
@lijinke666 lijinke666 deleted the feat-2828 branch August 23, 2024 09:07
@lijinke666
Copy link
Member Author

🎉 This PR is included in version @antv/s2-v2.0.0-next.27 🎉

The release is available on:

Your semantic-release bot 📦🚀

@lijinke666
Copy link
Member Author

🎉 This PR is included in version @antv/s2-react-v2.0.0-next.26 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
next 2.0-next 版本的问题 pr(feature) new feature released on @next
Projects
None yet
2 participants