Bootstrap-vue: Popover: close if focus moves on element in popover body

Created on 17 Nov 2017  路  3Comments  路  Source: bootstrap-vue/bootstrap-vue

Hello!

triggers="click blur"

https://jsfiddle.net/6haq0jvL/

When focus moves on element in popup body (checkbox), popup closes.
But in hide event I can't resolve real activeElement (checkbox), because activeElement - always propagate to body.

I want to know in hide event which element has taken focus, so that, if necessary, prevent closing. Thanks!

Most helpful comment

We have added better blur handling in release v1.1.0

All 3 comments

Popovers are normally used for informational purposes and not form content. form content needs special handling, as shown in the example in the documentation.

Here is an updated fiddle: https://jsfiddle.net/6haq0jvL/2/

Thank you, I saw this use case in examples.

But what about some fixes for click blur triggers combination: if focus getting on some elements in popover body - don't close popover, if focus getting on any elements not in popover body - close popover? Or at least a workaround in the current implementation for my case?

We have added better blur handling in release v1.1.0

Was this page helpful?
0 / 5 - 0 ratings

Related issues

claviska picture claviska  路  3Comments

tpines picture tpines  路  3Comments

studnitz picture studnitz  路  3Comments

kossa picture kossa  路  3Comments

ghost picture ghost  路  3Comments