Skip to content

Commit

Permalink
Merge pull request #212 from php-school/private-style
Browse files Browse the repository at this point in the history
Make style props private
  • Loading branch information
AydinHassan committed Dec 20, 2019
2 parents 0902895 + 0ef8a49 commit 95df7b9
Show file tree
Hide file tree
Showing 2 changed files with 49 additions and 19 deletions.
35 changes: 25 additions & 10 deletions src/Style/CheckboxStyle.php
Expand Up @@ -4,22 +4,37 @@

class CheckboxStyle
{
protected const DEFAULT_STYLES = [
private const DEFAULT_STYLES = [
'markerOn' => '[✔] ',
'markerOff' => '[ ] ',
'itemExtra' => '✔',
'displaysExtra' => false,
];

protected $markerOn = '';

protected $markerOff = '';

protected $itemExtra = '';

protected $displaysExtra = false;

protected $custom = false;
/**
* @var string
*/
private $markerOn;

/**
* @var string
*/
private $markerOff;

/**
* @var string
*/
private $itemExtra;

/**
* @var bool
*/
private $displaysExtra;

/**
* @var bool
*/
private $custom = false;

public function __construct()
{
Expand Down
33 changes: 24 additions & 9 deletions src/Style/RadioStyle.php
Expand Up @@ -4,21 +4,36 @@

class RadioStyle
{
protected const DEFAULT_STYLES = [
private const DEFAULT_STYLES = [
'markerOn' => '[●] ',
'markerOff' => '[○] ',
'itemExtra' => '✔',
'displaysExtra' => false,
];

protected $markerOn = '';

protected $markerOff = '';

protected $itemExtra = '';

protected $displaysExtra = false;

/**
* @var string
*/
private $markerOn;

/**
* @var string
*/
private $markerOff;

/**
* @var string
*/
private $itemExtra;

/**
* @var bool
*/
private $displaysExtra;

/**
* @var bool
*/
protected $custom = false;

public function __construct()
Expand Down

0 comments on commit 95df7b9

Please sign in to comment.