-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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
[Bug]: cursor jumps to end of input when editing, when using useArgs
#25673
Comments
Hi @emlai The below code using
@shilman, if you do have additional inputs please do provide them... |
You wrote |
Hi @emlai, When I am using the code (i.e., the code in the sandbox link) you have provided, I got the below error message to change it to capital Can you please provide the steps to reproduce using |
@Satya-Manikanta It's reproduced in the sandbox which means you are having a local issue of some kind. If you are having problems using Storybook, you could ask for help in Stack overflow for example. |
That's a false positive eslint warning. See #21115. You can ignore it, or work around it with: render: function Render(args) { |
Disable react-hooks/rules-of-hooks in ESLint config overrides: [
{
files: ["**/*.stories.tsx"],
rules: {
"react-hooks/rules-of-hooks": "off",
},
},
], |
Hi @emlai i have resolved the bug please access it at :- |
Describe the bug
When using
useArgs
in a story, with thevalue
prop of a simple<input>
in theargs
, editing the input in the middle causes the cursor to move to the end.Using
React.useState
insteaduseArgs
, the cursor behaves normally. (but then the SB controls won't be updated when editing the input field.)Also on the Docs page, the non-primary stories'
<input>
fields cannot be edited at all.To Reproduce
https://stackblitz.com/edit/github-4dcmyf?file=src%2Fstories%2FTextField.stories.jsx&preset=node
System
Reproduced on 8.0.0-alpha.11 and 7.6.10.
Additional context
No response
The text was updated successfully, but these errors were encountered: