UNPKG

@makeen.io/material-ui-kit

Version:
14 lines (6 loc) 1.27 kB
import _extends from "@babel/runtime/helpers/extends";import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";function _templateObject() {var data = _taggedTemplateLiteral(["\n display: flex;\n align-items: center;\n\n .explorer-tap-radio {\n margin-left: 20px;\n margin-right: 20px;\n }\n"]);_templateObject = function _templateObject() {return data;};return data;}import React from "react"; import { TapRadio } from "../../atoms"; import styled from "styled-components"; var TapRadioGroupWrapper = styled.div(_templateObject()); export default (function (_ref) {var options = _ref.options,disabled = _ref.disabled,selectedKey = _ref.selectedKey,onChangeOption = _ref.onChangeOption;return /*#__PURE__*/React.createElement(TapRadioGroupWrapper, null, options.map(function (_ref2) {var icon = _ref2.icon,key = _ref2.key,option = _objectWithoutProperties(_ref2, ["icon", "key"]);return /*#__PURE__*/React.createElement(TapRadio, _extends({ key: key, disabled: !!disabled, active: selectedKey === key, onClick: function onClick() {return onChangeOption(key, option);}, IconComponent: icon }, option));}));}); //# sourceMappingURL=index.js.map