-
Notifications
You must be signed in to change notification settings - Fork 382
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixed#4371 - Theme builder/Preview : strange resulting page (#4626)
* Fixed#4371 - Theme builder/Preview : strange resulting page * Work for #4371 - Theme builder/Preview : strange resulting page - updated etalons * Work for #4371 - Theme builder/Preview : strange resulting page - updated etalons --------- Co-authored-by: tsv2013 <[email protected]>
- Loading branch information
Showing
25 changed files
with
67 additions
and
33 deletions.
There are no files selected for viewing
4 changes: 2 additions & 2 deletions
4
packages/survey-creator-angular/src/tabs/preview/test-again.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
<ng-template #template> | ||
<div role="button" class="svc-preview__test-again svc-btn" (click)="model.action()" [key2click]> | ||
<div role="button" class="svc-preview__test-again svc-btn" (click)="action.action()" [key2click]> | ||
<span class="svc-text svc-text--normal svc-text--bold"> | ||
{{model.title}} | ||
{{action.title}} | ||
</span> | ||
</div> | ||
</ng-template> |
13 changes: 9 additions & 4 deletions
13
packages/survey-creator-angular/src/tabs/preview/test-again.component.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,20 @@ | ||
import { Component, Input } from "@angular/core"; | ||
import { BaseAngular } from "survey-angular-ui"; | ||
import { AngularComponentFactory, BaseAngular } from "survey-angular-ui"; | ||
import { Action } from "survey-core"; | ||
import { TestSurveyTabViewModel } from "survey-creator-core"; | ||
|
||
@Component({ | ||
selector: "survey-test-again", | ||
templateUrl: "./test-again.component.html", | ||
styles: [":host { display: none; }"] | ||
}) | ||
export class TestAgainActionComponent extends BaseAngular<Action> { | ||
@Input() model!: Action; | ||
@Input() model!: { testAgainAction: Action }; | ||
protected getModel(): Action { | ||
return this.model; | ||
return this.model.testAgainAction; | ||
} | ||
} | ||
get action() { | ||
return this.getModel(); | ||
} | ||
} | ||
AngularComponentFactory.Instance.registerComponent("svc-complete-page", TestAgainActionComponent); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<div role="button" class="svc-preview__test-again svc-btn" | ||
data-bind="click: testAgainAction.action, key2click, clickBubble: false"> | ||
<span class="svc-text svc-text--normal svc-text--bold" data-bind="text: testAgainAction.title"> | ||
</span> | ||
</div> |
19 changes: 19 additions & 0 deletions
19
packages/survey-creator-knockout/src/tabs/test-complete.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import * as ko from "knockout"; | ||
import { ImplementorBase } from "survey-knockout-ui"; | ||
import { TestSurveyTabViewModel } from "survey-creator-core"; | ||
|
||
const template = require("./test-complete.html"); | ||
// import template from "./test-complete.html"; | ||
|
||
ko.components.register("svc-complete-page", { | ||
viewModel: { | ||
createViewModel: (params: any, componentInfo: any) => { | ||
const model: TestSurveyTabViewModel = params.model; | ||
new ImplementorBase(model.testAgainAction); | ||
return { | ||
testAgainAction: model.testAgainAction | ||
}; | ||
}, | ||
}, | ||
template: template | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file modified
BIN
+4.03 KB
(120%)
visualRegressionTests/tests/designer/etalons/complete-tab-results-part.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+3.06 KB
(110%)
visualRegressionTests/tests/designer/etalons/complete-tab-results-via-json.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+2.36 KB
(110%)
visualRegressionTests/tests/designer/etalons/complete-tab-results-via-table-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+258 Bytes
(100%)
visualRegressionTests/tests/designer/etalons/complete-tab-results-via-table-2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+5.11 KB
(150%)
visualRegressionTests/tests/designer/etalons/theme-default-test-again.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+5.15 KB
(150%)
visualRegressionTests/tests/designer/etalons/theme-legacy-test-again.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+5.27 KB
(130%)
visualRegressionTests/tests/designer/etalons/theme-modern-test-again.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.