Skip to content

Commit f3d0e6a

Browse files
authored
Merge branch 'master' into typo
2 parents f1303de + 17ab36e commit f3d0e6a

File tree

20 files changed

+526
-84
lines changed

20 files changed

+526
-84
lines changed

cypress/fixtures/selectors.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
"indicatorClear": ".react-select__clear-indicator",
1111
"indicatorDropdown": ".react-select__dropdown-indicator",
1212
"menu": ".react-select__menu",
13+
"control": ".react-select__control",
1314
"menuOption": ".react-select__option",
1415
"noOptionsValue": ".react-select__menu-notice--no-options",
1516
"placeholder": ".react-select__placeholder",

cypress/integration/single-select.spec.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,11 @@ describe('Single Select', () => {
107107
.click({ force: true })
108108
.find('input')
109109
.should('exist')
110-
.should('be.disabled');
110+
.should('be.disabled')
111+
// control should have aria-disabled
112+
.get(selector.singleBasicSelect)
113+
.find(selector.control)
114+
.should('have.attr', 'aria-disabled', 'true');
111115
});
112116

113117
it(`Should filter options when searching in view: ${viewport}`, () => {

docs/pages/typescript/index.tsx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,12 @@ The \`actionMeta\` parameter is optional. \`ActionMeta\` is a union that is disc
9191
You can use module augmentation to add custom props to the \`Select\` prop types:
9292
9393
~~~jsx
94-
declare module 'react-select/dist/declarations/src/Select' {
94+
import type {} from 'react-select/base';
95+
// This import is necessary for module augmentation.
96+
// It allows us to extend the 'Props' interface in the 'react-select/base' module
97+
// and add our custom property 'myCustomProp' to it.
98+
99+
declare module 'react-select/base' {
95100
export interface Props<
96101
Option,
97102
IsMulti extends boolean,

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,8 @@
5858
"jest-in-case": "^1.0.2",
5959
"prettier": "^2.2.1",
6060
"style-loader": "^0.23.1",
61-
"typescript": "^4.1.3"
61+
"typescript": "^4.1.3",
62+
"user-agent-data-types": "^0.4.2"
6263
},
6364
"scripts": {
6465
"build": "preconstruct build",

packages/react-select/CHANGELOG.md

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,33 @@
11
# react-select
22

3+
## 5.8.0
4+
5+
### Minor Changes
6+
7+
- [`884f1c42`](https://github.com/JedWatson/react-select/commit/884f1c42549faad7cb210169223b427ad6f0c9fd) [#5758](https://github.com/JedWatson/react-select/pull/5758) Thanks [@Ke1sy](https://github.com/Ke1sy)! - 1. Added 'aria-activedescendant' for input and functionality to calculate it;
8+
9+
2. Added role 'option' and 'aria-selected' for option;
10+
3. Added role 'listbox' for menu;
11+
4. Added tests for 'aria-activedescendant';
12+
5. Changes in aria-live region:
13+
14+
- the instructions how to use select will be announced only one time when user focuses the input for the first time.
15+
- instructions for menu or selected value will be announced only once after focusing them.
16+
- removed aria-live for focused option because currently with correct aria-attributes it will be announced by screenreader natively as well as the status of this option (active or disabled).
17+
- separated ariaContext into ariaFocused, ariaResults, ariaGuidance to avoid announcing redundant information and higlight only current change.
18+
19+
## 5.7.7
20+
21+
### Patch Changes
22+
23+
- [`224a8f0d`](https://github.com/JedWatson/react-select/commit/224a8f0d01a5b6200ff10280a0d7a9b613383032) [#5666](https://github.com/JedWatson/react-select/pull/5666) Thanks [@yhy-1](https://github.com/yhy-1)! - Add aria-disabled to select's control component.
24+
25+
## 5.7.6
26+
27+
### Patch Changes
28+
29+
- [`f6315cd5`](https://github.com/JedWatson/react-select/commit/f6315cd5feddb2e9ea168bcad391b29990b53afb) [#5672](https://github.com/JedWatson/react-select/pull/5672) Thanks [@tu4mo](https://github.com/tu4mo)! - Fix for calling non-cancellable scroll events
30+
331
## 5.7.5
432

533
### Patch Changes

packages/react-select/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "react-select",
3-
"version": "5.7.5",
3+
"version": "5.8.0",
44
"description": "A Select control built with and for ReactJS",
55
"main": "dist/react-select.cjs.js",
66
"module": "dist/react-select.esm.js",

0 commit comments

Comments
 (0)