-
Notifications
You must be signed in to change notification settings - Fork 373
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into feature/5747-use-add-question-component
- Loading branch information
Showing
113 changed files
with
1,839 additions
and
216 deletions.
There are no files selected for viewing
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
2 changes: 1 addition & 1 deletion
2
packages/survey-creator-angular/src/property-panel/object-selector.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
2 changes: 1 addition & 1 deletion
2
.../src/side-bar/side-bar-tab.component.html → ...src/side-bar/side-bar-page.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,5 +1,5 @@ | ||
<ng-template #template> | ||
<ng-container *ngIf="model.visible"> | ||
<ng-template [component]="{ name: model.componentName, data: { model: model.model } }"></ng-template> | ||
<ng-template [component]="{ name: model.componentName, data: { model: model.componentData } }"></ng-template> | ||
</ng-container> | ||
</ng-template> |
16 changes: 16 additions & 0 deletions
16
packages/survey-creator-angular/src/side-bar/side-bar-page.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 |
---|---|---|
@@ -0,0 +1,16 @@ | ||
|
||
import { Component, Input } from "@angular/core"; | ||
import { BaseAngular } from "survey-angular-ui"; | ||
import { SidebarPageModel } from "survey-creator-core"; | ||
|
||
@Component({ | ||
selector: "svc-side-bar-page", | ||
templateUrl: "./side-bar-page.component.html", | ||
styles: [":host { display: none; }"] | ||
}) | ||
export class SidebarPageComponent extends BaseAngular<SidebarPageModel> { | ||
@Input() model!: SidebarPageModel; | ||
protected getModel(): SidebarPageModel { | ||
return this.model; | ||
} | ||
} |
16 changes: 0 additions & 16 deletions
16
packages/survey-creator-angular/src/side-bar/side-bar-tab.component.ts
This file was deleted.
Oops, something went wrong.
28 changes: 19 additions & 9 deletions
28
packages/survey-creator-angular/src/side-bar/side-bar.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,20 +1,30 @@ | ||
<ng-template #template> | ||
<div class="svc-side-bar" [class.svc-flyout-side-bar]="model.flyoutPanelMode" [visible]="model.hasVisibleTabs"> | ||
<div class="svc-side-bar" [class.svc-flyout-side-bar]="model.flyoutPanelMode" [visible]="model.hasVisiblePages"> | ||
<div class="svc-side-bar__shadow" (click)="model.collapseSidebar()"></div> | ||
<div class="svc-flex-column svc-side-bar__wrapper"> | ||
<div class="svc-flex-row svc-side-bar__wrapper"> | ||
<div class="svc-side-bar__container" [visible]="model.renderedIsVisible" #container> | ||
<div class="svc-side-bar__container-header"> | ||
<div class="svc-side-bar__container-actions"> | ||
<sv-action-bar [model]="model.toolbar"></sv-action-bar> | ||
<ng-container *ngIf="model.headerComponentName"> | ||
<ng-template | ||
[component]="{ name: model.headerComponentName, data: { model: model.headerComponentData } }"></ng-template> | ||
</ng-container> | ||
<ng-container *ngIf="!model.headerComponentName"> | ||
<div class="svc-side-bar__container-header"> | ||
<div class="svc-side-bar__container-actions"> | ||
<sv-action-bar [model]="model.toolbar"></sv-action-bar> | ||
</div> | ||
<div *ngIf="!!model.headerText" class="svc-side-bar__container-title">{{model.headerText}}</div> | ||
</div> | ||
<div *ngIf="!!model.headerText" class="svc-side-bar__container-title">{{model.headerText}}</div> | ||
</div> | ||
</ng-container> | ||
<div class="svc-side-bar__container-content"> | ||
<ng-container *ngFor="let tab of model.tabs"> | ||
<svc-side-bar-tab [model]="tab"></svc-side-bar-tab> | ||
<ng-container *ngFor="let page of model.pages"> | ||
<svc-side-bar-page [model]="page"></svc-side-bar-page> | ||
</ng-container> | ||
</div> | ||
</div> | ||
<ng-container *ngIf="model.sideAreaComponentName"> | ||
<ng-template | ||
[component]="{ name: model.sideAreaComponentName, data: { model: model.sideAreaComponentData } }"></ng-template> | ||
</ng-container> | ||
</div> | ||
</div> | ||
</ng-template> |
5 changes: 5 additions & 0 deletions
5
...es/survey-creator-angular/src/tab-control/property-grid-placeholder-header.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 |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<ng-template #template> | ||
<div class="svc-side-bar__container-header svc-sidebar__header-container"> | ||
<div class="svc-side-bar__container-title">{{model.caption}}</div> | ||
</div> | ||
</ng-template> |
17 changes: 17 additions & 0 deletions
17
...ages/survey-creator-angular/src/tab-control/property-grid-placeholder-header.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 |
---|---|---|
@@ -0,0 +1,17 @@ | ||
|
||
import { Component, Input } from "@angular/core"; | ||
import { AngularComponentFactory, BaseAngular } from "survey-angular-ui"; | ||
import { SidebarPageModel } from "survey-creator-core"; | ||
|
||
@Component({ | ||
selector: "svc-side-bar-property-grid-placeholder-header", | ||
templateUrl: "./property-grid-placeholder-header.component.html", | ||
styles: [":host { display: none; }"] | ||
}) | ||
export class SidebarPropertyGridPlaceholderHeaderComponent extends BaseAngular<SidebarPageModel> { | ||
@Input() model!: SidebarPageModel; | ||
protected getModel(): SidebarPageModel { | ||
return this.model; | ||
} | ||
} | ||
AngularComponentFactory.Instance.registerComponent("svc-side-bar-property-grid-placeholder-header", SidebarPropertyGridPlaceholderHeaderComponent); |
14 changes: 14 additions & 0 deletions
14
packages/survey-creator-angular/src/tab-control/property-grid-placeholder.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 |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<ng-template #template> | ||
<div class="svc-property-grid-placeholder"> | ||
<div class="svc-property-grid-placeholder__header"> | ||
<span | ||
class="svc-property-grid-placeholder__title">{{editorLocalization.getString("ed.propertyGridPlaceholderTitle")}}</span> | ||
<span | ||
class="svc-property-grid-placeholder__description">{{editorLocalization.getString("ed.propertyGridPlaceholderDescription")}}</span> | ||
</div> | ||
<div class="svc-property-grid-placeholder__content"> | ||
<div class="svc-property-grid-placeholder__gap"></div> | ||
<div class="svc-property-grid-placeholder__image"></div> | ||
</div> | ||
</div> | ||
</ng-template> |
13 changes: 13 additions & 0 deletions
13
packages/survey-creator-angular/src/tab-control/property-grid-placeholder.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 |
---|---|---|
@@ -0,0 +1,13 @@ | ||
import { Component } from "@angular/core"; | ||
import { AngularComponentFactory, EmbeddedViewContentComponent } from "survey-angular-ui"; | ||
import { editorLocalization } from "survey-creator-core"; | ||
|
||
@Component({ | ||
selector: "svc-property-grid-placeholder", | ||
templateUrl: "./property-grid-placeholder.component.html", | ||
styles: [":host { display: none; }"] | ||
}) | ||
export class PropertyGridPlaceholderComponent extends EmbeddedViewContentComponent { | ||
editorLocalization = editorLocalization; | ||
} | ||
AngularComponentFactory.Instance.registerComponent("svc-property-grid-placeholder", PropertyGridPlaceholderComponent); |
15 changes: 15 additions & 0 deletions
15
packages/survey-creator-angular/src/tab-control/side-bar-property-grid-header.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 |
---|---|---|
@@ -0,0 +1,15 @@ | ||
<ng-template #template> | ||
<div class="svc-sidebar__header svc-sidebar__header--tabbed"> | ||
<div class="svc-sidebar__header-container svc-sidebar__header-container--with-subtitle"> | ||
<div class="svc-sidebar__header-content" (click)="model.action()"> | ||
<div [class]="model.buttonClassName"> | ||
<div class="svc-sidebar__header-caption"> | ||
<span class="svc-sidebar__header-title">{{model.title}}</span> | ||
<span class="svc-sidebar__header-subtitle">{{model.tooltip}}</span> | ||
</div> | ||
</div> | ||
<sv-ng-popup [popupModel]="model.popupModel" [getTarget]="getTarget"></sv-ng-popup> | ||
</div> | ||
</div> | ||
</div> | ||
</ng-template> |
20 changes: 20 additions & 0 deletions
20
packages/survey-creator-angular/src/tab-control/side-bar-property-grid-header.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 |
---|---|---|
@@ -0,0 +1,20 @@ | ||
|
||
import { Component, Input } from "@angular/core"; | ||
import { AngularComponentFactory, BaseAngular } from "survey-angular-ui"; | ||
import { getActionDropdownButtonTarget } from "survey-core"; | ||
import { MenuButton } from "survey-creator-core"; | ||
|
||
@Component({ | ||
selector: "svc-side-bar-property-grid-header", | ||
templateUrl: "./side-bar-property-grid-header.component.html", | ||
styles: [":host { display: none; }"] | ||
}) | ||
export class SidebarPropertyGridHeaderComponent extends BaseAngular<MenuButton> { | ||
@Input() model!: MenuButton; | ||
public getTarget: (container: HTMLElement) => HTMLElement = getActionDropdownButtonTarget; | ||
|
||
protected getModel(): MenuButton { | ||
return this.model; | ||
} | ||
} | ||
AngularComponentFactory.Instance.registerComponent("svc-side-bar-property-grid-header", SidebarPropertyGridHeaderComponent); |
11 changes: 11 additions & 0 deletions
11
packages/survey-creator-angular/src/tab-control/tab-button.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 |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<ng-template #template> | ||
<div class="svc-menu-action"> | ||
<div [class]="model.buttonClassName" [attr.title]="model.tooltip" (click)="model.action()"> | ||
<div class="svc-menu-action__icon"> | ||
<div class="svc-menu-action__icon-container"> | ||
<svg [iconName]="model.iconName" [size]="24" sv-ng-svg-icon></svg> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</ng-template> |
16 changes: 16 additions & 0 deletions
16
packages/survey-creator-angular/src/tab-control/tab-button.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 |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { Component, Input } from "@angular/core"; | ||
import { BaseAngular, AngularComponentFactory } from "survey-angular-ui"; | ||
import { MenuButton } from "survey-creator-core"; | ||
|
||
@Component({ | ||
selector: "svc-tab-button", | ||
templateUrl: "./tab-button.component.html", | ||
styles: [":host { display: none; }"] | ||
}) | ||
export class TabButtonComponent extends BaseAngular<MenuButton> { | ||
@Input() model!: MenuButton; | ||
protected getModel(): MenuButton { | ||
return this.model; | ||
} | ||
} | ||
AngularComponentFactory.Instance.registerComponent("svc-tab-button", TabButtonComponent); |
20 changes: 20 additions & 0 deletions
20
packages/survey-creator-angular/src/tab-control/tab-control.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 |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<ng-template #template> | ||
<div [class]="model.sideBarClassName"> | ||
<div class="svc-sidebar-tabs__top-container"> | ||
<div class="svc-sidebar-tabs__collapse-button"> | ||
<svc-tab-button [model]="model.expandCollapseAction"></svc-tab-button> | ||
</div> | ||
<div class="svc-sidebar-tabs__separator"> | ||
<div></div> | ||
</div> | ||
<div class="svc-sidebar-tabs__items"> | ||
<svc-tabs [model]="model.topToolbar"></svc-tabs> | ||
</div> | ||
</div> | ||
<div class="svc-sidebar-tabs__bottom-container"> | ||
<div class="svc-sidebar-tabs__items"> | ||
<svc-tabs [model]="model.bottomToolbar"></svc-tabs> | ||
</div> | ||
</div> | ||
</div> | ||
</ng-template> |
16 changes: 16 additions & 0 deletions
16
packages/survey-creator-angular/src/tab-control/tab-control.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 |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { Component, Input } from "@angular/core"; | ||
import { BaseAngular, AngularComponentFactory } from "survey-angular-ui"; | ||
import { TabControlModel } from "survey-creator-core"; | ||
|
||
@Component({ | ||
selector: "svc-tab-control", | ||
templateUrl: "./tab-control.component.html", | ||
styles: [":host { display: none; }"] | ||
}) | ||
export class TabControlComponent extends BaseAngular<TabControlModel> { | ||
@Input() model!: TabControlModel; | ||
protected getModel(): TabControlModel { | ||
return this.model; | ||
} | ||
} | ||
AngularComponentFactory.Instance.registerComponent("svc-tab-control", TabControlComponent); |
5 changes: 5 additions & 0 deletions
5
packages/survey-creator-angular/src/tab-control/tabs.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 |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<ng-template #template> | ||
<ng-container *ngFor="let action of model.actions"> | ||
<svc-tab-button [model]="action"></svc-tab-button> | ||
</ng-container> | ||
</ng-template> |
16 changes: 16 additions & 0 deletions
16
packages/survey-creator-angular/src/tab-control/tabs.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 |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { Component, Input } from "@angular/core"; | ||
import { BaseAngular } from "survey-angular-ui"; | ||
import { ActionContainer } from "survey-core"; | ||
import { MenuButton } from "survey-creator-core"; | ||
|
||
@Component({ | ||
selector: "svc-tabs", | ||
templateUrl: "./tabs.component.html", | ||
styles: [":host { display: none; }"] | ||
}) | ||
export class TabsComponent extends BaseAngular<ActionContainer<MenuButton>> { | ||
@Input() model!: ActionContainer<MenuButton>; | ||
protected getModel(): ActionContainer<MenuButton> { | ||
return this.model; | ||
} | ||
} |
Oops, something went wrong.