Passed
Push — master ( d888e7...d5d975 )
by Rafael
01:12
created

src/controls/padding/padding.js   A

Size

Lines of Code 40

Duplication

Duplicated Lines 0
Ratio 0 %

Importance

Changes 2
Bugs 0 Features 0
Metric Value
c 2
b 0
f 0
nc 1
dl 0
loc 40
rs 10
noi 0

1 Function

Rating   Name   Duplication   Size   Complexity  
B padding.js ➔ ??? 0 34 1
1
import { Direction } from '../direction';
2
3
export class Padding extends Direction {
4
	constructor( options ) {
5
		super( options );
6
7
		this.controlOptions = {
8
			control: {
9
				title: 'Padding',
10
				name: 'padding',
11
				units: {
12
					default: 'px',
13
					enabled: [ 'px' ]
14
				},
15
				sliders: [
16
					{ name: 'top', label: 'Top', cssProperty: 'padding-top' },
17
					{ name: 'right', label: 'Right', cssProperty: 'padding-right' },
18
					{ name: 'bottom', label: 'Bottom', cssProperty: 'padding-bottom' },
19
					{ name: 'left', label: 'Left', cssProperty: 'padding-left' }
20
				]
21
			},
22
			slider: {
23
				px: {
24
					min: 0,
25
					max: 100
26
				},
27
				'%': {
28
					min: 0,
29
					max: 100
30
				},
31
				em: {
32
					min: 0.1,
33
					max: 5
34
				}
35
			}
36
		};
37
	}
38
}
39
40
export { Padding as default };
41