An Ember modifier for working with Popper.js.
- Ember.js v3.12 or above
- Ember CLI v2.13 or above
- Node.js v10 or above
ember install ember-popper-modifier
This addon provides Ember modifiers that interfaces with the Popper.js library. It handles creating Popper instances as well as configuring them as options are updated.
Popper.js operates on two elements at the same time:
- The "reference" element, which is the one the tooltip is positioned relative to
- The "popper" element, which is the one that floats.
Two modifiers are provided, depending on which element you want to apply the modifier to and which you want to pass as a reference:
{{popper}}
is applied on the reference element and given the tooltip as an argument{{popper-tooltip}}
is applied on the tooltip element and passed the reference as an argument
Aside from that difference, the modifiers are identical. Thus, the examples below will only show the usage of {{popper}}
; know that all of the same principles and options work for {{popper-tooltip}}
as well.
More information WIP.
See the Contributing guide for details.
This project is licensed under the MIT License.