Skip to content

Commit

Permalink
Work for #5282 - If question width is small for text type then changi…
Browse files Browse the repository at this point in the history
…ng input type breaks adaptivity
  • Loading branch information
tsv2013 committed Mar 6, 2024
1 parent 2d27ec4 commit dea16d1
Show file tree
Hide file tree
Showing 2 changed files with 37 additions and 1 deletion.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
38 changes: 37 additions & 1 deletion visualRegressionTests/tests/designer/surface.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1965,4 +1965,40 @@ test("Composite question - check no scroll", async (t) => {
await t.hover(".sd-input.sd-text");
await takeElementScreenshot("composite-question-no-scroll.png", Selector(".svc-question__adorner"), t, comparer);
});
});
});

test("Check adorner actions responsifity after convert", async (t) => {
await wrapVisualTest(t, async (t, comparer) => {
await t.resizeWindow(1400, 900);
const root = Selector(".sd-page.sd-body__page");
await setJSON({
"logoPosition": "right",
"pages": [
{
"name": "page1",
"elements": [
{
"type": "text",
"name": "question1"
},
{
"type": "text",
"name": "question2",
"startWithNewLine": false
},
{
"type": "text",
"name": "question3",
"startWithNewLine": false
}
]
}
]
});
await t.hover(Selector(".svc-question__adorner").nth(2)).click(Selector("#convertTo").nth(2)).click(Selector("#convertTo").nth(2))
.click(Selector("div[data-sv-drop-target-survey-element='question3'] .sv-list__item-body[title='Yes/No (Boolean)']"))
.click(Selector(".svc-question__adorner").nth(1)).click(Selector(".svc-question__adorner").nth(1))
.click(Selector(".svc-question__adorner").nth(2), { offsetX: 10, offsetY: 10 }).click(Selector(".svc-question__adorner").nth(2), { offsetX: 10, offsetY: 10 });
await takeElementScreenshot("actions-on-converted-question.png", root.nth(0), t, comparer);
});
});

0 comments on commit dea16d1

Please sign in to comment.