41 lines
901 B
React
41 lines
901 B
React
|
( function( wp ) {
|
||
|
const registerBlockType = wp.blocks.registerBlockType;
|
||
|
const el = wp.element.createElement;
|
||
|
const __ = wp.i18n.__;
|
||
|
|
||
|
registerBlockType( 'room-vw/room-vw-hero', {
|
||
|
title: __( 'RoomWaVW hero block', 'room-vw' ),
|
||
|
category: 'widgets',
|
||
|
supports: {
|
||
|
// Removes support for an HTML mode.
|
||
|
html: false,
|
||
|
},
|
||
|
|
||
|
edit( props ) {
|
||
|
return (
|
||
|
<article className={ props.className }>
|
||
|
<div className='imagecontainer'>
|
||
|
<ul id='js-hero-imgs' className='anim-hero'>
|
||
|
<li><span>Yah from jsx insides the editor</span></li>
|
||
|
</ul>
|
||
|
</div>
|
||
|
</article>
|
||
|
)
|
||
|
},
|
||
|
|
||
|
save() {
|
||
|
return (
|
||
|
<article className='home-hero fixed-full'>
|
||
|
<div className='imagecontainer'>
|
||
|
<ul id='js-hero-imgs' className='anim-hero'>
|
||
|
<li><span>Yah from jsx outsides the editor</span></li>
|
||
|
</ul>
|
||
|
</div>
|
||
|
</article>
|
||
|
)
|
||
|
},
|
||
|
} );
|
||
|
}(
|
||
|
window.wp
|
||
|
) );
|