More stuff
This commit is contained in:
parent
a11237f70d
commit
4d3834be1d
4
.idea/common.iml
generated
4
.idea/common.iml
generated
@ -1,7 +1,9 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<module type="WEB_MODULE" version="4">
|
<module type="WEB_MODULE" version="4">
|
||||||
<component name="NewModuleRootManager">
|
<component name="NewModuleRootManager">
|
||||||
<content url="file://$MODULE_DIR$" />
|
<content url="file://$MODULE_DIR$">
|
||||||
|
<excludeFolder url="file://$MODULE_DIR$/dist" />
|
||||||
|
</content>
|
||||||
<orderEntry type="inheritedJdk" />
|
<orderEntry type="inheritedJdk" />
|
||||||
<orderEntry type="sourceFolder" forTests="false" />
|
<orderEntry type="sourceFolder" forTests="false" />
|
||||||
</component>
|
</component>
|
||||||
|
|||||||
10
dataTypes.ts
10
dataTypes.ts
@ -10,8 +10,14 @@ export class Song {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
export class PlayingSong extends Song {
|
export class QueuedSong extends Song {
|
||||||
constructor(type: SongType, title: string, songId: string, image: string, public length: number, public position: number) {
|
constructor(type: SongType, title: string, songId: string, image: string, public listener: string) {
|
||||||
super(type, title, songId, image);
|
super(type, title, songId, image);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export class PlayingSong extends QueuedSong {
|
||||||
|
constructor(type: SongType, title: string, songId: string, image: string, listener: string, public length: number, public position: number) {
|
||||||
|
super(type, title, songId, image, listener);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
8
dist/dataTypes.d.ts
vendored
8
dist/dataTypes.d.ts
vendored
@ -9,8 +9,12 @@ export declare class Song {
|
|||||||
image: string;
|
image: string;
|
||||||
constructor(type: SongType, title: string, songId: string, image: string);
|
constructor(type: SongType, title: string, songId: string, image: string);
|
||||||
}
|
}
|
||||||
export declare class PlayingSong extends Song {
|
export declare class QueuedSong extends Song {
|
||||||
|
listener: string;
|
||||||
|
constructor(type: SongType, title: string, songId: string, image: string, listener: string);
|
||||||
|
}
|
||||||
|
export declare class PlayingSong extends QueuedSong {
|
||||||
length: number;
|
length: number;
|
||||||
position: number;
|
position: number;
|
||||||
constructor(type: SongType, title: string, songId: string, image: string, length: number, position: number);
|
constructor(type: SongType, title: string, songId: string, image: string, listener: string, length: number, position: number);
|
||||||
}
|
}
|
||||||
|
|||||||
18
dist/dataTypes.js
vendored
18
dist/dataTypes.js
vendored
@ -15,7 +15,7 @@ var __extends = (this && this.__extends) || (function () {
|
|||||||
};
|
};
|
||||||
})();
|
})();
|
||||||
exports.__esModule = true;
|
exports.__esModule = true;
|
||||||
exports.PlayingSong = exports.Song = exports.SongType = void 0;
|
exports.PlayingSong = exports.QueuedSong = exports.Song = exports.SongType = void 0;
|
||||||
var SongType;
|
var SongType;
|
||||||
(function (SongType) {
|
(function (SongType) {
|
||||||
SongType[SongType["YouTube"] = 0] = "YouTube";
|
SongType[SongType["YouTube"] = 0] = "YouTube";
|
||||||
@ -31,14 +31,24 @@ var Song = /** @class */ (function () {
|
|||||||
return Song;
|
return Song;
|
||||||
}());
|
}());
|
||||||
exports.Song = Song;
|
exports.Song = Song;
|
||||||
|
var QueuedSong = /** @class */ (function (_super) {
|
||||||
|
__extends(QueuedSong, _super);
|
||||||
|
function QueuedSong(type, title, songId, image, listener) {
|
||||||
|
var _this = _super.call(this, type, title, songId, image) || this;
|
||||||
|
_this.listener = listener;
|
||||||
|
return _this;
|
||||||
|
}
|
||||||
|
return QueuedSong;
|
||||||
|
}(Song));
|
||||||
|
exports.QueuedSong = QueuedSong;
|
||||||
var PlayingSong = /** @class */ (function (_super) {
|
var PlayingSong = /** @class */ (function (_super) {
|
||||||
__extends(PlayingSong, _super);
|
__extends(PlayingSong, _super);
|
||||||
function PlayingSong(type, title, songId, image, length, position) {
|
function PlayingSong(type, title, songId, image, listener, length, position) {
|
||||||
var _this = _super.call(this, type, title, songId, image) || this;
|
var _this = _super.call(this, type, title, songId, image, listener) || this;
|
||||||
_this.length = length;
|
_this.length = length;
|
||||||
_this.position = position;
|
_this.position = position;
|
||||||
return _this;
|
return _this;
|
||||||
}
|
}
|
||||||
return PlayingSong;
|
return PlayingSong;
|
||||||
}(Song));
|
}(QueuedSong));
|
||||||
exports.PlayingSong = PlayingSong;
|
exports.PlayingSong = PlayingSong;
|
||||||
|
|||||||
6
dist/messageTypes.d.ts
vendored
6
dist/messageTypes.d.ts
vendored
@ -1,4 +1,4 @@
|
|||||||
import { Song, PlayingSong } from "./dataTypes";
|
import { Song, PlayingSong, QueuedSong } from "./dataTypes";
|
||||||
export declare type StuenMessages = ListenerLeft | ListenerList | ListenerJoined | SendChatMessage | SearchSong | SearchSongResult | Join | QueueSong | CurrentQueue | CurrentSong | UnqueueSong | ReorderSong;
|
export declare type StuenMessages = ListenerLeft | ListenerList | ListenerJoined | SendChatMessage | SearchSong | SearchSongResult | Join | QueueSong | CurrentQueue | CurrentSong | UnqueueSong | ReorderSong;
|
||||||
export declare abstract class StuenMessage {
|
export declare abstract class StuenMessage {
|
||||||
type: string;
|
type: string;
|
||||||
@ -42,8 +42,8 @@ export declare class QueueSong extends StuenMessage {
|
|||||||
constructor(song: Song);
|
constructor(song: Song);
|
||||||
}
|
}
|
||||||
export declare class CurrentQueue extends StuenMessage {
|
export declare class CurrentQueue extends StuenMessage {
|
||||||
songs: Song[];
|
songs: QueuedSong[];
|
||||||
constructor(songs: Song[]);
|
constructor(songs: QueuedSong[]);
|
||||||
}
|
}
|
||||||
export declare class CurrentSong extends StuenMessage {
|
export declare class CurrentSong extends StuenMessage {
|
||||||
song: PlayingSong | null;
|
song: PlayingSong | null;
|
||||||
|
|||||||
@ -1,4 +1,4 @@
|
|||||||
import {Song, PlayingSong} from "./dataTypes";
|
import {Song, PlayingSong, QueuedSong} from "./dataTypes";
|
||||||
|
|
||||||
export type StuenMessages = ListenerLeft | ListenerList | ListenerJoined | SendChatMessage | SearchSong | SearchSongResult | Join | QueueSong | CurrentQueue | CurrentSong | UnqueueSong | ReorderSong;
|
export type StuenMessages = ListenerLeft | ListenerList | ListenerJoined | SendChatMessage | SearchSong | SearchSongResult | Join | QueueSong | CurrentQueue | CurrentSong | UnqueueSong | ReorderSong;
|
||||||
export abstract class StuenMessage {
|
export abstract class StuenMessage {
|
||||||
@ -62,7 +62,7 @@ export class QueueSong extends StuenMessage {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export class CurrentQueue extends StuenMessage {
|
export class CurrentQueue extends StuenMessage {
|
||||||
constructor(public songs: Song[]) {
|
constructor(public songs: QueuedSong[]) {
|
||||||
super('CurrentQueue');
|
super('CurrentQueue');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user