Skip to content

Commit

Permalink
Refactor #4274 - For SpeedDial
Browse files Browse the repository at this point in the history
  • Loading branch information
tugcekucukoglu committed Aug 16, 2023
1 parent 2c47b94 commit 1d67d47
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
12 changes: 7 additions & 5 deletions components/lib/speeddial/SpeedDial.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -262,27 +262,29 @@ export interface SpeedDialSlots {
*/
item: MenuItem;
/**
* ıtem click function
* Item click function
* @param {Event} event - Browser event.
*/
onClick: void;
onClick(): void;
}): VNode[];
/**
* Custom button template.
* @param {Object} scope - button slot's params.
*/
button(scope: {
/**
* Toggle metadata
* Button click function
* @param {Event} event - Browser event.
*/
toggle(): void;
onClick(): void;
}): VNode[];
/**
* Custom icon template.
* @param {Object} scope - icon slot's params.
*/
icon(scope: {
/**
*
* Visible state of the item
*/
visible: boolean;
}): VNode[];
Expand Down
2 changes: 1 addition & 1 deletion components/lib/speeddial/SpeedDial.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<template>
<div :ref="containerRef" :class="containerClass" :style="[style, sx('root')]" v-bind="ptm('root')" data-pc-name="speeddial">
<slot name="button" :toggle="onClick">
<slot name="button" :onClick="onClick">
<SDButton
type="button"
:class="[cx('button'), buttonClass]"
Expand Down

0 comments on commit 1d67d47

Please sign in to comment.