Completed
Push — master ( bafc2b...789f6f )
by Oscar
03:26
created

ToolbarTrait::getToolbarButtons()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 4
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
c 1
b 0
f 0
dl 0
loc 4
rs 10
cc 1
eloc 2
nc 1
nop 0
1
<?php
2
3
namespace Folk\Formats\Traits;
4
5
trait ToolbarTrait
6
{
7
    private $icon_up = '<svg fill="#FFFFFF" height="18" viewBox="0 0 24 24" width="18" xmlns="http://www.w3.org/2000/svg"><path d="M4 12l1.41 1.41L11 7.83V20h2V7.83l5.58 5.59L20 12l-8-8-8 8z"/></svg>';
8
    private $icon_down = '<svg fill="#FFFFFF" height="18" viewBox="0 0 24 24" width="18" xmlns="http://www.w3.org/2000/svg"><path d="M20 12l-1.41-1.41L13 16.17V4h-2v12.17l-5.58-5.59L4 12l8 8 8-8z"/></svg>';
9
    private $icon_close = '<svg fill="#FFFFFF" height="18" viewBox="0 0 24 24" width="18" xmlns="http://www.w3.org/2000/svg"><path d="M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"/></svg>';
10
11
    private function getToolbarButtons()
12
    {
13
        return '<button title="Move to up" type="button" class="button format-child-up">'.$this->icon_up.'</button><button title="Move to down" type="button" class="button format-child-down">'.$this->icon_down.'</button><button title="Remove" type="button" class="button format-child-remove">'.$this->icon_close.'</button>';
14
    }
15
}
16