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

Alias onClick to onTouchTap for ListItem right button/icon. #1967

Closed
wants to merge 1 commit into from

Conversation

hartmamt
Copy link

We have had a lot of issues with initializeTapEventsPlugin when trying to build a Material-UI project with Webpack using React as an external. The way the tap event plugin is injected just does not work with an external React. This may be more widespread (in other components) but our biggest pain point right now is not being able to expand nested list items. Is there a problem with aliasing onClick to onTouchTap for those who might not be able to handle touch events or those that have an issue with the initializeTapEvents plugin and Webpack externals?

We have had a lot of issues with initializeTapEventsPlugin when trying to build a Material-UI project with Webpack using React as an external.  The way the tap event plugin is injected just does not work with an external React.  This may be more widespread (in other components) but our biggest pain point right now is not being able to expand nested list items.  Is there a problem with aliasing onClick to onTouchTap for those who might not be able to handle touch events or those that have an issue with the initializeTapEvents plugin and Webpack externals?
@hartmamt hartmamt changed the title Alias onClick to onTouchTap for right button Alias onClick to onTouchTap for ListItem right button/icon. Oct 22, 2015
@hartmamt
Copy link
Author

Work around for this issue... Quick webpack example of how to patch react-with-addons with the tap events plugin. This is required as far as I can tell if you want to use material-ui with react as an external dependency. https://github.com/hartmamt/react-with-tap-events

@hartmamt
Copy link
Author

Closing this issue. I prefer my workaround which is actually a real solution to the problem...it isn't material-ui's fault that this is happening.

@hartmamt hartmamt closed this Oct 26, 2015
@hartmamt hartmamt deleted the patch-1 branch October 26, 2015 10:01
@hartmamt
Copy link
Author

Yes. There is an open ticket here. zilverline/react-tap-event-plugin#22. Definitely not a material-ui issue.

@oliviertassinari
Copy link
Member

Ok thanks.

mnajdova pushed a commit to mnajdova/material-ui that referenced this pull request Nov 10, 2020
@zannager zannager added the component: button This is the name of the generic UI component, not the React module! label Mar 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: button This is the name of the generic UI component, not the React module!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants