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

[SwipeableDrawer][Drawer] Include a simplified code-source version with only one Drawer, on the Drawer documentation. #20018

Closed
1 task done
TommyJackson85 opened this issue Mar 7, 2020 · 6 comments · Fixed by #20040
Labels
docs Improvements or additions to the documentation

Comments

@TommyJackson85
Copy link
Contributor

TommyJackson85 commented Mar 7, 2020

  • I have searched the issues of this repository and believe that this is not a duplicate.

Summary 💡

Just have second code source example (with sandbox) on the SwipeableDrawer section of the Drawer page.

The current one we have has 4 swipeable drawers from each side of the device. This is good to keep, but a lot of applications might only want it to be swiped from one direction for less complication.

We could keep the newer version as the prime example, and keep the 4 slides version as secondary.

Examples 🌈

This is the example I built:
https://codesandbox.io/s/material-demo-96r4c

Very simple set up.

Motivation 🔦

Just for developers who want to copy an easier version of it to work from. The current code source is just a little bit complicated in its set up. Took me around 10 + minutes bring it to just one drawer and cleaning up the code.

This could lead to including more complicated examples, like a mini variant drawer version (where it remains slightly closed), but it would also only have one drawer.

@mbrookes mbrookes added the docs Improvements or additions to the documentation label Mar 7, 2020
@mbrookes
Copy link
Member

mbrookes commented Mar 7, 2020

I wonder if we really need to show all the positions in a single demo?

@TommyJackson85
Copy link
Contributor Author

TommyJackson85 commented Mar 7, 2020 via email

@mbrookes
Copy link
Member

mbrookes commented Mar 7, 2020

Yes, I'm just questioning whether it's necessary to have the "four side" version. @oliviertassinari ?

@TommyJackson85
Copy link
Contributor Author

TommyJackson85 commented Mar 7, 2020 via email

@mbrookes
Copy link
Member

mbrookes commented Mar 7, 2020

In any case we can definitely add the simpler version. Would you like to submit a PR?

@TommyJackson85
Copy link
Contributor Author

TommyJackson85 commented Mar 7, 2020 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Improvements or additions to the documentation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants