2
0
mirror of https://github.com/ad1217/PrinterStatus synced 2024-11-25 08:53:48 -05:00

Apply prettier

This commit is contained in:
Adam Goldsmith 2022-01-04 21:56:12 -05:00
parent 310344a450
commit d288af13aa
4 changed files with 10 additions and 15 deletions

View File

@ -2,8 +2,8 @@ import * as WebSocket from 'ws';
import fetch from 'node-fetch'; import fetch from 'node-fetch';
import * as Mp4Frag from 'mp4frag'; import * as Mp4Frag from 'mp4frag';
import {make_mp4frag} from './camera-stream'; import { make_mp4frag } from './camera-stream';
import {Message, StatusMessage, SettingsMessage} from '../../types/messages'; import { Message, StatusMessage, SettingsMessage } from '../../types/messages';
import * as octoprint from '../../types/octoprint'; import * as octoprint from '../../types/octoprint';
const PING_TIME = 10000; const PING_TIME = 10000;
@ -43,11 +43,11 @@ export default class OctoprintConnection {
this.webcamStream = make_mp4frag(this.slug, webcamURL, settings.webcam); this.webcamStream = make_mp4frag(this.slug, webcamURL, settings.webcam);
} }
this.settingsMessage = { this.settingsMessage = {
kind: "settings", kind: 'settings',
printer: this.slug, printer: this.slug,
name: settings.appearance.name, name: settings.appearance.name,
color: settings.appearance.color, color: settings.appearance.color,
} };
this.broadcast(this.settingsMessage); this.broadcast(this.settingsMessage);
// do passive login to get a session key from the API key // do passive login to get a session key from the API key
@ -74,7 +74,7 @@ export default class OctoprintConnection {
const event: octoprint.Message = JSON.parse(data as string); const event: octoprint.Message = JSON.parse(data as string);
let ext_event: StatusMessage = { let ext_event: StatusMessage = {
kind: "status", kind: 'status',
printer: this.slug, printer: this.slug,
msg: event, msg: event,
}; };

View File

@ -1,5 +1,5 @@
declare module "mp4frag" { declare module 'mp4frag' {
import { Transform } from "stream"; import { Transform } from 'stream';
namespace Mp4Frag { namespace Mp4Frag {
interface SegmentObject { interface SegmentObject {

View File

@ -11,12 +11,7 @@
</div> </div>
<div <div
v-else v-else
class=" class="row row-cols-1 row-cols-md-2 row-cols-xxl-3 m-1 m-md-3 g-4 justify-content-center"
row row-cols-1 row-cols-md-2 row-cols-xxl-3
m-1 m-md-3
g-4
justify-content-center
"
> >
<div class="col" v-for="(printer, slug) in printers" :key="slug"> <div class="col" v-for="(printer, slug) in printers" :key="slug">
<PrinterCard :slug="slug as string" v-bind="printer" :now="now"> <PrinterCard :slug="slug as string" v-bind="printer" :now="now">

View File

@ -1,7 +1,7 @@
import * as Vue from 'vue'; import * as Vue from 'vue';
import "bootstrap/dist/css/bootstrap.min.css"; import 'bootstrap/dist/css/bootstrap.min.css';
import "bootstrap"; import 'bootstrap';
import App from './App.vue'; import App from './App.vue';