Browse Source

Format prettier after update

pull/3506/head
Pavel Djundik 2 years ago
parent
commit
a13bcb8e93
  1. 1
      .prettierignore
  2. 4
      client/components/MessageTypes/topic.vue
  3. 5
      client/js/socket-events/quit.js
  4. 20
      test/client/js/libs/handlebars/ircmessageparser/fill.js
  5. 6
      test/src/command-line/utilsTest.js

1
.prettierignore

@ -21,5 +21,6 @@ yarn.lock
.editorconfig
.eslintignore
.gitattributes
.browserslistrc
*.css

4
client/components/MessageTypes/topic.vue

@ -3,9 +3,7 @@
<template v-if="message.from && message.from.nick"
><Username :user="message.from" /> has changed the topic to:
</template>
<template v-else
>The topic is:
</template>
<template v-else>The topic is: </template>
<span v-if="message.text" class="new-topic"
><ParsedMessage :network="network" :message="message"
/></span>

5
client/js/socket-events/quit.js

@ -6,7 +6,10 @@ const sidebar = $("#sidebar");
const {vueApp} = require("../vue");
socket.on("quit", function(data) {
vueApp.networks.splice(vueApp.networks.findIndex((n) => n.uuid === data.network), 1);
vueApp.networks.splice(
vueApp.networks.findIndex((n) => n.uuid === data.network),
1
);
vueApp.$nextTick(() => {
const chan = sidebar.find(".chan");

20
test/client/js/libs/handlebars/ircmessageparser/fill.js

@ -7,7 +7,10 @@ describe("fill", () => {
const text = "01234567890123456789";
it("should return an entry for the unmatched end of string", () => {
const existingEntries = [{start: 0, end: 10}, {start: 5, end: 15}];
const existingEntries = [
{start: 0, end: 10},
{start: 5, end: 15},
];
const expected = [{start: 15, end: 20}];
@ -17,9 +20,15 @@ describe("fill", () => {
});
it("should return an entry per unmatched areas of the text", () => {
const existingEntries = [{start: 0, end: 5}, {start: 10, end: 15}];
const existingEntries = [
{start: 0, end: 5},
{start: 10, end: 15},
];
const expected = [{start: 5, end: 10}, {start: 15, end: 20}];
const expected = [
{start: 5, end: 10},
{start: 15, end: 20},
];
const actual = fill(existingEntries, text);
@ -27,7 +36,10 @@ describe("fill", () => {
});
it("should not return anything when entries match all text", () => {
const existingEntries = [{start: 0, end: 10}, {start: 10, end: 20}];
const existingEntries = [
{start: 0, end: 10},
{start: 10, end: 20},
];
const actual = fill(existingEntries, text);

6
test/src/command-line/utilsTest.js

@ -117,9 +117,9 @@ describe("Utils", function() {
});
it("should maintain existing properties of a nested object", function() {
expect(Utils.parseConfigOptions("foo.bar=true", {foo: {baz: false}})).to.deep.equal(
{foo: {bar: true, baz: false}}
);
expect(
Utils.parseConfigOptions("foo.bar=true", {foo: {baz: false}})
).to.deep.equal({foo: {bar: true, baz: false}});
});
it("should maintain existing entries of an array", function() {

Loading…
Cancel
Save