Merge pull request #3471 from primefaces/issue-3394
SplitButton: Button class style and dropdown icon customizationpull/3518/head^2
commit
e62a65f2fa
|
@ -35,6 +35,12 @@ const SplitButtonProps = [
|
||||||
default: 'body',
|
default: 'body',
|
||||||
description: 'A valid query selector or an HTMLElement to specify where the overlay gets attached.'
|
description: 'A valid query selector or an HTMLElement to specify where the overlay gets attached.'
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: 'disabled',
|
||||||
|
type: 'boolean',
|
||||||
|
default: 'false',
|
||||||
|
description: 'When present, it specifies that the element should be disabled.'
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: 'class',
|
name: 'class',
|
||||||
type: 'string',
|
type: 'string',
|
||||||
|
@ -46,6 +52,12 @@ const SplitButtonProps = [
|
||||||
type: 'any',
|
type: 'any',
|
||||||
default: 'null',
|
default: 'null',
|
||||||
description: 'Inline of the component.'
|
description: 'Inline of the component.'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'menuButtonIcon',
|
||||||
|
type: 'string',
|
||||||
|
default: 'null',
|
||||||
|
description: 'Name of the menu button icon.'
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
@ -53,6 +53,10 @@ export interface SplitButtonProps {
|
||||||
* Uses to pass all properties of the HTMLButtonElement to the menu button.
|
* Uses to pass all properties of the HTMLButtonElement to the menu button.
|
||||||
*/
|
*/
|
||||||
menuButtonProps?: ButtonHTMLAttributes | undefined;
|
menuButtonProps?: ButtonHTMLAttributes | undefined;
|
||||||
|
/**
|
||||||
|
* Name of the menu button icon.
|
||||||
|
*/
|
||||||
|
menuButtonIcon?: string | undefined;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface SplitButtonSlots {
|
export interface SplitButtonSlots {
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
ref="button"
|
ref="button"
|
||||||
type="button"
|
type="button"
|
||||||
class="p-splitbutton-menubutton"
|
class="p-splitbutton-menubutton"
|
||||||
icon="pi pi-chevron-down"
|
:icon="menuButtonIcon"
|
||||||
:disabled="disabled"
|
:disabled="disabled"
|
||||||
aria-haspopup="true"
|
aria-haspopup="true"
|
||||||
:aria-expanded="isExpanded"
|
:aria-expanded="isExpanded"
|
||||||
|
@ -72,6 +72,10 @@ export default {
|
||||||
menuButtonProps: {
|
menuButtonProps: {
|
||||||
type: null,
|
type: null,
|
||||||
default: null
|
default: null
|
||||||
|
},
|
||||||
|
menuButtonIcon: {
|
||||||
|
type: String,
|
||||||
|
default: 'pi pi-chevron-down'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
|
|
|
@ -182,6 +182,12 @@ export default {
|
||||||
<td>null</td>
|
<td>null</td>
|
||||||
<td>Uses to pass all properties of the HTMLButtonElement to the menu button.</td>
|
<td>Uses to pass all properties of the HTMLButtonElement to the menu button.</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>menuButtonIcon</td>
|
||||||
|
<td>string</td>
|
||||||
|
<td>null</td>
|
||||||
|
<td>Name of the menu button icon.</td>
|
||||||
|
</tr>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in New Issue