Components
10 months ago
autoloader.js
1 year ago
edit.js
6 months ago
ic-arrow-up-right-square.svg
11 months ago
index.js
6 months ago
reach-logo.svg
11 months ago
styles.scss
1 month ago
view.js
1 month ago
index.js
62 lines
| 1 | import {registerBlockType} from '@wordpress/blocks'; |
| 2 | import {__} from '@wordpress/i18n'; |
| 3 | import Edit from './edit'; |
| 4 | import './styles.scss' |
| 5 | |
| 6 | registerBlockType('hostinger-reach/subscription', |
| 7 | { |
| 8 | name: "hostinger-reach/subscription", |
| 9 | title: __("Reach Subscription Form", "hostinger-reach"), |
| 10 | icon: |
| 11 | <svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"> |
| 12 | <path |
| 13 | d="M13.925 7.35306L18.0634 3.21429L20.7856 5.9365L18.5036 8.21843H15.8008L15.7823 8.20957L10.0747 5.67124V1.5H13.925V7.35306Z" |
| 14 | fill="#1D1E20"/> |
| 15 | <path |
| 16 | d="M5.49586 15.7815L8.21638 15.7895L13.9252 18.3287V22.4999H10.0749L10.0736 16.649L5.93656 20.7856L3.21436 18.0634L5.49586 15.7815Z" |
| 17 | fill="#1D1E20"/> |
| 18 | <path |
| 19 | d="M22.5003 10.0757H18.3282L15.7827 15.7997V18.505L18.0638 20.7861L20.786 18.0635L16.6472 13.9251L22.5003 13.9243V10.0757Z" |
| 20 | fill="#1D1E20"/> |
| 21 | <path |
| 22 | d="M5.9365 3.21436L8.21632 5.49418V8.20415L5.67208 13.9244H1.5V10.0758H7.35306L3.21429 5.93741L5.9365 3.21436Z" |
| 23 | fill="#1D1E20"/> |
| 24 | </svg>, |
| 25 | category: "common", |
| 26 | textdomain: "hostinger-reach", |
| 27 | attributes: { |
| 28 | formId: { |
| 29 | type: 'string', |
| 30 | default: '', |
| 31 | }, |
| 32 | showName: { |
| 33 | type: 'boolean', |
| 34 | default: false, |
| 35 | }, |
| 36 | showSurname: { |
| 37 | type: 'boolean', |
| 38 | default: false, |
| 39 | }, |
| 40 | contactList: { |
| 41 | type: 'string', |
| 42 | default: '', |
| 43 | }, |
| 44 | "tags": { |
| 45 | "type": "array", |
| 46 | "default": [] |
| 47 | }, |
| 48 | layout: { |
| 49 | type: 'string', |
| 50 | default: 'default', |
| 51 | enum: ['default', 'inline'] |
| 52 | } |
| 53 | }, |
| 54 | edit: Edit, |
| 55 | save: () => { |
| 56 | return null; |
| 57 | } |
| 58 | } |
| 59 | ); |
| 60 | |
| 61 | |
| 62 |