Skip to content

feat(textAreaInput): Add an autoresize option #4210

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

Merged
merged 8 commits into from
Apr 30, 2025
Merged

Conversation

cpsievert
Copy link
Collaborator

@cpsievert cpsievert commented Apr 25, 2025

Adds an autoresize option to textAreaInput(). When TRUE, the input will automatically resize the height to the contents of the input.

Note this effectively backports this feature from Python (posit-dev/py-shiny#463) to R.

In this PR, I decided to bundle the autoresize logic with "core" Shiny assets, removing the need for another dependency. This is handy since I'd also like re-use this logic for another component in rstudio/bslib#1204.

IMPORTANT: if we do end up bundling the autoresize logic with shiny.js, py-shiny should get updated to gut the autoresize dependency.

@cpsievert cpsievert requested a review from wch April 25, 2025 23:07
@cpsievert cpsievert force-pushed the feat/textAreaAutoResize branch from cad1639 to e0fc4dc Compare April 25, 2025 23:07
@cpsievert cpsievert added this to the Next Release milestone Apr 25, 2025
@cpsievert cpsievert requested a review from wch April 29, 2025 21:55
@cpsievert
Copy link
Collaborator Author

@wch ok to merge?

@cpsievert cpsievert merged commit 316c3c8 into main Apr 30, 2025
12 checks passed
@cpsievert cpsievert deleted the feat/textAreaAutoResize branch April 30, 2025 23:34
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