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

Spellcheck attribute does not work #69

Closed
evnz opened this issue Dec 10, 2020 · 2 comments
Closed

Spellcheck attribute does not work #69

evnz opened this issue Dec 10, 2020 · 2 comments

Comments

@evnz
Copy link

evnz commented Dec 10, 2020

Spellcheck attribute does not propagate down to the TextArea and so it doesn't work.

@jaywcjlove
Copy link
Member

@evnz ??? did not get your point.

<TextArea
ref={textarea}
tabSize={tabSize}
className={`${prefixCls}-input`}
prefixCls={prefixCls}
value={value}
autoFocus={autoFocus}
{...textareaProps}
onScroll={handleScroll}
onMouseOver={() => leftScroll.current = true}
onMouseLeave={() => leftScroll.current = false}
onChange={handleChange}
/>
)}

@evnz
Copy link
Author

evnz commented Dec 10, 2020

@jaywcjlove thanks for clarifying, I was passing the spellcheck attribute in the wrong way 🤦

I was doing

 <MDEditor
        spellCheck={true}
        autoFocus={props.autoFocus}
        preview="edit"
        value={props.input}
        onChange={(detail) => props.onChange(detail!)}
 />

^Which is the incorrect way

instead of

<MDEditor
        textareaProps={
            {spellCheck:"true"}
        }
        autoFocus={props.autoFocus}
        preview="edit"
        value={props.input}
        onChange={(detail) => props.onChange(detail!)}
/>

@evnz evnz closed this as completed Dec 10, 2020
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

No branches or pull requests

2 participants