Skip to content

Commit

Permalink
Update popover position when children contents change (#966)
Browse files Browse the repository at this point in the history
* create EuiMutationObserver util; implement it on accordion and popover

* updated EuiContextMenu to trigger popover's mutation observer during height transition

* another approach to the popover conundrum

* change popover to call requestAnimationFrame while a transition may be active

* refactor EuiMutationObserver to support multiple children

* Added full MutationObserver polyfill, added tests for EuiMutationObserver

* Allow EuiPortal to be inserted at specific locations in the DOM

* Added documentation for EuiMutationObserver

* EuiPopover now watches for text changes too

* Add EuiWrappingPopover to allow non-React elements to be used as popover anchors

* changelog and some cleanup

* Add container prop to EuiPopover

* more changelog

* PR feedback

* re-worded portal docs

* Allow EuiPopover to be created with isOpen=true

* Update EuiPopover's arrow positioning
  • Loading branch information
chandlerprall authored Jul 18, 2018
1 parent 24f8fef commit c3759f7
Show file tree
Hide file tree
Showing 26 changed files with 1,536 additions and 164 deletions.
9 changes: 8 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
## [`master`](https://github.com/elastic/eui/tree/master)

No public interface changes since `3.0.2`.
- Added `EuiMutationObserver` to expose Mutation Observer API to React components ([#966](https://github.com/elastic/eui/pull/966))
- Added `EuiWrappingPopover` which allows existing non-React elements to be popover anchors ([#966](https://github.com/elastic/eui/pull/966))
- `EuiPopover` accepts a `container` prop to further restrict popover placement ([#966](https://github.com/elastic/eui/pull/966))
- `EuiPortal` can inject content at arbitrary DOM locations, added `portalRef` prop ([#966](https://github.com/elastic/eui/pull/966))

**Bug fixes**

- `EuiPopover` re-positions with dynamic content (including CSS height/width transitions) ([#966](https://github.com/elastic/eui/pull/966))

## [`3.0.2`](https://github.com/elastic/eui/tree/v3.0.2)

Expand Down
1 change: 1 addition & 0 deletions scripts/jest/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
"\\.(css|less|scss)$": "<rootDir>/scripts/jest/mocks/style_mock.js"
},
"setupFiles": [
"<rootDir>/scripts/jest/setup/polyfills.js",
"<rootDir>/scripts/jest/setup/enzyme.js",
"<rootDir>/scripts/jest/setup/throw_on_console_error.js"
],
Expand Down
Loading

0 comments on commit c3759f7

Please sign in to comment.