Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

340835710: (fix) [Risk assessment] change page view when callout is visible #461

Merged
merged 1 commit into from
May 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,15 @@
See the License for the specific language governing permissions and
limitations under the License.
-->

<mat-drawer-container
class="risk-assessment-container"
*ngIf="viewModel$ | async as vm">
<mat-drawer-content class="risk-assessment-content">
<mat-toolbar class="risk-assessment-toolbar">
<h2 class="title">Risk assessment</h2>
</mat-toolbar>
<div class="main-content"></div>
</mat-drawer-content>
<ng-container *ngIf="viewModel$ | async as vm">
<mat-drawer-container class="risk-assessment-container">
<mat-drawer-content class="risk-assessment-content">
<mat-toolbar class="risk-assessment-toolbar">
<h2 class="title">Risk assessment</h2>
</mat-toolbar>
<div class="main-content"></div>
</mat-drawer-content>
</mat-drawer-container>
<mat-drawer
mode="side"
opened
Expand All @@ -37,4 +36,4 @@ <h2 class="profiles-drawer-header-title">Saved profiles</h2>
</app-profile-item>
</div>
</mat-drawer>
</mat-drawer-container>
</ng-container>
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
* limitations under the License.
*/
@import 'src/theming/colors';
@import 'src/theming/variables';

.risk-assessment-container,
.risk-assessment-content {
Expand All @@ -38,7 +39,7 @@
}

.profiles-drawer {
width: 320px;
width: $profiles-drawer-width;
box-shadow: none;
border-left: 1px solid $light-grey;
}
Expand Down
21 changes: 19 additions & 2 deletions modules/ui/src/styles.scss
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
*/
@use '@angular/material' as mat;
@import './theming/theme';
@import 'src/theming/variables';

html,
body {
Expand Down Expand Up @@ -234,6 +235,10 @@ body
body
#main:has(app-callout .info):not(:has(app-callout .error))
app-progress:not(:has(.progress-content-empty)),
body
#main:has(app-callout .info):not(:has(app-callout .error))
app-risk-assessment
.risk-assessment-container,
body
#main:has(app-callout .error):not(:has(app-callout .info))
app-device-repository:not(:has(.device-repository-content-empty)),
Expand All @@ -242,7 +247,11 @@ body
app-history:not(:has(.results-content-empty)),
body
#main:has(app-callout .error):not(:has(app-callout .info))
app-progress:not(:has(.progress-content-empty)) {
app-progress:not(:has(.progress-content-empty)),
body
#main:has(app-callout .error):not(:has(app-callout .info))
app-risk-assessment
.risk-assessment-container {
margin-top: 96px;
}

Expand All @@ -254,10 +263,18 @@ body
app-history:not(:has(.results-content-empty)),
body
#main:has(app-callout .info):has(app-callout .error)
app-progress:not(:has(.progress-content-empty)) {
app-progress:not(:has(.progress-content-empty)),
body
#main:has(app-callout .info):has(app-callout .error)
app-risk-assessment
.risk-assessment-container {
margin-top: 156px;
}

body:has(app-risk-assessment .profiles-drawer) #main app-callout {
width: calc(100% - $profiles-drawer-width);
}

.text-nowrap {
white-space: nowrap;
}
Expand Down
1 change: 1 addition & 0 deletions modules/ui/src/theming/variables.scss
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,6 @@
* limitations under the License.
*/
$device-item-width: 352px;
$profiles-drawer-width: 320px;

$font-secondary: 'Roboto';
Loading