Move Ei Card as part of EI coordinator module 12/5712/2
authorychacon <yennifer.chacon@est.tech>
Tue, 2 Mar 2021 09:43:13 +0000 (10:43 +0100)
committerychacon <yennifer.chacon@est.tech>
Thu, 4 Mar 2021 08:14:48 +0000 (09:14 +0100)
Issue-ID: NONRTRIC-453
Signed-off-by: ychacon <yennifer.chacon@est.tech>
Change-Id: Ib550a0cd59a5bf813f36176ea4f32ebbe52f88cf

webapp-frontend/src/app/app.module.ts
webapp-frontend/src/app/ei-coordinator/ei-card/ei-card.component.html [moved from webapp-frontend/src/app/ui/ei-card/ei-card.component.html with 71% similarity]
webapp-frontend/src/app/ei-coordinator/ei-card/ei-card.component.scss [new file with mode: 0644]
webapp-frontend/src/app/ei-coordinator/ei-card/ei-card.component.spec.ts [moved from webapp-frontend/src/app/ui/ei-card/ei-card.component.spec.ts with 86% similarity]
webapp-frontend/src/app/ei-coordinator/ei-card/ei-card.component.ts [moved from webapp-frontend/src/app/ui/ei-card/ei-card.component.ts with 95% similarity]
webapp-frontend/src/app/ei-coordinator/ei-coordinator.module.ts
webapp-frontend/src/app/ui/ei-card/ei-card.component.scss [deleted file]

index 6ea9f03..ecb20bd 100644 (file)
@@ -64,7 +64,6 @@ import { SidenavListComponent } from './navigation/sidenav-list/sidenav-list.com
 import { UiService } from './services/ui/ui.service';
 import { CookieService } from 'ngx-cookie-service';
 import { NodeModulesComponent } from './node-modules/node-modules.component';
-import { EICardComponent } from './ui/ei-card/ei-card.component';
 import { HttpMockRequestInterceptor } from './interceptor.mock';
 import { environment } from 'src/environments/environment';
 import { HttpRequestInterceptor } from './interceptor';
@@ -75,7 +74,6 @@ export const isMock = environment.mock;
   declarations: [
     AppComponent,
     ConfirmDialogComponent,
-    EICardComponent,
     ErrorDialogComponent,
     FooterComponent,
     MainComponent,
   limitations under the License.
   ========================LICENSE_END===================================
   -->
-<div class="ei__card" routerLink="/ei-coordinator" [ngClass]="{'add__card-dark': darkMode}">
-  <div class="header__container">
-    <span class="card__title">Enrichment Information Coordinator</span>
-  <div class="body__container">
-    <img src="assets/oran-logo.png" width="250px"/>
+  <div class="ei__card" routerLink="/ei-coordinator" [ngClass]="{'add__card-dark': darkMode}">
+    <div class="header__container">
+      <span class="card__title">Enrichment Information Coordinator</span>
+    <div class="body__container">
+      <img src="assets/oran-logo.png" width="250px"/>
+    </div>
   </div>
-</div>
+  
\ No newline at end of file
diff --git a/webapp-frontend/src/app/ei-coordinator/ei-card/ei-card.component.scss b/webapp-frontend/src/app/ei-coordinator/ei-card/ei-card.component.scss
new file mode 100644 (file)
index 0000000..f308fb6
--- /dev/null
@@ -0,0 +1,58 @@
+/*-\r
+ * ========================LICENSE_START=================================\r
+ * O-RAN-SC\r
+ * %%\r
+ * Copyright (C) 2019 Nordix Foundation\r
+ * %%\r
+ * Licensed under the Apache License, Version 2.0 (the "License");\r
+ * you may not use this file except in compliance with the License.\r
+ * You may obtain a copy of the License at\r
+ *\r
+ *      http://www.apache.org/licenses/LICENSE-2.0\r
+ *\r
+ * Unless required by applicable law or agreed to in writing, software\r
+ * distributed under the License is distributed on an "AS IS" BASIS,\r
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
+ * See the License for the specific language governing permissions and\r
+ * limitations under the License.\r
+ * ========================LICENSE_END===================================\r
+ */\r
+ .ei__card {\r
+    background-color: #ffffff;\r
+    box-shadow: 0 0 2rem rgba(0, 0, 255, 0.1);\r
+    display: grid;\r
+    grid-template-columns: 1fr;\r
+    grid-template-rows: 1fr 1fr;\r
+    padding: 2rem;\r
+    margin: 2rem;\r
+    width: 19rem;\r
+    height: 30rem;\r
+    justify-items: center;\r
+    cursor: pointer;\r
+    border-radius: 1.75rem;\r
+    animation: fadein 1.25s ease-in-out 0ms 1;\r
+    color: #443282;\r
+  }\r
+\r
+  .add__card-dark {\r
+    background: linear-gradient(to bottom, rgb(78, 78, 129), rgb(45, 44, 61));\r
+    color: white;\r
+  }\r
+\r
+  .card__title {\r
+    text-transform: uppercase;\r
+    letter-spacing: 0.1rem;\r
+  }\r
+\r
+  .body__container {\r
+    align-self: end;\r
+    display: flex;\r
+    justify-content: space-between;\r
+    align-items: center;\r
+    flex-flow: column;\r
+  }\r
+\r
+  .add__icon {\r
+    width: 10rem;\r
+    margin-bottom: 1.15rem;\r
+  }
\ No newline at end of file
  */
 import {async, ComponentFixture, TestBed} from '@angular/core/testing';
 
-import {EICardComponent} from './ei-card.component';
+import {EiCardComponent} from './ei-card.component';
 import { MatIconModule } from '@angular/material/icon';
 import { RouterTestingModule } from '@angular/router/testing';
 import {UiService} from '../../services/ui/ui.service';
 
 describe('EICardComponent', () => {
-  let component: EICardComponent;
-  let fixture: ComponentFixture<EICardComponent>;
+  let component: EiCardComponent;
+  let fixture: ComponentFixture<EiCardComponent>;
 
   beforeEach(async(() => {
     TestBed.configureTestingModule({
-      declarations: [EICardComponent],
+      declarations: [EiCardComponent],
       imports: [ MatIconModule,
         RouterTestingModule
       ],
@@ -40,7 +40,7 @@ describe('EICardComponent', () => {
   }));
 
   beforeEach(() => {
-    fixture = TestBed.createComponent(EICardComponent);
+    fixture = TestBed.createComponent(EiCardComponent);
     component = fixture.componentInstance;
     fixture.detectChanges();
   });
@@ -26,7 +26,7 @@ import { UiService } from '../../services/ui/ui.service';
   templateUrl: './ei-card.component.html',
   styleUrls: ['./ei-card.component.scss']
 })
-export class EICardComponent implements OnInit, OnDestroy {
+export class EiCardComponent implements OnInit, OnDestroy {
   darkMode: boolean;
 
   constructor(public router: Router, private ui: UiService) { }
index 1e38575..cda22ce 100644 (file)
@@ -32,6 +32,7 @@ import { FormsModule, ReactiveFormsModule } from '@angular/forms';
 import { MatSortModule } from '@angular/material/sort';
 import { MatButtonModule } from '@angular/material/button';
 import { FlexLayoutModule } from '@angular/flex-layout';
+import { EiCardComponent } from './ei-card/ei-card.component';
 
 
 const routes: Routes = [
@@ -42,7 +43,8 @@ const routes: Routes = [
   declarations: [
     EICoordinatorComponent,
     ProducersListComponent,
-    JobsListComponent
+    JobsListComponent,
+    EiCardComponent
   ],
   imports: [
     CommonModule,
@@ -57,7 +59,8 @@ const routes: Routes = [
     RouterModule.forChild(routes)
   ],
   exports: [
-    EICoordinatorComponent
+    EICoordinatorComponent,
+    EiCardComponent
   ]
 })
 export class EiCoordinatorModule { }
diff --git a/webapp-frontend/src/app/ui/ei-card/ei-card.component.scss b/webapp-frontend/src/app/ui/ei-card/ei-card.component.scss
deleted file mode 100644 (file)
index 8f91696..0000000
+++ /dev/null
@@ -1,58 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 Nordix Foundation
- * %%
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- *      http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- * ========================LICENSE_END===================================
- */
-.ei__card {
-  background-color: #ffffff;
-  box-shadow: 0 0 2rem rgba(0, 0, 255, 0.1);
-  display: grid;
-  grid-template-columns: 1fr;
-  grid-template-rows: 1fr 1fr;
-  padding: 2rem;
-  margin: 2rem;
-  width: 19rem;
-  height: 30rem;
-  justify-items: center;
-  cursor: pointer;
-  border-radius: 1.75rem;
-  animation: fadein 1.25s ease-in-out 0ms 1;
-  color: #443282;
-}
-
-.add__card-dark {
-  background: linear-gradient(to bottom, rgb(78, 78, 129), rgb(45, 44, 61));
-  color: white;
-}
-
-.card__title {
-  text-transform: uppercase;
-  letter-spacing: 0.1rem;
-}
-
-.body__container {
-  align-self: end;
-  display: flex;
-  justify-content: space-between;
-  align-items: center;
-  flex-flow: column;
-}
-
-.add__icon {
-  width: 10rem;
-  margin-bottom: 1.15rem;
-}
\ No newline at end of file