JedWatson from React-select Repository

MIT License

05 Oct 2022

Haxkalibrr

The Select Component for React.js

Forked On 05 Oct 2022 at 05:59:27

R3b311i0n

started

Started On 05 Oct 2022 at 05:02:27

Devsfer1

started

Started On 05 Oct 2022 at 03:22:47
Issue Comment

Imanpalsingh

add aria-required attribute to select

Description

if aria-required is passed to the select component, it is not drilled to the input element. This update adds it to the props of Select component

This

<Select
    options={options}
    aria-required={true}
  /> 

will result in

<input aria-required="true  ... /> 

For issue : #5006

Forked On 05 Oct 2022 at 01:58:50

Imanpalsingh

Would need some editing if we merged both

@SimonSelg @Methuselah96 @Rall3n I have resolved the merge conflicts.

Let me know if you meant something else

Commented On 05 Oct 2022 at 01:58:50
Issue Comment

Rall3n

add aria-required attribute to select

Description

if aria-required is passed to the select component, it is not drilled to the input element. This update adds it to the props of Select component

This

<Select
    options={options}
    aria-required={true}
  /> 

will result in

<input aria-required="true  ... /> 

For issue : #5006

Forked On 05 Oct 2022 at 01:28:48

Rall3n

@Methuselah96 I added aria-required as part of the required PR.

Would need some editing if we merged both, but I think the ability to set aria-required separately should be added.

Commented On 05 Oct 2022 at 01:28:48
Issue Comment

Krajcikondra

Uncaught TypeError: dispatcher.useInsertionEffect is not a function

Hi, after update react to version 18 react select throw following error:

Uncaught TypeError: dispatcher.useInsertionEffect is not a function 

Are you planning to update this package for react 18? Thanks in advance

Forked On 05 Oct 2022 at 01:17:06

Krajcikondra

update react-dom from v17 to v18 solved my problem.

Commented On 05 Oct 2022 at 01:17:06
Issue Comment

Methuselah96

Uncaught TypeError: dispatcher.useInsertionEffect is not a function

Hi, after update react to version 18 react select throw following error:

Uncaught TypeError: dispatcher.useInsertionEffect is not a function 

Are you planning to update this package for react 18? Thanks in advance

Forked On 05 Oct 2022 at 01:16:01

Methuselah96

This package should with React 18. Can you check out https://github.com/JedWatson/react-select/issues/5076 and see if anything there helps resolve your issue?

Commented On 05 Oct 2022 at 01:16:01
Issue Comment

Methuselah96

add aria-required attribute to select

Description

if aria-required is passed to the select component, it is not drilled to the input element. This update adds it to the props of Select component

This

<Select
    options={options}
    aria-required={true}
  /> 

will result in

<input aria-required="true  ... /> 

For issue : #5006

Forked On 05 Oct 2022 at 12:56:53

Methuselah96

@Rall3n Any objections?

Commented On 05 Oct 2022 at 12:56:53

Piotrkonowrocki

started

Started On 05 Oct 2022 at 11:29:53

Shirinapr

The Select Component for React.js

Forked On 05 Oct 2022 at 11:13:40

Shirinapr

started

Started On 05 Oct 2022 at 11:12:31

Pntpbgn

started

Started On 05 Oct 2022 at 11:05:00
Issue Comment

SimonSelg

add aria-required attribute to select

Description

if aria-required is passed to the select component, it is not drilled to the input element. This update adds it to the props of Select component

This

<Select
    options={options}
    aria-required={true}
  /> 

will result in

<input aria-required="true  ... /> 

For issue : #5006

Forked On 05 Oct 2022 at 08:54:31

SimonSelg

@imanpalsingh thanks for the PR! are there any updates on getting this merged?

Commented On 05 Oct 2022 at 08:54:31
Issue Comment

Umerfarooq69

React Select [v2] focus outline color

Hi i want to change the focus outline color, how can i do this

Thanks

Forked On 05 Oct 2022 at 08:42:14

Umerfarooq69

Yeah bro i got it thank you for the help

Regards

[image: Mailtrack] https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11& Sender notified by Mailtrack https://mailtrack.io?utm_source=gmail&utm_medium=signature&utm_campaign=signaturevirality11& 10/05/22, 01:41:40 PM Remove

On Tue, Oct 4, 2022 at 11:33 PM aashim @.***> wrote:

This one worked for me!

— Reply to this email directly, view it on GitHub https://github.com/JedWatson/react-select/issues/2728#issuecomment-1267416196, or unsubscribe https://github.com/notifications/unsubscribe-auth/AK2HP2TIYW74DAI474KUK43WBRZ6HANCNFSM4FFYEHRA . You are receiving this because you commented.Message ID: @.***>

Commented On 05 Oct 2022 at 08:42:14

Kim-Hyunjo

started

Started On 05 Oct 2022 at 07:35:06

Mohitk0208

started

Started On 05 Oct 2022 at 06:43:36
Issue Comment

Rikusen0335

`Cannot read properties of undefined (reading 'name')` with useFieldArray in react-hook-form

So thus using react-select and useFieldArray in react-hook-form which is handles array of input, will occur the error that Cannot read properties of undefined (reading 'name').

I'm really not sure what's the reason of issue, I investigated few hours but I still doesn't know why. This could be a question but instead I opened this issue as bug.

How to reproduce

  1. Go here (CodeSandbox)
  2. Add Select
  3. Select anything you want

Are you reporting a bug or runtime error?

Runtime error probably?

Forked On 04 Oct 2022 at 08:18:38

Rikusen0335

I must notify about that. Thank you.

Commented On 04 Oct 2022 at 08:18:38

Etylsarin

started

Started On 04 Oct 2022 at 07:59:02
Issue Comment

Jphawk

Async: defaultOptions={true} gives strange behaviour when lodash debounce function is in use

Hello,

I noticed that AsyncSelect behaviour is weird when I use a lodash debounce function together with defaultOptions={true}. When I use keyboard to focus the Select component, I can start typing and both loading state in the menu and options appear as intended. However, when I click the Select component, I can see a Loading state in the Menu for a moment which I think isn't supposed to be visible and then it disappears. Looks like there is some difference in handling this between onClick and onFocus events.

Here is a Sandbox where you can check this bug.

How to reproduce?

  1. On first render click on AsyncSelect with an empty input
  2. Menu with Loading state appears which is not an intended behaviour. If the Menu with Loading doesn't appear, try reloading the page and it will be there.
  3. After that component works as intended. Loading state doesn't appear on next clicks with an empty input.

Can be compared to the keyboard behaviour:

  1. On first render Tab to AsyncSelect
  2. Menu with Loading state doesn't appear
  3. Component works as intended

Are you reporting a bug or runtime error?

Bug

Forked On 04 Oct 2022 at 07:24:38

Jphawk

@Rall3n

If I understand this correctly the main problem you encounter is that the "Loading..." text inside the menu is visible on click, but not on keyboard focus immediately after first render?

Correct, "Loading..." is visible on first click, but not on first keyboard focus. I would like to prevent "Loading..." appearing on first click. I understand why it is happening and that the select is still loading options, but users don't need to see this process on the first interaction when they haven't even typed anything yet. To me it looks like a UI bug, which clearly doesn't happen on focus and on click as well when it's not the first one.

I'm aware of openMenuOnClick and openMenuOnFocus, but these props do not solve my problem of preventing "Loading..." to appear on first click with debounce. I'm quite happy with default functionality, but in this case defaults for focus and click behaviour should match from the UI point of view, but they don't.

Commented On 04 Oct 2022 at 07:24:38
Issue Comment

Aashimgarg

React Select [v2] focus outline color

Hi i want to change the focus outline color, how can i do this

Thanks

Forked On 04 Oct 2022 at 06:32:55

Aashimgarg

 <Select className="styles" />
   .styles {
    input:focus-visible {
      outline : 0px !important;
    }
  } 

This one worked for me!

Commented On 04 Oct 2022 at 06:32:55
Issue Comment

Aashimgarg

React Select [v2] focus outline color

Hi i want to change the focus outline color, how can i do this

Thanks

Forked On 04 Oct 2022 at 06:32:08

Aashimgarg

 <Select className="styles"  />
   .styles {
    input:focus-visible {
      outline : 0px !important;
    }
  } 

This one worked for me!

Commented On 04 Oct 2022 at 06:32:08
Issue Comment

Aashimgarg

React Select [v2] focus outline color

Hi i want to change the focus outline color, how can i do this

Thanks

Forked On 04 Oct 2022 at 06:30:09

Aashimgarg

const customStyles = { control: (styles) => ({ ...styles, boxShadow: 'none !important', '*': { boxShadow: 'none !important', }, }), };

Commented On 04 Oct 2022 at 06:30:09

Dxman

started

Started On 04 Oct 2022 at 06:25:30

DenisAlliswell

started

Started On 04 Oct 2022 at 04:22:54

About Repository

The Select Component for React.js
Language: TypeScript
Star: 25212
Fork: 3968
Watchers: 25212
Open Issues: 284
https://github.com/JedWatson/react-select
MIT License
Last updated: 05 Oct 2022