mirror of
https://github.com/amir20/dozzle.git
synced 2025-12-21 21:33:18 +01:00
fixes spacing
This commit is contained in:
@@ -7,9 +7,16 @@ indent_style = space
|
|||||||
indent_size = 4
|
indent_size = 4
|
||||||
insert_final_newline = true
|
insert_final_newline = true
|
||||||
trim_trailing_whitespace = true
|
trim_trailing_whitespace = true
|
||||||
|
max_line_length = 120
|
||||||
|
|
||||||
[*.sh]
|
[*.sh]
|
||||||
indent_size = 2
|
indent_size = 2
|
||||||
|
|
||||||
|
[*.js]
|
||||||
|
indent_size = 2
|
||||||
|
|
||||||
|
[*.vue]
|
||||||
|
indent_size = 2
|
||||||
|
|
||||||
[Makefile]
|
[Makefile]
|
||||||
indent_style = tab
|
indent_style = tab
|
||||||
|
|||||||
@@ -1,14 +1,14 @@
|
|||||||
<template lang="html">
|
<template lang="html">
|
||||||
<ul ref="events" class="events">
|
<ul ref="events" class="events">
|
||||||
<li v-for="item in messages" class="event" :key="item.key">
|
<li v-for="item in messages" class="event" :key="item.key">
|
||||||
<span class="date">{{ item.dateRelative }}</span>
|
<span class="date">{{ item.dateRelative }}</span> <span class="text">{{ item.message }}</span>
|
||||||
<span class="text">{{ item.message }}</span>
|
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { formatRelative } from "date-fns";
|
import { formatRelative } from "date-fns";
|
||||||
|
|
||||||
let ws = null;
|
let ws = null;
|
||||||
let nextId = 0;
|
let nextId = 0;
|
||||||
const parseMessage = data => {
|
const parseMessage = data => {
|
||||||
@@ -44,9 +44,7 @@ export default {
|
|||||||
const message = parseMessage(e.data);
|
const message = parseMessage(e.data);
|
||||||
this.messages.push(message);
|
this.messages.push(message);
|
||||||
|
|
||||||
this.$nextTick(() =>
|
this.$nextTick(() => document.querySelector("li.event:last-child").scrollIntoView());
|
||||||
document.querySelector("li.event:last-child").scrollIntoView()
|
|
||||||
);
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
beforeDestroy() {
|
beforeDestroy() {
|
||||||
|
|||||||
@@ -4,15 +4,10 @@
|
|||||||
<section class="section">
|
<section class="section">
|
||||||
<ul class="is-marginless is-paddless">
|
<ul class="is-marginless is-paddless">
|
||||||
<li v-for="item in containers" class="unstyled box">
|
<li v-for="item in containers" class="unstyled box">
|
||||||
<router-link
|
<router-link :to="{ name: 'container', params: { id: item.Id } }" class="columns">
|
||||||
:to="{ name: 'container', params: { id: item.Id } }"
|
|
||||||
class="columns"
|
|
||||||
>
|
|
||||||
<div class="column is-6">
|
<div class="column is-6">
|
||||||
<h2 class="is-2 hide-overflow">{{ item.Names[0] }}</h2>
|
<h2 class="is-2 hide-overflow">{{ item.Names[0] }}</h2>
|
||||||
<span class="subtitle is-6 code hide-overflow">{{
|
<span class="subtitle is-6 code hide-overflow"> {{ item.Command }} </span>
|
||||||
item.Command
|
|
||||||
}}</span>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="column is-4">
|
<div class="column is-4">
|
||||||
<span class="code hide-overflow">{{ item.Image }}</span>
|
<span class="code hide-overflow">{{ item.Image }}</span>
|
||||||
@@ -48,6 +43,7 @@ export default {
|
|||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
.code {
|
.code {
|
||||||
background-color: #f5f5f5;
|
background-color: #f5f5f5;
|
||||||
color: #ff3860;
|
color: #ff3860;
|
||||||
|
|||||||
2
main.go
2
main.go
@@ -86,7 +86,7 @@ func logs(w http.ResponseWriter, r *http.Request) {
|
|||||||
for {
|
for {
|
||||||
_, err := reader.Read(hdr)
|
_, err := reader.Read(hdr)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
panic(err)
|
log.Panicln(err)
|
||||||
}
|
}
|
||||||
count := binary.BigEndian.Uint32(hdr[4:])
|
count := binary.BigEndian.Uint32(hdr[4:])
|
||||||
n, err := reader.Read(content[:count])
|
n, err := reader.Read(content[:count])
|
||||||
|
|||||||
Reference in New Issue
Block a user