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: textarea focus with proper padding #399

Closed
wants to merge 1 commit into from

Conversation

yue4u
Copy link
Contributor

@yue4u yue4u commented Oct 10, 2023

やったこと

fix textarea focus issue especially when count is shown.

before

image

textarea-before-2.mp4

after

image

textarea-after-3.mp4

動作確認環境

チェックリスト

不要なチェック項目は消して構いません

  • 破壊的変更がある場合には、対象のパッケージのメジャーバージョンが上がっていることを確認した
  • 追加したコンポーネントが index.ts から再 export されている
  • README やドキュメントに影響があることを確認した

padding: calc(9px / 0.875) 0 ${(p) => (p.noBottomPadding ? 0 : '')};
padding: calc(9px / 0.875) calc(8px / 0.875)
${(p) => (p.withCountPadding ? 0 : '')};
/* Using padding on textarea will cause text overflow */
Copy link
Contributor Author

Choose a reason for hiding this comment

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

スクリーンショット 2023-10-10 11 00 17
maybe replace padding with border in the future?

@toshusai
Copy link
Contributor

Thank you very much for your PR. I've considered a different approach and created a new PR based on that. I'd love to hear your thoughts on it.
PR: #404

Copy link
Contributor

@toshusai toshusai left a comment

Choose a reason for hiding this comment

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

I apologize for my misunderstanding. It seems that your PR is fine. Thank you for your contribution.

@toshusai
Copy link
Contributor

With this PR, one issue is addressed, but another problem has been identified. When clicking on borderBottom, the cursor ends up behind the text that follows. We might want to consider using focus() to properly restore the click position.

@toshusai
Copy link
Contributor

toshusai commented Dec 4, 2023

Thank you for submitting the PR. This PR has resolved the issue.
#413

@toshusai toshusai closed this Dec 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants