Skip to content

Commit

Permalink
#6185 Description under input raises scrollbar in Designer (#6192)
Browse files Browse the repository at this point in the history
* #6185 Description under input raises scrollbar in Designer
Fixes #6185

* fix test #6185

* etalons #6185
  • Loading branch information
novikov82 authored Dec 9, 2024
1 parent c777808 commit efaf292
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/survey-creator-core/src/components/question.scss
Original file line number Diff line number Diff line change
Expand Up @@ -1307,6 +1307,11 @@ svc-question,
overflow-x: auto;
}

.sd-question--description-under-input .sd-question__content {
margin-bottom: calcSize(-1);
padding-bottom: calcSize(1);
}

.sd-composite {
.sd-question__content {
margin-left: 0;
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
28 changes: 28 additions & 0 deletions visualRegressionTests/tests/designer/surface.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2378,4 +2378,32 @@ test("Matrix Dynamiv with rows drad-drop", async (t) => {
await setJSON(json);
await takeElementScreenshot("design-surface-matrixdynamic-with-drag-drop.png", Selector(".svc-tab-designer .sd-table-wrapper"), t, comparer);
});
});

test("Question description bottom", async (t) => {
await wrapVisualTest(t, async (t, comparer) => {
await t.resizeWindow(1024, 800);

const json = {
"logoPosition": "right",
"pages": [
{
"name": "page1",
"elements": [
{
"type": "text",
"name": "question1",
"description": "Description",
"descriptionLocation": "underInput"
}
]
}
]
};
await setJSON(json);

await t.click(Selector(".sv-string-editor").withText("Description"));
const QRoot = Selector(".svc-question__adorner").filterVisible();
await takeElementScreenshot("surface-question-bottom-description.png", QRoot, t, comparer);
});
});

0 comments on commit efaf292

Please sign in to comment.