Skip to content

Commit

Permalink
#7311 Multiple Questions in a Row - An extra padding appears on the l…
Browse files Browse the repository at this point in the history
…eft side of a row when questionsOnPageMode is singlePage (#7319)

* #7311 Multiple Questions in a Row - An extra padding appears on the left side of a row when questionsOnPageMode is singlePage
Fixes #7311

* #7311-add-screenshot
  • Loading branch information
novikov82 committed Nov 10, 2023
1 parent e2ec2be commit 8353d16
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/defaultV2-theme/blocks/sd-row.scss
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
}
}

.sd-panel {
.sd-panel:not(.sd-panel--as-page) {
.sd-row--multiple {
row-gap: var(--sd-base-vertical-padding);

Expand Down
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
31 changes: 31 additions & 0 deletions visualRegressionTests/tests/defaultV2/panel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -448,6 +448,37 @@ frameworks.forEach(framework => {
await takeElementScreenshot("panel-single-page.png", panelRoot, t, comparer);
});
});
test("Check panel with singlePage mode - one line", async (t) => {
await wrapVisualTest(t, async (t, comparer) => {
await t.resizeWindow(1920, 1080);
await initSurvey(framework, {
questionsOnPageMode: "singlePage",
pages: [
{
title: "Page title",
description: "Page description",
elements: [{
name: "username",
type: "text",
title: "Username",
}, {
name: "email",
type: "text",
title: "E-mail address",
startWithNewLine: false
}, {
name: "password",
type: "text",
title: "Password",
startWithNewLine: false
}]
}]
});
const panelRoot = Selector(".sd-panel");
await resetFocusToBody();
await takeElementScreenshot("panel-single-page-one-line.png", panelRoot, t, comparer);
});
});
test("Check multiple panels with singlePage mode", async (t) => {
await wrapVisualTest(t, async (t, comparer) => {
await t.resizeWindow(1920, 1080);
Expand Down

0 comments on commit 8353d16

Please sign in to comment.