How to use the @rmwc/select.Select function in @rmwc/select

To help you get started, we’ve selected a few @rmwc/select 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 fluidtrends / chunky / web / lib / components / Navigation.js View on Github external
{
          raised: true,
          theme: 'secondary-bg text-primary-on-secondary',
          onClick: this._onMenuItem(item),
          style: _extends({
            color: this.props.theme.navigationTextButton,
            marginRight: '0px'
          }, actionButtonAdditionalStyle)
        },
        '' + translatedTitle
      );
      var languages = this.props.theme.languages;

      var dropdownAdditionalStyle = this.props.theme.dropdownStyle ? this.props.theme.dropdownStyle : {};

      var MenuDropdown = _react2.default.createElement(_select.Select, {
        label: item.title,
        options: languages,
        onChange: function onChange(evt) {
          return _this3.changeLanguage(evt.target.value);
        },
        value: this.state.selectedLanguage,
        style: _extends({
          color: this.props.theme.navigationTextButton
        }, dropdownAdditionalStyle)
      });
      return (0, _responsive.renderResponsive)('menuItem' + index++, _react2.default.createElement('div', null), item.alwaysShowIcon ? MenuIcon : item.action ? MenuActionButton : item.id === 'translation' ? MenuDropdown : MenuButton);
    }
  }, {
github fluidtrends / chunky / web / lib / components / Drawer.js View on Github external
return this._menu.map(function (item) {
        var translatedTitle = theme.headerTranslation && _this3.state.strings && _this3.state.selectedLanguage ? _this3.state.strings[_this3.state.selectedLanguage]['title' + index] : item.title;
        return _react2.default.createElement(
          _list.ListItem,
          {
            onClick: _this3._onMenuItem(item),
            key: 'menuItem' + index++ },
          item.id === 'translation' ? _react2.default.createElement(_select.Select, {
            label: item.title,
            options: languages,
            onChange: function onChange(evt) {
              return _this3.changeLanguage(evt.target.value);
            },
            value: _this3.state.selectedLanguage,
            style: {
              color: theme.navigationTextButton
            }
          }) : _react2.default.createElement(
            _list.ListItemPrimaryText,
            null,
            translatedTitle
          )
        );
      });

@rmwc/select

RMWC Select component

MIT
Latest version published 12 days ago

Package Health Score

84 / 100
Full package analysis

Popular @rmwc/select functions