diff --git a/src/app/home/home.component.html b/src/app/home/home.component.html index f7832eba6..3a9decb21 100644 --- a/src/app/home/home.component.html +++ b/src/app/home/home.component.html @@ -15,15 +15,21 @@ list - {{ 'HOME.TABS.RECENTLY_ADDED' | translate }} + + {{ 'HOME.TABS.RECENTLY_ADDED' | translate }} + + + + + - - attach_file - {{ 'HOME.TABS.FILE_UPLOAD' | translate }} + + {{ 'HOME.TABS.FILE_UPLOAD' | translate }} + link - {{ 'HOME.TABS.URL_UPLOAD' | translate }} + + {{ 'HOME.TABS.URL_UPLOAD' | translate }} + text_format - {{ 'HOME.TABS.TEXT_IMPORT' | translate }} + + {{ 'HOME.TABS.TEXT_IMPORT' | translate }} + ; - @Component({ selector: 'app-home', templateUrl: './home.component.html', diff --git a/src/app/home/recent-playlists/playlist-item/playlist-item.component.ts b/src/app/home/recent-playlists/playlist-item/playlist-item.component.ts index ef312734c..15e478835 100644 --- a/src/app/home/recent-playlists/playlist-item/playlist-item.component.ts +++ b/src/app/home/recent-playlists/playlist-item/playlist-item.component.ts @@ -1,5 +1,5 @@ import { Component, EventEmitter, Input, Output } from '@angular/core'; -import { PlaylistMeta } from '../../home.component'; +import { PlaylistMeta } from '../../../shared/playlist-meta.type'; @Component({ selector: 'app-playlist-item', diff --git a/src/app/home/recent-playlists/recent-playlists.component.spec.ts b/src/app/home/recent-playlists/recent-playlists.component.spec.ts index ca927a4f2..1fe5f197d 100644 --- a/src/app/home/recent-playlists/recent-playlists.component.spec.ts +++ b/src/app/home/recent-playlists/recent-playlists.component.spec.ts @@ -14,7 +14,7 @@ import { import { DataService } from '../../services/data.service'; import { DialogService } from '../../services/dialog.service'; import { ElectronServiceStub } from '../../services/electron.service.stub'; -import { PlaylistMeta } from '../home.component'; +import { PlaylistMeta } from '../../shared/playlist-meta.type'; import { RecentPlaylistsComponent } from './recent-playlists.component'; describe('RecentPlaylistsComponent', () => { diff --git a/src/app/home/recent-playlists/recent-playlists.component.ts b/src/app/home/recent-playlists/recent-playlists.component.ts index 453bdd75e..a348e6897 100644 --- a/src/app/home/recent-playlists/recent-playlists.component.ts +++ b/src/app/home/recent-playlists/recent-playlists.component.ts @@ -15,7 +15,7 @@ import { PLAYLIST_UPDATE_POSITIONS, } from './../../../../shared/ipc-commands'; import { DialogService } from './../../services/dialog.service'; -import { PlaylistMeta } from './../home.component'; +import { PlaylistMeta } from './../../shared/playlist-meta.type'; import { PlaylistInfoComponent } from './playlist-info/playlist-info.component'; @Component({ diff --git a/src/app/shared/components/header/header.component.html b/src/app/shared/components/header/header.component.html index 58b4a89d3..ddc86baa2 100644 --- a/src/app/shared/components/header/header.component.html +++ b/src/app/shared/components/header/header.component.html @@ -1,13 +1,11 @@ - + - - - {{ title }} - {{ subtitle }} - + + {{ title }} + {{ subtitle }} - + - + menu - + settings - Settings + {{ 'MENU.SETTINGS' | translate }} recommend @@ -37,28 +43,28 @@ bug_report - Report a bug + {{ 'MENU.BUG_REPORT' | translate }} new_releases - What is new + {{ 'MENU.WHAT_IS_NEW' | translate }} info - About + {{ 'MENU.ABOUT' | translate }} diff --git a/src/app/shared/components/header/header.component.scss b/src/app/shared/components/header/header.component.scss index 797d7ff7f..d8b49f342 100644 --- a/src/app/shared/components/header/header.component.scss +++ b/src/app/shared/components/header/header.component.scss @@ -1,14 +1,38 @@ :host { background: #000; color: #fff; + display: flex; + width: 100%; } -.title { - font-size: 1.1em; +.logo { + flex: 1 1 100px; } -.subtitle { - color: #999; - font-size: 0.9em; - margin-top: 10px; +.main { + place-content: center flex-start; + align-self: center; + flex-direction: column; + box-sizing: border-box; + display: flex; + flex: 1 1 100%; + max-width: 100%; + + .title { + font-size: 1.1em; + } + + .subtitle { + color: #999; + font-size: 0.9em; + margin-top: 10px; + } +} + +.menu { + place-content: center; + align-self: center; + min-width: 50px; + max-width: 50px; + display: flex; } diff --git a/src/app/shared/playlist-meta.type.ts b/src/app/shared/playlist-meta.type.ts new file mode 100644 index 000000000..0cacd9189 --- /dev/null +++ b/src/app/shared/playlist-meta.type.ts @@ -0,0 +1,16 @@ +import { Playlist } from '../../../shared/playlist.interface'; + +export type PlaylistMeta = Pick< + Playlist, + | 'count' + | 'title' + | 'filename' + | '_id' + | 'url' + | 'importDate' + | 'userAgent' + | 'filePath' + | 'updateDate' + | 'updateState' + | 'position' +>;