Skip to content

Commit fc4a599

Browse files
mattgperryclaude
andcommitted
Update SSR tests to include overflow-anchor style
🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent c82aa56 commit fc4a599

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

packages/framer-motion/src/components/Reorder/__tests__/server.ssr.test.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ describe("Reorder", () => {
1313
const staticMarkup = renderToStaticMarkup(<Component />)
1414
const string = renderToString(<Component />)
1515

16-
const expectedMarkup = `<article><main draggable="false" style="z-index:unset;transform:none;-webkit-touch-callout:none;-webkit-user-select:none;user-select:none;touch-action:pan-x"></main></article>`
16+
const expectedMarkup = `<article style="overflow-anchor:none"><main draggable="false" style="z-index:unset;transform:none;-webkit-touch-callout:none;-webkit-user-select:none;user-select:none;touch-action:pan-x"></main></article>`
1717

1818
expect(staticMarkup).toBe(expectedMarkup)
1919
expect(string).toBe(expectedMarkup)
@@ -32,7 +32,7 @@ describe("Reorder", () => {
3232
const staticMarkup = renderToStaticMarkup(<Component />)
3333
const string = renderToString(<Component />)
3434

35-
const expectedMarkup = `<article><main draggable="false" style="z-index:unset;transform:none;-webkit-touch-callout:none;-webkit-user-select:none;user-select:none;touch-action:pan-x"></main></article>`
35+
const expectedMarkup = `<article style="overflow-anchor:none"><main draggable="false" style="z-index:unset;transform:none;-webkit-touch-callout:none;-webkit-user-select:none;user-select:none;touch-action:pan-x"></main></article>`
3636

3737
expect(staticMarkup).toBe(expectedMarkup)
3838
expect(string).toBe(expectedMarkup)

packages/framer-motion/src/motion/__tests__/ssr.test.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,7 @@ function runTests(render: (components: any) => string) {
285285
const div = render(<Component />)
286286

287287
expect(div).toBe(
288-
`<ul><li draggable="false" style="z-index:unset;transform:none;-webkit-touch-callout:none;-webkit-user-select:none;user-select:none;touch-action:pan-x"></li></ul>`
288+
`<ul style="overflow-anchor:none"><li draggable="false" style="z-index:unset;transform:none;-webkit-touch-callout:none;-webkit-user-select:none;user-select:none;touch-action:pan-x"></li></ul>`
289289
)
290290
})
291291

@@ -301,7 +301,7 @@ function runTests(render: (components: any) => string) {
301301
const div = render(<Component />)
302302

303303
expect(div).toBe(
304-
`<ul><li style="z-index:unset;transform:none"></li></ul>`
304+
`<ul style="overflow-anchor:none"><li style="z-index:unset;transform:none"></li></ul>`
305305
)
306306
})
307307

@@ -317,7 +317,7 @@ function runTests(render: (components: any) => string) {
317317
const div = render(<Component />)
318318

319319
expect(div).toBe(
320-
`<div><div draggable="false" style="z-index:unset;transform:none;-webkit-touch-callout:none;-webkit-user-select:none;user-select:none;touch-action:pan-x"></div></div>`
320+
`<div style="overflow-anchor:none"><div draggable="false" style="z-index:unset;transform:none;-webkit-touch-callout:none;-webkit-user-select:none;user-select:none;touch-action:pan-x"></div></div>`
321321
)
322322
})
323323

0 commit comments

Comments
 (0)