button-container.js
3 years ago
button.js
3 years ago
container.js
3 years ago
default.js
3 years ago
grid.js
3 years ago
headline.js
3 years ago
image.js
3 years ago
index.js
3 years ago
image.js
57 lines
| 1 | import defaultContext from './default'; |
| 2 | import { __ } from '@wordpress/i18n'; |
| 3 | import { defaultsDeep } from 'lodash'; |
| 4 | |
| 5 | const imageContext = defaultsDeep( { |
| 6 | id: 'image', |
| 7 | supports: { |
| 8 | responsiveTabs: true, |
| 9 | settingsPanel: { |
| 10 | enabled: true, |
| 11 | icon: 'backgrounds', |
| 12 | }, |
| 13 | spacing: { |
| 14 | enabled: true, |
| 15 | dimensions: [ |
| 16 | { |
| 17 | type: 'padding', |
| 18 | label: __( 'Padding', 'generateblocks' ), |
| 19 | units: [ 'px', 'em', '%' ], |
| 20 | }, |
| 21 | { |
| 22 | type: 'margin', |
| 23 | label: __( 'Margin', 'generateblocks' ), |
| 24 | units: [ 'px', 'em', '%' ], |
| 25 | }, |
| 26 | { |
| 27 | type: 'borderSize', |
| 28 | label: __( 'Border Size', 'generateblocks' ), |
| 29 | units: [ 'px' ], |
| 30 | }, |
| 31 | { |
| 32 | type: 'borderRadius', |
| 33 | label: __( 'Border Radius', 'generateblocks' ), |
| 34 | units: [ 'px', 'em', '%' ], |
| 35 | }, |
| 36 | ], |
| 37 | }, |
| 38 | colors: { |
| 39 | enabled: true, |
| 40 | elements: [ |
| 41 | { |
| 42 | group: 'border', |
| 43 | label: __( 'Border', 'generateblocks' ), |
| 44 | items: [ |
| 45 | { |
| 46 | attribute: 'borderColor', |
| 47 | alpha: true, |
| 48 | }, |
| 49 | ], |
| 50 | }, |
| 51 | ], |
| 52 | }, |
| 53 | }, |
| 54 | }, defaultContext ); |
| 55 | |
| 56 | export default imageContext; |
| 57 |