Skip to content

fix: Fixed the issue where the inputSlot format was not displayed whe…#3050

Merged
YannLynn merged 2 commits intomainfrom
fix/3049
Dec 5, 2025
Merged

fix: Fixed the issue where the inputSlot format was not displayed whe…#3050
YannLynn merged 2 commits intomainfrom
fix/3049

Conversation

@YyumeiZhang
Copy link
Collaborator

@YyumeiZhang YyumeiZhang commented Nov 24, 2025

…n pasting content into an empty inputSlot

中文模板 / Chinese Template

What kind of change does this PR introduce? (check at least one)

  • Bugfix
  • Feature
  • Code style update
  • Refactor
  • Test Case
  • TypeScript definition update
  • Document improve
  • CI/CD improve
  • Branch sync
  • Other, please describe:

PR description

Fixes #3049

Changelog

🇨🇳 Chinese


🇺🇸 English

Checklist

  • Test or no need
  • Document or no need
  • Changelog or no need

Other

  • Skip Changelog

Additional information

@YyumeiZhang YyumeiZhang requested a review from YannLynn November 24, 2025 06:47
@codesandbox-ci
Copy link

codesandbox-ci bot commented Nov 24, 2025

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit 271bcff:

Sandbox Source
pr-story Configuration

@cypress
Copy link

cypress bot commented Nov 24, 2025

semi-design    Run #3388

Run Properties:  status check passed Passed #3388  •  git commit 84a0f80694 ℹ️: Merge 271bcff95eb6f0392509ed89521a19e87cbc5d2c into 43af16d46da655674617ba112336...
Project semi-design
Branch Review fix/3049
Run status status check passed Passed #3388
Run duration 08m 36s
Commit git commit 84a0f80694 ℹ️: Merge 271bcff95eb6f0392509ed89521a19e87cbc5d2c into 43af16d46da655674617ba112336...
Committer YyumeiZhang
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 0
Tests that did not run due to a developer annotating a test with .skip  Pending 13
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 291
⚠️ You've recorded test results over your free plan limit.
Upgrade your plan to view test results.
View all changes introduced in this branch ↗︎

* Removing zero-width characters directly will cause the input slot to disappear.
* Therefore, this paste behavior is processed to retrieve the text portion and replace the zero-width characters with the text content.
*/
export function specialPasteLogicForInputSlot(event: ClipboardEvent, $from: any, tr: Transaction, dispatch: (tr: Transaction) => void) {
Copy link
Collaborator

Choose a reason for hiding this comment

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

有考虑过替换的场景吗?这个场景也有类似的问题

@YannLynn YannLynn merged commit 3974f4c into main Dec 5, 2025
13 checks passed
@YannLynn YannLynn deleted the fix/3049 branch December 5, 2025 03:30
@cypress
Copy link

cypress bot commented Dec 5, 2025

semi-design    Run #3396

Run Properties:  status check passed Passed #3396  •  git commit 3974f4c71e: fix: Fixed the issue where the inputSlot format was not displayed whe… (#3050)
Project semi-design
Branch Review main
Run status status check passed Passed #3396
Run duration 08m 27s
Commit git commit 3974f4c71e: fix: Fixed the issue where the inputSlot format was not displayed whe… (#3050)
Committer YyumeiZhang
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 0
Tests that did not run due to a developer annotating a test with .skip  Pending 13
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 291
⚠️ You've recorded test results over your free plan limit.
Upgrade your plan to view test results.
View all changes introduced in this branch ↗︎

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.

[BUG] [AIChatInput] 内容粘贴不到空的 inputSlot 中

2 participants