-
Notifications
You must be signed in to change notification settings - Fork 1
fix(): rename pasted images #486
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
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #486 +/- ##
==========================================
+ Coverage 75.75% 75.81% +0.05%
==========================================
Files 599 599
Lines 18570 18574 +4
Branches 2855 2856 +1
==========================================
+ Hits 14067 14081 +14
+ Misses 3965 3954 -11
- Partials 538 539 +1
🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR adds functionality to automatically rename pasted images that have the generic browser-assigned name "image.png" to unique names with timestamps and UIDs, preventing naming conflicts when multiple screenshots or images are pasted.
- Implements
renamePastedImagefunction to rename files named "image.png" topasted-image-{timestamp}-{uid}.png - Integrates renaming into the paste handler workflow
- Adds comprehensive test coverage for paste functionality including renaming behavior
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| bricks/ai-portal/src/shared/useFilesUploading.ts | Adds renamePastedImage helper function and integrates it into the paste handler to rename generic "image.png" files to unique names |
| bricks/ai-portal/src/shared/useFilesUploading.spec.ts | Adds comprehensive test suite for paste functionality covering enabled/disabled states, file renaming, and edge cases |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
📐🤏 Size check result (710a29b...a33a247): Load all bricks together
Critical changes: None. See full changes
Load bricks by each packageCritical changes: None. See full changes
Load by each brickCritical changes:
See full changes
Critical details for brick eo-auto-complete
Critical details for brick eo-directory-tree
Critical details for brick eo-radio
Critical details for brick eo-switch
Critical details for brick form.general-input
Critical details for brick form.general-radio
Critical details for brick markdown.markdown-editor
|
依赖检查
组件之间的依赖声明,是微服务组件架构下的重要信息,请确保其正确性。
请勾选以下两组选项其中之一:
或者:
提交信息检查
Git 提交信息将决定包的版本发布及自动生成的 CHANGELOG,请检查工作内容与提交信息是否相符,并在以下每组选项中都依次确认。
破坏性变更:
feat作为提交类型。BREAKING CHANGE: 你的变更说明。新特性:
feat作为提交类型。问题修复:
fix作为提交类型。杂项工作:
即所有对下游使用者无任何影响、且没有必要显示在 CHANGELOG 中的改动,例如修改注释、测试用例、开发文档等:
chore,docs,test等作为提交类型。