Skip to content

Commit

Permalink
Fields are not on a one line (#7187)
Browse files Browse the repository at this point in the history
  • Loading branch information
novikov82 committed Oct 19, 2023
1 parent 1363dd9 commit 1defd63
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/defaultV2-theme/blocks/sd-question.scss
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,6 @@
.sd-question__title--empty {
.sv-string-viewer {
display: inline-block;
height: calcSize(3);
height: multiply(1.5, $font-questiontitle-size);
}
}
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
33 changes: 33 additions & 0 deletions visualRegressionTests/tests/defaultV2/question.ts
Original file line number Diff line number Diff line change
Expand Up @@ -830,4 +830,37 @@ frameworks.forEach(framework => {
await takeElementScreenshot("question-descriptionLocation-underInput.png", questionRows.nth(3), t, comparer);
});
});

test("Question empty title height", async (t) => {
await wrapVisualTest(t, async (t, comparer) => {
await t.resizeWindow(1920, 1080);
await initSurvey(framework, {
"pages": [
{
"name": "page1",
"elements": [
{
"type": "text",
"name": "question1"
},
{
"type": "text",
"name": "question2",
"startWithNewLine": false,
"title": " "
}
]
}
],
"showQuestionNumbers": "off",
"widthMode": "static",
"width": "800"
});
await ClientFunction(() => {
document.documentElement.style.setProperty("--sjs-font-size", "8px");
})();
const questionRows = Selector(".sd-row");
await takeElementScreenshot("question-empty-title-height.png", questionRows.nth(0), t, comparer);
});
});
});

0 comments on commit 1defd63

Please sign in to comment.