123456789101112131415161718192021222324 |
- const themes = {
- textmate: "textmate",
- monokai: "monokai",
- xcode: "xcode",
- twilight: "twilight",
- terminal: "terminal",
- github: "github",
- tomorrow: "tomorrow",
- kuroir: "kuroir",
- solarized_dark: "solarized_dark",
- solarized_light: "solarized_light",
- };
- export const SelectTheme = ({ listObj = themes, onChange, value }) => {
- return (
- <select value={value} onChange={e => onChange(e.target.value)}>
- {Object.entries(listObj).map(([value, text]) => (
- <option value={value} key={value}>
- {text}
- </option>
- ))}
- </select>
- );
- };
|