🚧 More work on React components
This commit is contained in:
parent
66b42967dc
commit
e2b5ba2ee7
10 changed files with 10841 additions and 73 deletions
|
@ -9,8 +9,6 @@ import Count from "../PatternOptionCount";
|
|||
import { optionType } from "../utils";
|
||||
import { FormattedMessage } from "react-intl";
|
||||
import { injectIntl } from "react-intl";
|
||||
import ListItem from "@material-ui/core/ListItem";
|
||||
import ListItemText from "@material-ui/core/ListItemText";
|
||||
|
||||
const OptionGroup = props => {
|
||||
const update = (name, value) => props.updateValue("option", name, value);
|
||||
|
@ -60,7 +58,7 @@ const OptionGroup = props => {
|
|||
};
|
||||
|
||||
return (
|
||||
<div className="optiongroup">
|
||||
<React.Fragment>
|
||||
{props.options.map(name => {
|
||||
let key = name;
|
||||
let output = [];
|
||||
|
@ -78,13 +76,9 @@ const OptionGroup = props => {
|
|||
}
|
||||
} else output.push(renderOption(name));
|
||||
|
||||
return (
|
||||
<ListItem key={`lki-${key}`}>
|
||||
<ListItemText>{output}</ListItemText>
|
||||
</ListItem>
|
||||
);
|
||||
return output;
|
||||
})}
|
||||
</div>
|
||||
</React.Fragment>
|
||||
);
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue