(props)
| 30 | * @return {Element} Element to render. |
| 31 | */ |
| 32 | export default function Edit(props) { |
| 33 | function updateSkyColor(e) { |
| 34 | props.setAttributes({ skyColor: e.target.value }); |
| 35 | } |
| 36 | |
| 37 | function updateGrassColor(e) { |
| 38 | props.setAttributes({ grassColor: e.target.value }); |
| 39 | } |
| 40 | |
| 41 | return ( |
| 42 | <div {...useBlockProps()}> |
| 43 | <input |
| 44 | type="text" |
| 45 | value={props.attributes.skyColor} |
| 46 | onChange={updateSkyColor} |
| 47 | placeholder="sky color..." |
| 48 | /> |
| 49 | <input |
| 50 | type="text" |
| 51 | value={props.attributes.grassColor} |
| 52 | onChange={updateGrassColor} |
| 53 | placeholder="grass color..." |
| 54 | /> |
| 55 | </div> |
| 56 | ); |
| 57 | } |
nothing calls this directly
no outgoing calls
no test coverage detected