Skip to content

Commit

Permalink
Refactor #4231 - For ColorPicker
Browse files Browse the repository at this point in the history
  • Loading branch information
mertsincan committed Aug 2, 2023
1 parent 3f233cb commit 01d6582
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions components/lib/colorpicker/ColorPicker.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,10 @@ export interface ColorPickerPassThroughOptions {
* @see {@link BaseComponent.ComponentHooks}
*/
hooks?: ComponentHooks;
/**
* Used to control Vue Transition API.
*/
transition?: any;
}

/**
Expand Down
2 changes: 1 addition & 1 deletion components/lib/colorpicker/ColorPicker.vue
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<div ref="container" :class="cx('root')" v-bind="ptm('root')">
<input v-if="!inline" ref="input" type="text" :class="cx('input')" readonly="readonly" :tabindex="tabindex" :disabled="disabled" @click="onInputClick" @keydown="onInputKeydown" v-bind="ptm('input')" />
<Portal :appendTo="appendTo" :disabled="inline">
<transition name="p-connected-overlay" @enter="onOverlayEnter" @leave="onOverlayLeave" @after-leave="onOverlayAfterLeave">
<transition name="p-connected-overlay" @enter="onOverlayEnter" @leave="onOverlayLeave" @after-leave="onOverlayAfterLeave" v-bind="ptm('transition')">
<div v-if="inline ? true : overlayVisible" :ref="pickerRef" :class="[cx('panel'), panelClass]" @click="onOverlayClick" v-bind="ptm('panel')">
<div :class="cx('panel')" v-bind="ptm('content')">
<div :ref="colorSelectorRef" :class="cx('selector')" @mousedown="onColorMousedown($event)" @touchstart="onColorDragStart($event)" @touchmove="onDrag($event)" @touchend="onDragEnd()" v-bind="ptm('selector')">
Expand Down

0 comments on commit 01d6582

Please sign in to comment.