Skip to content

Commit

Permalink
feat: add disclaimer to indicate approximate numbers
Browse files Browse the repository at this point in the history
  • Loading branch information
gulfaraz committed Aug 14, 2024
1 parent c3e26e7 commit 19452a2
Show file tree
Hide file tree
Showing 9 changed files with 70 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<ion-item class="ion-margin-vertical" lines="none">
<ion-thumbnail slot="start">
<ion-img src="assets/icons/source-info-grey.svg"></ion-img>
</ion-thumbnail>
<ion-label class="ion-text-wrap" color="fiveten-neutral-700">
{{ 'disclaimer-approximate-component.message' | translate }}
</ion-label>
</ion-item>
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
ion-item {
ion-thumbnail {
--size: 1rem;
}
ion-label {
font-size: 0.75rem;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';

import { DisclaimerApproximateComponent } from './disclaimer-approximate.component';

describe('DisclaimerApproximateComponent', () => {
let component: DisclaimerApproximateComponent;
let fixture: ComponentFixture<DisclaimerApproximateComponent>;

beforeEach(async () => {
await TestBed.configureTestingModule({
imports: [DisclaimerApproximateComponent],
}).compileComponents();

fixture = TestBed.createComponent(DisclaimerApproximateComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});

it('should create', () => {
expect(component).toBeTruthy();
});
});
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import { Component } from '@angular/core';

@Component({
selector: 'app-disclaimer-approximate',
templateUrl: './disclaimer-approximate.component.html',
styleUrls: ['./disclaimer-approximate.component.scss'],
})
export class DisclaimerApproximateComponent {}
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@
>
<ion-content>
<ion-grid
class="ibf-dashboard-right-column-left-sub-column-grid ion-justify-content-between ion-no-padding"
class="ibf-dashboard-right-column-left-sub-column-grid ion-no-padding"
>
<ion-row>
<ion-col>
Expand All @@ -150,6 +150,11 @@
</ion-col>
</ion-row>
<ion-row>
<ion-col>
<app-disclaimer-approximate></app-disclaimer-approximate>
</ion-col>
</ion-row>
<ion-row class="margin-top-auto">
<ion-col>
<app-areas-of-focus-summary></app-areas-of-focus-summary>
</ion-col>
Expand Down
3 changes: 3 additions & 0 deletions interfaces/IBF-dashboard/src/app/shared.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ import { TooltipComponent } from './components/tooltip/tooltip.component';
import { UserStateComponent } from './components/user-state/user-state.component';
import { BackendMockScenarioComponent } from './mocks/backend-mock-scenario-component/backend-mock-scenario.component';
import { CompactPipe } from './pipes/compact.pipe';
import { DisclaimerApproximateComponent } from './components/disclaimer-approximate/disclaimer-approximate.component';

@NgModule({
imports: [
Expand Down Expand Up @@ -104,6 +105,7 @@ import { CompactPipe } from './pipes/compact.pipe';
DynamicPointPopupComponent,
TyphoonTrackpointPopupContentComponent,
GlofasStationPopupContentComponent,
DisclaimerApproximateComponent,
],
exports: [
AboutBtnComponent,
Expand Down Expand Up @@ -149,6 +151,7 @@ import { CompactPipe } from './pipes/compact.pipe';
DynamicPointPopupComponent,
TyphoonTrackpointPopupContentComponent,
GlofasStationPopupContentComponent,
DisclaimerApproximateComponent,
],
})
export class SharedModule {}
3 changes: 3 additions & 0 deletions interfaces/IBF-dashboard/src/assets/i18n/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,9 @@
"plural-suffix": "(s)",
"not-applicable": "N/A"
},
"disclaimer-approximate-component": {
"message": "All numbers are approximate and meant to be used as guidance."
},
"areas-of-focus-summary-component": {
"title": "Actions Summary",
"aof-subtitle": "Sector",
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions interfaces/IBF-dashboard/src/global.scss
Original file line number Diff line number Diff line change
Expand Up @@ -310,3 +310,7 @@ app-tooltip {
}
}
}

.margin-top-auto {
margin-top: auto;
}

0 comments on commit 19452a2

Please sign in to comment.