You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Clicking into a text field selects its whole content #4358
I understand this is a bug report and questions should be posted in the Community Discussions
I searched issues and couldn’t find anything (or linked relevant results below)
Bug Description
Clicking or tapping into any OcTextInput selects its whole content, so the first key you type replaces the entire value instead of being inserted at the caret. Affects every form using it (user and group edit, space and link names, ...).
Cause: onFocus in packages/design-system/src/components/OcTextInput/OcTextInput.vue calls select() on every focus, mouse and touch included. Selecting everything only makes sense where it's wanted, e.g. the rename and create modals (which use selectionRange).
Reproduction Steps
As admin, open Users and click Edit on a user
Click (or tap) at the end of "First and last name"
Type Y
Expected Outcome
Y is inserted at the caret. Modals that preselect a name (rename, new file/folder) keep doing that.
Actual Outcome
The whole value is selected on focus and replaced by Y.
Activity