-
-
- @if (cover != null) {
-
-
-
- }
-
-
-
- {{name}}
-
- @if(description) {
-
- {{description}}
-
- }
-
-
-
-
- @for (data of artists; track data.id;) {
-
-
-
- }
-
-
-
- @for (data of tracks; track data.id;) {
-
- }
-
-
-
diff --git a/front/src/app/scene/gender/gender.less b/front/src/app/scene/gender/gender.less
deleted file mode 100644
index e69de29..0000000
diff --git a/front/src/app/scene/gender/gender.ts b/front/src/app/scene/gender/gender.ts
deleted file mode 100644
index b6d32eb..0000000
--- a/front/src/app/scene/gender/gender.ts
+++ /dev/null
@@ -1,98 +0,0 @@
-/** @file
- * @author Edouard DUPIN
- * @copyright 2018, Edouard DUPIN, all right reserved
- * @license PROPRIETARY (see license file)
- */
-
-import { Component, OnInit } from '@angular/core';
-
-import { GenderService, DataService, ArianeService, TrackService } from 'app/service';
-
-@Component({
- selector: 'app-gender',
- templateUrl: './gender.html',
- styleUrls: ['./gender.less']
-})
-
-export class GenderScene implements OnInit {
- genderId = -1;
- name: string = '';
- description: string = '';
- cover: string = null;
- covers: string[] = [];
- artistsError = '';
- artists = [];
- tracksError = '';
- tracks = [];
- constructor(
- private genderService: GenderService,
- private trackService: TrackService,
- private arianeService: ArianeService,
- private dataService: DataService) {
- //NOTHING TO DO ...
- }
-
- ngOnInit() {
- this.genderId = this.arianeService.getTypeId();
- let self = this;
- console.log(`get gender global id: ${this.genderId}`);
- this.genderService.get(this.genderId)
- .then((response) => {
- self.name = response.name;
- self.description = response.description;
- console.log(` ==> get answer gender detail: ${JSON.stringify(response)}`);
- if (response.covers === undefined || response.covers === null || response.covers.length === 0) {
- self.cover = null;
- self.covers = [];
- } else {
- self.cover = self.dataService.getUrl(response.covers[0]);
- for (let iii = 0; iii < response.covers.length; iii++) {
- self.covers.push(self.dataService.getUrl(response.covers[iii]));
- }
- }
- }).catch((response) => {
- self.name = '???';
- self.description = '';
- self.covers = [];
- self.cover = null;
- });
- /*
- TODO ???
- this.trackService.getSubArtist(this.genderId)
- .then((response) => {
- console.log(` ==> get answer sub-artist: ${JSON.stringify(response)}`);
- self.artistsError = '';
- self.artists = response;
- }).catch((response) => {
- console.log(` ==> get answer sub-artist (ERROR): ${JSON.stringify(response)}`);
- self.artistsError = 'Wrong e-mail/login or password';
- self.artists = [];
- });
- */
- this.trackService.getTracksForGender(this.genderId)
- .then((response) => {
- console.log(` ==> get answer sub-track: ${JSON.stringify(response)}`);
- self.tracksError = '';
- self.tracks = response;
- }).catch((response) => {
- console.log(` ==> get answer sub-track (ERROR): ${JSON.stringify(response)}`);
- self.tracksError = 'Wrong e-mail/login or password';
- self.tracks = [];
- });
- }
- onSelectArtist(event: any, idSelected: number): void {
- if (event.ctrlKey === false) {
- this.arianeService.navigateArtist({ artistId: idSelected, newWindows: event.which === 2 });
- } else {
- this.arianeService.navigateArtistEdit({ id: idSelected, newWindows: event.which === 2 });
- }
- }
-
- onSelectTrack(event: any, idSelected: number): void {
- if (event.ctrlKey === false) {
- this.arianeService.navigateTrack({ trackId: idSelected, newWindows: event.which === 2 });
- } else {
- this.arianeService.navigateTrackEdit({ id: idSelected, newWindows: event.which === 2 });
- }
- }
-}
diff --git a/front/src/app/scene/help/help.html b/front/src/app/scene/help/help.html
deleted file mode 100644
index 775c107..0000000
--- a/front/src/app/scene/help/help.html
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
- Karusic
-
-
- @for (data of dataList; track data.id) {
-
- }
-
-
-
\ No newline at end of file
diff --git a/front/src/app/scene/home/home.less b/front/src/app/scene/home/home.less
deleted file mode 100644
index 57816ee..0000000
--- a/front/src/app/scene/home/home.less
+++ /dev/null
@@ -1,70 +0,0 @@
-
-.title {
- //background-color: green;
- font-size: 45px;
- font-weight: bold;
- line-height: 60px;
- width:100%;
- align: left;
- text-align: center;
- vertical-align: middle;
- margin: 10px 0 10px 0;
- text-shadow: 1px 1px 2px white, 0 0 1em white, 0 0 0.2em white;
- text-transform: uppercase;
- font-family: "Roboto","Helvetica","Arial",sans-serif;
-}
-.item-home {
- background-color: rgba(200, 200, 200, 0.5);
- font-size: 20px;
- height: 190px;
- width: 200px;
- margin: 5px;
- padding: 0;
- overflow: hidden;
- // box-shadow: 0 1px 1.5px 0 rgba(0,0,0,.12),0 1px 1px 0 rgba(0,0,0,.24);
- box-shadow: 0px 2px 4px 0 rgba(0, 0, 0, 0.6);
- line-height: normal;
- border: none;
- font-family: "Roboto","Helvetica","Arial","sans-serif";
- font-weight: 500;
- text-transform: uppercase;
- letter-spacing: 0;
- will-change: box-shadow;
- outline: none;
- cursor: pointer;
- text-decoration: none;
- text-align: center;
- vertical-align: middle;
- transition-duration: 0.4s;
- float:left;
- display:block;
-
- h1 {
- font-size: 24px;
- }
-
- &:hover {
- background-color: rgba(200, 200, 200, 1);
- //box-shadow: 0px 2px 4px 0 rgba(255, 0, 0, 0.6);
- }
-
- .material-icons {
- vertical-align: middle;
- }
-
- .material-icons {
- position: absolute;
- top: 50%;
- left: 50%;
- transform: ~"translate(-12px,-12px)";
- line-height: 24px;
- width: 24px;
- }
-}
-
-@media all and (min-width: 1310px) {
- .colomn_mutiple {
- width: ~"calc(210px * 5)";
- margin: auto;
- }
-}
\ No newline at end of file
diff --git a/front/src/app/scene/home/home.ts b/front/src/app/scene/home/home.ts
deleted file mode 100644
index fd9bd9c..0000000
--- a/front/src/app/scene/home/home.ts
+++ /dev/null
@@ -1,70 +0,0 @@
-/** @file
- * @author Edouard DUPIN
- * @copyright 2018, Edouard DUPIN, all right reserved
- * @license PROPRIETARY (see license file)
- */
-
-import { Component, OnInit } from '@angular/core';
-import { HomeInterface } from 'app/component/AppElementHomeType/AppElementHomeType';
-
-import { ArianeService } from 'app/service';
-
-@Component({
- selector: 'app-home',
- templateUrl: './home.html',
- styleUrls: ['./home.less']
-})
-export class HomeScene implements OnInit {
- dataList: HomeInterface[] = [
- {
- id: 1,
- name: "Genders",
- }, {
- id: 2,
- name: "Artists",
- }, {
- id: 3,
- name: "Album",
- }, {
- id: 4,
- name: "Tracks",
- }, {
- id: 5,
- name: "Playlist",
- },
- ];
- error = '';
- constructor(private arianeService: ArianeService) {
-
- }
-
- ngOnInit() {
- let self = this;
- /*
- this.genderService.getData()
- .then((response) => {
- self.error = '';
- self.dataList = response;
- console.log(`Get response: ${ JSON.stringify(response, null, 2)}`);
- }).catch((response) => {
- self.error = 'Wrong e-mail/login or password';
- console.log(`[E] ${ self.constructor.name }: Does not get a correct response from the server ...`);
- self.dataList = [];
- });
- */
- this.arianeService.reset();
- }
- onSelectType(event: any, idSelected: number): void {
- if (idSelected === 1) {
- this.arianeService.navigateGender({ newWindows: event.which === 2 });
- } else if (idSelected === 2) {
- this.arianeService.navigateArtist({ newWindows: event.which === 2 });
- } else if (idSelected === 3) {
- this.arianeService.navigateAlbum({ newWindows: event.which === 2 });
- } else if (idSelected === 4) {
- this.arianeService.navigateTrack({ newWindows: event.which === 2 });
- } else if (idSelected === 5) {
- this.arianeService.navigatePlaylist({ newWindows: event.which === 2 });
- }
- }
-}
diff --git a/front/src/app/scene/index.ts b/front/src/app/scene/index.ts
deleted file mode 100644
index e29404e..0000000
--- a/front/src/app/scene/index.ts
+++ /dev/null
@@ -1,36 +0,0 @@
-import { GenderScene } from "./gender/gender";
-import { HelpScene } from "./help/help";
-import { HomeScene } from "./home/home";
-import { AlbumEditScene } from "./album-edit/SceneAlbumEdit";
-import { AlbumScene } from "./album/SceneAlbum";
-import { AlbumsScene } from "./album/SceneAlbums";
-import { ArtistEditScene } from "./artist-edit/artist-edit";
-import { ArtistScene } from "./artist/artist";
-import { ArtistsScene } from "./artist/artists";
-import { SettingsScene } from "./settings/settings";
-import { PlaylistScene } from "./playlist/playlist";
-import { TrackEditScene } from "./track-edit/track-edit";
-import { TrackScene } from "./track/track";
-import { UploadScene } from "./upload/upload";
-import { ArtistAlbumScene } from "./artist/artist-album";
-
-
-export {
- HelpScene,
- HomeScene,
- SettingsScene,
- AlbumScene,
- AlbumsScene,
- AlbumEditScene,
- ArtistsScene,
- ArtistScene,
- ArtistAlbumScene,
- ArtistEditScene,
- GenderScene,
- PlaylistScene,
- TrackScene,
- TrackEditScene,
- UploadScene,
-};
-
-
diff --git a/front/src/app/scene/playlist/playlist.html b/front/src/app/scene/playlist/playlist.html
deleted file mode 100644
index bc9ec47..0000000
--- a/front/src/app/scene/playlist/playlist.html
+++ /dev/null
@@ -1,10 +0,0 @@
-
-
- @for (data of tracks; track data.id) {
-
- }
-
-
-
\ No newline at end of file
diff --git a/front/src/app/scene/playlist/playlist.less b/front/src/app/scene/playlist/playlist.less
deleted file mode 100644
index 09160ef..0000000
--- a/front/src/app/scene/playlist/playlist.less
+++ /dev/null
@@ -1,62 +0,0 @@
-.fill-all{
- width:100%;
- height:100%;
- margin:0;
- padding:0;
- border:0;
- background-color:#0F0;
-}
-
-.item {
- font-size: 20px;
- height: 21%;
- width: 23%;
- margin: 1%;
- padding: 0;
- overflow: hidden;
- //box-shadow: 0 1px 1.5px 0 rgba(0,0,0,.12),0 1px 1px 0 rgba(0,0,0,.24);
- box-shadow: 0px 2px 4px 0 rgba(0, 0, 0, 0.6);
- line-height: normal;
- border: none;
- font-family: "Roboto","Helvetica","Arial",sans-serif;
- font-weight: 500;
- text-transform: uppercase;
- letter-spacing: 0;
- will-change: box-shadow;
- outline: none;
- cursor: pointer;
- text-decoration: none;
- text-align: center;
- vertical-align: middle;
- transition-duration: 0.4s;
- float:left;
- display:block;
-
- h1 {
- font-size: 24px;
- }
-
- &:hover {
- background-color: #F00;
- }
-
- .material-icons {
- vertical-align: middle;
- }
-
- .material-icons {
- position: absolute;
- top: 50%;
- left: 50%;
- transform: ~"translate(-12px,-12px)";
- line-height: 24px;
- width: 24px;
- }
-}
-
-.item-video {
- &:hover {
- background-color: #0F0;
- }
-}
-
diff --git a/front/src/app/scene/playlist/playlist.ts b/front/src/app/scene/playlist/playlist.ts
deleted file mode 100644
index 3e986ce..0000000
--- a/front/src/app/scene/playlist/playlist.ts
+++ /dev/null
@@ -1,52 +0,0 @@
-/** @file
- * @author Edouard DUPIN
- * @copyright 2018, Edouard DUPIN, all right reserved
- * @license PROPRIETARY (see license file)
- */
-
-import { Component, OnInit } from '@angular/core';
-import { Router } from '@angular/router';
-
-import { ArianeService } from 'app/service/ariane';
-
-@Component({
- selector: 'app-playlist',
- templateUrl: './playlist.html',
- styleUrls: [ './playlist.less' ]
-})
-
-export class PlaylistScene implements OnInit {
- playlistId = -1;
- tracksError = '';
- tracks = [];
- constructor(private router: Router,
- private arianeService: ArianeService) {
-
- }
-
- ngOnInit() {
- this.playlistId = this.arianeService.getPlaylistId();
- console.log(`get parameter id: ${ this.playlistId}`);
-
- /*
- let self = this;
- this.playlistService.getTrack(this.universId)
- .then(function(response) {
- self.tracksError = "";
- self.tracks = response
- }).catch(function(response) {
- self.tracksError = "Can not get the List of track without album";
- self.tracks = []
- });
- */
- }
-
- onSelectTrack(event: any, idSelected: number):void {
- if(event.which === 2) {
- window.open(`/track/${ idSelected}`);
- } else {
- this.router.navigate([ `track/${ idSelected}` ]);
- this.arianeService.setTrack(idSelected);
- }
- }
-}
diff --git a/front/src/app/scene/settings/settings.html b/front/src/app/scene/settings/settings.html
deleted file mode 100644
index 143f747..0000000
--- a/front/src/app/scene/settings/settings.html
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
- Edit Media
-
- @if(itemIsRemoved) {
-
-
-
- The media has been removed
-
-
-
- }
- @else if (itemIsNotFound) {
-
-
-
- The media does not exist
-
-
-
- }
- @else if (itemIsLoading) {
-
-
-
- Loading ...
- Please wait.
-
-
-
- }
- @else {
-
-
-
-
- description Description:
-
-
-
-
-
-
-
-
- Gender:
-
-
-
-
-
-
-
-
-
-
- Artist:
-
-
-
-
-
-
-
-
-
-
- Album:
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Administration
-
-
-
-
- data_usage ID:
-
-
- {{data.dataId}}
-
-
-
-
-
- delete_forever Trash:
-
-
-
-
-
-
-
- }
-
-
-
- @if(mediaIsNotFound) {
-
-
- Play media
- The media does not exist
-
-
- }
- @if(mediaIsLoading) {
-
-
- Play media
- Loading ...
- Please wait.
-
-
- }
- @if(!mediaIsNotFound && !mediaIsLoading && !playTrack) {
-
-
- {{name}}
-
-
-
- @if (covers && covers.length > 0) {
-
-
-
- }
- @else {
-
- }
-
-
-
-
- @if (haveNext !== null) {
-
-
-
- }
- @if (havePrevious !== null) {
-
-
-
- }
-
-
- @if (artistName!=null) {
-
- Artist: {{artistName}}
-
- }
- @if (albumName!=null) {
-
- Album: {{albumName}}
-
- }
- @if (track!=null) {
-
- Piste: {{track}}
-
- }
-
- generatedName: {{generatedName}}
-
-
- {{description}}
-
-
- }
- @if (playTrack) {
-
-
-
-
-
- @if (!displayNeedHide || !isPlaying) {
-
- @if (!isPlaying) {
-
- }
- @else {
-
- }
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- @if (!isFullScreen) {
-
- }
- @else {
-
- }
-
-
- @if (!isPlaying) {
-
-
-
- }
-
- }
- @if(!isFullScreen || !isPlaying) {
-
- {{generatedName}}
-
-
-
-
- }
- @if (displayVolumeMenu && (!displayNeedHide || !isPlaying)) {
-
-
-
- }
-
-
- }
-
-
\ No newline at end of file
diff --git a/front/src/app/scene/track/track.less b/front/src/app/scene/track/track.less
deleted file mode 100644
index eddbe5b..0000000
--- a/front/src/app/scene/track/track.less
+++ /dev/null
@@ -1,460 +0,0 @@
-.fill-all{
- //width:100%;
- max-width:80%;
- height:100%;
- margin: 20px auto;
- padding: 20px;
- border:0;
- background-color: rgba(200, 200, 200, 0.5);
- box-shadow: 0px 2px 4px 0 rgba(0, 0, 0, 0.6);
-}
-
-.title {
- width: 90%;
- margin: 0 auto;
- font-size: 50px;
- text-align: center;
-}
-
-.description {
- width: 80%;
- margin: 0 auto;
-}
-
-.episode {
- width: 80%;
- margin: 0 auto;
-}
-.generated_name {
- width: 80%;
- margin: 0 auto;
-}
-.cover-full {
- position:relative;
- width: 100%;
- height: 500px;
- margin: 0 auto;
- overflow:hidden;
- .cover {
- position:relative;
- width: 400px;
- height: 500px;
- margin: 0 auto;
- overflow:hidden;
-
- .cover-image {
- position:absolute;
- };
- .cover-no-image {
- position:absolute;
- width: 390px;
- height: 490px;
- margin: 0 auto;
- border: solid 5px;
- border-color: rgba(0, 0, 0, 0.7);
- };
- .cover-button {
- position: absolute;
- top: 50%;
- left: 50%;
- -ms-transform: translate(-50%, -50%);
- transform: translate(-50%, -50%);
- };
-
- img {
- width: 100%;
- };
- button {
- border: none;
- background: none;
- color: #00F000;
- :hover {
- color: #F00000;
- }
- };
- }
- button {
- border: none;
- background: none;
- color: #000000;
- :hover {
- color: #F00000;
- }
- };
- .cover-button-previous {
- position: absolute;
- top: 50%;
- left: 15%;
- -ms-transform: translate(-50%, -50%);
- transform: translate(-50%, -50%);
- };
- .cover-button-next {
- position: absolute;
- top: 50%;
- left: 85%;
- -ms-transform: translate(-50%, -50%);
- transform: translate(-50%, -50%);
- };
-}
-.video {
- position: absolute;
- top:0px;
- left:0px;
- width: 100%;
- height: 100%;
- z-index: 1000;
- background: #3C3C3C;
-
- .video-elem {
- background-color: black;
- position:absolute;
- width: 100%;
- height: 100%;
- top: 0;
- //right: 50%;
- //-ms-transform: translate(-50%, -50%);
- //transform: translate(-50%, -50%);
- };
- .video-button {
- position: absolute;
- top: 20px;
- right:20px;
- //-ms-transform: translate(-50%, 0);
- //transform: translate(-50%, 0);
- button {
- border: none;
- background: none;
- color: #F00000;
- };
- };
- .title-inline {
- position: absolute;
- top: 20px;
- left:20px;
- margin: 0 auto;
- font-size: 25px;
- color: #888;
- //text-align: center;
- };
-
-
- video {
- width: 100%;
- height: 100%;
- z-index: 1600;
- };
-
- .controls {
- //visibility: hidden;
- opacity: 0.5;
- width: 96%;
- height: 60px;
- border-radius: 10px;
- position: absolute;
- bottom: 20px;
- left: 2%;
- //margin-left: -200px;
- background-color: black;
- box-shadow: 3px 3px 5px black;
- transition: 1s all;
- display: flex;
- font-size: 40px;
- .material-icons {
- color: #FFF;
- font-size: 40px;
- }
- button {
- border: none;
- background: none;
- }
-
- .bigPause {
- position: fixed;
- top: 120px;
- left: 40%;
- width: 20%;
- height: calc(90% - 120px*2);
- border: none;
- box-shadow: none;
- cursor: pointer;
- .material-icons {
- color: #FFF;
- font-size: 120px;
- color: green;
- }
- &:focus {
- outline: none;
- }
- opacity: 95%;
- }
- .bigRewind {
- position: fixed;
- top: 120px;
- left: 20%;
- width: 20%;
- height: calc(90% - 120px*2);
- border: none;
- .material-icons {
- color: #FFF;
- font-size: 120px;
- color: red;
- }
- &:focus {
- outline: none;
- }
- opacity: 95%;
- }
- .bigForward {
- position: fixed;
- top: 120px;
- left: 60%;
- width: 20%;
- height: calc(90% - 120px*2);
- border: none;
- .material-icons {
- color: #FFF;
- font-size: 120px;
- color: blue;
- }
- &:focus {
- outline: none;
- }
- opacity: 95%;
- }
-
- .slidecontainer {
- line-height: 38px;
- font-size: 10px;
- font-family: monospace;
- text-shadow: 1px 1px 0px black;
- color: white;
- flex: 5;
- position: relative;
- }
- .slider {
- position: relative;
- -webkit-appearance: none;
- width: 98%;
- height: 10px;
- top: 5px;
- border-radius: 5px;
- background: #d3d3d3;
- outline: none;
- opacity: 0.7;
- -webkit-transition: .2s;
- transition: opacity .2s;
- flex: 5;
- }
- .slider::-webkit-slider-thumb {
- -webkit-appearance: none;
- appearance: none;
- width: 25px;
- height: 25px;
- border-radius: 50%;
- background: #4CAF50;
- cursor: pointer;
- }
-
- .slider::-moz-range-thumb {
- width: 25px;
- height: 25px;
- border-radius: 50%;
- background: #4CAF50;
- cursor: pointer;
- }
- .timer-text {
- position: absolute;
- top: 25px;
- left: 0px;
- width: 100%;
- line-height: 38px;
- font-size: 30px;
- font-weight:bold;
- }
- }
- /*
- :hover .controls, :focus .controls {
- opacity: 1;
- }
- */
-
- button:before {
- font-family: HeydingsControlsRegular;
- font-size: 30px;
- position: relative;
- color: #FFF;
- //text-shadow: 1px 1px 0px black;
- }
- .timer {
- line-height: 38px;
- font-size: 30px;
- font-family: monospace;
- text-shadow: 1px 1px 0px black;
- color: white;
- flex: 5;
- position: relative;
- }
-
- .timer div {
- width:100%;
- line-height: 38px;
- font-size: 10px;
- font-family: monospace;
- text-shadow: 1px 1px 0px black;
- color: white;
- flex: 5;
- position: relative;
- }
-
- .timer span {
- position: absolute;
- z-index: 3;
- left: 19px;
- }
-
-
- .volume-menu {
- font-size: 40px;
- opacity: 0.5;
- width: 300px;
- height: 60px;
- border-radius: 10px;
- position: absolute;
- bottom: 90px;
- right: 2%;
- //margin-left: -200px;
- background-color: black;
- box-shadow: 3px 3px 5px black;
- transition: 1s all;
- display: flex;
-
- .material-icons {
- vertical-align: middle;
- color: #FFF;
- font-size: 40px;
- }
- /* Create an Arraw on the top ob the box ... */
- &:after, &:before {
- bottom: 100%;
- right: 13px;
- border: solid transparent;
- content: " ";
- height: 0;
- width: 0;
- position: absolute;
- pointer-events: none;
- }
-
- &:after {
- border-color: rgba(136, 183, 213, 0);
- border-bottom-color: #263238;
- border-width: 15px;
- margin-left: -15px;
- }
- button {
- border: none;
- background: none;
- border-radius: 50%;
- }
- .slidecontainer {
- line-height: 38px;
- font-size: 10px;
- font-family: monospace;
- text-shadow: 1px 1px 0px black;
- color: white;
- flex: 5;
- position: relative;
- }
- .slider {
- position: relative;
- -webkit-appearance: none;
- width: 98%;
- height: 10px;
- top: 15px;
- border-radius: 5px;
- background: #d3d3d3;
- outline: none;
- opacity: 0.7;
- -webkit-transition: .2s;
- transition: opacity .2s;
- flex: 5;
- }
- .slider::-webkit-slider-thumb {
- -webkit-appearance: none;
- appearance: none;
- width: 25px;
- height: 25px;
- border-radius: 50%;
- background: #4CAF50;
- cursor: pointer;
- }
-
- .slider::-moz-range-thumb {
- width: 25px;
- height: 25px;
- border-radius: 50%;
- background: #4CAF50;
- cursor: pointer;
- }
-
- }
-
-}
-
-.big-button {
- font-size:100px;
-}
-
-.item {
- font-size: 20px;
- height: 21%;
- width: 23%;
- margin: 1%;
- padding: 0;
- overflow: hidden;
- //box-shadow: 0 1px 1.5px 0 rgba(0,0,0,.12),0 1px 1px 0 rgba(0,0,0,.24);
- box-shadow: 0px 2px 4px 0 rgba(0, 0, 0, 0.6);
- line-height: normal;
- border: none;
- font-family: "Roboto","Helvetica","Arial",sans-serif;
- font-weight: 500;
- text-transform: uppercase;
- letter-spacing: 0;
- will-change: box-shadow;
- outline: none;
- cursor: pointer;
- text-decoration: none;
- text-align: center;
- vertical-align: middle;
- transition-duration: 0.4s;
- float:left;
- display:block;
-
- h1 {
- font-size: 24px;
- }
-
- &:hover {
- background-color: #F00;
- }
-
- .material-icons {
- vertical-align: middle;
- }
-
- .material-icons {
- position: absolute;
- top: 50%;
- left: 50%;
- transform: ~"translate(-12px,-12px)";
- line-height: 24px;
- width: 24px;
- }
-}
-
-.item-video {
- &:hover {
- background-color: #0F0;
- }
-}
-
diff --git a/front/src/app/scene/track/track.ts b/front/src/app/scene/track/track.ts
deleted file mode 100644
index ad0475f..0000000
--- a/front/src/app/scene/track/track.ts
+++ /dev/null
@@ -1,565 +0,0 @@
-/** @file
- * @author Edouard DUPIN
- * @copyright 2018, Edouard DUPIN, all right reserved
- * @license PROPRIETARY (see license file)
- */
-
-import { Component, OnInit, ViewChild, ElementRef } from '@angular/core';
-import { isNullOrUndefined } from '@kangaroo-and-rabbit/kar-cw';
-import { Track } from 'app/back-api';
-import { DataService, TrackService, ArtistService, AlbumService, ArianeService } from 'app/service';
-
-@Component({
- selector: 'app-track',
- templateUrl: './track.html',
- styleUrls: ['./track.less']
-})
-
-export class TrackScene implements OnInit {
- trackGlobal: any;
- @ViewChild('globalTrackElement')
- set mainDivEl(el: ElementRef) {
- if (el !== null && el !== undefined) {
- this.trackGlobal = el.nativeElement;
- }
- }
- trackPlayer: HTMLVideoElement;
- @ViewChild('videoPlayer')
- set mainTrackEl(el: ElementRef) {
- if (el !== null && el !== undefined) {
- this.trackPlayer = el.nativeElement;
- }
- }
- videoCanva: any;
- @ViewChild('canvascreenshoot')
- set mainCanvaEl(el: ElementRef) {
- if (el !== null && el !== undefined) {
- this.videoCanva = el.nativeElement;
- }
- }
- haveNext = null;
- havePrevious = null;
- idTrack: number = -1;
-
- mediaIsNotFound: boolean = false;
- mediaIsLoading: boolean = true;
- error: string = '';
-
- name: string = '';
- description: string = '';
- track?: number;
- artists?: number[];
- artistName?: string;
- albumId?: number;
- albumName?: string;
- dataId: string = "";
- typeId?: number;
- generatedName: string = '';
- trackSource: string = '';
- covers: string[];
-
- playTrack: boolean = false;
- displayVolumeMenu: boolean = false;
- isPlaying: boolean = false;
- isFullScreen: boolean = false;
- currentTime: number = 0;
- currentTimeDisplay: string = '00';
- duration: number = 0;
- durationDisplay: string = '00';
- volumeValue: number = 100;
-
- displayNeedHide: boolean = false;
- timeLeft: number = 10;
- interval = null;
- constructor(private trackService: TrackService,
- private artistService: ArtistService,
- private albumService: AlbumService,
- private arianeService: ArianeService,
- private dataService: DataService) {
-
- }
-
- startHideTimer() {
- this.displayNeedHide = false;
- this.timeLeft = 5;
- if (this.interval !== null) {
- return;
- }
- let self = this;
- this.interval = setInterval(() => {
- console.log(`periodic event: ${self.timeLeft}`);
- if (self.timeLeft > 0) {
- self.timeLeft--;
- } else {
- clearInterval(self.interval);
- self.timeOutDetected();
- }
- }, 1000);
- }
- timeOutDetected() {
- console.log(' ==> stop timer');
- this.displayNeedHide = true;
- clearInterval(this.interval);
- this.interval = null;
- }
- onRequireNext(event: any) {
- console.log(`generate next : ${this.haveNext.id}`);
- if (event.ctrlKey === false) {
- this.arianeService.navigateTrack({ trackId: this.haveNext.id, newWindows: event.which === 2 });
- } else {
- this.arianeService.navigateTrackEdit({ id: this.haveNext.id, newWindows: event.which === 2 });
- }
- this.arianeService.setTrack(this.haveNext.id);
- }
- onRequirePrevious(event: any) {
- console.log(`generate previous : ${this.havePrevious.id}`);
- if (event.ctrlKey === false) {
- this.arianeService.navigateTrack({ trackId: this.haveNext.id, newWindows: event.which === 2 });
- } else {
- this.arianeService.navigateTrackEdit({ id: this.haveNext.id, newWindows: event.which === 2 });
- }
- this.arianeService.setTrack(this.havePrevious.id);
- }
- generateName() {
- this.generatedName = '';
- if (this.artistName !== undefined) {
- this.generatedName = `${this.generatedName}${this.artistName}-`;
- }
- if (this.albumName !== undefined) {
- if (this.albumName.length < 2) {
- this.generatedName = `${this.generatedName}s0${this.albumName}-`;
- } else {
- this.generatedName = `${this.generatedName}s${this.albumName}-`;
- }
- }
- if (this.track !== undefined) {
- if (this.track < 10) {
- this.generatedName = `${this.generatedName}e0${this.track}-`;
- } else {
- this.generatedName = `${this.generatedName}e${this.track}-`;
- }
- }
- this.generatedName = this.generatedName + this.name;
- this.generatedName = this.generatedName.replace(new RegExp('&', 'g'), '_');
- this.generatedName = this.generatedName.replace(new RegExp('/', 'g'), '_');
- // update the path of the uri request
- this.trackSource = this.dataService.getUrl(this.dataId, this.generatedName);
- }
-
- myPeriodicCheckFunction() {
- console.log('check ... ');
- }
- changeMetadata() {
- console.log('list of the stream:');
-
- /*
- let captureStream = this.trackPlayer.audioTracks;
- for (let iii=0; iii < captureStream.length; iii++) {
- console.log(" - " + captureStream[iii].language);
- if (captureStream[iii].language.substring(0,2) === "fr") {
- captureStream[iii].enabled = true;
- } else {
- captureStream[iii].enabled = false;
- }
- }
- */
- }
- audioTracks(event) {
- console.log(`list of the stream:${event}`);
-
- /*
- let captureStream = this.trackPlayer.audioTracks;
- for (let iii=0; iii < captureStream.length; iii++) {
- console.log(" - " + captureStream[iii].language);
- if (captureStream[iii].language.substring(0,2) === "fr") {
- captureStream[iii].enabled = true;
- } else {
- captureStream[iii].enabled = false;
- }
- }
- */
- }
-
- ngOnInit() {
- let self = this;
- this.startHideTimer();
- this.idTrack = this.arianeService.getTrackId();
- this.arianeService.trackChange.subscribe((trackId) => {
- console.log(`Detect trackId change...${trackId}`);
- self.idTrack = trackId;
- self.updateDisplay();
- });
- self.updateDisplay();
- }
- updateDisplay(): void {
- let self = this;
- self.haveNext = null;
- self.havePrevious = null;
- this.trackService.get(this.idTrack)
- .then((response: Track) => {
- console.log(`get response of track : ${JSON.stringify(response, null, 2)}`);
- self.error = '';
- self.name = response.name;
- self.description = response.description;
- //self.episode = response.episode;
- self.artists = response.artists;
- self.albumId = response.albumId;
- self.dataId = response.dataId;
- self.generatedName = "????????? TODO: ???????" //response.generatedName;
- if (!isNullOrUndefined(self.dataId)) {
- self.trackSource = this.dataService.getUrl(self.dataId);
- } else {
- self.trackSource = '';
- }
- self.covers = self.dataService.getListUrl(response.covers);
-
- self.generateName();
- if (!isNullOrUndefined(self.artists) && self.artists.length !== 0) {
- self.artistService.get(self.artists[0])
- .then((response2) => {
- self.artistName = response2.name;
- self.generateName();
- }).catch((response3) => {
- // nothing to do ...
- });
- }
- if (!isNullOrUndefined(self.albumId)) {
- self.albumService.get(self.albumId)
- .then((response4) => {
- self.albumName = response4.name;
- self.generateName();
- }).catch((response5) => {
- // nothing to do ...
- });
- self.trackService.getTracksWithAlbumId(self.albumId)
- .then((response6: Track[]) => {
- self.haveNext = null;
- self.havePrevious = null;
- for (let iii = 0; iii < response6.length; iii++) {
- if (isNullOrUndefined(response6[iii].track)) {
- continue;
- }
- if (response6[iii].track < self.track) {
- if (self.havePrevious === null) {
- self.havePrevious = response6[iii];
- } else if (self.havePrevious.episode < response6[iii].track) {
- self.havePrevious = response6[iii];
- }
- } else if (response6[iii].track > self.track) {
- if (self.haveNext === null) {
- self.haveNext = response6[iii];
- } else if (self.haveNext.episode > response6[iii].track) {
- self.haveNext = response6[iii];
- }
- }
- //self.covers.push(self.dataService.getUrl(response6[iii].covers));
- }
- }).catch((response7: any) => {
-
- });
- }
- self.mediaIsLoading = false;
- // console.log("display source " + self.trackSource);
- // console.log("set transformed : " + JSON.stringify(self, null, 2));
- }).catch((response8) => {
- self.error = 'Can not get the data';
- self.name = '';
- self.description = '';
- self.track = undefined;
- self.artists = undefined;
- self.albumId = undefined;
- self.dataId = "";
- self.generatedName = '';
- self.trackSource = '';
- self.covers = undefined;
- self.artistName = undefined;
- self.albumName = undefined;
- self.mediaIsNotFound = true;
- self.mediaIsLoading = false;
- });
- }
- onRequirePlay() {
- this.startHideTimer();
- this.playTrack = true;
- this.displayVolumeMenu = false;
- }
- onRequireStop() {
- this.startHideTimer();
- this.playTrack = false;
- this.displayVolumeMenu = false;
- }
- onTrackEnded() {
- this.startHideTimer();
- this.playTrack = false;
- this.displayVolumeMenu = false;
-
- /*
- if(this.isFullScreen === true) {
- this.isFullScreen = false;
- }
- */
- }
-
- changeStateToPlay() {
- this.isPlaying = true;
- if (this.isFullScreen === true) {
- this.onFullscreen();
- }
- }
- changeStateToPause() {
- this.isPlaying = false;
- }
-
- convertIndisplayTime(time: number): string {
- let tmpp = parseInt(`${time}`, 10);
- let heures = parseInt(`${tmpp / 3600}`, 10);
- tmpp = tmpp - heures * 3600;
- let minutes = parseInt(`${tmpp / 60}`, 10);
- let seconds = tmpp - minutes * 60;
- let out = '';
- if (heures !== 0) {
- out = `${out}${heures}:`;
- }
- if (minutes >= 10) {
- out = `${out}${minutes}:`;
- } else {
- out = `${out}0${minutes}:`;
- }
- if (seconds >= 10) {
- out = out + seconds;
- } else {
- out = `${out}0${seconds}`;
- }
- return out;
- }
-
- changeTimeupdate(currentTime: any) {
- // console.log("time change ");
- // console.log(" ==> " + this.trackPlayer.currentTime);
- this.currentTime = this.trackPlayer.currentTime;
- this.currentTimeDisplay = this.convertIndisplayTime(this.currentTime);
- // console.log(" ==> " + this.currentTimeDisplay);
- }
- changeDurationchange(duration: any) {
- console.log('duration change ');
- console.log(` ==> ${this.trackPlayer.duration}`);
- this.duration = this.trackPlayer.duration;
- this.durationDisplay = this.convertIndisplayTime(this.duration);
- }
-
- onPlay() {
- console.log('play');
- this.startHideTimer();
- if (this.trackPlayer === null ||
- this.trackPlayer === undefined) {
- console.log(`error element: ${this.trackPlayer}`);
- return;
- }
- this.trackPlayer.volume = this.volumeValue / 100;
- this.trackPlayer.play();
- }
-
- onPause() {
- console.log('pause');
- this.startHideTimer();
- if (this.trackPlayer === null ||
- this.trackPlayer === undefined) {
- console.log(`error element: ${this.trackPlayer}`);
- return;
- }
- this.trackPlayer.pause();
- }
-
- onPauseToggle() {
- console.log('pause toggle ...');
- if (this.isPlaying === true) {
- this.onPause();
- } else {
- this.onPlay();
- }
- }
-
- onStop() {
- console.log('stop');
- this.startHideTimer();
- if (this.trackPlayer === null ||
- this.trackPlayer === undefined) {
- console.log(`error element: ${this.trackPlayer}`);
- return;
- }
- this.trackPlayer.pause();
- this.trackPlayer.currentTime = 0;
- }
-
- onBefore() {
- console.log('before');
- this.startHideTimer();
- }
-
- onNext() {
- console.log('next');
- this.startHideTimer();
- }
-
- seek(newValue: any) {
- console.log(`seek ${newValue.value}`);
- this.startHideTimer();
- if (this.trackPlayer === null ||
- this.trackPlayer === undefined) {
- console.log(`error element: ${this.trackPlayer}`);
- return;
- }
- this.trackPlayer.currentTime = newValue.value;
- }
-
- onRewind() {
- console.log('rewind');
- this.startHideTimer();
- if (this.trackPlayer === null ||
- this.trackPlayer === undefined) {
- console.log(`error element: ${this.trackPlayer}`);
- return;
- }
- this.trackPlayer.currentTime = this.currentTime - 10;
- }
-
- onForward() {
- console.log('forward');
- this.startHideTimer();
- if (this.trackPlayer === null ||
- this.trackPlayer === undefined) {
- console.log(`error element: ${this.trackPlayer}`);
- return;
- }
- this.trackPlayer.currentTime = this.currentTime + 10;
- }
-
- onMore() {
- console.log('more');
- this.startHideTimer();
- if (this.trackPlayer === null ||
- this.trackPlayer === undefined) {
- console.log(`error element: ${this.trackPlayer}`);
- return;
- }
- }
- onFullscreen() {
- console.log('fullscreen');
- this.startHideTimer();
- if (this.trackGlobal === null ||
- this.trackGlobal === undefined) {
- console.log(`error element: ${this.trackGlobal}`);
- return;
- }
- if (this.trackGlobal.requestFullscreen) {
- this.trackGlobal.requestFullscreen();
- } else if (this.trackGlobal.mozRequestFullScreen) {
- this.trackGlobal.mozRequestFullScreen();
- } else if (this.trackGlobal.webkitRequestFullscreen) {
- this.trackGlobal.webkitRequestFullscreen();
- } else if (this.trackGlobal.msRequestFullscreen) {
- this.trackGlobal.msRequestFullscreen();
- }
- }
-
- onFullscreenExit() {
- this.onFullscreenExit22(document);
- }
- onFullscreenExit22(docc: any) {
- console.log('fullscreen EXIT');
- this.startHideTimer();
- if (this.trackGlobal === null ||
- this.trackGlobal === undefined) {
- console.log(`error element: ${this.trackGlobal}`);
- return;
- }
- if (docc.exitFullscreen) {
- docc.exitFullscreen();
- } else if (docc.mozCancelFullScreen) {
- docc.mozCancelFullScreen();
- } else if (docc.webkitExitFullscreen) {
- docc.webkitExitFullscreen();
- } else if (docc.msExitFullscreen) {
- docc.msExitFullscreen();
- }
- }
-
- onFullscreenChange() {
- this.onFullscreenChange22(document);
- }
- onFullscreenChange22(element: any) {
- let isInFullScreen = element.fullscreenElement && element.fullscreenElement !== null ||
- element.webkitFullscreenElement && element.webkitFullscreenElement !== null ||
- element.mozFullScreenElement && element.mozFullScreenElement !== null ||
- element.msFullscreenElement && element.msFullscreenElement !== null;
- console.log(`onFullscreenChange(${isInFullScreen})`);
- this.isFullScreen = isInFullScreen;
- }
-
- onVolumeMenu() {
- this.displayVolumeMenu = !this.displayVolumeMenu;
- this.startHideTimer();
- }
-
- onVolume(newValue: any) {
- console.log(`onVolume ${newValue.value}`);
- this.startHideTimer();
- if (this.trackPlayer === null ||
- this.trackPlayer === undefined) {
- console.log(`error element: ${this.trackPlayer}`);
- return;
- }
- this.volumeValue = newValue.value;
- this.trackPlayer.volume = this.volumeValue / 100;
- this.trackPlayer.muted = false;
- }
-
- onVolumeMute() {
- this.startHideTimer();
- if (this.trackPlayer === null ||
- this.trackPlayer === undefined) {
- console.log(`error element: ${this.trackPlayer}`);
- return;
- }
- this.trackPlayer.muted = true;
- }
-
- onVolumeUnMute() {
- this.startHideTimer();
- if (this.trackPlayer === null ||
- this.trackPlayer === undefined) {
- console.log(`error element: ${this.trackPlayer}`);
- return;
- }
- this.trackPlayer.muted = false;
- }
-
- onTakeScreenShoot() {
- this.startHideTimer();
- // const canvas = document.createElement("canvas");
- // scale the canvas accordingly
- this.videoCanva.width = this.trackPlayer.videoWidth;
- this.videoCanva.height = this.trackPlayer.videoHeight;
- // draw the track at that frame
- this.videoCanva.getContext('2d').drawImage(this.trackPlayer, 0, 0, this.videoCanva.width, this.videoCanva.height);
- // canvas.crossorigin="anonymous"
- // convert it and send it to the server
- let self = this;
-
- console.log("not implemented right now...");
- /*
- this.videoCanva.toBlob((blob) => {
- self.trackService.uploadCoverBlob(blob, this.idTrack);
- }, 'image/jpeg', 0.95);
- */
- /*
- let tmpUrl = this.videoCanva.toDataURL('image/jpeg', 0.95);
- fetch(tmpUrl)
- .then(res => res.blob()) // Gets the response and returns it as a blob
- .then(blob => {
- self.trackService.uploadCoverBlob(blob, this.idTrack);
- });
- */
- }
-}
-
diff --git a/front/src/app/scene/upload/upload.html b/front/src/app/scene/upload/upload.html
deleted file mode 100644
index 5caffc5..0000000
--- a/front/src/app/scene/upload/upload.html
+++ /dev/null
@@ -1,260 +0,0 @@
-
-
- Upload Media
-
-
-
- @if(parsedElement.length !== 0) {
-
- Meta-data:
-
- }
-
- @if(parsedElement.length !== 0) {
-
-
-
-
-
-
-
-
-
- @if(listFileInBdd) {
-
-
-
-
-
-
-
-
-
- Track ID: |
- Title: |
-
-
-
- @for (data of listFileInBdd; track data.id;) {
-
- {{data.episode}} |
- {{data.name}} |
-
- }
-
-
-
- }
-
- }
- @if(parsedElement.length !== 0) {
-
-
-
-
-
-
-
-
- @for (data of parsedFailedElement; track data.id;) {
-
- Rejected: |
-
- {{data.file.name}} ==> {{data.reason}}
- |
-
- }
-
-
-
-
- }
-
-