| 1 |
<?php |
| 2 |
namespace MBSocial; |
| 3 |
defined('ABSPATH') or die('No direct access permitted'); |
| 4 |
|
| 5 |
class dropSquareStyle extends style |
| 6 |
{ |
| 7 |
|
| 8 |
public $class = 'dropsquare single-meta'; |
| 9 |
public $name = 'dropsquare'; |
| 10 |
public $description = " Square Buttons with dropSquare "; |
| 11 |
|
| 12 |
public $width = '60'; // in pix |
| 13 |
public $height = '65'; // in pix |
| 14 |
|
| 15 |
public $has_share = true; |
| 16 |
public $has_label = true; |
| 17 |
|
| 18 |
public function mainCSS() |
| 19 |
{ |
| 20 |
parent::mainCSS(); |
| 21 |
|
| 22 |
$this->addFlex(); |
| 23 |
|
| 24 |
$meta_css = array( |
| 25 |
'position' => 'absolute', |
| 26 |
'left' => 0, |
| 27 |
'bottom' => '-3px', |
| 28 |
'width' => '100%', |
| 29 |
'background-color' => '#000', |
| 30 |
'line-height' => '20px', |
| 31 |
'transition' => 'bottom .2s linear', |
| 32 |
'z-index' => '-1', |
| 33 |
'display' => 'inline-block', |
| 34 |
'font-size' => '10px', |
| 35 |
); |
| 36 |
|
| 37 |
$meta_css_hover = array( |
| 38 |
'bottom' => '-20px', |
| 39 |
); |
| 40 |
|
| 41 |
$this->addCSS ( |
| 42 |
$meta_css, |
| 43 |
'', |
| 44 |
'mb-label'); |
| 45 |
|
| 46 |
$this->addCSS ( |
| 47 |
$meta_css, |
| 48 |
'', |
| 49 |
'mb-share-count'); |
| 50 |
|
| 51 |
$this->addCSS( |
| 52 |
$meta_css_hover, |
| 53 |
'', |
| 54 |
'mb-label', |
| 55 |
'hover' |
| 56 |
); |
| 57 |
|
| 58 |
$this->addCSS( |
| 59 |
$meta_css_hover, |
| 60 |
'', |
| 61 |
'mb-share-count', |
| 62 |
'hover' |
| 63 |
); |
| 64 |
|
| 65 |
$this->addCSS ( |
| 66 |
array( 'z-index' => 0, |
| 67 |
'position' => 'relative', |
| 68 |
), |
| 69 |
'', |
| 70 |
'collection-item'); |
| 71 |
|
| 72 |
//$this->addCSS('overflow', 'hidden','maxbutton-social'); |
| 73 |
} |
| 74 |
|
| 75 |
|
| 76 |
public function prepareCSS($args) |
| 77 |
{ |
| 78 |
parent::prepareCSS($args); |
| 79 |
|
| 80 |
if (! isset($args['child_override']) && $args['orientation'] == 'vertical') |
| 81 |
{ |
| 82 |
$this->addCSS('margin-bottom', '20px', 'maxbutton-social', 'hover'); |
| 83 |
} |
| 84 |
} |
| 85 |
|
| 86 |
} |
| 87 |
|
| 88 |
|
| 89 |
dropSquareStyle::registerStyle(60); |
| 90 |
|