@@ -7,7 +7,9 @@ import { module, test } from 'qunit';
77import { setupRenderingTest } from ' showcase/tests/helpers' ;
88import { render } from ' @ember/test-helpers' ;
99import { wait } from ' showcase/tests/helpers' ;
10- import hdsAnchoredPosition , { getFloatingUIOptions } from ' @hashicorp/design-system-components/modifiers/hds-anchored-position' ;
10+ import hdsAnchoredPosition, {
11+ getFloatingUIOptions ,
12+ } from ' @hashicorp/design-system-components/modifiers/hds-anchored-position' ;
1113import anchoredElementModifier from ' @hashicorp/design-system-components/modifiers/hds-anchored-position' ;
1214
1315//
@@ -213,12 +215,14 @@ module('Integration | Modifier | hds-anchored-position', function (hooks) {
213215 });
214216
215217 test (' render "anchor/floating/arrow" elements with default `options`' , async function (assert ) {
216- await render (<template >
217- <div id =" wrapper" >
218- <div id =" anchor" >anchor</div >
219- <div id =" floating" ><div id =" arrow" ></div >floating</div >
220- </div >
221- </template >);
218+ await render (
219+ <template >
220+ <div id =" wrapper" >
221+ <div id =" anchor" >anchor</div >
222+ <div id =" floating" ><div id =" arrow" ></div >floating</div >
223+ </div >
224+ </template >,
225+ );
222226 this .anchorElement = document .getElementById (' anchor' );
223227 this .floatingElement = document .getElementById (' floating' );
224228 this .arrowElement = document .getElementById (' arrow' );
@@ -245,12 +249,14 @@ module('Integration | Modifier | hds-anchored-position', function (hooks) {
245249 });
246250
247251 test (' render "anchor/floating/arrow" elements with custom options' , async function (assert ) {
248- await render (<template >
249- <div id =" wrapper" >
250- <div id =" anchor" >anchor</div >
251- <div id =" floating" ><div id =" arrow" ></div >floating</div >
252- </div >
253- </template >);
252+ await render (
253+ <template >
254+ <div id =" wrapper" >
255+ <div id =" anchor" >anchor</div >
256+ <div id =" floating" ><div id =" arrow" ></div >floating</div >
257+ </div >
258+ </template >,
259+ );
254260 this .anchorElement = document .getElementById (' anchor' );
255261 this .floatingElement = document .getElementById (' floating' );
256262 this .arrowElement = document .getElementById (' arrow' );
@@ -283,12 +289,23 @@ module('Integration | Modifier | hds-anchored-position', function (hooks) {
283289 });
284290
285291 test (' the modifier works also when applied directly in the template code' , async function (assert ) {
286- await render (<template >
287- <div id =" wrapper" >
288- <div id =" anchor" >anchor</div >
289- <div id =" floating" {{hdsAnchoredPosition " #anchor" placement =" bottom-start" strategy =" fixed" offsetOptions =20 arrowSelector =" #arrow" }} ><div id =" arrow" ></div >floating</div >
290- </div >
291- </template >);
292+ await render (
293+ <template >
294+ <div id =" wrapper" >
295+ <div id =" anchor" >anchor</div >
296+ <div
297+ id =" floating"
298+ {{hdsAnchoredPosition
299+ " #anchor"
300+ placement =" bottom-start"
301+ strategy =" fixed"
302+ offsetOptions =20
303+ arrowSelector =" #arrow"
304+ }}
305+ ><div id =" arrow" ></div >floating</div >
306+ </div >
307+ </template >,
308+ );
292309 this .anchorElement = document .getElementById (' anchor' );
293310 this .floatingElement = document .getElementById (' floating' );
294311 this .arrowElement = document .getElementById (' arrow' );
0 commit comments