import { h, Component } from 'preact'; import PropTypes from 'prop-types'; import { Options } from './Options'; import { Button } from '@crayons'; const Icon = () => ( ); export class EditorActions extends Component { constructor(props) { super(props); this.state = { moreConfigShowing: false, }; } setCommonProps = ({ moreConfigShowing = false }) => { return { moreConfigShowing, }; }; toggleMoreConfig = (e) => { const { moreConfigShowing } = this.state; e.preventDefault(); this.setState({ ...this.setCommonProps({ moreConfigShowing: !moreConfigShowing }), }); }; render() { const { onSaveDraft, onPublish, onClearChanges, published, edited, version, passedData, onConfigChange, submitting, } = this.props; const { moreConfigShowing } = this.state; return submitting ? (