diff options
Diffstat (limited to 'StyleButton.js')
-rw-r--r-- | StyleButton.js | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/StyleButton.js b/StyleButton.js new file mode 100644 index 0000000..806ece6 --- /dev/null +++ b/StyleButton.js @@ -0,0 +1,15 @@ +function StyleButton(props) +{ + const { enabled, handleClick } = props; + + const className = enabled ? 'StyleButtonEnabled' : 'StyleButtonDisabled'; + + + return h( + `div.unselectable.StyleButton.${className}`, + { + onClick: handleClick, + }, + props.text + ); +} |