Skip to content

Latest commit

 

History

History
53 lines (44 loc) · 1.43 KB

SocialWidget.md

File metadata and controls

53 lines (44 loc) · 1.43 KB

SocialWidget

Since v0.6

Pay attention! You should use echo and widget() method when you work with the widget. It uses ShadowSupport, ColorSupport and CustomCssSupport traits.

Public properties, its types and default values

  • string $name - username
  • string $image = '' - user image
  • string $position = '' - user role or position (title of a card)
  • bool $gradient = false - makes a gradient card, uses $color property (Bootstrap 4 colors or additional colors of AdminLTE)
  • array $rows = [] - list of rows (see an example below).

Example

<?= SocialWidget::widget([
	'name' => 'Jonathan Burke Jr.',
	'position' => 'Senior backend developer',
	'image' => '../avatars/user2-160x160.jpg',
	'color' => 'lightblue',
	'shadow' => 'shadow',
	'rows' => [
		'Projects' => [
			'31',
			'#url',
			'primary'
		],
		'Tasks'	=> [
			'5',
			'#',
			'navy'
		],
		'Completed Projects' => [
			'12',
			'#',
			'success'
		],
		'Followers'	=> [
			'842',
			'https://example.com',
			'purple'
		],
	],
]); ?>

Rendered SocialWidget

Rendered SocialWidget

Back to doc index or readme