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

Major state refactor #493

Merged
merged 141 commits into from
Jun 22, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
141 commits
Select commit Hold shift + click to select a range
c0fe54f
initial
alexreardon May 2, 2018
5883efd
Why does everything need to be some complicated?
alexreardon May 2, 2018
511e911
fixing reordering
alexreardon May 2, 2018
eab420d
changing key
alexreardon May 2, 2018
6c7dad0
collector
alexreardon May 3, 2018
c8e2c79
wip
alexreardon May 3, 2018
8617353
updating droppable dimension publisher
alexreardon May 3, 2018
bed898d
yum
alexreardon May 3, 2018
d951a2d
progress
alexreardon May 4, 2018
513d0b6
progress
alexreardon May 4, 2018
0805272
Merge branch 'master' of github.com:atlassian/react-beautiful-dnd int…
alexreardon May 4, 2018
7ef1da9
cancel drag on any uncaught errors
alexreardon May 6, 2018
756c7a3
initial
alexreardon May 6, 2018
c18cf5d
more accurate placeholder
alexreardon May 6, 2018
3a785c3
moving things around a little
alexreardon May 7, 2018
bc948ec
removing box-sizing
alexreardon May 7, 2018
9f616a0
wip
alexreardon May 7, 2018
184696c
fresh slate
alexreardon May 7, 2018
589ef1e
lets see how we go
alexreardon May 7, 2018
0f1fa90
pushing forward
alexreardon May 7, 2018
ed8a743
moving forward
alexreardon May 7, 2018
8946249
progressing
alexreardon May 8, 2018
cc70c39
moving
alexreardon May 8, 2018
72944e3
moving to middleware
alexreardon May 8, 2018
2ebe6cc
progress
alexreardon May 9, 2018
5521315
yolo
alexreardon May 9, 2018
af9c215
moving away from thunks
alexreardon May 9, 2018
2dfb621
killing it
alexreardon May 9, 2018
ce2e8ad
adding hook placeholder
alexreardon May 10, 2018
597a236
Merge branch 'master' of github.com:atlassian/react-beautiful-dnd int…
alexreardon May 11, 2018
d7b8c9c
upgrading hooks
alexreardon May 13, 2018
4c43a70
progress
alexreardon May 13, 2018
bebb771
Merge branch 'master' of github.com:atlassian/react-beautiful-dnd int…
alexreardon May 13, 2018
f7b265b
hooks are dead. long live hooks
alexreardon May 14, 2018
37dd5db
improving hooks
alexreardon May 14, 2018
53cbb39
progress
alexreardon May 14, 2018
d936e96
cleanup
alexreardon May 14, 2018
7f77585
getting into it
alexreardon May 14, 2018
7ea6a1a
today smells like success
alexreardon May 14, 2018
bac8217
bulk publish flow improvement
alexreardon May 15, 2018
2d7ecc1
yummy test
alexreardon May 15, 2018
a0fd7e8
adding a post drag end abort test
alexreardon May 15, 2018
25b5b36
moving files around
alexreardon May 15, 2018
85da3f4
improving things
alexreardon May 16, 2018
65b7eb0
surely something valuable
alexreardon May 16, 2018
9d0725b
fixing flow types
alexreardon May 17, 2018
beb3be8
cancel drop animating
alexreardon May 17, 2018
962212a
more drop tests
alexreardon May 17, 2018
ffe6d81
window scroll is a little nicer
alexreardon May 17, 2018
1f3812b
reorganing reducer imports
alexreardon May 17, 2018
d6adc0e
wip
alexreardon May 17, 2018
85305a5
Merge branch 'master' of github.com:atlassian/react-beautiful-dnd int…
alexreardon May 17, 2018
bb28a9d
original
alexreardon May 17, 2018
ad6ef18
wip
alexreardon May 17, 2018
9e0708f
moving direction movement into reducer
alexreardon May 17, 2018
cef948c
fixing infinite auto scroll recursion
alexreardon May 17, 2018
6725051
lots o tests
alexreardon May 18, 2018
2ea4a74
starting to look at auto scrolling
alexreardon May 18, 2018
d8d2710
fixing fluid scroller tests
alexreardon May 18, 2018
481f7ab
wip
alexreardon May 18, 2018
637cd00
removing old code
alexreardon May 18, 2018
d484233
almost done with fluid scroller
alexreardon May 18, 2018
a9a64c5
finishing remaining fluid scroller tests
alexreardon May 18, 2018
9daafd1
improving api
alexreardon May 18, 2018
311f1cb
jump scroller
alexreardon May 20, 2018
f9ef7a1
minor changes
alexreardon May 21, 2018
572df8b
moving things around a lot
alexreardon May 21, 2018
f5df39a
viewport is back in action
alexreardon May 21, 2018
edc21bb
drastically improved viewport
alexreardon May 21, 2018
23f50d5
test test tests
alexreardon May 21, 2018
c46f68b
removing older debug
alexreardon May 21, 2018
49b022a
testing++
alexreardon May 23, 2018
04ce4e8
more tests
alexreardon May 23, 2018
3bb4f07
dimension marshal
alexreardon May 23, 2018
966b2c6
more dimension marshal tests
alexreardon May 23, 2018
6182601
hooks integration is a go
alexreardon May 24, 2018
7576193
test wip
alexreardon May 24, 2018
947748e
fixing middleware tests
alexreardon May 24, 2018
3d80f27
lift
alexreardon May 24, 2018
b5aa18d
adding more stories
alexreardon May 25, 2018
e095ec7
wip
alexreardon May 25, 2018
e788c3e
wip
alexreardon May 27, 2018
5a5d2e7
bumping deps
alexreardon Jun 5, 2018
3c0677c
comments
alexreardon Jun 5, 2018
28b74f5
wip post drop updates
alexreardon Jun 5, 2018
eba6d05
fix moveable. fix autoscroll for window
alexreardon Jun 6, 2018
77b3cfd
fixing droppable scrolling
alexreardon Jun 6, 2018
b4df9d4
fixing dimension tests
alexreardon Jun 6, 2018
36a5fde
adding jest typeahead
alexreardon Jun 7, 2018
e6b1a64
bulk replace getting some love
alexreardon Jun 7, 2018
d57cfd4
getting tests ready
alexreardon Jun 7, 2018
00fd3eb
getting closer
alexreardon Jun 8, 2018
d9b9157
working, but not well
alexreardon Jun 8, 2018
ffc440a
progress
alexreardon Jun 12, 2018
fe77d8c
its happening
alexreardon Jun 12, 2018
59c3dc3
using style marshal to clear transitions will collecting
alexreardon Jun 12, 2018
8275cc7
new strategy for draggable dimension correcting
alexreardon Jun 12, 2018
bdf35bc
logging
alexreardon Jun 12, 2018
abb3abc
yeah
alexreardon Jun 12, 2018
2e9b757
updating types
alexreardon Jun 13, 2018
b17857d
yep
alexreardon Jun 13, 2018
b2c52aa
crazy simple use case now working
alexreardon Jun 13, 2018
c5a4dee
getting ready
alexreardon Jun 13, 2018
db7bd19
wip
alexreardon Jun 13, 2018
1bdced5
moving things around
alexreardon Jun 13, 2018
e802a06
loving it
alexreardon Jun 13, 2018
fdef7ae
correctly shifting draggable post update
alexreardon Jun 14, 2018
2add044
placeholder
alexreardon Jun 14, 2018
302d60c
now passing type down through context
alexreardon Jun 14, 2018
212365b
moving forward
alexreardon Jun 15, 2018
60ccbd4
renaming
alexreardon Jun 15, 2018
a6002a9
why hello there my old friend
alexreardon Jun 15, 2018
adfe9a9
new registration tests
alexreardon Jun 15, 2018
c542979
Merge branch 'master' of github.com:atlassian/react-beautiful-dnd int…
alexreardon Jun 15, 2018
41ecab2
more tests
alexreardon Jun 17, 2018
b816d09
dimension marshal tests wrapping up
alexreardon Jun 17, 2018
3e1aa00
finishing sub test
alexreardon Jun 17, 2018
59479bc
draggable and droppable dimension components and tests
alexreardon Jun 18, 2018
59c4c17
its happening
alexreardon Jun 18, 2018
3b4638e
tests everywhere
alexreardon Jun 18, 2018
9a1ef92
renaming and adding tests
alexreardon Jun 18, 2018
de452ca
connected draggable
alexreardon Jun 19, 2018
c396b92
fixing middleware tests
alexreardon Jun 19, 2018
3a012dc
more middleware tests
alexreardon Jun 19, 2018
8db4a5e
fixing middleware tests
alexreardon Jun 19, 2018
c0557bf
moving testing utilities out of connected draggable
alexreardon Jun 19, 2018
25d6f85
connected droppable
alexreardon Jun 19, 2018
e2bd8c6
connected droppable tests
alexreardon Jun 19, 2018
3a9ae20
dropping
alexreardon Jun 20, 2018
89487bb
finishing connected droppable tests
alexreardon Jun 20, 2018
a6fe9cb
draggable tests
alexreardon Jun 20, 2018
b990562
dimensions getting some love
alexreardon Jun 20, 2018
b99c2c3
removing old bulk replace
alexreardon Jun 20, 2018
d962533
fixing tests
alexreardon Jun 20, 2018
b514662
more tests
alexreardon Jun 20, 2018
dd1910d
fixing drag handle
alexreardon Jun 21, 2018
4a4d1cb
fixing touch sensor test
alexreardon Jun 21, 2018
9372d1e
ignoring pesky website cache directory
alexreardon Jun 21, 2018
de8fee6
fixing flow
alexreardon Jun 21, 2018
a0ccc4f
fixing linting
alexreardon Jun 21, 2018
9b28d51
it is okay to end a drag while preparing
alexreardon Jun 21, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 11 additions & 11 deletions .size-snapshot.json
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
{
"dist/react-beautiful-dnd.js": {
"bundled": 400269,
"minified": 151652,
"gzipped": 43139
"bundled": 391074,
"minified": 148259,
"gzipped": 42162
},
"dist/react-beautiful-dnd.min.js": {
"bundled": 358556,
"minified": 134751,
"gzipped": 38201
"bundled": 353559,
"minified": 135149,
"gzipped": 37985
},
"dist/react-beautiful-dnd.esm.js": {
"bundled": 177759,
"minified": 89807,
"gzipped": 22649,
"bundled": 174113,
"minified": 88585,
"gzipped": 22372,
"treeshaked": {
"rollup": 78288,
"webpack": 80060
"rollup": 76698,
"webpack": 78485
}
}
}
7 changes: 7 additions & 0 deletions jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,11 @@

module.exports = {
setupFiles: ['./test/setup.js'],
// node_modules is default.
// We want to ignore any tests in the website(sometimes they are added to / website /.cache)
testPathIgnorePatterns: ['/node_modules/', '/website/.cache/'],
watchPlugins: [
'jest-watch-typeahead/filename',
'jest-watch-typeahead/testname',
],
};
37 changes: 18 additions & 19 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,58 +47,57 @@
"babel-runtime": "^6.26.0",
"css-box-model": "^0.0.14",
"memoize-one": "^3.1.1",
"prop-types": "^15.6.0",
"prop-types": "^15.6.1",
"raf-schd": "^2.1.2",
"react-motion": "^0.5.2",
"react-redux": "^5.0.7",
"redux": "^4.0.0",
"redux-thunk": "^2.2.0",
"reselect": "^3.0.1",
"tiny-invariant": "^0.0.3"
},
"devDependencies": {
"@atlaskit/css-reset": "^2.0.0",
"@storybook/react": "^3.4.3",
"@atlaskit/css-reset": "^2.0.2",
"@storybook/react": "^3.4.6",
"babel-cli": "^6.26.0",
"babel-core": "^6.26.3",
"babel-eslint": "^8.2.3",
"babel-jest": "^22.4.3",
"babel-jest": "^23.0.1",
"babel-plugin-styled-components": "^1.5.1",
"babel-plugin-transform-class-properties": "^6.24.1",
"babel-plugin-transform-es2015-modules-commonjs": "^6.26.2",
"babel-plugin-transform-export-extensions": "^6.22.0",
"babel-plugin-transform-object-rest-spread": "^6.26.0",
"babel-plugin-transform-runtime": "^6.23.0",
"babel-preset-env": "^1.6.1",
"babel-preset-env": "^1.7.0",
"babel-preset-flow": "^6.23.0",
"babel-preset-react": "^6.24.1",
"cross-env": "^5.1.4",
"cross-env": "^5.1.6",
"enzyme": "^3.3.0",
"enzyme-adapter-react-16": "^1.1.1",
"eslint": "^4.19.1",
"eslint-config-airbnb": "^16.1.0",
"eslint-plugin-flowtype": "^2.46.3",
"eslint-plugin-import": "^2.11.0",
"eslint-plugin-jest": "^21.15.1",
"eslint-plugin-flowtype": "^2.49.3",
"eslint-plugin-import": "^2.12.0",
"eslint-plugin-jest": "^21.17.0",
"eslint-plugin-jsx-a11y": "^6.0.3",
"eslint-plugin-react": "^7.7.0",
"flow-bin": "0.71.0",
"jest": "^22.4.3",
"puppeteer": "^1.3.0",
"eslint-plugin-react": "^7.9.1",
"flow-bin": "0.73.0",
"jest": "^23.1.0",
"jest-watch-typeahead": "^0.1.0",
"puppeteer": "^1.4.0",
"raf-stub": "^2.0.2",
"react": "^16.3.1",
"react-dom": "^16.3.1",
"react-test-renderer": "^16.3.1",
"rimraf": "^2.6.2",
"rollup": "^0.58.2",
"rollup-plugin-babel": "^3.0.3",
"rollup-plugin-commonjs": "^9.1.0",
"rollup": "^0.59.4",
"rollup-plugin-babel": "^3.0.4",
"rollup-plugin-commonjs": "^9.1.3",
"rollup-plugin-node-resolve": "^3.3.0",
"rollup-plugin-replace": "^2.0.0",
"rollup-plugin-size-snapshot": "^0.4.0",
"rollup-plugin-strip": "^1.1.1",
"rollup-plugin-uglify": "^3.0.0",
"styled-components": "^3.2.6",
"styled-components": "^3.3.2",
"stylelint": "9.2.1",
"stylelint-config-standard": "^18.2.0",
"stylelint-config-styled-components": "^0.1.1",
Expand Down
8 changes: 3 additions & 5 deletions src/debug/timings.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
// @flow
import invariant from 'tiny-invariant';

type Records = {
[key: string]: number,
Expand All @@ -10,7 +11,7 @@ const flag: string = '__react-beautiful-dnd-debug-timings-hook__';

const isTimingsEnabled = (): boolean => Boolean(window[flag]);

// TEMP
// Debug: uncomment to enable
// window[flag] = true;

export const start = (key: string) => {
Expand All @@ -35,10 +36,7 @@ export const finish = (key: string) => {

const previous: ?number = records[key];

if (previous == null) {
console.error('cannot finish timing as no previous time found');
return;
}
invariant(previous, 'cannot finish timing as no previous time found');

const result: number = now - previous;
const rounded: string = result.toFixed(2);
Expand Down
Loading