Compare commits

...

3 Commits

Author SHA1 Message Date
85019b2a54 add home screen components 2022-08-27 02:13:43 +03:00
947dbfe734 delete obsolete components 2022-08-27 02:13:27 +03:00
ea6aa09e1c add modules for home screen 2022-08-27 02:03:02 +03:00
25 changed files with 145 additions and 163 deletions

View File

@ -15,13 +15,12 @@ import { HomeModule } from './home/home.module';
import { DetailModule } from './detail/detail.module';
import { AppComponent } from './app.component';
import { GameSideButtonComponent } from './game-side-button/game-side-button.component';
// AoT requires an exported function for factories
const httpLoaderFactory = (http: HttpClient): TranslateHttpLoader => new TranslateHttpLoader(http, './assets/i18n/', '.json');
@NgModule({
declarations: [AppComponent, GameSideButtonComponent],
declarations: [AppComponent],
imports: [
BrowserModule,
FormsModule,

View File

@ -1,10 +0,0 @@
import { NgModule } from '@angular/core';
import { RouterModule, Routes } from '@angular/router';
const routes: Routes = [];
@NgModule({
imports: [RouterModule.forChild(routes)],
exports: [RouterModule]
})
export class GameBarRoutingModule { }

View File

@ -1,17 +0,0 @@
import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { GameBarRoutingModule } from './game-bar-routing.module';
import { GameButtonComponent } from './game-button/game-button.component';
@NgModule({
declarations: [
GameButtonComponent
],
imports: [
CommonModule,
GameBarRoutingModule
]
})
export class GameBarModule { }

View File

@ -1 +0,0 @@
<p>game-button works!</p>

View File

@ -1,18 +0,0 @@
<div class="GameBar">
<div class="img cornering">
<img src="https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcTENKPSC6g94JwGU4-HeYtwTDS6MW2_RO6TL51IDw9H2Gy9HfOkt8xx3VYAqSqW944M03E&usqp=CAU" height="60px" width="60px">
</div>
<div class="two-lines-centered">
<div class="first-line">
<div class="text header">
<span>Warface</span>
</div>
<div class="label">
Pirate
</div>
</div>
<div class="text light darken">
<span>2 people voted. Need 4 more to play.</span>
</div>
</div>
</div>

View File

@ -1,27 +0,0 @@
/*********************************************/
/************** Games Bar *******************/
/*********************************************/
#GamesBar {
margin-left: 15px;
}
.GameBar {
display: flex;
margin-top: 13px;
padding: 10px 0 2px 10px;
margin-right: 15px;
}
.GameBar:hover {
background-color: rgba(255, 255, 255, 0.2);
border-radius: 10px;
-webkit-backdrop-filter: drop-shadow(5px 5px 0px #ffffff);
backdrop-filter: drop-shadow(5px 5px 4px #ffffff);
}
.GameBar > .two-lines-centered {
margin-top: 5px;
margin-left: 15px;
}
.SessionCount {
font-size: 13px;
margin: 20px 0 20px 10px;
}

View File

@ -1,15 +0,0 @@
import { Component, OnInit } from '@angular/core';
@Component({
selector: 'app-game-side-button',
templateUrl: './game-side-button.component.html',
styleUrls: ['./game-side-button.component.scss']
})
export class GameSideButtonComponent implements OnInit {
constructor() { }
ngOnInit(): void {
}
}

View File

@ -0,0 +1,4 @@
<div id="LeftBar">
<app-user-info></app-user-info>
<app-game-button></app-game-button>
</div>

View File

@ -1,18 +1,18 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { GameSideButtonComponent } from './game-side-button.component';
import { GameBarComponent } from './game-bar.component';
describe('GameSideButtonComponent', () => {
let component: GameSideButtonComponent;
let fixture: ComponentFixture<GameSideButtonComponent>;
describe('GameBarComponent', () => {
let component: GameBarComponent;
let fixture: ComponentFixture<GameBarComponent>;
beforeEach(async () => {
await TestBed.configureTestingModule({
declarations: [ GameSideButtonComponent ]
declarations: [ GameBarComponent ]
})
.compileComponents();
fixture = TestBed.createComponent(GameSideButtonComponent);
fixture = TestBed.createComponent(GameBarComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});

View File

@ -0,0 +1,15 @@
import { Component, OnInit } from '@angular/core';
@Component({
selector: 'app-game-bar',
templateUrl: './game-bar.component.html',
styleUrls: ['./game-bar.component.scss']
})
export class GameBarComponent implements OnInit {
constructor() { }
ngOnInit(): void {
}
}

View File

@ -0,0 +1,16 @@
<div class="two-lines-centered">
<div class="first-line">
<div class="text header">
<span>Minecraft</span>
</div>
<div class="label">
Survival
</div>
<div class="label">
1.12.2
</div>
</div>
<div class="text light darken">
<span>Survival world with mods such as Industrial Craft, RailCraft, etc.</span>
</div>
</div>

View File

@ -0,0 +1,18 @@
<div class="ProfileBar">
<div class="img rounded" id="ProfilePicture">
<img src="./assets/avatar.jpeg" height="45px" width="45px">
</div>
<div class="two-lines-centered">
<div class="first-line">
<div class="text header big">
<span>MrSandyMoon</span>
</div>
<div class="label">
Booster
</div>
</div>
<div class="text light darken">
<span>Administrator</span>
</div>
</div>
</div>

View File

@ -0,0 +1,23 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { UserInfoComponent } from './user-info.component';
describe('UserInfoComponent', () => {
let component: UserInfoComponent;
let fixture: ComponentFixture<UserInfoComponent>;
beforeEach(async () => {
await TestBed.configureTestingModule({
declarations: [ UserInfoComponent ]
})
.compileComponents();
fixture = TestBed.createComponent(UserInfoComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});

View File

@ -0,0 +1,15 @@
import { Component, OnInit } from '@angular/core';
@Component({
selector: 'app-user-info',
templateUrl: './user-info.component.html',
styleUrls: ['./user-info.component.scss']
})
export class UserInfoComponent implements OnInit {
constructor() { }
ngOnInit(): void {
}
}

View File

@ -0,0 +1 @@
ОГО, ну и хуита эта ваша игра

View File

@ -0,0 +1,23 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { GenericGameComponent } from './generic-game.component';
describe('GenericGameComponent', () => {
let component: GenericGameComponent;
let fixture: ComponentFixture<GenericGameComponent>;
beforeEach(async () => {
await TestBed.configureTestingModule({
declarations: [ GenericGameComponent ]
})
.compileComponents();
fixture = TestBed.createComponent(GenericGameComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});
it('should create', () => {
expect(component).toBeTruthy();
});
});

View File

@ -0,0 +1,15 @@
import { Component, OnInit } from '@angular/core';
@Component({
selector: 'app-generic-game',
templateUrl: './generic-game.component.html',
styleUrls: ['./generic-game.component.scss']
})
export class GenericGameComponent implements OnInit {
constructor() { }
ngOnInit(): void {
}
}

View File

@ -1,67 +1,4 @@
<div class="container">
<div id="LeftBar">
<div class="ProfileBar">
<div class="img rounded" id="ProfilePicture">
<img src="./assets/avatar.jpeg" height="45px" width="45px">
</div>
<div class="two-lines-centered">
<div class="first-line">
<div class="text header big">
<span>MrSandyMoon</span>
</div>
<div class="label">
Booster
</div>
</div>
<div class="text light darken">
<span>Administrator</span>
</div>
</div>
</div>
<hr>
<div #page id="GamesBar">
<GameSideButtonComponent></GameSideButtonComponent>
<div class="SessionCount">
<span class="semi-bold">2 </span>
<span class="light">sessions active</span>
</div>
<div class="SessionCount">
<span class="semi-bold">1 </span>
<span class="light">session announced</span>
</div>
<div class="SessionCount">
<span class="semi-bold">2 </span>
<span class="light">sessions to be voted</span>
</div>
</div>
</div>
<div id="RightBar">
<div class="two-lines-centered">
<div class="first-line">
<div class="text header">
<span>Minecraft</span>
</div>
<div class="label">
Survival
</div>
<div class="label">
1.12.2
</div>
</div>
<div class="text light darken">
<span>Survival world with mods such as Industrial Craft, RailCraft, etc.</span>
</div>
</div>
</div>
</div>
<app-game-bar></app-game-bar>
<app-generic-game></app-generic-game>
</div>

View File

@ -5,9 +5,13 @@ import { HomeRoutingModule } from './home-routing.module';
import { HomeComponent } from './home.component';
import { SharedModule } from '../shared/shared.module';
import { GameBarComponent } from './game-bar/game-bar.component';
import { GenericGameComponent } from './generic-game/generic-game.component';
import { GameButtonComponent } from './game-bar/game-button/game-button.component';
import { UserInfoComponent } from './game-bar/user-info/user-info.component';
@NgModule({
declarations: [HomeComponent],
declarations: [HomeComponent, GameBarComponent, GenericGameComponent, GameButtonComponent, UserInfoComponent],
imports: [CommonModule, SharedModule, HomeRoutingModule]
})
export class HomeModule {}