Maslosoft Framework Logo Maslosoft Framework Documentation
Flexible Application Foundation


Slider Tabs in Modal Window

Slider Tabs widget can be placed inside modal window. Simply pass entire widget as a modal $content param:

echo $modal = Modal::widget([
	'title' => 'Tabs in Modal Window',
	'size' => 'large',
	'autoOpen' => true,
	'content' => SliderTabs::widget([
		'items' => [
			[
				'label' => 'Item one',
				'content' => 'Content of one'
			],
			[
				'label' => 'Item two',
				'content' => 'Content of two'
			],
			[
				'label' => 'Item three',
				'content' => 'Content of three'
			],
			[
				'label' => 'Item four',
				'content' => 'Content of four'
			],
			[
				'label' => 'Item five',
				'content' => 'Content of five'
			],
			[
				'label' => 'Item six',
				'content' => 'Content of six'
			],
		]
	])
]);

Open window
Variable $modal is also captured to create above link for opening modal window:

<a href="#" data-bind="click: <?= $modal->jsRef->open; ?>">Open window</a>