Skip to content

Commit

Permalink
Fix: Moved focusTrapTarget from ec-modal__content to ec-modal (#1978)
Browse files Browse the repository at this point in the history
  • Loading branch information
corinaper authored Jun 12, 2024
1 parent 2b43831 commit 396b453
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@ebury/chameleon-components",
"version": "2.8.8",
"version": "2.8.9",
"main": "src/main.ts",
"sideEffects": false,
"author": "Ebury Team (http://labs.ebury.rocks/)",
Expand Down
2 changes: 1 addition & 1 deletion src/components/ec-modal/ec-modal.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@ describe('EcModal', () => {
attachTo: element,
});
const container = wrapper.vm.getFocusTrapContainer();
expect(container).toBe(wrapper.findByDataTest<HTMLElement>('ec-modal__content').element);
expect(container).toBe(wrapper.findByDataTest<HTMLElement>('ec-modal').element);
});
});

Expand Down
2 changes: 1 addition & 1 deletion src/components/ec-modal/ec-modal.vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<template>
<transition name="ec-modal__fade">
<div
ref="focusTrapTarget"
v-if="show"
class="ec-modal"
:style="zIndexStyle"
Expand All @@ -11,7 +12,6 @@
@click.self="closeModal()"
>
<div
ref="focusTrapTarget"
class="ec-modal__content"
data-test="ec-modal__content"
:class="{ 'ec-modal--lg': large }"
Expand Down

0 comments on commit 396b453

Please sign in to comment.