How to use rmwc - 2 common examples

To help you get started, we’ve selected a few rmwc examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github webiny / webiny-js / packages / webiny-client-ui-material / src / Menu / Menu.js View on Github external
// @flow
import * as React from "react";
import { Menu as BaseMenu, MenuItem, MenuAnchor } from "rmwc/Menu";

type Props = {
    // One or more Menu.Item components.
    children: React.ChildrenArray>,
    // A handler which triggers the menu, eg. button or link.
    handle?: React.Node
};

type State = {
    menuIsOpen: boolean
};

MenuItem.displayName = "Menu.Item";

class Menu extends React.Component {
    static Item = MenuItem;

    static defaultProps = {
        handle: null
    };

    state = {
        menuIsOpen: false
    };
    render() {
        return (
github fluidtrends / chunky / web / lib / components / Timeline.js View on Github external
value: function renderComponent() {
      if (this.state.loading) {
        return _react2.default.createElement(
          'div',
          {
            style: {
              display: 'flex',
              flex: 1,
              margin: '10px',
              justifyContent: 'center',
              flexDirection: 'column',
              alignItems: 'center'
            }
          },
          _react2.default.createElement(
            _Card.Card,
            { style: { width: '80vw', margin: '20px', padding: '0px' } },
            _react2.default.createElement(_linearProgress.LinearProgress, { determinate: false })
          )
        );
      }

      return _react2.default.createElement(
        'div',
        {
          style: {
            color: this.props.textColor,
            backgroundColor: this.props.backgroundColor
          } },
        this.renderTimeline(),
        _react2.default.createElement(
          'div',

rmwc

RMWC is a React UI Kit built on Google's official Material Components Web library.

MIT
Latest version published 2 months ago

Package Health Score

84 / 100
Full package analysis