Skip to content
Permalink
Browse files
feat(b-form-datepicker, b-form-timepicker): emit shown and hidden
… events (#5004)

* feat(b-form-datepicker, b-form-timepicker): emit shown and hidden events

* Update form-timepicker.js

* Update package.json

* Update package.json

Co-authored-by: Jacob Müller <jacob.mueller.elz@gmail.com>
  • Loading branch information
tmorehouse and jacobmllr95 committed Mar 24, 2020
1 parent 68ad33f commit eb259b998dfd3e88a1b04ed8d3f4c97560f69dbb
Showing 4 changed files with 24 additions and 0 deletions.
@@ -400,10 +400,12 @@ export const BFormDatepicker = /*#__PURE__*/ Vue.extend({
try {
this.$refs.calendar.focus()
} catch {}
this.$emit('shown')
})
},
onHidden() {
this.isVisible = false
this.$emit('hidden')
},
// Render helpers
defaultButtonFn({ isHovered, hasFocus }) {
@@ -260,6 +260,16 @@
"type": "Object"
}
]
},
{
"event": "shown",
"version": "2.9.0",
"description": "Emitted when the picker popup has shown"
},
{
"event": "hidden",
"version": "2.9.0",
"description": "Emitted when the picker popup has hidden"
}
],
"slots": [
@@ -316,10 +316,12 @@ export const BFormTimepicker = /*#__PURE__*/ Vue.extend({
try {
this.$refs.time.focus()
} catch {}
this.$emit('shown')
})
},
onHidden() {
this.isVisible = false
this.$emit('hidden')
},
// Render function helpers
defaultButtonFn({ isHovered, hasFocus }) {
@@ -214,6 +214,16 @@
"type": "Object"
}
]
},
{
"event": "shown",
"version": "2.9.0",
"description": "Emitted when the picker popup has shown"
},
{
"event": "hidden",
"version": "2.9.0",
"description": "Emitted when the picker popup has hidden"
}
],
"slots": [

0 comments on commit eb259b9

Please sign in to comment.