jetformbuilder
/
modules
/
captcha
/
assets-src
/
js
/
editor
/
captcha-container-block
Last commit date
edit.js
2 years ago
index.js
2 years ago
preview.js
2 years ago
index.js
40 lines
| 1 | import EditCaptchaContainer from './edit'; |
| 2 | import metadata from '@blocks/captcha-container/block.json'; |
| 3 | |
| 4 | const { |
| 5 | name, |
| 6 | icon, |
| 7 | } = metadata; |
| 8 | |
| 9 | const { |
| 10 | __, |
| 11 | } = wp.i18n; |
| 12 | |
| 13 | /** |
| 14 | * Available items for `useEditProps`: |
| 15 | * - uniqKey |
| 16 | * - formFields |
| 17 | * - blockName |
| 18 | * - attrHelp |
| 19 | */ |
| 20 | const settings = { |
| 21 | icon: <span dangerouslySetInnerHTML={ { __html: icon } }></span>, |
| 22 | description: __( |
| 23 | `Insert the captcha for your form. Determine its location yourself |
| 24 | using the block, as is added before the submit button by default.`, |
| 25 | 'jet-form-builder', |
| 26 | ), |
| 27 | edit: EditCaptchaContainer, |
| 28 | example: { |
| 29 | attributes: { |
| 30 | isPreview: true, |
| 31 | }, |
| 32 | }, |
| 33 | }; |
| 34 | |
| 35 | export { |
| 36 | metadata, |
| 37 | name, |
| 38 | settings, |
| 39 | }; |
| 40 |