File "duplicate.js"
Full path: /home/satitravel/public_html/wp-content/plugins/foogallery/gutenberg/src/block/edit/views/duplicate.js
File
size: 1.11 B
MIME-type: text/plain
Charset: utf-8
Download Open Edit Advanced Editor &nnbsp; Back
import {
FooGalleryEditModal,
FooGalleryEditPlaceholder,
FooGalleryEditBlockControls,
FooGalleryEditInspectorControls
} from '../components';
const { __ } = wp.i18n;
const { Component, Fragment } = wp.element;
const { Button } = wp.components;
export default class FooGalleryEditDuplicate extends Component {
render(){
const { icon, label, instructions, button, ...props } = this.props;
let placeholderProps = { icon, label, instructions };
return (
<Fragment>
<FooGalleryEditBlockControls { ...props } />
<FooGalleryEditPlaceholder { ...placeholderProps }>
<Button isDefault isLarge onClick={ props.onRequestModalOpen }>{ button }</Button>
</FooGalleryEditPlaceholder>
<FooGalleryEditModal { ...props } />
<FooGalleryEditInspectorControls { ...props } />
</Fragment>
);
}
}
FooGalleryEditDuplicate.defaultProps = {
icon: "format-gallery",
label: __("FooGallery", "foogallery"),
instructions: __("Duplicate gallery, please select another to insert.", "foogallery"),
button: __("Select Gallery", "foogallery"),
onRequestModalOpen: _.noop
};