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

Added paging support to scrollview and ART #603

Closed
wants to merge 9 commits into from

Conversation

naqvitalha
Copy link

Addresses #601 , #602

@naqvitalha
Copy link
Author

Not sure how the new base should align with existing implementation such that everything remains composable. Help out, I have to add scrollTo logic

@@ -65,7 +65,8 @@
"inline-style-prefixer": "^3.0.6",
"normalize-css-color": "^1.0.2",
"prop-types": "^15.5.10",
"react-timer-mixin": "^0.13.3"
"react-timer-mixin": "^0.13.3",
"@ecliptic/react-art": "0.15.4-fork.1"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why the this fork instead of the one owned by FB?

https://www.npmjs.com/package/react-art

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check out this issue reactjs/react-art#113
The npm package no longer worked with latest react version, unfortunately no one is publishing it :(

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll consider this once the official package can be used

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why don't you fork and publish one yourself? We can use that

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No thanks. Let's get the official package updated

@@ -1,2 +1,3 @@
node_modules
dist
.idea
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please remove

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will do

timeStamp: Date.now()
});

export default class PagingScrollViewBase extends Component {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this a new component?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because it does not really use the base at all. Scroll events are raised using onTouchMove, you can snap browser scrolling. Switching the base seemed like a good idea to me. I'm open to ideas here since you know the code better

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What about scrolling without touch?

@@ -39,6 +39,7 @@ class View extends Component {
const {
hitSlop,
style,
domRef,
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had wrtiten a comment around this, onLayout does not fire and measure doesn't work on one of the views that I created. Needed dom node for clientWidth, let me know the alternative

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Didn't have the time to look into the missing callbacks issue

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK. I don't think I will accept a patch that hacks around what is apparently another issue though

@necolas
Copy link
Owner

necolas commented Aug 16, 2017

Also, please break this into 2 PRs. One for ART and the other for paging. Thanks

@naqvitalha
Copy link
Author

I know there should be multiple PRs. I'm mostly trying to understand contributing to this project right now. Just reply to my question, we can close this PR post that. I'll raise two in the future.

@necolas
Copy link
Owner

necolas commented Sep 7, 2017

Just reply to my question, we can close this PR post that.

Which question is that?

@naqvitalha
Copy link
Author

naqvitalha commented Sep 8, 2017

I meant respond to my replies to your review comments.

@necolas
Copy link
Owner

necolas commented Sep 10, 2017

I think you can break this into 2 PRs now

@necolas
Copy link
Owner

necolas commented Dec 18, 2017

Closing this PR for now. ART was added in 321051b.

@necolas necolas closed this Dec 18, 2017
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

Successfully merging this pull request may close these issues.

3 participants