Skip to content

Commit c7432e3

Browse files
committed
initial bumping
1 parent 9c544d6 commit c7432e3

File tree

82 files changed

+2241
-1323
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

82 files changed

+2241
-1323
lines changed

.stylelintrc.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
"rules": {
1616
"declaration-empty-line-before": null,
1717
"comment-empty-line-before": null,
18-
"block-no-empty": null
18+
"block-no-empty": null,
19+
"value-keyword-case": null
1920
}
2021
}

browser-test-harness.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -45,11 +45,11 @@ Promise.all([
4545
process.on('exit', () => {
4646
child.kill();
4747
});
48-
child.on('exit', code => {
48+
child.on('exit', (code) => {
4949
process.exit(code);
5050
});
5151
})
52-
.catch(error => {
52+
.catch((error) => {
5353
// eslint-disable-next-line no-console
5454
console.error('Unable to spin up standalone servers');
5555
// eslint-disable-next-line no-console

csp-server/app.jsx

+6-6
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,8 @@ import PropTypes from 'prop-types';
77
import { DragDropContext, Droppable, Draggable } from '../src';
88

99
// fake data generator
10-
const getItems = count =>
11-
Array.from({ length: count }, (v, k) => k).map(k => ({
10+
const getItems = (count) =>
11+
Array.from({ length: count }, (v, k) => k).map((k) => ({
1212
id: `item-${k}`,
1313
content: `item ${k}`,
1414
}));
@@ -33,8 +33,8 @@ export default class App extends Component {
3333
}
3434

3535
componentDidMount() {
36-
document.addEventListener('securitypolicyviolation', e => {
37-
this.setState(state => {
36+
document.addEventListener('securitypolicyviolation', (e) => {
37+
this.setState((state) => {
3838
return { cspErrors: [...state.cspErrors, e] };
3939
});
4040
});
@@ -67,11 +67,11 @@ export default class App extends Component {
6767
<b id="cspErrors">{this.state.cspErrors.length}</b>
6868
</h1>
6969
<Droppable droppableId="droppable">
70-
{droppableProvided => (
70+
{(droppableProvided) => (
7171
<div ref={droppableProvided.innerRef}>
7272
{this.state.items.map((item, index) => (
7373
<Draggable key={item.id} draggableId={item.id} index={index}>
74-
{draggableProvided => (
74+
{(draggableProvided) => (
7575
<div
7676
ref={draggableProvided.innerRef}
7777
{...draggableProvided.draggableProps}

csp-server/main.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ const compiler = webpack(config);
1414
// $ExpectError
1515
compiler.outputFileSystem = fs;
1616
// $ExpectError
17-
const outputPath = compiler.compilers.find(cfg => cfg.name === 'client')
17+
const outputPath = compiler.compilers.find((cfg) => cfg.name === 'client')
1818
.outputPath;
1919

2020
compiler.run(() => {

cypress/integration/content-security-policy.spec.js

+4-13
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,8 @@ import ports from '../../server-ports';
77
function commonTest(url: string, cspTest: string) {
88
cy.visit(url);
99

10-
cy.get(getHandleSelector())
11-
.eq(0)
12-
.as('first')
13-
.should('contain', 'item 0');
14-
cy.get(getHandleSelector())
15-
.eq(1)
16-
.should('contain', 'item 1');
10+
cy.get(getHandleSelector()).eq(0).as('first').should('contain', 'item 0');
11+
cy.get(getHandleSelector()).eq(1).should('contain', 'item 1');
1712

1813
// reorder operation
1914
cy.get('@first')
@@ -28,13 +23,9 @@ function commonTest(url: string, cspTest: string) {
2823

2924
// order now 2, 1
3025
// note: not using get aliases as they where returning incorrect results
31-
cy.get(getHandleSelector())
32-
.eq(0)
33-
.should('contain', 'item 1');
26+
cy.get(getHandleSelector()).eq(0).should('contain', 'item 1');
3427

35-
cy.get(getHandleSelector())
36-
.eq(1)
37-
.should('contain', 'item 0');
28+
cy.get(getHandleSelector()).eq(1).should('contain', 'item 0');
3829

3930
// element should maintain focus post drag
4031
cy.focused().should('contain', 'item 0');

cypress/integration/reorder-lists.spec.js

+4-13
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,9 @@ describe('reorder lists', () => {
1010

1111
it('should reorder lists', () => {
1212
// order: Jake, BMO
13-
cy.get('h4')
14-
.eq(0)
15-
.as('first')
16-
.should('contain', 'Jake');
13+
cy.get('h4').eq(0).as('first').should('contain', 'Jake');
1714

18-
cy.get('h4')
19-
.eq(1)
20-
.should('contain', 'BMO');
15+
cy.get('h4').eq(1).should('contain', 'BMO');
2116

2217
// reorder operation
2318
cy.get('@first')
@@ -31,13 +26,9 @@ describe('reorder lists', () => {
3126

3227
// order now 2, 1
3328
// note: not using get aliases as they where returning incorrect results
34-
cy.get('h4')
35-
.eq(0)
36-
.should('contain', 'BMO');
29+
cy.get('h4').eq(0).should('contain', 'BMO');
3730

3831
// index of the drag handle has changed
39-
cy.get('h4')
40-
.eq(1)
41-
.should('contain', 'Jake');
32+
cy.get('h4').eq(1).should('contain', 'Jake');
4233
});
4334
});

cypress/integration/reorder-virtual.spec.js

+3-7
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,9 @@ describe('reorder: virtual', () => {
1111
it('should reorder within a list', () => {
1212
const movements: number = 12;
1313

14-
cy.get(getHandleSelector())
15-
.first()
16-
.as('item');
14+
cy.get(getHandleSelector()).first().as('item');
1715

18-
cy.get('@item')
19-
.invoke('attr', 'data-testid')
20-
.as('item-id');
16+
cy.get('@item').invoke('attr', 'data-testid').as('item-id');
2117

2218
cy.get('@item')
2319
.invoke('attr', 'data-index')
@@ -48,7 +44,7 @@ describe('reorder: virtual', () => {
4844
// This is setting up a chain of commands and this test will not wait
4945
// for a 'promise' to resolve. Linting is getting confused by .then
5046
// eslint-disable-next-line jest/valid-expect-in-promise
51-
cy.get('@item-id').then(id => {
47+
cy.get('@item-id').then((id) => {
5248
cy.get(getHandleSelector(id))
5349
.invoke('attr', 'data-index')
5450
.should('equal', `${movements}`);

cypress/integration/reorder.spec.js

+4-13
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,8 @@ describe('reorder', () => {
1010

1111
it('should reorder within a list', () => {
1212
// order: 1, 2
13-
cy.get(getHandleSelector())
14-
.eq(0)
15-
.as('first')
16-
.should('contain', 'id:1');
17-
cy.get(getHandleSelector())
18-
.eq(1)
19-
.should('contain', 'id:2');
13+
cy.get(getHandleSelector()).eq(0).as('first').should('contain', 'id:1');
14+
cy.get(getHandleSelector()).eq(1).should('contain', 'id:2');
2015

2116
// reorder operation
2217
cy.get('@first')
@@ -31,13 +26,9 @@ describe('reorder', () => {
3126

3227
// order now 2, 1
3328
// note: not using get aliases as they where returning incorrect results
34-
cy.get(getHandleSelector())
35-
.eq(0)
36-
.should('contain', 'id:2');
29+
cy.get(getHandleSelector()).eq(0).should('contain', 'id:2');
3730

38-
cy.get(getHandleSelector())
39-
.eq(1)
40-
.should('contain', 'id:1');
31+
cy.get(getHandleSelector()).eq(1).should('contain', 'id:1');
4132

4233
// element should maintain focus post drag
4334
cy.focused().should('contain', 'id:1');

docs/api/draggable.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ The function is provided with three arguments:
109109
110110
```js
111111
type DraggableProvided = {|
112-
innerRef: HTMLElement => void,
112+
innerRef: (HTMLElement) => void,
113113
draggableProps: DraggableProps,
114114
// will be null if the draggable is disabled
115115
dragHandleProps: ?DragHandleProps,

docs/guides/dragging-svgs.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ You can use the `src` of an `<img>` tag (which is a `HTMLElement`) to have a dra
6969
```js
7070
// ✅ supported
7171
<Draggable draggableId="supported" index={0}>
72-
{provided => (
72+
{(provided) => (
7373
<img
7474
{...provided.draggableProps}
7575
{...provided.dragHandleProps}
@@ -95,7 +95,7 @@ Alternatively you could also apply the SVG as a `background-image` to another `H
9595
```js
9696
// ✅ supported
9797
<Draggable draggableId="supported" index={0}>
98-
{provided => (
98+
{(provided) => (
9999
<div
100100
{...provided.draggableProps}
101101
{...provided.dragHandleProps}

docs/guides/screen-reader.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ When making a screen reader announcement we recommend announcing the position of
7070
It reads more natural to hear "You have moved an item to position 2" than "You have moved an item to index 1"
7171

7272
```js
73-
const position = index => index + 1;
73+
const position = (index) => index + 1;
7474

7575
const startPosition = position(source.index);
7676
const endPosition = destination ? position(destination.index) : null;

docs/guides/using-inner-ref.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ class Person extends React.Component {
6262
}
6363

6464
class App extends React.Component {
65-
setPersonRef = ref => {
65+
setPersonRef = (ref) => {
6666
this.personRef = ref;
6767

6868
// When the ref changes it will firstly be set to null
@@ -71,7 +71,7 @@ class App extends React.Component {
7171
this.personRef.sayHello();
7272
}
7373
};
74-
setDivRef = ref => {
74+
setDivRef = (ref) => {
7575
this.divRef = ref;
7676

7777
if (this.divRef) {
@@ -190,7 +190,7 @@ If you also need to use the _HTMLElement_ within your _Component_ you can have a
190190

191191
```js
192192
class Person extends React.Component {
193-
setRef = ref => {
193+
setRef = (ref) => {
194194
// keep a reference to the dom ref as an instance property
195195
this.ref = ref;
196196
// give the dom ref to react-beautiful-dnd

package.json

+46-46
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
"/src"
3131
],
3232
"config": {
33-
"prettier_target": "*.{js,jsx,md,json} src/**/*.{js,jsx,md,json} test/**/*.{js,jsx,md,json} docs/**/*.{js,jsx,md,json} stories/**/*.{js,jsx,md,json} cypress/**/*.{js,jsx,md,json}"
33+
"prettier_target": "*.{js,jsx,md,json} src/**/*.{js,jsx,md,json} test/**/*.{js,jsx,md,json} docs/**/*.{js,jsx,md,json} stories/**/*.{js,jsx,md,json} cypress/**/*.{js,jsx,md,json} csp-server/**/*.{js,jsx,md,json}"
3434
},
3535
"scripts": {
3636
"test:accessibility": "lighthouse http://localhost:9002/iframe.html?id=single-vertical-list--basic --chrome-flags='--headless' --output=json --output=html --output-path=./test-reports/lighthouse/a11y.json && node a11y-audit-parse.js",
@@ -56,7 +56,7 @@
5656
"prepublishOnly": "yarn build"
5757
},
5858
"dependencies": {
59-
"@babel/runtime": "^7.8.4",
59+
"@babel/runtime": "^7.9.2",
6060
"css-box-model": "^1.2.0",
6161
"memoize-one": "^5.1.1",
6262
"raf-schd": "^4.0.2",
@@ -65,82 +65,82 @@
6565
"use-memo-one": "^1.1.1"
6666
},
6767
"devDependencies": {
68-
"@atlaskit/css-reset": "^5.0.9",
69-
"@atlaskit/theme": "^9.5.0",
70-
"@babel/core": "^7.8.4",
68+
"@atlaskit/css-reset": "^5.0.10",
69+
"@atlaskit/theme": "^9.5.2",
70+
"@babel/core": "^7.9.0",
7171
"@babel/plugin-proposal-class-properties": "^7.8.3",
72-
"@babel/plugin-transform-modules-commonjs": "^7.8.3",
72+
"@babel/plugin-transform-modules-commonjs": "^7.9.0",
7373
"@babel/plugin-transform-object-assign": "^7.8.3",
74-
"@babel/plugin-transform-runtime": "^7.8.3",
75-
"@babel/preset-env": "^7.8.4",
76-
"@babel/preset-flow": "^7.8.3",
77-
"@babel/preset-react": "^7.8.3",
74+
"@babel/plugin-transform-runtime": "^7.9.0",
75+
"@babel/preset-env": "^7.9.5",
76+
"@babel/preset-flow": "^7.9.0",
77+
"@babel/preset-react": "^7.9.4",
7878
"@emotion/babel-preset-css-prop": "^10.0.27",
79-
"@emotion/core": "^10.0.27",
79+
"@emotion/core": "^10.0.28",
8080
"@emotion/styled": "^10.0.27",
81-
"@storybook/react": "^5.3.10",
82-
"@storybook/theming": "^5.3.10",
83-
"@testing-library/react": "^9.4.0",
81+
"@storybook/react": "^5.3.18",
82+
"@storybook/theming": "^5.3.18",
83+
"@testing-library/react": "^10.0.2",
8484
"babel-core": "^7.0.0-bridge.0",
85-
"babel-eslint": "^10.0.3",
86-
"babel-jest": "^25.1.0",
87-
"babel-loader": "^8.0.6",
85+
"babel-eslint": "^10.1.0",
86+
"babel-jest": "^25.3.0",
87+
"babel-loader": "^8.1.0",
8888
"babel-plugin-dev-expression": "^0.2.2",
89-
"babel-plugin-emotion": "^10.0.27",
90-
"cross-env": "^7.0.0",
91-
"cypress": "^4.0.0",
89+
"babel-plugin-emotion": "^10.0.33",
90+
"cross-env": "^7.0.2",
91+
"cypress": "^4.4.0",
9292
"emotion-theming": "^10.0.27",
9393
"enzyme": "^3.11.0",
9494
"enzyme-adapter-react-16": "^1.15.2",
9595
"eslint": "6.8.0",
96-
"eslint-config-airbnb": "^18.0.1",
97-
"eslint-config-prettier": "^6.10.0",
98-
"eslint-plugin-cypress": "^2.8.1",
96+
"eslint-config-airbnb": "^18.1.0",
97+
"eslint-config-prettier": "^6.10.1",
98+
"eslint-plugin-cypress": "^2.10.3",
9999
"eslint-plugin-emotion": "^10.0.27",
100100
"eslint-plugin-es5": "^1.5.0",
101-
"eslint-plugin-flowtype": "^4.6.0",
102-
"eslint-plugin-import": "^2.20.1",
103-
"eslint-plugin-jest": "^23.6.0",
101+
"eslint-plugin-flowtype": "^4.7.0",
102+
"eslint-plugin-import": "^2.20.2",
103+
"eslint-plugin-jest": "^23.8.2",
104104
"eslint-plugin-jsx-a11y": "^6.2.1",
105-
"eslint-plugin-prettier": "^3.1.2",
106-
"eslint-plugin-react": "^7.18.3",
107-
"eslint-plugin-react-hooks": "^2.3.0",
105+
"eslint-plugin-prettier": "^3.1.3",
106+
"eslint-plugin-react": "^7.19.0",
107+
"eslint-plugin-react-hooks": "^3.0.0",
108108
"flow-bin": "0.110.1",
109-
"fs-extra": "^8.0.1",
109+
"fs-extra": "^9.0.0",
110110
"globby": "^11.0.0",
111-
"jest": "^25.1.0",
112-
"jest-axe": "^3.3.0",
111+
"jest": "^25.3.0",
112+
"jest-axe": "^3.4.0",
113113
"jest-junit": "^10.0.0",
114-
"jest-watch-typeahead": "^0.4.2",
114+
"jest-watch-typeahead": "^0.5.0",
115115
"lighthouse": "^5.6.0",
116116
"markdown-it": "^10.0.0",
117-
"prettier": "^1.19.1",
117+
"prettier": "^2.0.4",
118118
"raf-stub": "^3.0.0",
119-
"react": "^16.12.0",
120-
"react-dom": "^16.12.0",
121-
"react-test-renderer": "^16.12.0",
119+
"react": "^16.13.1",
120+
"react-dom": "^16.13.1",
121+
"react-test-renderer": "^16.13.1",
122122
"react-virtualized": "^9.21.2",
123123
"react-window": "^1.8.5",
124124
"require-from-string": "^2.0.2",
125-
"rimraf": "^3.0.1",
126-
"rollup": "^1.31.0",
127-
"rollup-plugin-babel": "^4.3.3",
125+
"rimraf": "^3.0.2",
126+
"rollup": "^2.6.1",
127+
"rollup-plugin-babel": "^4.4.0",
128128
"rollup-plugin-commonjs": "^10.1.0",
129129
"rollup-plugin-json": "^4.0.0",
130130
"rollup-plugin-node-resolve": "^5.1.0",
131131
"rollup-plugin-replace": "^2.2.0",
132132
"rollup-plugin-size-snapshot": "^0.11.0",
133133
"rollup-plugin-strip": "^1.2.2",
134-
"rollup-plugin-terser": "^5.2.0",
135-
"styled-components": "5.0.0",
136-
"stylelint": "^13.0.0",
134+
"rollup-plugin-terser": "^5.3.0",
135+
"styled-components": "5.1.0",
136+
"stylelint": "^13.3.2",
137137
"stylelint-config-prettier": "^8.0.1",
138138
"stylelint-config-recommended": "^3.0.0",
139-
"stylelint-config-standard": "^19.0.0",
139+
"stylelint-config-standard": "^20.0.0",
140140
"stylelint-config-styled-components": "^0.1.1",
141-
"stylelint-processor-styled-components": "^1.9.0",
141+
"stylelint-processor-styled-components": "^1.10.0",
142142
"wait-port": "^0.2.7",
143-
"webpack": "^4.41.5"
143+
"webpack": "^4.42.1"
144144
},
145145
"peerDependencies": {
146146
"react": "^16.8.5",

0 commit comments

Comments
 (0)