Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Y
yii2bootstrap
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
夏彬
yii2bootstrap
Commits
a58a4f71
Unverified
Commit
a58a4f71
authored
Apr 14, 2017
by
Carsten Brandt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed indentation
parent
aa9be414
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
22 additions
and
22 deletions
+22
-22
ButtonDropdown.php
ButtonDropdown.php
+8
-8
Nav.php
Nav.php
+5
-5
Tabs.php
Tabs.php
+7
-7
TabsTest.php
tests/TabsTest.php
+2
-2
No files found.
ButtonDropdown.php
View file @
a58a4f71
...
...
@@ -67,11 +67,11 @@ class ButtonDropdown extends Widget
* @var boolean whether the label should be HTML-encoded.
*/
public
$encodeLabel
=
true
;
/**
* @var string name of a class to use for rendering dropdowns withing this widget. Defaults to [[Dropdown]].
* @since 2.0.7
*/
public
$dropdownClass
=
'yii\bootstrap\Dropdown'
;
/**
* @var string name of a class to use for rendering dropdowns withing this widget. Defaults to [[Dropdown]].
* @since 2.0.7
*/
public
$dropdownClass
=
'yii\bootstrap\Dropdown'
;
/**
...
...
@@ -144,8 +144,8 @@ class ButtonDropdown extends Widget
$config
=
$this
->
dropdown
;
$config
[
'clientOptions'
]
=
false
;
$config
[
'view'
]
=
$this
->
getView
();
/** @var Widget $dropdownClass */
$dropdownClass
=
$this
->
dropdownClass
;
return
$dropdownClass
::
widget
(
$config
);
/** @var Widget $dropdownClass */
$dropdownClass
=
$this
->
dropdownClass
;
return
$dropdownClass
::
widget
(
$config
);
}
}
Nav.php
View file @
a58a4f71
...
...
@@ -107,9 +107,9 @@ class Nav extends Widget
public
$dropDownCaret
;
/**
* @var string name of a class to use for rendering dropdowns withing this widget. Defaults to [[Dropdown]].
* @since 2.0.7
* @since 2.0.7
*/
public
$dropdownClass
=
'yii\bootstrap\Dropdown'
;
public
$dropdownClass
=
'yii\bootstrap\Dropdown'
;
/**
...
...
@@ -214,9 +214,9 @@ class Nav extends Widget
*/
protected
function
renderDropdown
(
$items
,
$parentItem
)
{
/** @var Widget $dropdownClass */
$dropdownClass
=
$this
->
dropdownClass
;
return
$dropdownClass
::
widget
([
/** @var Widget $dropdownClass */
$dropdownClass
=
$this
->
dropdownClass
;
return
$dropdownClass
::
widget
([
'options'
=>
ArrayHelper
::
getValue
(
$parentItem
,
'dropDownOptions'
,
[]),
'items'
=>
$items
,
'encodeLabels'
=>
$this
->
encodeLabels
,
...
...
Tabs.php
View file @
a58a4f71
...
...
@@ -124,11 +124,11 @@ class Tabs extends Widget
* @since 2.0.7
*/
public
$tabContentOptions
=
[];
/**
* @var string name of a class to use for rendering dropdowns withing this widget. Defaults to [[Dropdown]].
* @since 2.0.7
*/
public
$dropdownClass
=
'yii\bootstrap\Dropdown'
;
/**
* @var string name of a class to use for rendering dropdowns withing this widget. Defaults to [[Dropdown]].
* @since 2.0.7
*/
public
$dropdownClass
=
'yii\bootstrap\Dropdown'
;
/**
...
...
@@ -188,8 +188,8 @@ class Tabs extends Widget
if
(
!
isset
(
$linkOptions
[
'data-toggle'
]))
{
$linkOptions
[
'data-toggle'
]
=
'dropdown'
;
}
/** @var Widget $dropdownClass */
$dropdownClass
=
$this
->
dropdownClass
;
/** @var Widget $dropdownClass */
$dropdownClass
=
$this
->
dropdownClass
;
$header
=
Html
::
a
(
$label
,
"#"
,
$linkOptions
)
.
"
\n
"
.
$dropdownClass
::
widget
([
'items'
=>
$item
[
'items'
],
'clientOptions'
=>
false
,
'view'
=>
$this
->
getView
()]);
}
else
{
...
...
tests/TabsTest.php
View file @
a58a4f71
...
...
@@ -199,7 +199,7 @@ class TabsTest extends TestCase
],
[
'label'
=>
'Tab 2'
,
'content'
=>
'some content'
'content'
=>
'some content'
],
[
'label'
=>
'Tab 3'
,
...
...
@@ -211,7 +211,7 @@ class TabsTest extends TestCase
'content'
=>
'some content'
]
]
]);
]);
$this
->
assertContains
(
'<li class="active"><a href="#mytab-tab2" data-toggle="tab">Tab 3</a></li>'
,
$html
);
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment