{{ t('advanced.warning') }}
5 | 34 |
47 |
49 | 50 | 51 | 52 | 53 | | 54 |55 | {{ element.name }} 56 | | 57 |58 | 61 | | 62 |63 | {{ secToHMS(element.duration) }} 64 | | 65 | 66 | 67 | 68 | 69 | 70 |
14 |
15 | {{ t('player.start') }}
16 |
17 | |
18 |
19 |
20 | {{ t('player.file') }}
21 |
22 | |
23 |
24 |
25 | {{ t('player.play') }}
26 |
27 | |
28 |
33 |
38 |
43 |
48 |
49 |
50 | {{ t('player.edit') }}
51 |
52 | |
53 |
58 |
---|---|---|---|
85 | {{ secondsToTime(element.begin) }} 86 | | 87 |88 | {{ element.title || filename(element.source) }} 89 | | 90 |91 | 94 | | 95 | 96 | 99 | 102 | 110 |111 | 114 | | 115 | 120 |
7 | {{ $t('error.notFound') }} 8 |
9 |13 | {{ $t('error.serverError') }} 14 |
15 |.js',
24 | + },
25 | ],
26 |
27 | ...
28 | ```
29 |
30 | And also add the new link paths:
31 |
32 | ```DIFF
33 | i18n: {
34 | locales: [...],
35 | ...
36 | pages: {
37 | 'player': {
38 | de: '/wiedergabe',
39 | en: '/player',
40 | + : /,
41 | },
42 |
43 | ...
44 | ```
45 |
--------------------------------------------------------------------------------
/i18n/locales/de-DE.js:
--------------------------------------------------------------------------------
1 | export default {
2 | ok: 'Ok',
3 | cancel: 'Abbrechen',
4 | socketConnected: 'Event Stream verbunden',
5 | socketDisconnected: 'Event Stream nicht verbunden',
6 | alert: {
7 | wrongLogin: 'Falsche Anmeldedaten!',
8 | },
9 | button: {
10 | login: 'Anmelden',
11 | home: 'Start',
12 | player: 'Wiedergabe',
13 | media: 'Medien',
14 | message: 'Nachrichten',
15 | logging: 'Protokollierung',
16 | channels: 'Kanäle',
17 | configure: 'Einstellungen',
18 | logout: 'Abmelden',
19 | },
20 | error: {
21 | notFound: 'Seite nicht gefunden',
22 | serverError: 'Interner Server Fehler',
23 | },
24 | input: {
25 | username: 'Benutzername',
26 | password: 'Passwort',
27 | },
28 | system: {
29 | cpu: 'CPU',
30 | cores: 'Kerne',
31 | load: 'Auslastung',
32 | memory: 'Arbeitsspeicher',
33 | swap: 'Auslagerungsspeicher',
34 | total: 'Gesamt',
35 | usage: 'Verwendung',
36 | network: 'Netzwerk',
37 | in: 'Eingehend',
38 | out: 'Ausgehend',
39 | storage: 'Speicher',
40 | device: 'Gerät',
41 | size: 'Größe',
42 | used: 'Genutzt',
43 | },
44 | control: {
45 | noClip: 'Es wird kein Clip abgespielt',
46 | ingest: 'Live-Übertragung',
47 | start: 'Playout-Dienst starten',
48 | last: 'Zum letzten Clip springen',
49 | stop: 'Playout-Dienst stoppen',
50 | reset: 'Playout-Zustand zurücksetzen',
51 | restart: 'Playout-Dienst neu starten',
52 | next: 'Zum nächsten Clip springen',
53 | },
54 | player: {
55 | start: 'Start',
56 | file: 'Datei',
57 | play: 'Abspielen',
58 | title: 'Titel',
59 | duration: 'Dauer',
60 | in: 'Eingang',
61 | out: 'Ausgang',
62 | ad: 'Werbung',
63 | edit: 'Bearbeiten',
64 | delete: 'Löschen',
65 | copy: 'Wiedergabeliste kopieren',
66 | loop: 'Clips in {date} Wiedergabeliste wiederholen',
67 | remote: 'Externe Quelle zur Wiedergabeliste hinzufügen',
68 | import: 'Text-/m3u-Datei importieren',
69 | generate: 'Einfacher und erweiterter Wiedergabelisten-Generator',
70 | reset: 'Wiedergabeliste zurücksetzen',
71 | save: 'Wiedergabeliste speichern',
72 | deletePlaylist: 'Wiedergabeliste löschen',
73 | unsavedProgram: 'Es existiert Programm das nicht gespeichert ist!',
74 | copyTo: 'Kopiere aktuelles Programm nach',
75 | addEdit: 'Quelle hinzufügen/bearbeiten',
76 | audio: 'Audio',
77 | customFilter: 'Benutzerdefinierter Filter',
78 | deleteFrom: 'Programm löschen von',
79 | deleteSuccess: 'Wiedergabeliste gelöscht...',
80 | generateProgram: 'Programm generieren',
81 | simple: 'Einfach',
82 | advanced: 'Erweitert',
83 | sorted: 'Sortiert',
84 | shuffle: 'Zufall',
85 | shift: 'Zeitverschiebung',
86 | all: 'Alle',
87 | addBlock: 'Zeitblock hinzufügen',
88 | infinitInfo: 'Die Wiedergabe läuft im unendlichen Modus. Es sind keine zeitbasierten Informationen möglich.',
89 | generateDone: 'Wiedergabeliste generieren erledigt...',
90 | dateYesterday: 'Aktuelle Uhrzeit liegt vor der Playlist-Startzeit!',
91 | },
92 | media: {
93 | notExists: 'Speicher existiert nicht!',
94 | create: 'Ordner erstellen',
95 | upload: 'Dateien hochladen',
96 | deleteTitle: 'Datei/Ordner löschen',
97 | deleteQuestion: 'Sind Sie sicher, dass Sie löschen möchten',
98 | preview: 'Vorschau',
99 | rename: 'Datei umbenennen',
100 | newFile: 'Neuer Dateiname',
101 | createFolder: 'Ordner erstellen',
102 | foldername: 'Ordnername',
103 | current: 'Aktuell',
104 | overall: 'Insgesamt',
105 | uploading: 'Hochladen',
106 | moveError: 'Fehler beim Verschieben',
107 | deleteError: 'Löschfehler',
108 | folderExists: 'Ordner existiert bereits',
109 | folderCreate: 'Ordner erstellen abgeschlossen...',
110 | folderError: 'Fehler beim Erstellen des Ordners',
111 | uploadError: 'Fehler beim Hochladen',
112 | fileExists: 'Datei existiert bereits!',
113 | },
114 | message: {
115 | savePreset: 'Voreinstellung speichern',
116 | newPreset: 'Neue Voreinstellung',
117 | delPreset: 'Voreinstellung löschen',
118 | delText: 'Sind Sie sicher, dass Sie die Voreinstellung löschen möchten',
119 | placeholder: 'Nachricht',
120 | xAxis: 'X-Achse',
121 | yAxis: 'Y-Achse',
122 | showBox: 'Box anzeigen',
123 | boxColor: 'Boxfarbe',
124 | boxAlpha: 'Box-Transparenz',
125 | size: 'Größe',
126 | spacing: 'Abstand',
127 | overallAlpha: 'Gesamttransparenz',
128 | fontColor: 'Schriftfarbe',
129 | fontAlpha: 'Schrifttransparenz',
130 | borderWidth: 'Rahmenbreite',
131 | send: 'Senden',
132 | name: 'Name',
133 | saveDone: 'Voreinstellung gespeichert!',
134 | saveFailed: 'Voreinstellung speichern fehlgeschlagen!',
135 | sendDone: 'Erfolgreich gesendet...',
136 | sendFailed: 'Senden fehlgeschlagen...',
137 | },
138 | log: {
139 | download: 'Protokoll herunterladen',
140 | },
141 | advanced: {
142 | title: 'Advanced Configuration',
143 | decoder: 'Decoder',
144 | encoder: 'Encoder',
145 | filter: 'Filter',
146 | ingest: 'Ingest',
147 | updateSuccess: 'Update advanced config success!',
148 | updateFailed: 'Update advanced config failed!',
149 | warning: 'Warning! These settings are experimental and only intended for advanced users who are familiar with ffmpeg. Only change the settings here if you are sure of what you are doing! The settings can make the system unstable.',
150 | },
151 | config: {
152 | channel: 'Kanal',
153 | user: 'Benutzer',
154 | channelConf: 'Kanal-Konfiguration',
155 | addChannel: 'Neuen Kanal hinzufügen',
156 | name: 'Name',
157 | previewUrl: 'Vorschau-URL',
158 | extensions: 'Zusätzliche Erweiterungen',
159 | save: 'Speichern',
160 | delete: 'Löschen',
161 | updateChannelSuccess: 'Kanal-Konfiguration erfolgreich aktualisiert!',
162 | updateChannelFailed: 'Fehler beim Aktualisieren der Kanal-Konfiguration!',
163 | errorChannelDelete: 'Der erste Kanal kann nicht gelöscht werden!',
164 | deleteChannelSuccess: 'Kanal-Konfiguration erfolgreich gelöscht!',
165 | deleteChannelFailed: 'Fehler beim Löschen der Kanal-Konfiguration!',
166 | playoutConf: 'Playout-Konfiguration',
167 | general: 'Allgemein',
168 | rpcServer: 'RPC Server',
169 | mail: 'EMail',
170 | logging: 'Protokollierung',
171 | processing: 'Verarbeitung',
172 | ingest: 'Live-Eingang',
173 | playlist: 'Wiedergabeliste',
174 | storage: 'Speicher',
175 | text: 'Text',
176 | task: 'Aufgabe',
177 | output: 'Ausgabe',
178 | placeholderPass: 'Passwort',
179 | help: 'Hilfe',
180 | generalText: `Manchmal kann es vorkommen, dass eine Datei beschädigt, aber noch abspielbar ist, was einen Streaming-Fehler bei allen folgenden Dateien verursachen kann. Die einzige Möglichkeit, dies zu beheben, besteht darin, ffplayout anzuhalten und neu zu starten. Wir sagen hier nur, wann es gestoppt werden muss, der Startvorgang ist Ihnen überlassen. Der beste Weg ist ein systemd-Dienst unter Linux.
181 | 'stop_threshold' wird ffplayout stoppen, wenn es zeitlich über diesem Wert liegt. Eine Zahl kleiner als 3 kann zu unerwarteten Fehlern führen.`,
182 | rpcText:
183 | 'Führe einen JSON-RPC-Server aus, um Informationen über die Wiedergabe und einige Kontrollfunktionen zu erhalten.',
184 | mailText: `Senden Sie Fehlermeldungen an die E-Mail-Adresse, z. B. fehlende Playlist, ungültiges json-Format, fehlender Clip-Pfad. Lassen Sie den Empfänger leer, wenn Sie keine Benachrichtigung benötigen. 'mail_level' kann INFO, WARNING oder ERROR sein. 'interval' bedeutet Sekunden, bis eine neue E-Mail gesendet wird.`,
185 | logText: `Wenn 'log_to_file' true ist, wird in eine Datei protokolliert, wenn false, in die Konsole. 'local_time' auf false setzt die Log-Zeitstempel auf UTC. Pfad zu /var/log/ nur, wenn Sie dies als Daemon ausführen.
186 | 'level' kann DEBUG, INFO, WARNING, ERROR sein. 'ffmpeg_level' kann INFO, WARNING, ERROR sein. 'detect_silence' protokolliert eine Fehlermeldung, wenn die Audiospur während des Validierungsprozesses 15 Sekunden lang still ist.`,
187 | processingText: `Standardverarbeitung für alle Clips, um sie einheitlich zu machen. Modus kann "playlist" oder "folder" sein. 'aspect' muss eine Fließkommazahl sein. 'logo' wird nur verwendet, wenn der Pfad existiert.
188 | 'logo_scale' skaliert das Logo auf die Zielgröße, leer lassen, wenn keine Skalierung erforderlich ist, Format ist 'width:height', zum Beispiel '100:-1' für proportionale Skalierung. Mit 'logo_opacity' können Sie das Logo transparent machen.
189 | Mit 'audio_tracks' kann man einstellen, wie viele Audiospuren verarbeitet werden sollen. 'audio_channels' kann verwendet werden, wenn das Audio mehr Kanäle als nur Stereo hat. Mit 'logo_position' im Format 'x:y' wird die Position des Logos festgelegt. Mit 'custom_filter' ist es möglich, zusätzliche Filter anzuwenden. Die Filterausgänge sollten mit [c_v_out] für Videofilter und [c_a_out] für Audiofilter enden.`,
190 | ingestText: `Startet einen Server für einen Live-Eingangsstream. Dieser Stream hat Vorrang vor dem normalen Streaming, bis er fertig ist. Es gibt nur einen sehr einfachen Authentifizierungsmechanismus, um zu prüfen, ob der Streamname korrekt ist. 'custom_filter' kann auf die gleiche Weise wie im Abschnitt Verarbeitung verwendet werden.`,
191 | playlistText: `'path' kann ein Pfad zu einer einzelnen Datei oder einem Verzeichnis sein. Bei Verzeichnissen geben Sie nur das Stammverzeichnis an, z. B. '/playlists', Unterverzeichnisse werden vom Program gelesen. Unterverzeichnisse benötigen diese Struktur '/playlists/2018/01'.
192 | 'day_start' ist die Uhrzeit, zu der die Wiedergabeliste beginnen soll; lassen Sie 'day_start' leer, wenn die Wiedergabeliste immer am Anfang beginnen soll. 'length' steht für die Ziellänge der Wiedergabeliste; wenn leer, wird die tatsächliche Länge nicht berücksichtigt. 'infinit: true' arbeitet mit einer einzelnen Wiedergabelistendatei und spielt diese in einer Endlosschleife.`,
193 | storageText: `Spielt geordnete oder zufällige Dateien aus dem Pfad ab. 'filler_clip' ist zum Füllen des Endes, um 24 Stunden zu erreichen, es wird eine Schleife abgespielt, wenn nötig. Setzen Sie 'extensions', um nur nach Dateien mit dieser Erweiterung zu suchen. Setzen Sie 'shuffle' auf 'true', um Dateien zufällig auszuwählen.`,
194 | textText: `Überlagernder Text in Kombination mit libzmq für die Remote-Textmanipulation. Unter Windows muss der Pfad der Schriftartdatei 'C\\:/WINDOWS/fonts/DejaVuSans.ttf' sein. 'text_from_filename' aktiviert die Textextraktion aus einem Dateinamen. Mit 'style' können Sie die Zeichentext-Parameter wie Position, Farbe, etc. festlegen. Post Text via API wird dies überschreiben. Mit 'regex' können Sie den Dateinamen formatieren, um einen Titel zu erhalten.`,
195 | taskText: `Führt ein externes Programm mit einem bestimmten Medienobjekt aus. Das Medienobjekt liegt im json-Format vor und enthält alle Informationen über den aktuellen Clip. Das externe Programm kann ein Skript oder eine Binärdatei sein. oder eine Binärdatei, sollte aber nur für kurze Zeit laufen.`,
196 | outputText: `Die endgültige Playout-Kompression. Passen Sie die Einstellungen entsprechend Ihren Bedürfnissen an. 'mode' hat die Optionen 'desktop', 'hls', 'null', 'stream'. Verwenden Sie 'stream' und passen Sie die 'output_param:'-Einstellungen an, wenn Sie zu einem rtmp/rtsp/srt/... Server streamen wollen. In der Produktion sollten Sie die hls-Wiedergabeliste nicht mit ffpapi ausliefern, sondern nginx oder einen anderen Webserver verwenden!`,
197 | restartTile: 'Playout neustarten',
198 | restartText: 'ffplayout neustarten um Einstellungen anzuwenden?',
199 | updatePlayoutSuccess: 'Update der Playout-Konfiguration erfolgreich!',
200 | updatePlayoutFailed: 'Update playout config fehlgeschlagen!',
201 | forbiddenPlaylistPath: 'Zugriff untersagt: Playlist-Ordner kann nicht geöffnet werden.',
202 | noPlayoutConfig: 'Keine Playout-Konfiguration gefunden!',
203 | hlsPath: 'HLS-Pfad',
204 | playlistPath: 'Wiedergabelistenpfad',
205 | storagePath: 'Speicherpfad',
206 | sharedStorage: 'Gemeinsamer Speicher ist aktiviert, verwende denselben Speicherstamm für alle Kanäle!',
207 | },
208 | user: {
209 | title: 'Benutzer-Konfiguration',
210 | add: 'Benutzer hinzufügen',
211 | delete: 'Löschen',
212 | name: 'Benutzername',
213 | mail: 'E-Mail',
214 | password: 'Passwort',
215 | newPass: 'Neues Passwort',
216 | confirmPass: 'Passwort bestätigen',
217 | save: 'Speichern',
218 | admin: 'Administrator',
219 | deleteNotPossible: 'Löschen des aktuellen Benutzers nicht möglich!',
220 | deleteSuccess: 'Benutzer erfolgreich gelöscht!',
221 | deleteError: 'Fehler beim Löschen des Benutzers',
222 | addSuccess: 'Benutzer erfolgreich hinzugefügt!',
223 | addFailed: 'Fehler beim Hinzufügen des Benutzers!',
224 | mismatch: 'Passwort stimmt nicht überein!',
225 | updateSuccess: 'Benutzerprofil erfolgreich aktualisiert!',
226 | updateFailed: 'Fehler beim Aktualisieren des Benutzerprofils!',
227 | },
228 | }
229 |
--------------------------------------------------------------------------------
/i18n/locales/en-US.js:
--------------------------------------------------------------------------------
1 | export default {
2 | ok: 'Ok',
3 | cancel: 'Cancel',
4 | socketConnected: 'Event stream connected',
5 | socketDisconnected: 'Event stream disconnected',
6 | alert: {
7 | wrongLogin: 'Incorrect login data!',
8 | },
9 | button: {
10 | login: 'Login',
11 | home: 'Home',
12 | player: 'Player',
13 | media: 'Media',
14 | message: 'Message',
15 | logging: 'Logging',
16 | channels: 'Channels',
17 | configure: 'Configure',
18 | logout: 'Logout',
19 | },
20 | error: {
21 | notFound: 'Page not found',
22 | serverError: 'Internal server error',
23 | },
24 | input: {
25 | username: 'Username',
26 | password: 'Password',
27 | },
28 | system: {
29 | cpu: 'CPU',
30 | cores: 'Cores',
31 | load: 'Load',
32 | memory: 'Memory',
33 | swap: 'Swap',
34 | total: 'Total',
35 | usage: 'Usage',
36 | network: 'Network',
37 | in: 'In',
38 | out: 'Out',
39 | storage: 'Storage',
40 | device: 'Device',
41 | size: 'Size',
42 | used: 'Used',
43 | },
44 | control: {
45 | noClip: 'No clip is playing',
46 | ingest: 'Live Ingest',
47 | start: 'Start Playout Service',
48 | last: 'Jump to last Clip',
49 | stop: 'Stop Playout Service',
50 | reset: 'Reset Playout State',
51 | restart: 'Restart Playout Service',
52 | next: 'Jump to next Clip',
53 | },
54 | player: {
55 | start: 'Start',
56 | file: 'File',
57 | play: 'Play',
58 | title: 'Title',
59 | duration: 'Duration',
60 | in: 'In',
61 | out: 'Out',
62 | ad: 'Ad',
63 | edit: 'Edit',
64 | delete: 'Delete',
65 | copy: 'Copy Playlist',
66 | loop: 'Loop Clips in Playlist',
67 | remote: 'Add (remote) Source to Playlist',
68 | import: 'Import text/m3u file',
69 | generate: 'Simple and advanced playlist generator',
70 | reset: 'Reset Playlist',
71 | save: 'Save Playlist',
72 | deletePlaylist: 'Delete Playlist',
73 | unsavedProgram: 'There is a program that is not saved!',
74 | copyTo: 'Copy current Program to',
75 | addEdit: 'Add/Edit Source',
76 | audio: 'Audio',
77 | customFilter: 'Custom Filter',
78 | deleteFrom: 'Delete program from',
79 | deleteSuccess: 'Playlist deleted...',
80 | generateProgram: 'Generate Program',
81 | simple: 'Simple',
82 | advanced: 'Advanced',
83 | sorted: 'Sorted',
84 | shuffle: 'Shuffle',
85 | shift: 'Shift',
86 | all: 'All',
87 | addBlock: 'Add time block',
88 | infinitInfo: 'Playout runs in infinite mode. No time based information is possible.',
89 | generateDone: 'Generate Playlist done...',
90 | dateYesterday: 'Current time is before the playlist start time!',
91 | },
92 | media: {
93 | notExists: 'Storage not exist!',
94 | create: 'Create Folder',
95 | upload: 'Upload Files',
96 | deleteTitle: 'Delete File/Folder',
97 | deleteQuestion: 'Are you sure that you want to delete',
98 | preview: 'Preview',
99 | rename: 'Rename File',
100 | newFile: 'New filename',
101 | createFolder: 'Create Folder',
102 | foldername: 'Foldername',
103 | current: 'Current',
104 | overall: 'Overall',
105 | uploading: 'Uploading',
106 | moveError: 'Move error',
107 | deleteError: 'Delete error',
108 | folderExists: 'Folder exists already',
109 | folderCreate: 'Folder create done...',
110 | folderError: 'Folder create error',
111 | uploadError: 'Upload error',
112 | fileExists: 'File exists already!',
113 | },
114 | message: {
115 | savePreset: 'Save Preset',
116 | newPreset: 'New Preset',
117 | delPreset: 'Delete Preset',
118 | delText: 'Are you sure that you want to delete preset',
119 | placeholder: 'Message',
120 | xAxis: 'X Axis',
121 | yAxis: 'Y Axis',
122 | showBox: 'Show Box',
123 | boxColor: 'Box Color',
124 | boxAlpha: 'Box Alpha',
125 | size: 'Size',
126 | spacing: 'Spacing',
127 | overallAlpha: 'Overall Alpha',
128 | fontColor: 'Font Color',
129 | fontAlpha: 'Font Alpha',
130 | borderWidth: 'Border Width',
131 | send: 'Send',
132 | name: 'Name',
133 | saveDone: 'Save Preset done!',
134 | saveFailed: 'Save Preset failed!',
135 | sendDone: 'Sending success...',
136 | sendFailed: 'Sending failed...',
137 | },
138 | log: {
139 | download: 'Download log file',
140 | },
141 | advanced: {
142 | title: 'Advanced Configuration',
143 | decoder: 'Decoder',
144 | encoder: 'Encoder',
145 | filter: 'Filter',
146 | ingest: 'Ingest',
147 | updateSuccess: 'Update advanced config success!',
148 | updateFailed: 'Update advanced config failed!',
149 | warning: 'Warning! These settings are experimental and only intended for advanced users who are familiar with ffmpeg. Only change the settings here if you are sure of what you are doing! The settings can make the system unstable.',
150 | },
151 | config: {
152 | channel: 'Channel',
153 | user: 'User',
154 | channelConf: 'Channel Configuration',
155 | addChannel: 'Add new Channel',
156 | name: 'Name',
157 | previewUrl: 'Preview URL',
158 | extensions: 'Extra Extensions',
159 | save: 'Save',
160 | delete: 'Delete',
161 | updateChannelSuccess: 'Update channel config success!',
162 | updateChannelFailed: 'Update channel config failed!',
163 | errorChannelDelete: 'First channel can not be deleted!',
164 | deleteChannelSuccess: 'Delete channel config success!',
165 | deleteChannelFailed: 'Delete channel config failed!',
166 | playoutConf: 'Playout Configuration',
167 | general: 'General',
168 | rpcServer: 'RPC Server',
169 | mail: 'Email',
170 | logging: 'Logging',
171 | processing: 'Processing',
172 | ingest: 'Ingest',
173 | playlist: 'Playlist',
174 | storage: 'Storage',
175 | text: 'Text',
176 | task: 'Task',
177 | output: 'Output',
178 | placeholderPass: 'Password',
179 | help: 'Help',
180 | generalText: `Sometimes it can happen that a file is corrupted but still playable, this can cause a streaming error on all following files. The only way to fix this is to stop and restart ffplayout. Here we only say when to stop, the starting process is up to you. The best way is a systemd service on Linux.
181 | 'stop_threshold' will stop ffplayout if it is async in time above this value. A number less than 3 may cause unexpected errors.`,
182 | rpcText: 'Run a JSON RPC server to get information about what is playing and for some control functions.',
183 | mailText: `Send error messages to the email address, such as missing playlist; invalid json format; missing clip path. Leave the recipient blank if you don't need it. 'mail_level' can be INFO, WARNING or ERROR. 'interval' means seconds until a new mail is sent.`,
184 | logText: `If 'log_to_file' is true, log to file, if false, log to console. 'local_time' to false will set log timestamps to UTC. Path to /var/log/ only if you are running this as a daemon.
185 | 'level' can be DEBUG, INFO, WARNING, ERROR. 'ffmpeg_level' can be INFO, WARNING, ERROR. 'detect_silence' logs an error message if the audio line is silent for 15 seconds during the validation process.`,
186 | processingText: `Default processing for all clips to make them unique. Mode can be Playlist or Folder. 'aspect' must be a float number. 'logo' is only used if the path exists.
187 | 'logo_scale' scales the logo to the target size, leave empty if no scaling is needed, format is 'width:height', for example '100:-1' for proportional scaling. With 'logo_opacity' you can make the logo transparent.
188 | With 'audio_tracks' it is possible to configure how many audio tracks should be processed. 'audio_channels' can be used if the audio has more channels than just stereo. With 'logo_position' in 'x:y' format you set the logo position. With 'custom_filter' it is possible to apply additional filters. The filter outputs should end with [c_v_out] for video filters and [c_a_out] for audio filters.`,
189 | ingestText: `Run a server for an ingest stream. This stream will override the normal streaming until it is done. There is only a very simple authentication mechanism to check if the stream name is correct. 'custom_filter' can be used in the same way as in the process section.`,
190 | playlistText: `'path' can be a path to a single file or a directory. For directory specify only the root folder, for example '/playlists', subdirectories will be read by the program. Subdirectories need this structure '/playlists/2018/01'.
191 | 'day_start' is the time at which the playlist should start, leave 'day_start' empty if the playlist should always start at the beginning. 'length' represents the target length of the playlist, if empty, real length will not be considered. 'infinit: true' works with single playlist file and loops it infinitely.`,
192 | storageText: `Play ordered or random files from path. 'filler_clip' is for filling the end to reach 24 hours, it will loop when necessary. Set 'extensions' to search only for files with that extension. Set 'shuffle' to 'true' to select files randomly.`,
193 | textText: `Overlay text in combination with libzmq for remote text manipulation. On Windows, the font file path must be 'C\\:/WINDOWS/fonts/DejaVuSans.ttf'. 'text_from_filename' activates text extraction from a filename. With 'style' you can set the drawtext parameters like position, color, etc. Post Text via API will override this. With 'regex' you can format the filename to get a title.`,
194 | taskText: `Run an external program with a given media object. The media object is in json format and contains all the information about the current clip. The external program can be a script or a binary. or a binary, but should only run for a short time.`,
195 | outputText: `The final playout compression. Adjust the settings according to your needs. 'mode' has the options 'desktop', 'hls', 'null', 'stream'. Use 'stream' and adjust the 'output_param:' settings if you want to stream to an rtmp/rtsp/srt/... server. In production don't serve hls playlist with ffpapi, use nginx or another web server!`,
196 | restartTile: 'Restart Playout',
197 | restartText: 'Restart ffplayout to apply changes?',
198 | updatePlayoutSuccess: 'Update playout config success!',
199 | updatePlayoutFailed: 'Update playout config failed!',
200 | forbiddenPlaylistPath: 'Access forbidden: Playlist folder cannot be opened.',
201 | noPlayoutConfig: 'No playout config found!',
202 | hlsPath: 'HLS Path',
203 | playlistPath: 'Playlist Path',
204 | storagePath: 'Storage Path',
205 | sharedStorage: 'Shared storage is enabled, use the same storage root for all channels!',
206 | },
207 | user: {
208 | title: 'User Configuration',
209 | add: 'Add User',
210 | delete: 'Delete',
211 | name: 'Username',
212 | mail: 'Email',
213 | password: 'Password',
214 | newPass: 'New Password',
215 | confirmPass: 'Confirm Password',
216 | save: 'Save',
217 | admin: 'Admin',
218 | deleteNotPossible: 'Delete current user not possible!',
219 | deleteSuccess: 'Delete user done!',
220 | deleteError: 'Delete user error',
221 | addSuccess: 'Add user success!',
222 | addFailed: 'Add user failed!',
223 | mismatch: 'Password mismatch!',
224 | updateSuccess: 'Update user profile success!',
225 | updateFailed: 'Update user profile failed!',
226 | },
227 | }
228 |
--------------------------------------------------------------------------------
/i18n/locales/pt-BR.js:
--------------------------------------------------------------------------------
1 | export default {
2 | ok: 'Ok',
3 | cancel: 'Cancelar',
4 | socketConnected: 'Aviso! stream conectada.',
5 | socketDisconnected: 'Aviso! stream desconectado.',
6 | alert: {
7 | wrongLogin: 'Dados incorretos!',
8 | },
9 | button: {
10 | login: 'Logar',
11 | home: 'Início',
12 | player: 'Player',
13 | media: 'Armazenamento',
14 | message: 'Legenda',
15 | logging: 'Registro',
16 | channels: 'Canais',
17 | configure: 'Configurar',
18 | logout: 'Sair',
19 | },
20 | error: {
21 | notFound: 'Página não encontrada',
22 | serverError: 'Erro do servidor interno',
23 | },
24 | input: {
25 | username: 'Usuário',
26 | password: 'Senha',
27 | },
28 | system: {
29 | cpu: 'CPU',
30 | cores: 'Núcleos',
31 | load: 'Carga de CPU',
32 | memory: 'Memória',
33 | swap: 'Swap',
34 | total: 'Total',
35 | usage: 'Uso',
36 | network: 'Rede',
37 | in: 'Entrada',
38 | out: 'Saída',
39 | storage: 'Armazenamento',
40 | device: 'Dispositivo',
41 | size: 'Tamanho total',
42 | used: 'Disponível',
43 | },
44 | control: {
45 | noClip: 'Nenhum clipe está sendo reproduzido',
46 | ingest: 'Ingestão ao Vivo',
47 | start: 'Iniciar Serviço do Playout',
48 | last: 'Ir para o último Clipe',
49 | stop: 'Parar Serviço do Playout',
50 | reset: 'Redefinir Estado do Playout',
51 | restart: 'Reiniciar Serviço do Playout',
52 | next: 'Ir para o próximo Clipe',
53 | },
54 | player: {
55 | start: 'Horário',
56 | file: 'Arquivo',
57 | play: 'Play',
58 | title: 'Título',
59 | duration: 'Duração',
60 | in: 'Início',
61 | out: 'Fim',
62 | ad: 'Ad',
63 | edit: 'Editar',
64 | delete: 'Deletar',
65 | copy: 'Copiar playlist',
66 | loop: 'Repetir Clipes na Playlist',
67 | remote: 'Adicionar fonte (remota) à Playlist',
68 | import: 'Importar arquivo de texto/.m3u8',
69 | generate: 'Gerador de Playlist simples e avançado',
70 | reset: 'Resetar Playlist',
71 | save: 'Salvar Playlist',
72 | deletePlaylist: 'Deletar Playlist',
73 | unsavedProgram: 'Existe uma Programação que não está salva!',
74 | copyTo: 'Copiar Programação atual para',
75 | addEdit: 'Adicionar/Editar Fonte',
76 | audio: 'Áudio',
77 | customFilter: 'Filtro Personalizado',
78 | deleteFrom: 'Excluir programação de',
79 | deleteSuccess: 'Lista de reprodução excluída...',
80 | generateProgram: 'Gerar Programação',
81 | simple: 'Simples',
82 | advanced: 'Avançado',
83 | sorted: 'Ordenado',
84 | shuffle: 'Aleatório',
85 | shift: 'Diferença horária',
86 | all: 'Todos',
87 | addBlock: 'Adicionar bloco de tempo',
88 | infinitInfo: 'O playout é executado no modo infinito. Nenhuma informação baseada em tempo é possível',
89 | generateDone: 'Gerar lista de reprodução concluída...',
90 | dateYesterday: 'A hora atual é anterior à hora de início da lista de reprodução!',
91 | },
92 | media: {
93 | notExists: 'O armazenamento não existe!',
94 | create: 'Criar Pasta',
95 | upload: 'Enviar Arquivos',
96 | deleteTitle: 'Deletar Arquivo/Pasta',
97 | deleteQuestion: 'Tem certeza que deseja deletar?',
98 | preview: 'Visualizar',
99 | rename: 'Renomear Arquivo',
100 | newFile: 'Novo nome de arquivo',
101 | createFolder: 'Criar Pasta',
102 | foldername: 'Nome da Pasta',
103 | current: 'Atual',
104 | overall: 'Total',
105 | uploading: 'Enviando',
106 | moveError: 'Erro ao mover',
107 | deleteError: 'Erro ao deletar!',
108 | folderExists: 'A pasta já existe',
109 | folderCreate: 'Criação da pasta concluída...',
110 | folderError: 'Erro ao criar pasta',
111 | uploadError: 'Erro ao carregar',
112 | fileExists: 'O arquivo já existe!',
113 | },
114 | message: {
115 | savePreset: 'Salvar predefinição',
116 | newPreset: 'Nova predefinição',
117 | delPreset: 'Excluir predefinição',
118 | delText: 'Tem certeza de que deseja excluir a predefinição?',
119 | placeholder: 'Mensagem',
120 | xAxis: 'Eixo X',
121 | yAxis: 'Eixo Y',
122 | showBox: 'Mostrar caixa',
123 | boxColor: 'Cor da caixa',
124 | boxAlpha: 'Caixa Alfa',
125 | size: 'Tamanho',
126 | spacing: 'Espaçamento',
127 | overallAlpha: 'Alfa geral',
128 | fontColor: 'Cor da fonte',
129 | fontAlpha: 'Fonte Alfa',
130 | borderWidth: 'Largura da borda',
131 | send: 'Enviar',
132 | name: 'Nome',
133 | saveDone: 'Salvar predefinição concluída!',
134 | saveFailed: 'Falha ao salvar a predefinição!',
135 | sendDone: 'Enviando com sucesso...',
136 | sendFailed: 'O envio falhou...',
137 | },
138 | log: {
139 | download: 'Baixar arquivo de registro',
140 | },
141 | advanced: {
142 | title: 'Configurações avançadas',
143 | decoder: 'Decoder',
144 | encoder: 'Encoder',
145 | filter: 'Filter',
146 | ingest: 'Ingest',
147 | updateSuccess: 'Configurações avançadas salva!',
148 | updateFailed: 'Configurações avançadas foi falhado!',
149 | warning: 'Aviso! Essas configurações são experimentais e destinadas apenas a usuários avançados familiarizados com o ffmpeg. Altere as configurações aqui apenas se tiver certeza do que está fazendo! As configurações podem tornar o sistema instável.',
150 | },
151 | config: {
152 | channel: 'Canal',
153 | user: 'Usuário',
154 | channelConf: 'Configuração do Canal',
155 | addChannel: 'Adicionar novo Canal',
156 | name: 'Nome',
157 | previewUrl: 'URL de Visualização',
158 | extensions: 'Extensões Extras',
159 | save: 'Salvar',
160 | delete: 'Deletar',
161 | updateChannelSuccess: 'Atualização da configuração do canal bem-sucedida!',
162 | updateChannelFailed: 'Falha na atualização da configuração do canal!',
163 | errorChannelDelete: 'O primeiro canal não pode ser deletado!',
164 | deleteChannelSuccess: 'Exclusão da configuração da canal bem-sucedida!',
165 | deleteChannelFailed: 'Falha na exclusão da configuração da canal!',
166 | playoutConf: 'Configuração de Playout',
167 | general: 'Geral',
168 | rpcServer: 'RPC Server',
169 | mail: 'Email',
170 | logging: 'Registro',
171 | processing: 'Processamento',
172 | ingest: 'Ingestão',
173 | playlist: 'Playlist',
174 | storage: 'Armazenamento',
175 | text: 'Texto',
176 | task: 'Tarefa',
177 | output: 'Saída',
178 | placeholderPass: 'Senha',
179 | help: 'Ajuda',
180 | generalText: `Às vezes pode acontecer que um arquivo esteja corrompido mas ainda assim ele pode ser reproduzido, isso pode causar um erro de transmissão em todos os arquivos seguintes. A única maneira de corrigir isso é parar e reiniciar o ffplayout. Aqui só dizemos quando parar, o processo de início é por sua conta. A melhor maneira é um serviço systemd no Linux.
181 | 'stop_threshold' vai parar o ffplayout se estiver assíncrono em um tempo acima deste valor. Um número menor que 3 pode causar erros inesperados.`,
182 | rpcText: 'Execute um servidor JSON RPC para obter informações sobre o que está sendo reproduzido e para algumas funções de controle.',
183 | mailText: `Envie mensagens de erro para o endereço de email, como lista de reprodução faltando; formato JSON inválido; caminho do clipe ausente. Deixe o destinatário em branco se não for necessário. 'mail_level' pode ser INFO, WARNING ou ERROR. 'interval' é o tempo em segundos até que um novo e-mail seja enviado.`,
184 | logText: `Se 'log_to_file' estiver ativado (true), o registro de log será salvo em um arquivo de texto, e se desativado (false), registrará o log no console. Se 'local_time' estiver desativado (false) o sistema definirá os carimbos de data/hora do registro para UTC. Defina o caminho para /var/log/ apenas se você estiver executando o programa como daemon.
185 | 'level' pode ser DEBUG, INFO, WARNING, ERROR. 'ffmpeg_level' pode ser INFO, WARNING, ERROR. 'detect_silence' registra uma mensagem de erro se a linha de áudio ficar silenciosa por 15 segundos durante o processo de validação.`,
186 | processingText: `Processamento padrão para todos os clipes para torná-los únicos. O modo ('mode') pode ser Playlist ou Folder. 'aspect' deve ser um número de ponto flutuante. 'logo' é usado apenas se o caminho existir.
187 | 'logo_scale' dimensiona o logo para o tamanho desejado, deixe esse campo de configuração vazio se nenhum dimensionamento for necessário, o formato é 'largura:altura', por exemplo '100:-1' para dimensionamento proporcional. Com 'logo_opacity' você pode tornar o logo transparente.
188 | Com 'audio_tracks' é possível configurar quantas faixas de áudio devem ser processadas. 'audio_channels' pode ser usado se o áudio tiver mais canais do que apenas estéreo. Com 'logo_position' no formato 'x:y' você define a posição do logo. Com 'custom_filter' é possível aplicar filtros adicionais. As saídas do filtro devem terminar com [c_v_out] para filtros de vídeo e [c_a_out] para filtros de áudio.`,
189 | ingestText: `Execute um servidor de ingestão para poder receber um fluxo de stream a partir de uma fonte externa, como por exemplo um software de streaming como o OBS Studio. Este stream substituirá o streaming normal até que seja concluído. Existe apenas um mecanismo de autenticação muito simples para verificar se o nome do stream está correto. 'custom_filter' pode ser usado da mesma forma que na seção de processo.`,
190 | playlistText: `'path' é o caminho para o arquivo de playlist. 'path' pode ser um caminho para um único arquivo ou um diretório. Se um diretório for especificado, defina apenas a pasta raiz desse diretório, por exemplo '/playlists', subdiretórios serão lidos pelo programa. Subdiretórios precisam seguir a seguinte estrutura de diretórios: '/playlists/2018/01'.
191 | 'day_start' é o horário fixo, inicial, em que a playlist será reproduzida, deixe 'day_start' vazio se a lista de reprodução sempre deve começar do início. 'length' representa a duração desejada da playlist, se vazio, a duração real não será considerada. 'infinit: true' funciona com um arquivo de lista de reprodução único e o repete infinitamente.`,
192 | storageText: `Reproduza arquivos de mídia de maneira ordenada ou aleatória a partir de um caminho de diretório ('path') especificado. 'filler_clip' define um "clipe de preenchimento", cuja função é preencher a lacuna de tempo de uma playlist com duração inferior a 24 horas completas, esse clipe ou conjunto de clipes também será repetido quando algum arquivo de mídia não puder ser reproduzido, quando estiver indisponível ou se nenhuma playlist válida estiver sendo reproduzida. Defina 'extensions' para delimitar a busca interna de arquivos de mídia apenas por arquivos com a extensão adicionada. Defina 'shuffle' como 'true' para selecionar arquivos aleatoriamente.`,
193 | textText: `Sobreponha texto (legenda) em combinação com o libzmq, para manipulação remota de texto. No Windows, o caminho do arquivo de fonte deve ser 'C\\:/WINDOWS/fonts/DejaVuSans.ttf'. 'text_from_filename' ativa a extração de texto (legenda) a partir de um arquivo de texto especificado. Com 'style' você pode definir os parâmetros drawtext como posição, cor, etc. Postar Texto via API irá substituir isso. Com 'regex' você pode formatar o nome do arquivo para obter um título.`,
194 | taskText: `Execute um programa externo em conjunto com um determinado objeto de mídia. O objeto de mídia está no formato JSON e contém todas as informações sobre o clipe atual. O programa externo pode ser um script ou um binário. ou um binário, mas deve ser executado apenas por um curto período de tempo.`,
195 | outputText: `A compressão final do stream gerado pelo playout. Ajuste as configurações de acordo com suas necessidades. 'mode' possui as opções 'desktop', 'hls', 'null', 'stream'. Use 'stream' e ajuste as configurações de 'output_param:' se você desejar retransmitir o stream para um servidor rtmp/rtsp/srt/... Em ambiente de produção não sirva a playlist hls com ffpapi, use nginx ou outro servidor web!`,
196 | restartTile: 'Reiniciar Playout',
197 | restartText: 'Reiniciar o ffplayout para aplicar as alterações?',
198 | updatePlayoutSuccess: 'Sucesso na atualização da configuração do playout!',
199 | updatePlayoutFailed: 'Falha na atualização da configuração do playout!',
200 | forbiddenPlaylistPath: 'Acesso proibido: A pasta da lista de reprodução não pode ser aberta',
201 | noPlayoutConfig: 'Nenhuma configuração de playout encontrada!',
202 | hlsPath: 'HLS Path',
203 | playlistPath: 'Playlist Path',
204 | storagePath: 'Storage Path',
205 | sharedStorage: 'O armazenamento compartilhado está ativado, use a mesma raiz de armazenamento para todos os canais',
206 | },
207 | user: {
208 | title: 'Configuração de usuário',
209 | add: 'Adicionar usuário',
210 | delete: 'Deletar',
211 | name: 'Nome de usuário',
212 | mail: 'Email',
213 | password: 'Senha',
214 | newPass: 'Nova Senha',
215 | confirmPass: 'Confirmar Senha',
216 | save: 'Salvar',
217 | admin: 'Administrador',
218 | deleteNotPossible: 'Excluir o usuário atual não é possível!',
219 | deleteSuccess: 'Usuário deletado com sucesso!',
220 | deleteError: 'Erro ao deletar usuário',
221 | addSuccess: 'Usuário adicionado com sucesso!',
222 | addFailed: 'Falha ao adicionar usuário!',
223 | mismatch: 'Senhas não coincidem!',
224 | updateSuccess: 'Atualização do perfil do usuário bem-sucedida! ',
225 | updateFailed: 'Atualização do perfil do usuário falhou!',
226 | },
227 | }
228 |
--------------------------------------------------------------------------------
/i18n/locales/ru-RU.js:
--------------------------------------------------------------------------------
1 | export default {
2 | ok: 'ОК',
3 | cancel: 'Отмена',
4 | socketConnected: 'Event stream connected',
5 | socketDisconnected: 'Event stream disconnected',
6 | alert: {
7 | wrongLogin: 'Неверные данные для входа!',
8 | },
9 | button: {
10 | login: 'Логин',
11 | home: 'Домашняя страница',
12 | player: 'Плеер',
13 | media: 'Файлы',
14 | message: 'Сообщение',
15 | logging: 'Логи',
16 | channels: 'Каналы',
17 | configure: 'Конфигурация',
18 | logout: 'Выйти',
19 | },
20 | error: {
21 | notFound: 'Страница не найдена',
22 | serverError: 'Внутреняя серверная ошибка',
23 | },
24 | input: {
25 | username: 'Логин',
26 | password: 'Пароль',
27 | },
28 | system: {
29 | cpu: 'Процессор',
30 | cores: 'Ядра',
31 | load: 'Нагрузка',
32 | memory: 'Оперативная память',
33 | swap: 'Swap',
34 | total: 'Всего',
35 | usage: 'Используется',
36 | network: 'Интернет',
37 | in: 'Прием',
38 | out: 'Отдача',
39 | storage: 'Хранилище',
40 | device: 'Устройство',
41 | size: 'Размер',
42 | used: 'Использовано',
43 | },
44 | control: {
45 | noClip: 'На данный момент ни один файл не воспроизводится',
46 | ingest: 'Прямой эфир/Перехват эфира',
47 | start: 'Запустить Playout Service',
48 | last: 'Переключить на предыдущий файл',
49 | stop: 'Остановить Playout Service',
50 | reset: 'Сбросить Playout State',
51 | restart: 'Перезапустить Playout Service',
52 | next: 'Переключить на следующий файл',
53 | },
54 | player: {
55 | start: 'Начало',
56 | file: 'Файл',
57 | play: 'Проиграть',
58 | title: 'Название файла',
59 | duration: 'Длительность',
60 | in: 'Начало',
61 | out: 'Конец',
62 | ad: 'Реклама',
63 | edit: 'Редактировать',
64 | delete: 'Удалить',
65 | copy: 'Скопировать плейлист',
66 | loop: 'Повторить все видео в плейлисте',
67 | remote: 'Добавить (удаленно) файл в плейлист',
68 | import: 'Загрузить text/m3u файл',
69 | generate: 'Простой и продвинутый генератор плейлистов',
70 | reset: 'Сбросить плейлист',
71 | save: 'Сохранить плейлист',
72 | deletePlaylist: 'Удалить плейлист',
73 | unsavedProgram: 'Этот плейлист не сохранен!',
74 | copyTo: 'Скопировать текущую программу за',
75 | addEdit: 'Добавить/Редактировать файл',
76 | audio: 'Звук',
77 | customFilter: 'Пользовательский фильтр',
78 | deleteFrom: 'Удалить плейлист за',
79 | deleteSuccess: 'Плейлист удален...',
80 | generateProgram: 'Генерация плейлиста',
81 | simple: 'Простой',
82 | advanced: 'Расширенный',
83 | sorted: 'Отсортировать',
84 | shuffle: 'Перемещать/Перетасовать',
85 | shift: 'Перемотка',
86 | all: 'Все',
87 | addBlock: 'Добавить время начало передачи',
88 | infinitInfo: 'Воспроизведение работает в бесконечном режиме. Никакая информация, основанная на времени, невозможна.',
89 | generateDone: 'Генерация плейлиста завершена...',
90 | dateYesterday: 'Current time is before the playlist start time!',
91 | },
92 | media: {
93 | notExists: 'Папки не существует!',
94 | create: 'Сделать папку',
95 | upload: 'Загрузить файлы',
96 | deleteTitle: 'Удалить Файл/Папку',
97 | deleteQuestion: 'Вы уверены что хотите это удалить',
98 | preview: 'Просмотр',
99 | rename: 'Переименовать файл',
100 | newFile: 'Название нового файла',
101 | createFolder: 'Сделать папку',
102 | foldername: 'Имя папки',
103 | current: 'Процесс загрузки',
104 | overall: 'Всего',
105 | uploading: 'Загружается',
106 | moveError: 'Move error',
107 | deleteError: 'Ошишка удаления',
108 | folderExists: 'Папка уже имеется!',
109 | folderCreate: 'Создание папки готово...',
110 | folderError: 'Ошибка Создания папки',
111 | uploadError: 'Ошибка Загрузки',
112 | fileExists: 'Файл уже имеется!',
113 | },
114 | message: {
115 | savePreset: 'Сохранить шаблон',
116 | newPreset: 'Новый шаблон',
117 | delPreset: 'Удалить шаблон',
118 | delText: 'Вы уверены что хотите удалить шаблон',
119 | placeholder: 'Текст',
120 | xAxis: 'X Axis',
121 | yAxis: 'Y Axis',
122 | showBox: 'Текст с фоном',
123 | boxColor: 'Цвет фона для текста',
124 | boxAlpha: 'Прозрачность фона для текста',
125 | size: 'Размер',
126 | spacing: 'Spacing',
127 | overallAlpha: 'Overall Alpha',
128 | fontColor: 'Цвет текста',
129 | fontAlpha: 'Font Alpha',
130 | borderWidth: 'Border Width',
131 | send: 'Отправить в эфир',
132 | name: 'Название',
133 | saveDone: 'Сохранение предустановки выполнено!',
134 | saveFailed: 'Сохранить пресет не удалось!',
135 | sendDone: 'Отправка успешна...',
136 | sendFailed: 'Отправка не удалась...',
137 | },
138 | log: {
139 | download: 'Скачать лог файл',
140 | },
141 | advanced: {
142 | title: 'Advanced Configuration',
143 | decoder: 'Decoder',
144 | encoder: 'Encoder',
145 | filter: 'Filter',
146 | ingest: 'Ingest',
147 | updateSuccess: 'Update advanced config success!',
148 | updateFailed: 'Update advanced config failed!',
149 | warning: 'Warning! These settings are experimental and only intended for advanced users who are familiar with ffmpeg. Only change the settings here if you are sure of what you are doing! The settings can make the system unstable.',
150 | },
151 | config: {
152 | channel: 'Канал',
153 | user: 'Юзер',
154 | channelConf: 'Конфигурация канала',
155 | addChannel: 'Сделать новый канал',
156 | name: 'Название канала',
157 | previewUrl: 'Предварительный просмотр эфира канала по URL',
158 | extensions: 'Дополнительные расширения',
159 | save: 'Сохранить',
160 | delete: 'Удалить',
161 | updateChannelSuccess: 'Обновление конфигурации канала успешно!',
162 | updateChannelFailed: 'Обновление конфигурации канала не получилось!',
163 | errorChannelDelete: 'Первый канал не может быть удален!',
164 | deleteChannelSuccess: 'Удаление канала успешно!',
165 | deleteChannelFailed: 'Удаление канала неуспешно!',
166 | playoutConf: 'Настройки Конфигурации',
167 | general: 'Главное',
168 | rpcServer: 'RPC Сервер',
169 | mail: 'Электронная почта',
170 | logging: 'Логирование',
171 | processing: 'Настройки эфира',
172 | ingest: 'Ingest',
173 | playlist: 'Плейлист',
174 | storage: 'Storage',
175 | text: 'Текст',
176 | task: 'Task',
177 | output: 'Out',
178 | placeholderPass: 'Password',
179 | help: 'Help',
180 | generalText: `Sometimes it can happen that a file is corrupted but still playable, this can cause a streaming error on all following files. The only way to fix this is to stop and restart ffplayout. Here we only say when to stop, the starting process is up to you. The best way is a systemd service on Linux.
181 | 'stop_threshold' will stop ffplayout if it is async in time above this value. A number less than 3 may cause unexpected errors.`,
182 | rpcText: 'Запустите сервер JSON RPC, чтобы получить информацию о том, что воспроизводится, а также о некоторых функциях управления.',
183 | mailText: `Отправлять сообщения об ошибках на адрес электронной почты, например об отсутствии списка воспроизведения; неверный формат json; отсутствует путь к клипу. Оставьте получателя пустым, если он вам не нужен. 'mail_level' может быть ИНФОРМАЦИЯ, ПРЕДУПРЕЖДЕНИЕ или ОШИБКА. 'interval' означает секунды до отправки нового письма.`,
184 | logText: `If 'log_to_file' is true, log to file, if false, log to console. 'local_time' to false will set log timestamps to UTC. Path to /var/log/ only if you are running this as a daemon.
185 | 'level' can be DEBUG, INFO, WARNING, ERROR. 'ffmpeg_level' can be INFO, WARNING, ERROR. 'detect_silence' logs an error message if the audio line is silent for 15 seconds during the validation process.`,
186 | processingText: `Default processing for all clips to make them unique. Mode can be Playlist or Folder. 'aspect' must be a float number. 'logo' is only used if the path exists.
187 | 'logo_scale' scales the logo to the target size, leave empty if no scaling is needed, format is 'width:height', for example '100:-1' for proportional scaling. With 'logo_opacity' you can make the logo transparent.
188 | With 'audio_tracks' it is possible to configure how many audio tracks should be processed. 'audio_channels' can be used if the audio has more channels than just stereo. With 'logo_position' in 'x:y' format you set the logo position. With 'custom_filter' it is possible to apply additional filters. The filter outputs should end with [c_v_out] for video filters and [c_a_out] for audio filters.`,
189 | ingestText: `Запустите сервер для получения входящего потока. Этот поток будет переопределять обычную потоковую передачу до тех пор, пока она не будет завершена. Существует только очень простой механизм аутентификации, позволяющий проверить правильность имени потока. 'custom_filter' можно использовать так же, как в разделе "Настройки эфира".`,
190 | playlistText: `'path' can be a path to a single file or a directory. For directory specify only the root folder, for example '/playlists', subdirectories will be read by the program. Subdirectories need this structure '/playlists/2018/01'.
191 | 'day_start' is the time at which the playlist should start, leave 'day_start' empty if the playlist should always start at the beginning. 'length' represents the target length of the playlist, if empty, real length will not be considered. 'infinit: true' works with single playlist file and loops it infinitely.`,
192 | storageText: `Play ordered or random files from path. 'filler_clip' is for filling the end to reach 24 hours, it will loop when necessary. Set 'extensions' to search only for files with that extension. Set 'shuffle' to 'true' to select files randomly.`,
193 | textText: `Overlay text in combination with libzmq for remote text manipulation. On Windows, the font file path must be 'C\\:/WINDOWS/fonts/DejaVuSans.ttf'. 'text_from_filename' activates text extraction from a filename. With 'style' you can set the drawtext parameters like position, color, etc. Post Text via API will override this. With 'regex' you can format the filename to get a title.`,
194 | taskText: `Run an external program with a given media object. The media object is in json format and contains all the information about the current clip. The external program can be a script or a binary. or a binary, but should only run for a short time.`,
195 | outputText: `The final playout compression. Adjust the settings according to your needs. 'mode' has the options 'desktop', 'hls', 'null', 'stream'. Use 'stream' and adjust the 'output_param:' settings if you want to stream to an rtmp/rtsp/srt/... server. In production don't serve hls playlist with ffpapi, use nginx or another web server!`,
196 | restartTile: 'Перезапуск Playout',
197 | restartText: 'Перезапустить ffplayout для применения изменений?',
198 | updatePlayoutSuccess: 'Обновление конфигурации воспроизведения прошло успешно!',
199 | updatePlayoutFailed: 'Обновление конфигурации воспроизведения не удалось!',
200 | forbiddenPlaylistPath: 'Доступ запрещен: Папка плейлиста не может быть открыта.',
201 | noPlayoutConfig: 'Конфигурация воспроизведения не найдена!',
202 | hlsPath: 'HLS Path',
203 | playlistPath: 'Playlist Path',
204 | storagePath: 'Storage Path',
205 | sharedStorage: 'Общее хранилище включено, используйте один и тот же корень хранилища для всех каналов!',
206 | },
207 | user: {
208 | title: 'Конфигурация пользователя',
209 | add: 'Добавить пользователя',
210 | delete: 'Удалить пользователя',
211 | name: 'Имя пользователя',
212 | mail: 'Электронная почта',
213 | password: 'Пароль',
214 | newPass: 'Новый пароль',
215 | confirmPass: 'Подтвердите пароль',
216 | save: 'Сохранить',
217 | admin: 'Админ',
218 | deleteNotPossible: 'Delete current user not possible!',
219 | deleteSuccess: 'Удаление пользователя успешно!',
220 | deleteError: 'Удаление пользователя с ошибкой',
221 | addSuccess: 'Добавление пользователя успешно!',
222 | addFailed: 'Добавление пользователя не успешно!',
223 | mismatch: 'Password mismatch!',
224 | updateSuccess: 'Обновление данных о пользователе успешно!',
225 | updateFailed: 'Обновление данных о пользователе не успешно!',
226 | },
227 | }
228 |
--------------------------------------------------------------------------------
/layouts/default.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
28 |
--------------------------------------------------------------------------------
/middleware/auth.global.ts:
--------------------------------------------------------------------------------
1 | export default defineNuxtRouteMiddleware((to) => {
2 | const auth = useAuth()
3 | const localePath = useLocalePath()
4 |
5 | auth.inspectToken()
6 |
7 | if (!auth.isLogin && !String(to.name).includes('index_')) {
8 | return navigateTo(localePath({ name: 'index' }))
9 | }
10 | })
11 |
--------------------------------------------------------------------------------
/nuxt.config.ts:
--------------------------------------------------------------------------------
1 | // https://nuxt.com/docs/api/configuration/nuxt-config
2 | export default defineNuxtConfig({
3 | devServer: {
4 | port: 3000, // default: 3000
5 | host: '127.0.0.1', // default: localhost
6 | },
7 |
8 | nitro: {
9 | devProxy: {
10 | '/api': { target: 'http://127.0.0.1:8787/api' },
11 | '/auth': { target: 'http://127.0.0.1:8787/auth' },
12 | '/data': { target: 'http://127.0.0.1:8787/data' },
13 | '/live': { target: 'http://127.0.0.1:8787/live' },
14 | '/1/live': { target: 'http://127.0.0.1:8787/1/live' },
15 | '/file': { target: 'http://127.0.0.1:8787/file' },
16 | '/hls': { target: 'http://127.0.0.1:8787/hls' },
17 | },
18 | },
19 |
20 | ignore: ['**/public/tv-media**', '**/public/Videos**', '**/public/live**', '**/public/home**'],
21 | ssr: false,
22 |
23 | // debug: true,
24 |
25 | app: {
26 | head: {
27 | title: 'ffplayout',
28 | meta: [
29 | {
30 | charset: 'utf-8',
31 | },
32 | {
33 | name: 'viewport',
34 | content: 'width=device-width, initial-scale=1',
35 | },
36 | {
37 | hid: 'description',
38 | name: 'description',
39 | content: 'Frontend for ffplayout, the 24/7 Rust and playlist based streaming solution.',
40 | },
41 | ],
42 | link: [
43 | {
44 | rel: 'icon',
45 | type: 'image/x-icon',
46 | href: '/favicon.ico',
47 | },
48 | ],
49 | },
50 | },
51 |
52 | modules: [
53 | '@nuxt/eslint',
54 | '@nuxtjs/color-mode',
55 | '@nuxtjs/tailwindcss',
56 | '@nuxtjs/i18n',
57 | '@pinia/nuxt',
58 | '@vueuse/nuxt',
59 | ],
60 |
61 | css: ['@/assets/scss/main.scss'],
62 |
63 | colorMode: {
64 | preference: 'dark', // default value of $colorMode.preference
65 | fallback: 'system', // fallback value if not system preference found
66 | hid: 'nuxt-color-mode-script',
67 | globalName: '__NUXT_COLOR_MODE__',
68 | componentName: 'ColorScheme',
69 | classPrefix: '',
70 | classSuffix: '',
71 | dataValue: 'theme',
72 | storageKey: 'theme',
73 | },
74 |
75 | i18n: {
76 | locales: [
77 | {
78 | code: 'de',
79 | name: 'Deutsch',
80 | file: 'de-DE.js',
81 | },
82 | {
83 | code: 'en',
84 | name: 'English',
85 | file: 'en-US.js',
86 | },
87 | {
88 | code: 'pt-br',
89 | name: 'Português (BR)',
90 | file: 'pt-BR.js',
91 | },
92 | {
93 | code: 'ru',
94 | name: 'Русский язык (RU)',
95 | file: 'ru-RU.js',
96 | },
97 | ],
98 | customRoutes: 'config',
99 | pages: {
100 | player: {
101 | de: '/wiedergabe',
102 | en: '/player',
103 | 'pt-br': '/player',
104 | ru: '/player',
105 | },
106 | media: {
107 | de: '/medien',
108 | en: '/media',
109 | 'pt-br': '/armazenamento',
110 | ru: '/media',
111 | },
112 | message: {
113 | de: '/nachrichten',
114 | en: '/message',
115 | 'pt-br': '/legenda',
116 | ru: '/message',
117 | },
118 | logging: {
119 | de: '/protokollierung',
120 | en: '/logging',
121 | 'pt-br': '/registro',
122 | ru: '/logging',
123 | },
124 | configure: {
125 | de: '/einstellungen',
126 | en: '/configure',
127 | 'pt-br': '/configurar',
128 | ru: '/configure',
129 | },
130 | },
131 | detectBrowserLanguage: {
132 | useCookie: true,
133 | alwaysRedirect: true,
134 | },
135 | // debug: true,
136 | langDir: 'i18n/locales',
137 | defaultLocale: 'en',
138 |
139 | compilation: {
140 | strictMessage: false,
141 | },
142 | },
143 |
144 | vite: {
145 | build: {
146 | chunkSizeWarningLimit: 800000,
147 | },
148 | css: {
149 | preprocessorOptions: {
150 | scss: {
151 | silenceDeprecations: ['legacy-js-api'],
152 | },
153 | },
154 | },
155 | },
156 |
157 | experimental: {
158 | payloadExtraction: false,
159 | },
160 |
161 | compatibilityDate: '2024-07-10',
162 | })
163 |
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "ffplayout-frontend",
3 | "version": "0.12.1",
4 | "description": "Web GUI for ffplayout",
5 | "author": "Jonathan Baecker",
6 | "private": true,
7 | "scripts": {
8 | "build": "nuxt build",
9 | "dev": "nuxt dev",
10 | "generate": "nuxt generate",
11 | "reset": "rm -rf .nuxt node_modules .output package-lock.json && npm install",
12 | "preview": "nuxt preview",
13 | "postinstall": "nuxt prepare"
14 | },
15 | "dependencies": {
16 | "@nuxtjs/color-mode": "^3.5.1",
17 | "@pinia/nuxt": "^0.5.4",
18 | "@vueform/multiselect": "^2.6.10",
19 | "@vuepic/vue-datepicker": "^9.0.3",
20 | "@vueuse/nuxt": "^11.1.0",
21 | "bootstrap-icons": "^1.11.3",
22 | "dayjs": "^1.11.13",
23 | "jwt-decode": "^4.0.0",
24 | "lodash": "^4.17.21",
25 | "mpegts.js": "^1.7.3",
26 | "nuxt": "3.13.2",
27 | "pinia": "^2.2.2",
28 | "sortablejs-vue3": "^1.2.11",
29 | "splitpanes": "^3.1.5",
30 | "video.js": "^8.17.4"
31 | },
32 | "devDependencies": {
33 | "@nuxt/eslint": "^0.5.7",
34 | "@nuxtjs/i18n": "^8.5.5",
35 | "@nuxtjs/tailwindcss": "^6.12.1",
36 | "@types/lodash": "^4.17.9",
37 | "@types/video.js": "^7.3.58",
38 | "daisyui": "^4.12.10",
39 | "mini-svg-data-uri": "^1.4.4",
40 | "postcss": "^8.4.47",
41 | "postcss-loader": "^8.1.1",
42 | "sass": "^1.79.3",
43 | "sass-loader": "^16.0.2",
44 | "vue": "^3.5.8",
45 | "vue-router": "^4.4.5"
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/pages/configure.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
11 |
19 |
26 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
65 |
--------------------------------------------------------------------------------
/pages/index.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 | {{ t('button.player') }}
11 |
12 |
13 | {{ t('button.media') }}
14 |
15 |
16 | {{ t('button.message') }}
17 |
18 |
19 | {{ t('button.logging') }}
20 |
21 |
26 | {{ t('button.configure') }}
27 |
28 |
31 |
43 |
48 |
49 |
50 |
51 | ffplayout
52 |
53 |
90 |
91 |
92 |
93 |
94 |
162 |
--------------------------------------------------------------------------------
/pages/logging.vue:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
15 |
28 |
31 |
32 |
33 |
34 |
38 |
39 |
40 |
41 |
42 |
148 |
149 |
195 |
--------------------------------------------------------------------------------
/plugins/dayjs.ts:
--------------------------------------------------------------------------------
1 | import dayjs from 'dayjs'
2 | import customParseFormat from 'dayjs/plugin/customParseFormat.js'
3 | import LocalizedFormat from 'dayjs/plugin/localizedFormat.js'
4 | import timezone from 'dayjs/plugin/timezone.js'
5 | import utc from 'dayjs/plugin/utc.js'
6 |
7 | import 'dayjs/locale/de'
8 | import 'dayjs/locale/en'
9 | import 'dayjs/locale/es'
10 | import 'dayjs/locale/pt-br'
11 | import 'dayjs/locale/ru'
12 |
13 | declare module '#app' {
14 | interface NuxtApp {
15 | $dayjs(date?: dayjs.ConfigType): dayjs.Dayjs
16 | }
17 | }
18 | declare module '@vue/runtime-core' {
19 | interface ComponentCustomProperties {
20 | $dayjs(date?: dayjs.ConfigType): dayjs.Dayjs
21 | }
22 | }
23 |
24 | export default defineNuxtPlugin((nuxtApp) => {
25 | dayjs.extend(customParseFormat)
26 | dayjs.extend(LocalizedFormat)
27 | dayjs.extend(timezone)
28 | dayjs.extend(utc)
29 |
30 | nuxtApp.provide('dayjs', dayjs)
31 | })
32 |
--------------------------------------------------------------------------------
/plugins/lodash.client.ts:
--------------------------------------------------------------------------------
1 | import lodash from 'lodash'
2 | import type { LoDashStatic } from 'lodash'
3 |
4 | declare module '#app' {
5 | interface NuxtApp {
6 | $_: LoDashStatic
7 | }
8 | }
9 | declare module '@vue/runtime-core' {
10 | interface ComponentCustomProperties {
11 | $_: LoDashStatic
12 | }
13 | }
14 |
15 | export default defineNuxtPlugin((nuxtApp) => {
16 | nuxtApp.provide('_', lodash)
17 | })
18 |
--------------------------------------------------------------------------------
/plugins/multiselect.client.ts:
--------------------------------------------------------------------------------
1 | import { defineNuxtPlugin } from '#imports'
2 | import Multiselect from '@vueform/multiselect'
3 | import '@vueform/multiselect/themes/tailwind.css'
4 |
5 | export default defineNuxtPlugin((nuxtApp) => {
6 | nuxtApp.vueApp.component('Multiselect', Multiselect)
7 | })
8 |
--------------------------------------------------------------------------------
/plugins/sortable.client.ts:
--------------------------------------------------------------------------------
1 | import { defineNuxtPlugin } from '#imports'
2 | import { Sortable } from 'sortablejs-vue3'
3 |
4 | export default defineNuxtPlugin((nuxtApp) => {
5 | nuxtApp.vueApp.component('Sortable', Sortable)
6 | })
7 |
--------------------------------------------------------------------------------
/plugins/splitpanes.client.js:
--------------------------------------------------------------------------------
1 | import { Splitpanes, Pane } from 'splitpanes'
2 | import 'splitpanes/dist/splitpanes.css'
3 |
4 | export default defineNuxtPlugin((nuxtApp) => {
5 | nuxtApp.vueApp.component('Splitpanes', Splitpanes)
6 | nuxtApp.vueApp.component('Pane', Pane)
7 | })
8 |
--------------------------------------------------------------------------------
/plugins/vue-datepicker.client.ts:
--------------------------------------------------------------------------------
1 | import VueDatePicker from '@vuepic/vue-datepicker'
2 | import '@vuepic/vue-datepicker/dist/main.css'
3 |
4 | export default defineNuxtPlugin((nuxtApp) => {
5 | nuxtApp.vueApp.component('VueDatePicker', VueDatePicker)
6 | })
7 |
--------------------------------------------------------------------------------
/public/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ffplayout/ffplayout-frontend/c897226188cc289b0744bb721691a438dba0f5fd/public/favicon.ico
--------------------------------------------------------------------------------
/public/live/.gitkeep:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ffplayout/ffplayout-frontend/c897226188cc289b0744bb721691a438dba0f5fd/public/live/.gitkeep
--------------------------------------------------------------------------------
/public/robots.txt:
--------------------------------------------------------------------------------
1 | User-agent: *
2 | Disallow: /
3 |
--------------------------------------------------------------------------------
/stores/auth.ts:
--------------------------------------------------------------------------------
1 | import { defineStore } from 'pinia'
2 | import { jwtDecode } from 'jwt-decode'
3 |
4 | export const useAuth = defineStore('auth', {
5 | state: () => ({
6 | isLogin: false,
7 | jwtToken: '',
8 | authHeader: {},
9 | channelID: 0,
10 | role: '',
11 | uuid: null as null | string,
12 | }),
13 |
14 | getters: {},
15 | actions: {
16 | updateToken(token: string) {
17 | const cookie = useCookie('token', {
18 | path: '/',
19 | maxAge: 60 * 60 * 24 * 365,
20 | sameSite: 'lax',
21 | })
22 |
23 | cookie.value = token
24 | this.jwtToken = token
25 | this.authHeader = { Authorization: `Bearer ${token}` }
26 | },
27 |
28 | removeToken() {
29 | const cookie = useCookie('token')
30 | cookie.value = null
31 | this.isLogin = false
32 | this.jwtToken = ''
33 | this.authHeader = {}
34 | },
35 |
36 | async obtainToken(username: string, password: string) {
37 | let code = 0
38 | const payload = {
39 | username,
40 | password,
41 | }
42 |
43 | await $fetch('/auth/login/', {
44 | method: 'POST',
45 | body: JSON.stringify(payload),
46 | async onResponse({ response }) {
47 | code = response.status
48 | },
49 | })
50 | .then((response) => {
51 | this.updateToken(response.user?.token)
52 | const decodedToken = jwtDecode(response.user?.token)
53 | this.isLogin = true
54 | this.channelID = decodedToken.channel
55 | this.role = decodedToken.role
56 | })
57 | .catch(() => {})
58 |
59 | return code
60 | },
61 |
62 | async obtainUuid() {
63 | await $fetch('/api/generate-uuid', {
64 | method: 'POST',
65 | headers: this.authHeader,
66 | })
67 | .then((response) => {
68 | this.uuid = response.uuid
69 | })
70 | .catch(e => {
71 | if (e.status === 401) {
72 | this.removeToken()
73 | }
74 | this.uuid = null
75 | })
76 | },
77 |
78 | inspectToken() {
79 | const token = useCookie('token').value
80 |
81 | if (token) {
82 | this.updateToken(token)
83 | const decodedToken = jwtDecode(token)
84 | const timestamp = Date.now() / 1000
85 | const expireToken = decodedToken.exp
86 | this.channelID = decodedToken.channel
87 | this.role = decodedToken.role
88 |
89 | if (expireToken && this.jwtToken && expireToken - timestamp > 15) {
90 | this.isLogin = true
91 | } else {
92 | // Prompt user to re-login.
93 | this.isLogin = false
94 | }
95 | } else {
96 | this.isLogin = false
97 | }
98 | },
99 | },
100 | })
101 |
--------------------------------------------------------------------------------
/stores/config.ts:
--------------------------------------------------------------------------------
1 | import _ from 'lodash'
2 | import { defineStore } from 'pinia'
3 |
4 | export const useConfig = defineStore('config', {
5 | state: () => ({
6 | id: 0,
7 | configCount: 0,
8 | contentType: { 'content-type': 'application/json;charset=UTF-8' },
9 | channels: [] as Channel[],
10 | channelsRaw: [] as Channel[],
11 | playlistLength: 86400.0,
12 | advanced: {} as any,
13 | playout: {} as any,
14 | currentUser: 0,
15 | configUser: {} as User,
16 | utcOffset: 0,
17 | onetimeInfo: true,
18 | showPlayer: true,
19 | }),
20 |
21 | getters: {},
22 | actions: {
23 | async configInit() {
24 | const authStore = useAuth()
25 |
26 | authStore.inspectToken()
27 |
28 | if (authStore.isLogin) {
29 | await authStore.obtainUuid()
30 | await this.getChannelConfig().then(async () => {
31 | await this.getPlayoutConfig()
32 | await this.getUserConfig()
33 |
34 | if (this.configUser.id === 1) {
35 | await this.getAdvancedConfig()
36 | }
37 | })
38 | }
39 | },
40 |
41 | logout() {
42 | const authStore = useAuth()
43 | const cookie = useCookie('token')
44 | cookie.value = null
45 | authStore.isLogin = false
46 |
47 | navigateTo('/')
48 | },
49 |
50 | async getChannelConfig() {
51 | const authStore = useAuth()
52 | const indexStore = useIndex()
53 |
54 | let statusCode = 0
55 | await fetch('/api/channels', {
56 | method: 'GET',
57 | headers: authStore.authHeader,
58 | })
59 | .then((response) => {
60 | statusCode = response.status
61 |
62 | return response
63 | })
64 | .then((response) => response.json())
65 | .then((objs) => {
66 | if (!objs[0]) {
67 | this.logout()
68 | throw new Error('User not found')
69 | }
70 |
71 | this.utcOffset = objs[0].utc_offset
72 | this.channels = objs
73 | this.channelsRaw = _.cloneDeep(objs)
74 | this.configCount = objs.length
75 | })
76 | .catch((e) => {
77 | if (statusCode === 401) {
78 | this.logout()
79 | }
80 |
81 | this.channels = [
82 | {
83 | id: 1,
84 | extra_extensions: '',
85 | name: 'Channel 1',
86 | preview_url: '',
87 | hls_path: '',
88 | playlist_path: '',
89 | storage_path: '',
90 | uts_offset: 0,
91 | },
92 | ]
93 |
94 | indexStore.msgAlert('error', e, 3)
95 | })
96 | },
97 |
98 | async setChannelConfig(obj: Channel): Promise {
99 | const authStore = useAuth()
100 | const stringObj = _.cloneDeep(obj)
101 | let response
102 |
103 | if (this.channelsRaw.some((e) => e.id === stringObj.id)) {
104 | response = await fetch(`/api/channel/${obj.id}`, {
105 | method: 'PATCH',
106 | headers: { ...this.contentType, ...authStore.authHeader },
107 | body: JSON.stringify(stringObj),
108 | })
109 | } else {
110 | response = await fetch('/api/channel/', {
111 | method: 'POST',
112 | headers: { ...this.contentType, ...authStore.authHeader },
113 | body: JSON.stringify(stringObj),
114 | })
115 |
116 | const json = await response.json()
117 | const guiConfigs = []
118 |
119 | for (const obj of this.channels) {
120 | if (obj.name === stringObj.name) {
121 | guiConfigs.push(json)
122 | } else {
123 | guiConfigs.push(obj)
124 | }
125 | }
126 |
127 | this.channels = guiConfigs
128 | this.channelsRaw = _.cloneDeep(guiConfigs)
129 | this.configCount = guiConfigs.length
130 | }
131 |
132 | await this.getPlayoutConfig()
133 |
134 | return response
135 | },
136 |
137 | async getPlayoutConfig() {
138 | const { $i18n } = useNuxtApp()
139 | const { timeToSeconds } = stringFormatter()
140 | const authStore = useAuth()
141 | const indexStore = useIndex()
142 | const channel = this.channels[this.id].id
143 |
144 | await fetch(`/api/playout/config/${channel}`, {
145 | method: 'GET',
146 | headers: authStore.authHeader,
147 | })
148 | .then((response) => response.json())
149 | .then((data) => {
150 | data.playlist.startInSec = timeToSeconds(data.playlist.day_start ?? 0)
151 | data.playlist.lengthInSec = timeToSeconds(data.playlist.length ?? this.playlistLength)
152 |
153 | if (data.storage.extensions) {
154 | data.storage.extensions = data.storage.extensions.join(',')
155 | }
156 |
157 | this.playout = data
158 | })
159 | .catch(() => {
160 | indexStore.msgAlert('error', $i18n.t('config.noPlayoutConfig'), 3)
161 | })
162 | },
163 |
164 | async getAdvancedConfig() {
165 | const { $i18n } = useNuxtApp()
166 | const authStore = useAuth()
167 | const indexStore = useIndex()
168 | const channel = this.channels[this.id].id
169 |
170 | await $fetch(`/api/playout/advanced/${channel}`, {
171 | method: 'GET',
172 | headers: authStore.authHeader,
173 | })
174 | .then((data) => {
175 | this.advanced = data
176 | })
177 | .catch(() => {
178 | indexStore.msgAlert('error', $i18n.t('config.noAdvancedConfig'), 3)
179 | })
180 | },
181 |
182 | async setPlayoutConfig(obj: any) {
183 | const { timeToSeconds } = stringFormatter()
184 | const authStore = useAuth()
185 | const channel = this.channels[this.id].id
186 |
187 | this.playlistLength = timeToSeconds(obj.playlist.length)
188 | this.playout.playlist.startInSec = timeToSeconds(obj.playlist.day_start)
189 | this.playout.playlist.lengthInSec = timeToSeconds(obj.playlist.length)
190 |
191 | if (typeof obj.storage.extensions === 'string') {
192 | obj.storage.extensions = obj.storage.extensions.replace(' ', '').split(/,|;/)
193 | }
194 |
195 | const update = await fetch(`/api/playout/config/${channel}`, {
196 | method: 'PUT',
197 | headers: { ...this.contentType, ...authStore.authHeader },
198 | body: JSON.stringify(obj),
199 | })
200 |
201 | return update
202 | },
203 |
204 | async setAdvancedConfig() {
205 | const authStore = useAuth()
206 | const channel = this.channels[this.id].id
207 |
208 | const update = await fetch(`/api/playout/advanced/${channel}`, {
209 | method: 'PUT',
210 | headers: { ...this.contentType, ...authStore.authHeader },
211 | body: JSON.stringify(this.advanced),
212 | })
213 |
214 | return update
215 | },
216 |
217 | async getUserConfig() {
218 | const authStore = useAuth()
219 |
220 | await fetch('/api/user', {
221 | method: 'GET',
222 | headers: authStore.authHeader,
223 | })
224 | .then((response) => response.json())
225 | .then((data) => {
226 | if (data.id === 0) {
227 | this.logout()
228 | throw new Error('User not found')
229 | }
230 |
231 | this.currentUser = data.id
232 | this.configUser = data
233 | })
234 | },
235 |
236 | async setUserConfig(obj: any) {
237 | const authStore = useAuth()
238 |
239 | const update = await fetch(`/api/user/${obj.id}`, {
240 | method: 'PUT',
241 | headers: { ...this.contentType, ...authStore.authHeader },
242 | body: JSON.stringify(obj),
243 | })
244 |
245 | return update
246 | },
247 |
248 | async addNewUser(user: User) {
249 | const authStore = useAuth()
250 | delete user.confirm
251 |
252 | const update = await fetch('/api/user/', {
253 | method: 'Post',
254 | headers: { ...this.contentType, ...authStore.authHeader },
255 | body: JSON.stringify(user),
256 | })
257 |
258 | return update
259 | },
260 | },
261 | })
262 |
--------------------------------------------------------------------------------
/stores/index.ts:
--------------------------------------------------------------------------------
1 | import { defineStore } from 'pinia'
2 |
3 | export const useIndex = defineStore('index', {
4 | state: () => ({
5 | darkMode: false,
6 | showAlert: false,
7 | alertVariant: 'success',
8 | alertMsg: '',
9 | sseConnected: false,
10 | severityLevels: {
11 | DEBUG: 1,
12 | INFO: 2,
13 | WARN: 3,
14 | ERROR: 4,
15 | } as { [key: string]: number }
16 | }),
17 |
18 | getters: {},
19 | actions: {
20 | msgAlert(variance: string, text: string, seconds: number = 3) {
21 | this.alertVariant = variance
22 | this.alertMsg = text
23 | this.showAlert = true
24 |
25 | setTimeout(() => {
26 | this.showAlert = false
27 | this.alertVariant = 'success'
28 | this.alertMsg = ''
29 | }, seconds * 1000)
30 | },
31 | },
32 | })
33 |
--------------------------------------------------------------------------------
/stores/media.ts:
--------------------------------------------------------------------------------
1 | import { defineStore } from 'pinia'
2 |
3 | const { genUID } = playlistOperations()
4 |
5 | export const useMedia = defineStore('media', {
6 | state: () => ({
7 | currentPath: '',
8 | crumbs: [] as Crumb[],
9 | folderTree: {} as FileFolderObject,
10 | folderList: {} as FolderObject,
11 | folderCrumbs: [] as Crumb[],
12 | isLoading: false,
13 | }),
14 |
15 | getters: {},
16 | actions: {
17 | async getTree(path: string, foldersOnly: boolean = false) {
18 | if (!foldersOnly) {
19 | this.isLoading = true
20 | }
21 |
22 | const { $i18n } = useNuxtApp()
23 | const authStore = useAuth()
24 | const configStore = useConfig()
25 | const indexStore = useIndex()
26 | const channel = configStore.channels[configStore.id].id
27 | const crumbs: Crumb[] = []
28 | let root = '/'
29 |
30 | await fetch(`/api/file/${channel}/browse/`, {
31 | method: 'POST',
32 | headers: { ...configStore.contentType, ...authStore.authHeader },
33 | body: JSON.stringify({ source: path, folders_only: foldersOnly }),
34 | })
35 | .then((response) => {
36 | if (response.status === 200) {
37 | return response.json()
38 | } else {
39 | indexStore.msgAlert('error', $i18n.t('media.notExists'), 3)
40 |
41 | return {
42 | source: '',
43 | parent: '',
44 | folders: [],
45 | files: [],
46 | }
47 | }
48 | })
49 | .then((data) => {
50 | const pathStr = `${data.parent}/` + data.source
51 | const pathArr = pathStr.split('/')
52 |
53 | if (path && path !== '/') {
54 | for (const crumb of pathArr) {
55 | if (crumb === data.parent) {
56 | crumbs.push({ text: crumb, path: root })
57 | } else if (crumb) {
58 | root += crumb + '/'
59 | crumbs.push({ text: crumb, path: root })
60 | }
61 | }
62 | } else {
63 | crumbs.push({ text: data.parent, path: '' })
64 | }
65 |
66 | if (foldersOnly) {
67 | this.folderCrumbs = crumbs
68 | data.parent_folders = data.parent_folders?.map((i: any) => ({ uid: genUID(), name: i })) ?? []
69 | data.folders = data.folders.map((i: any) => ({ uid: genUID(), name: i }))
70 | this.folderList = data
71 | } else {
72 | this.currentPath = path
73 | this.crumbs = crumbs
74 | data.parent_folders = data.parent_folders?.map((i: any) => ({ uid: genUID(), name: i })) ?? []
75 | data.folders = data.folders.map((i: any) => ({ uid: genUID(), name: i }))
76 | this.folderTree = data
77 | }
78 | })
79 |
80 | this.isLoading = false
81 | },
82 | },
83 | })
84 |
--------------------------------------------------------------------------------
/stores/playlist.ts:
--------------------------------------------------------------------------------
1 | import dayjs from 'dayjs'
2 | import utc from 'dayjs/plugin/utc.js'
3 | import timezone from 'dayjs/plugin/timezone.js'
4 |
5 | import { defineStore } from 'pinia'
6 |
7 | dayjs.extend(utc)
8 | dayjs.extend(timezone)
9 |
10 | const { processPlaylist } = playlistOperations()
11 |
12 | export const usePlaylist = defineStore('playlist', {
13 | state: () => ({
14 | playlist: [] as PlaylistItem[],
15 | isLoading: true,
16 | listDate: dayjs().format('YYYY-MM-DD'),
17 | progressValue: 0,
18 | current: {} as PlaylistItem,
19 | currentIndex: 0,
20 | ingestRuns: false,
21 | elapsedSec: 0,
22 | shift: 0,
23 | playoutIsRunning: false,
24 | last_channel: 0,
25 | firstLoad: true,
26 | }),
27 |
28 | getters: {},
29 | actions: {
30 | async getPlaylist(date: string) {
31 | const { $_, $i18n } = useNuxtApp()
32 | const authStore = useAuth()
33 | const configStore = useConfig()
34 | const indexStore = useIndex()
35 | const channel = configStore.channels[configStore.id].id
36 |
37 | await $fetch(`/api/playlist/${channel}?date=${date}`, {
38 | method: 'GET',
39 | headers: authStore.authHeader,
40 | })
41 | .then((data) => {
42 | if (data.program) {
43 | const programData = processPlaylist(date, data.program, false)
44 |
45 | if (
46 | channel === this.last_channel &&
47 | this.playlist.length > 0 &&
48 | programData.length > 0 &&
49 | (this.playlist[0].date === date || configStore.playout.playlist.infinit) &&
50 | $_.differenceWith(this.playlist, programData, (a, b) => {
51 | return $_.isEqual($_.omit(a, ['uid']), $_.omit(b, ['uid']))
52 | }).length > 0
53 | ) {
54 | indexStore.msgAlert('warning', $i18n.t('player.unsavedProgram'), 3)
55 | } else {
56 | this.playlist = programData ?? []
57 | }
58 | }
59 | })
60 | .catch((e) => {
61 | if (e.status >= 400) {
62 | indexStore.msgAlert('error', e.data, 5)
63 | } else if (
64 | channel === this.last_channel &&
65 | this.playlist.length > 0 &&
66 | this.playlist[0].date === date
67 | ) {
68 | indexStore.msgAlert('warning', $i18n.t('player.unsavedProgram'), 3)
69 | } else {
70 | this.playlist = []
71 | }
72 | })
73 |
74 | this.last_channel = channel
75 | },
76 |
77 | setStatus(item: PlayoutStatus) {
78 | this.playoutIsRunning = true
79 | this.current = item.media
80 | this.currentIndex = item.index
81 | this.elapsedSec = item.elapsed
82 | this.ingestRuns = item.ingest
83 | this.shift = item.shift
84 |
85 | this.progressValue = (this.elapsedSec * 100) / this.current.out
86 | },
87 | },
88 | })
89 |
--------------------------------------------------------------------------------
/tailwind.config.ts:
--------------------------------------------------------------------------------
1 | import daisyui from 'daisyui'
2 | import svgToDataUri from 'mini-svg-data-uri'
3 |
4 | module.exports = {
5 | theme: {
6 | extend: {
7 | backgroundImage: (theme: any) => ({
8 | 'multiselect-caret': `url("${svgToDataUri(
9 | ``
10 | )}")`,
11 | 'multiselect-spinner': `url("${svgToDataUri(
12 | ``
15 | )}")`,
16 | 'multiselect-remove': `url("${svgToDataUri(
17 | ``
18 | )}")`,
19 | }),
20 | maskImage: (theme: any) => ({
21 | 'multiselect-caret': `url("${svgToDataUri(
22 | ``
23 | )}")`,
24 | 'multiselect-spinner': `url("${svgToDataUri(
25 | ``
28 | )}")`,
29 | 'multiselect-clear-icon': `url("${svgToDataUri(
30 | ``
31 | )}")`,
32 | 'multiselect-tag-remove-icon': `url("${svgToDataUri(
33 | ``
34 | )}")`,
35 | }),
36 | borderWidth: {
37 | title: '0.1rem',
38 | },
39 | boxShadow: {
40 | '3xl': '0 1em 5em rgba(0, 0, 0, 0.3)',
41 | glow: '0 0 10px rgba(0, 0, 0, 0.3)',
42 | },
43 | colors: {
44 | 'my-gray': 'var(--my-gray)',
45 | },
46 | fontFamily: {
47 | sans: ['Source Sans Pro', 'Segoe UI', 'Helvetica Neue', 'Arial', 'sans-serif'],
48 | },
49 | fontSize: {
50 | xxs: '10px',
51 | sm: '14px',
52 | base: '15px',
53 | lg: '20px',
54 | xl: '24px',
55 | },
56 | screens: {
57 | xxs: '374px',
58 | xs: '500px',
59 | '2sm': '825px',
60 | '2md': '876px',
61 | '4xl': { min: '1971px' },
62 | },
63 | transitionProperty: {
64 | height: 'height',
65 | },
66 | },
67 | },
68 | daisyui: {
69 | themes: [
70 | {
71 | light: {
72 | 'color-scheme': 'light',
73 | primary: '#e0e0e0',
74 | 'base-content': '#222222',
75 | secondary: '#c7c7c7',
76 | accent: '#f28c1b',
77 | 'base-100': '#ffffff',
78 | 'base-200': '#F2F5F7',
79 | 'base-300': '#E5E6E6',
80 | neutral: '#2B3440',
81 | 'neutral-focus': '#343232',
82 | info: '#0000ff',
83 | success: '#008000',
84 | warning: '#f28c1b',
85 | error: '#ff3c00',
86 | '--base-100': '#ffffff',
87 | '--base-200': '#F2F5F7',
88 | '--base-300': '#E5E6E6',
89 | '--my-accent': '#f28c1b',
90 | '--my-gray': '#888888',
91 | '--my-purple': '#701a75',
92 | '--my-yellow': '#bea203',
93 | '--my-blue': '#436e9c',
94 | '--my-green': '#68b31e',
95 | },
96 | dark: {
97 | 'color-scheme': 'dark',
98 | primary: '#3b3b3b',
99 | 'base-content': '#DFDFDF',
100 | secondary: '#d3d3d3',
101 | accent: '#f28c1b',
102 | 'base-100': '#313131',
103 | 'base-200': '#222222',
104 | 'base-300': '#1c1c1c',
105 | neutral: '#272626',
106 | 'neutral-focus': '#343232',
107 | info: '#0000ff',
108 | success: '#008000',
109 | warning: '#f28c1b',
110 | error: '#ff3c00',
111 | '--base-100': '#313131',
112 | '--base-200': '#222222',
113 | '--base-300': '#1c1c1c',
114 | '--my-accent': '#f28c1b',
115 | '--my-gray': '#919191',
116 | '--my-purple': '#ad7fa8;',
117 | '--my-yellow': '#e2c317',
118 | '--my-blue': '#6c95c2',
119 | '--my-green': '#8ae234',
120 | },
121 | },
122 | ],
123 | },
124 | plugins: [daisyui],
125 | }
126 |
--------------------------------------------------------------------------------
/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "exclude": [
3 | "./public"
4 | ],
5 | // https://nuxt.com/docs/guide/concepts/typescript
6 | "extends": "./.nuxt/tsconfig.json"
7 | }
8 |
--------------------------------------------------------------------------------
/types/index.d.ts:
--------------------------------------------------------------------------------
1 | import type { JwtPayload } from 'jwt-decode'
2 |
3 | export {}
4 |
5 | declare global {
6 | interface JwtPayloadExt extends JwtPayload {
7 | id: number
8 | channel: number
9 | role: string
10 | }
11 |
12 | interface LoginObj {
13 | message: string
14 | user?: {
15 | id: number
16 | mail: string
17 | username: string
18 | token
19 | }
20 | }
21 |
22 | interface DataAuth {
23 | uuid: string
24 | }
25 |
26 | interface Channel {
27 | id: number
28 | extra_extensions: string | string[]
29 | name: string
30 | preview_url: string
31 | hls_path: string
32 | playlist_path: string
33 | storage_path: string
34 | uts_offset?: number
35 | }
36 |
37 | interface User {
38 | id: number
39 | username: string
40 | mail?: string
41 | password?: string
42 | confirm?: string
43 | admin?: boolean
44 | channel_ids?: number[]
45 | role_id?: number
46 | }
47 |
48 | interface Crumb {
49 | text: string
50 | path: string
51 | }
52 |
53 | interface Payload {
54 | method: string
55 | headers: any
56 | body?: any
57 | }
58 |
59 | interface Playlist {
60 | channel: string
61 | date: string
62 | program: PlaylistItem[]
63 | }
64 |
65 | interface PlaylistItem {
66 | date?: string
67 | uid: string
68 | begin: number
69 | title?: string | null
70 | source: string
71 | duration: number
72 | in: number
73 | out: number
74 | audio?: string
75 | category?: string
76 | custom_filter?: string
77 | overtime?: boolean
78 | }
79 |
80 | interface FileObject {
81 | name: string
82 | duration: number
83 | }
84 |
85 | interface Folder {
86 | uid: string
87 | name: string
88 | }
89 |
90 | interface FileFolderObject {
91 | source: string
92 | parent: string
93 | parent_folders: Folder[]
94 | folders: Folder[]
95 | files: FileObject[]
96 | }
97 |
98 | interface FolderObject {
99 | source: string
100 | parent: string
101 | folders: Folder[]
102 | }
103 |
104 | interface SourceObject {
105 | type: string
106 | src: string
107 | }
108 |
109 | interface TemplateItem {
110 | start: string
111 | duration: string
112 | shuffle: boolean
113 | paths: string[]
114 | }
115 |
116 | interface Template {
117 | sources: TemplateItem[]
118 | }
119 |
120 | interface BodyObject {
121 | paths?: string[]
122 | template?: Template
123 | }
124 |
125 | interface SystemStatistics {
126 | cpu: { cores: number; usage: number }
127 | load: { one: number; five: number; fifteen: number }
128 | memory: { total: number; used: number; free: number }
129 | network?: { name: string; current_in: number; current_out: number; total_in: number; total_out: number }
130 | storage?: { path: string; total: number; used: number }
131 | swap: { total: number; used: number; free: number }
132 | system: { name?: string; kernel?: string; version?: string; ffp_version?: string }
133 | }
134 |
135 | interface PlayoutStatus {
136 | media: PlaylistItem
137 | index: number
138 | ingest: boolean
139 | mode: string
140 | elapsed: number
141 | shift: number
142 | title?: string
143 | }
144 | }
145 |
--------------------------------------------------------------------------------