mirror of
https://github.com/humhub/humhub.git
synced 2025-01-17 14:18:27 +01:00
Improve style of button with single icon without text (#5952)
This commit is contained in:
parent
f685548885
commit
418812dbed
@ -2,7 +2,7 @@
|
|||||||
/**
|
/**
|
||||||
* This file is generated by the "yii asset" command.
|
* This file is generated by the "yii asset" command.
|
||||||
* DO NOT MODIFY THIS FILE DIRECTLY.
|
* DO NOT MODIFY THIS FILE DIRECTLY.
|
||||||
* @version 2022-11-29 11:02:20
|
* @version 2022-11-29 14:04:39
|
||||||
*/
|
*/
|
||||||
return [
|
return [
|
||||||
'app' => [
|
'app' => [
|
||||||
|
@ -227,6 +227,10 @@ class Button extends BootstrapComponent
|
|||||||
$this->htmlOptions['data-action-method'] = $method;
|
$this->htmlOptions['data-action-method'] = $method;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ($this->text === null && $this->_icon !== null) {
|
||||||
|
$this->htmlOptions['class'] .= ' btn-icon-only';
|
||||||
|
}
|
||||||
|
|
||||||
if ($this->_link) {
|
if ($this->_link) {
|
||||||
$href = isset($this->htmlOptions['href']) ? $this->htmlOptions['href'] : null;
|
$href = isset($this->htmlOptions['href']) ? $this->htmlOptions['href'] : null;
|
||||||
return Html::a($this->getText(), $href, $this->htmlOptions);
|
return Html::a($this->getText(), $href, $this->htmlOptions);
|
||||||
|
@ -15,8 +15,10 @@
|
|||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
padding: 8px 16px;
|
padding: 8px 16px;
|
||||||
i {
|
&:not(.btn-icon-only) {
|
||||||
margin-right: 4px;
|
i.fa {
|
||||||
|
margin-right: 4px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
File diff suppressed because one or more lines are too long
Loading…
x
Reference in New Issue
Block a user