From 26021c5cec303053b79ffd0dd554df3c813a1eeb Mon Sep 17 00:00:00 2001
From: Brandon Clayton <bclayton@usgs.gov>
Date: Mon, 30 Sep 2024 09:41:59 -0600
Subject: [PATCH] remove components

---
 .../component-summary.component.html          | 90 -------------------
 .../component-summary.component.scss          |  7 --
 .../component-summary.component.spec.ts       | 30 -------
 .../component-summary.component.ts            | 51 -----------
 .../full-summary/full-summary.component.html  | 84 -----------------
 .../full-summary/full-summary.component.scss  |  0
 .../full-summary.component.spec.ts            | 30 -------
 .../full-summary/full-summary.component.ts    | 33 -------
 8 files changed, 325 deletions(-)
 delete mode 100644 projects/nshmp-apps/src/app/hazard/disagg/components/component-summary/component-summary.component.html
 delete mode 100644 projects/nshmp-apps/src/app/hazard/disagg/components/component-summary/component-summary.component.scss
 delete mode 100644 projects/nshmp-apps/src/app/hazard/disagg/components/component-summary/component-summary.component.spec.ts
 delete mode 100644 projects/nshmp-apps/src/app/hazard/disagg/components/component-summary/component-summary.component.ts
 delete mode 100644 projects/nshmp-apps/src/app/hazard/disagg/components/full-summary/full-summary.component.html
 delete mode 100644 projects/nshmp-apps/src/app/hazard/disagg/components/full-summary/full-summary.component.scss
 delete mode 100644 projects/nshmp-apps/src/app/hazard/disagg/components/full-summary/full-summary.component.spec.ts
 delete mode 100644 projects/nshmp-apps/src/app/hazard/disagg/components/full-summary/full-summary.component.ts

diff --git a/projects/nshmp-apps/src/app/hazard/disagg/components/component-summary/component-summary.component.html b/projects/nshmp-apps/src/app/hazard/disagg/components/component-summary/component-summary.component.html
deleted file mode 100644
index dae869a8f..000000000
--- a/projects/nshmp-apps/src/app/hazard/disagg/components/component-summary/component-summary.component.html
+++ /dev/null
@@ -1,90 +0,0 @@
-<div class="height-full overflow-auto">
-  <div class="grid-container-widescreen">
-    <div class="padding-y-4">
-      <mat-card class="margin-bottom-2">
-        <mat-card-header>
-          <mat-card-title> Disaggregation Component Summary </mat-card-title>
-        </mat-card-header>
-
-        <!-- Select component -->
-        <mat-card-content>
-          <mat-form-field
-            class="grid-col-12 padding-top-4 disagg-component-select"
-          >
-            <mat-label> Component </mat-label>
-            <mat-select [formControl]="formGroup.controls.disaggComponent">
-              @for (disagg of disaggData()?.data; track disagg) {
-                <mat-option [value]="disagg?.component">
-                  {{ disagg?.component }}
-                </mat-option>
-              }
-            </mat-select>
-          </mat-form-field>
-        </mat-card-content>
-
-        <mat-card-actions>
-          <div class="print-display-none">
-            <button
-              mat-raised-button
-              color="primary"
-              (click)="service.saveComponentSummaryReport()"
-              [disabled]="disaggData() === null"
-            >
-              Export Summary Report
-            </button>
-          </div>
-        </mat-card-actions>
-      </mat-card>
-
-      <mat-accordion multi>
-        <!-- Summary report -->
-        <mat-expansion-panel
-          class="summary-report print-page-break"
-          [expanded]="disaggData()"
-          [disabled]="disaggData() === null"
-        >
-          <mat-expansion-panel-header>
-            <mat-panel-title
-              >Disaggregation Summary:
-              {{ formGroup.getRawValue().disaggComponent }}</mat-panel-title
-            >
-          </mat-expansion-panel-header>
-
-          <app-disagg-summary [componentData]="componentData()" />
-        </mat-expansion-panel>
-
-        <!-- Contributions -->
-        <mat-expansion-panel
-          class="contributions print-page-break"
-          [expanded]="componentData()?.sources.length > 0"
-          [disabled]="componentData()?.sources.length === 0"
-        >
-          <mat-expansion-panel-header>
-            <mat-panel-title
-              >Disaggregation Contributions:
-              {{ formGroup.getRawValue().disaggComponent }}</mat-panel-title
-            >
-          </mat-expansion-panel-header>
-
-          <app-disagg-contributors [componentData]="componentData()" />
-        </mat-expansion-panel>
-
-        <!-- Data -->
-        <mat-expansion-panel
-          class="print-page-break"
-          [expanded]="componentData()?.data.length > 0"
-          [disabled]="componentData()?.data.length === 0"
-        >
-          <mat-expansion-panel-header>
-            <mat-panel-title
-              >Disaggregation Data:
-              {{ formGroup.getRawValue().disaggComponent }}</mat-panel-title
-            >
-          </mat-expansion-panel-header>
-
-          <app-disagg-data [componentData]="componentData()" />
-        </mat-expansion-panel>
-      </mat-accordion>
-    </div>
-  </div>
-</div>
diff --git a/projects/nshmp-apps/src/app/hazard/disagg/components/component-summary/component-summary.component.scss b/projects/nshmp-apps/src/app/hazard/disagg/components/component-summary/component-summary.component.scss
deleted file mode 100644
index 3094eb336..000000000
--- a/projects/nshmp-apps/src/app/hazard/disagg/components/component-summary/component-summary.component.scss
+++ /dev/null
@@ -1,7 +0,0 @@
-@media print {
-  mat-accordion {
-    mat-expansion-panel {
-      box-shadow: none !important;
-    }
-  }
-}
diff --git a/projects/nshmp-apps/src/app/hazard/disagg/components/component-summary/component-summary.component.spec.ts b/projects/nshmp-apps/src/app/hazard/disagg/components/component-summary/component-summary.component.spec.ts
deleted file mode 100644
index cf9908a16..000000000
--- a/projects/nshmp-apps/src/app/hazard/disagg/components/component-summary/component-summary.component.spec.ts
+++ /dev/null
@@ -1,30 +0,0 @@
-import {provideHttpClient} from '@angular/common/http';
-import {ComponentFixture, TestBed} from '@angular/core/testing';
-import {provideNoopAnimations} from '@angular/platform-browser/animations';
-import {provideRouter} from '@angular/router';
-
-import {ComponentSummaryComponent} from './component-summary.component';
-
-describe('ComponentSummaryComponent', () => {
-  let component: ComponentSummaryComponent;
-  let fixture: ComponentFixture<ComponentSummaryComponent>;
-
-  beforeEach(async () => {
-    await TestBed.configureTestingModule({
-      imports: [ComponentSummaryComponent],
-      providers: [
-        provideHttpClient(),
-        provideNoopAnimations(),
-        provideRouter([]),
-      ],
-    }).compileComponents();
-
-    fixture = TestBed.createComponent(ComponentSummaryComponent);
-    component = fixture.componentInstance;
-    fixture.detectChanges();
-  });
-
-  it('should create', () => {
-    expect(component).toBeTruthy();
-  });
-});
diff --git a/projects/nshmp-apps/src/app/hazard/disagg/components/component-summary/component-summary.component.ts b/projects/nshmp-apps/src/app/hazard/disagg/components/component-summary/component-summary.component.ts
deleted file mode 100644
index d36a2d4aa..000000000
--- a/projects/nshmp-apps/src/app/hazard/disagg/components/component-summary/component-summary.component.ts
+++ /dev/null
@@ -1,51 +0,0 @@
-import {AsyncPipe} from '@angular/common';
-import {Component} from '@angular/core';
-import {ReactiveFormsModule} from '@angular/forms';
-import {MatButton} from '@angular/material/button';
-import {MatCardModule} from '@angular/material/card';
-import {MatDivider} from '@angular/material/divider';
-import {MatExpansionModule} from '@angular/material/expansion';
-import {
-  MatFormField,
-  MatLabel,
-  MatOption,
-  MatSelect,
-} from '@angular/material/select';
-
-import {AppService} from '../../services/app.service';
-import {DisaggContributorsComponent} from '../disagg-contributors/disagg-contributors.component';
-import {DisaggDataComponent} from '../disagg-data/disagg-data.component';
-import {DisaggSummaryComponent} from '../disagg-summary/disagg-summary.component';
-
-@Component({
-  imports: [
-    MatExpansionModule,
-    MatCardModule,
-    DisaggSummaryComponent,
-    DisaggContributorsComponent,
-    DisaggDataComponent,
-    AsyncPipe,
-    MatFormField,
-    MatSelect,
-    ReactiveFormsModule,
-    MatLabel,
-    MatOption,
-    MatDivider,
-    MatButton,
-  ],
-  selector: 'app-component-summary',
-  standalone: true,
-  styleUrl: './component-summary.component.scss',
-  templateUrl: './component-summary.component.html',
-})
-export class ComponentSummaryComponent {
-  /** Disaggregation component data */
-  componentData = this.service.componentData;
-
-  /** Disaggregation data */
-  disaggData = this.service.disaggData;
-
-  formGroup = this.service.formGroup;
-
-  constructor(public service: AppService) {}
-}
diff --git a/projects/nshmp-apps/src/app/hazard/disagg/components/full-summary/full-summary.component.html b/projects/nshmp-apps/src/app/hazard/disagg/components/full-summary/full-summary.component.html
deleted file mode 100644
index 10525c37e..000000000
--- a/projects/nshmp-apps/src/app/hazard/disagg/components/full-summary/full-summary.component.html
+++ /dev/null
@@ -1,84 +0,0 @@
-<div class="height-full overflow-auto">
-  <div class="grid-container-widescreen">
-    <div class="padding-y-4">
-      <mat-card class="margin-bottom-2">
-        <mat-card-header>
-          <mat-card-title> Disaggregation Full Summary </mat-card-title>
-        </mat-card-header>
-
-        <mat-card-content>
-          <div class="print-display-none padding-top-4">
-            <button
-              mat-raised-button
-              color="primary"
-              (click)="service.saveSummaryReport()"
-              [disabled]="disaggData() === null"
-            >
-              Export Summary Report
-            </button>
-          </div>
-        </mat-card-content>
-
-        <mat-card-actions>
-          <div class="print-display-none padding-right-4">
-            <button
-              mat-raised-button
-              color="accent"
-              [disabled]="disaggData() === null"
-              (click)="panels().openAll()"
-            >
-              Expand All Panels
-            </button>
-          </div>
-
-          <div class="print-display-none">
-            <button
-              mat-raised-button
-              color="accent"
-              [disabled]="disaggData() === null"
-              (click)="panels().closeAll()"
-            >
-              Close All Panels
-            </button>
-          </div>
-        </mat-card-actions>
-      </mat-card>
-
-      <mat-accordion multi>
-        @for (disagg of disaggData()?.data; track disagg) {
-          <mat-expansion-panel>
-            <mat-expansion-panel-header>
-              <mat-panel-title
-                >Component: {{ disagg.component }}</mat-panel-title
-              >
-            </mat-expansion-panel-header>
-
-            <mat-divider />
-
-            <ng-template matExpansionPanelContent>
-              <h2>Disaggregation Summary</h2>
-              <app-disagg-summary
-                [componentData]="disagg"
-                [showExportButton]="false"
-              />
-              <mat-divider />
-
-              <h2>Disaggregation Contributions</h2>
-              <app-disagg-contributors
-                [componentData]="disagg"
-                [showExportButton]="false"
-              />
-              <mat-divider />
-
-              <h2>Disaggregation Data</h2>
-              <app-disagg-data
-                [componentData]="disagg"
-                [showExportButton]="false"
-              />
-            </ng-template>
-          </mat-expansion-panel>
-        }
-      </mat-accordion>
-    </div>
-  </div>
-</div>
diff --git a/projects/nshmp-apps/src/app/hazard/disagg/components/full-summary/full-summary.component.scss b/projects/nshmp-apps/src/app/hazard/disagg/components/full-summary/full-summary.component.scss
deleted file mode 100644
index e69de29bb..000000000
diff --git a/projects/nshmp-apps/src/app/hazard/disagg/components/full-summary/full-summary.component.spec.ts b/projects/nshmp-apps/src/app/hazard/disagg/components/full-summary/full-summary.component.spec.ts
deleted file mode 100644
index 2175210d1..000000000
--- a/projects/nshmp-apps/src/app/hazard/disagg/components/full-summary/full-summary.component.spec.ts
+++ /dev/null
@@ -1,30 +0,0 @@
-import {provideHttpClient} from '@angular/common/http';
-import {ComponentFixture, TestBed} from '@angular/core/testing';
-import {provideNoopAnimations} from '@angular/platform-browser/animations';
-import {provideRouter} from '@angular/router';
-
-import {FullSummaryComponent} from './full-summary.component';
-
-describe('FullSummaryComponent', () => {
-  let component: FullSummaryComponent;
-  let fixture: ComponentFixture<FullSummaryComponent>;
-
-  beforeEach(async () => {
-    await TestBed.configureTestingModule({
-      imports: [FullSummaryComponent],
-      providers: [
-        provideHttpClient(),
-        provideNoopAnimations(),
-        provideRouter([]),
-      ],
-    }).compileComponents();
-
-    fixture = TestBed.createComponent(FullSummaryComponent);
-    component = fixture.componentInstance;
-    fixture.detectChanges();
-  });
-
-  it('should create', () => {
-    expect(component).toBeTruthy();
-  });
-});
diff --git a/projects/nshmp-apps/src/app/hazard/disagg/components/full-summary/full-summary.component.ts b/projects/nshmp-apps/src/app/hazard/disagg/components/full-summary/full-summary.component.ts
deleted file mode 100644
index 5b52886b0..000000000
--- a/projects/nshmp-apps/src/app/hazard/disagg/components/full-summary/full-summary.component.ts
+++ /dev/null
@@ -1,33 +0,0 @@
-import {Component, viewChild} from '@angular/core';
-import {MatButton} from '@angular/material/button';
-import {MatCardModule} from '@angular/material/card';
-import {MatDivider} from '@angular/material/divider';
-import {MatAccordion, MatExpansionModule} from '@angular/material/expansion';
-
-import {AppService} from '../../services/app.service';
-import {DisaggContributorsComponent} from '../disagg-contributors/disagg-contributors.component';
-import {DisaggDataComponent} from '../disagg-data/disagg-data.component';
-import {DisaggSummaryComponent} from '../disagg-summary/disagg-summary.component';
-
-@Component({
-  imports: [
-    MatExpansionModule,
-    DisaggSummaryComponent,
-    DisaggContributorsComponent,
-    DisaggDataComponent,
-    MatDivider,
-    MatButton,
-    MatCardModule,
-  ],
-  selector: 'app-full-summary',
-  standalone: true,
-  styleUrl: './full-summary.component.scss',
-  templateUrl: './full-summary.component.html',
-})
-export class FullSummaryComponent {
-  disaggData = this.service.disaggData;
-
-  panels = viewChild.required(MatAccordion);
-
-  constructor(public service: AppService) {}
-}
-- 
GitLab