Skip to content

Commit 01bcbec

Browse files
committed
add
1 parent 45b7458 commit 01bcbec

14 files changed

+220
-8
lines changed
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
@import url("https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.1.3/css/bootstrap.min.css");
2+
3+
.alert-primary
4+
{
5+
background-color: #e61a57dc;
6+
color: #fff;
7+
8+
9+
}
10+
.alert-success {
11+
background-color: #3dbb0bb4;
12+
color: #fff;
13+
}
14+
.alert-warning
15+
{
16+
background-color: #f1b708de;
17+
color: #fff;
18+
}
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
2+
3+
4+
5+
6+
<br>
7+
<div class="container text-center ">
8+
9+
<div id="refreshDivID">
10+
<div class="reloaded-divs">
11+
<div class="alert alert-primary alert-dismissible fade show" role="alert">
12+
<strong>Holy guacamole!</strong> You should
13+
<button type="button" class="close" data-dismiss="alert" aria-label="Close">
14+
<span aria-hidden="true">&times;</span>
15+
</button>
16+
</div>
17+
<div class="alert alert-warning alert-dismissible fade show" role="alert">
18+
<strong>Holy guacamole!</strong> You should check in
19+
<button type="button" class="close" data-dismiss="alert" aria-label="Close">
20+
<span aria-hidden="true">&times;</span>
21+
</button>
22+
</div>
23+
<div class="alert alert-success alert-dismissible fade show" role="alert">
24+
<strong>Holy guacamole!</strong> You should
25+
<button type="button" class="close" data-dismiss="alert" aria-label="Close">
26+
<span aria-hidden="true">&times;</span>
27+
</button>
28+
</div>
29+
30+
</div>
31+
</div>
32+
</div>
33+
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>
34+
<script src="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.3.1/js/bootstrap.min.js"></script>
35+
36+
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
import { ComponentFixture, TestBed } from '@angular/core/testing';
2+
3+
import { AlertComponent } from './alert.component';
4+
5+
describe('AlertComponent', () => {
6+
let component: AlertComponent;
7+
let fixture: ComponentFixture<AlertComponent>;
8+
9+
beforeEach(async () => {
10+
await TestBed.configureTestingModule({
11+
declarations: [ AlertComponent ]
12+
})
13+
.compileComponents();
14+
15+
fixture = TestBed.createComponent(AlertComponent);
16+
component = fixture.componentInstance;
17+
fixture.detectChanges();
18+
});
19+
20+
it('should create', () => {
21+
expect(component).toBeTruthy();
22+
});
23+
});
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
import { Component, OnInit } from '@angular/core';
2+
3+
@Component({
4+
selector: 'app-alert',
5+
templateUrl: './alert.component.html',
6+
styleUrls: ['./alert.component.css']
7+
})
8+
export class AlertComponent implements OnInit {
9+
10+
constructor() { }
11+
12+
ngOnInit(): void {
13+
}
14+
15+
}
Lines changed: 26 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,34 @@
1-
.app-child
1+
.app-childd
22
{
33
background-color: #1aace6;
44
padding: 50px;
55
margin: auto;
6+
padding-bottom: 0px;
67
height: 40vh;
7-
margin-top: 33vh;
88
border-radius: 15px;
99
border: 3px solid #fff;
1010
}
11+
.max{
12+
max-width: 500px !important;
13+
display: flex;
14+
margin-right: -120px;
15+
margin-top: -50px;
16+
}
17+
* {
18+
box-sizing: border-box;
19+
}
20+
21+
/* Create two equal columns that floats next to each other */
22+
.col {
23+
float: left;
24+
width: 50%;
25+
padding: 10px;
26+
height: 300px; /* Should be removed. Only for demonstration */
27+
}
28+
29+
/* Clear floats after the columns */
30+
.row:after {
31+
content: "";
32+
display: table;
33+
clear: both;
34+
}
Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,11 @@
1-
<section class="app-child ">
1+
<section class="app-childd ">
2+
<div class="row ">
3+
<div class="col"></div>
4+
<div class="max col">
5+
<app-alert></app-alert>
6+
</div>
7+
</div>
8+
29

310

411
</section>

a/src/app/mychild/components/from/from.component.css

Whitespace-only changes.
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
2+
3+
4+
<form (ngSubmit)="onSubmit()" #form="ngForm">
5+
6+
<input type="text" [(ngModel)]="name" />
7+
<input type="url" [(ngModel)]="url" />
8+
<textarea [(ngModel)]="text"></textarea>
9+
<button (click)="onClick()">Submit</button>
10+
11+
</form>
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
import { ComponentFixture, TestBed } from '@angular/core/testing';
2+
3+
import { FromComponent } from './from.component';
4+
5+
describe('FromComponent', () => {
6+
let component: FromComponent;
7+
let fixture: ComponentFixture<FromComponent>;
8+
9+
beforeEach(async () => {
10+
await TestBed.configureTestingModule({
11+
declarations: [ FromComponent ]
12+
})
13+
.compileComponents();
14+
15+
fixture = TestBed.createComponent(FromComponent);
16+
component = fixture.componentInstance;
17+
fixture.detectChanges();
18+
});
19+
20+
it('should create', () => {
21+
expect(component).toBeTruthy();
22+
});
23+
});
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
import { Component, OnInit } from '@angular/core';
2+
3+
@Component({
4+
selector: 'app-from',
5+
templateUrl: './from.component.html',
6+
styleUrls: ['./from.component.css']
7+
})
8+
export class FromComponent implements OnInit {
9+
10+
constructor() { }
11+
12+
ngOnInit(): void {
13+
}
14+
15+
}

0 commit comments

Comments
 (0)