Skip to content

Commit

Permalink
change format
Browse files Browse the repository at this point in the history
  • Loading branch information
ender-null committed May 5, 2024
1 parent 7c5b60b commit 6fb6da1
Show file tree
Hide file tree
Showing 7 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions src/plugins/help.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,10 @@ export class HelpPlugin extends PluginBase {
const lines = doc.split('\n');
if (!isCommand(this, 3, msg.content) || this.bot.config.prefix == '/' || command.keepDefault) {
if (showAll) {
text += `\n ${lines[0]}`;
text += `\n- ${lines[0]}`;
} else {
if (!command.skipHelp) {
text += `\n ${lines[0]}\n ${lines[1]}`;
text += `\n- ${lines[0]}\n ${lines[1]}`;
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/plugins/pin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ export class PinPlugin extends PluginBase {
if (ownPins.length > 0) {
text = format(this.strings.pins, ownPins.length);
ownPins.map((pin) => {
text += `\n #${pin.tag}`;
text += `\n- #${pin.tag}`;
});
} else {
text = this.strings.noPins;
Expand Down
2 changes: 1 addition & 1 deletion src/plugins/search.ts
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ export class SearchPlugin extends PluginBase {
if (item['t'].length > 26) {
item['t'] = item['t'].slice(0, 23) + '...';
}
text += `\n <a href="${item['u']}">${item['t']}</a>`;
text += `\n- <a href="${item['u']}">${item['t']}</a>`;
limit -= 1;
}
});
Expand Down
2 changes: 1 addition & 1 deletion src/plugins/telegram.ts
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ export class TelegramPlugin extends PluginBase {
if (doc) {
const lines = doc.split('\n');

text += `\n ${lines[0]}`;
text += `\n- ${lines[0]}`;

if (lines.length > 1) {
text += `\n ${lines[1]}`;
Expand Down
2 changes: 1 addition & 1 deletion src/plugins/valencia.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ export class ValenciaPlugin extends PluginBase {
line = $('img').eq(i).attr('title');
const show = $(elem).text().replace('.', '. ').trim();
const showSplit = show.split(' - ');
text += ` <b>${showSplit[1]}</b> ${line} <i>${showSplit[0]}</i>\n`;
text += `- <b>${showSplit[1]}</b> ${line} <i>${showSplit[0]}</i>\n`;
});

if (line == '') {
Expand Down
2 changes: 1 addition & 1 deletion src/plugins/youtube.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export class YouTubePlugin extends PluginBase {
if (item.snippet.title.length > 26) {
item.snippet.title = item.snippet.title.split(0, 23) + '...';
}
text += `\n <a href="https://youtu.be/${item.id.videoId}">${item.snippet.title}</a>`;
text += `\n- <a href="https://youtu.be/${item.id.videoId}">${item.snippet.title}</a>`;
});
this.bot.replyMessage(msg, text, 'text', null, { preview: false });
}
Expand Down
4 changes: 2 additions & 2 deletions src/plugins/zaragoza.ts
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ export class ZaragozaPlugin extends PluginBase {

if (content.times && Array.isArray(content.times)) {
content.times.map((bus) => {
text += `\n <b>${bus.time}</b> ${bus.line} <i>${bus.destination}</i>`;
text += `\n- <b>${bus.time}</b> ${bus.line} <i>${bus.destination}</i>`;
});
} else {
return this.bot.replyMessage(msg, this.bot.errors.noResults);
Expand Down Expand Up @@ -111,7 +111,7 @@ export class ZaragozaPlugin extends PluginBase {
}
text = `<b>${capitalize(content.title)}</b>\n ${this.strings.station}: <b>${
content.id
}</b>\n\nBicis Disponibles: <b>${content.bicisDisponibles}</b>\n Anclajes Disponibles: <b>${
}</b>\n\n- Bicis Disponibles: <b>${content.bicisDisponibles}</b>\n- Anclajes Disponibles: <b>${
content.anclajesDisponibles
}</b>`;
}
Expand Down

0 comments on commit 6fb6da1

Please sign in to comment.