grayhatdevelopers / material-web-components-react

Material Web Components for React ⚛
https://material-web-components-react.grayhat.studio
MIT License
28 stars 3 forks source link
design-system lit lit-element lit-html material-design material-ui material-you react react-components ui-components ui-library web web-components web-components-library

Material Web Components for React

npm version release docs docs

A thin React wrapper over @material/web. Aims to be a locally-installable, accessible and customizable Material standard for React. Recommended to use with MUI. Free. Open Source. Looking for maintainers.

hero

Installation

To use Material Web Components for React as a library in your project, run:

npm install material-web-components-react

Usage

Here's a general example of how the components can be used:

import React from 'react';
import Button from 'material-web-components-react/button';

function Example() {
  return (
    <div>
      <Button>Click me</Button>
    </div>
  );
}

For a detailed reference on usage, you might want to check out the source code of the NextJS demo. It's simple!

Under the hood, this library simply uses the official @material/web components. Visit the official Material Web Components docs to learn how to use those components. The props remain the same!

Contributing

We're looking for maintainers and contributors!

Roadmap 🚀

Credits

Huge shout out to Elizabeth Mitchell (asyncLiz) and the rest of the Material Design team for their awesome Web Components implementation.

Thank you Travis Reeder for your Web Component implementation of Navigation Rail. I had to copy it to this project. I couldn't use yours directly because it would import @material/web again and bring conflicts.

Thanks for making the crappy, brain-dead wrapper components:

Thanks for improving the demo:

Thanks for building BottomSheet and Snackbar: