From 73d67c33aa97f23df3d0a7aa1966d50f1893dff8 Mon Sep 17 00:00:00 2001 From: Matt Isenhower Date: Wed, 30 Nov 2022 22:21:23 -0800 Subject: [PATCH] Add X Battles to the schedule tweet --- app/twitter/generators/SchedulesTweet.mjs | 15 +++++++++++++-- .../screenshots/ScreenshotScheduleBox.vue | 16 ++++++++-------- src/views/screenshots/SchedulesView.vue | 1 + 3 files changed, 22 insertions(+), 10 deletions(-) diff --git a/app/twitter/generators/SchedulesTweet.mjs b/app/twitter/generators/SchedulesTweet.mjs index 993c826..31f74bb 100644 --- a/app/twitter/generators/SchedulesTweet.mjs +++ b/app/twitter/generators/SchedulesTweet.mjs @@ -1,6 +1,6 @@ import TweetGenerator from "./TweetGenerator.mjs"; import Media from "../Media.mjs"; -import { useAnarchyOpenSchedulesStore, useAnarchySeriesSchedulesStore, useRegularSchedulesStore, useSplatfestSchedulesStore } from "../../../src/stores/schedules.mjs"; +import { useAnarchyOpenSchedulesStore, useAnarchySeriesSchedulesStore, useLeagueSchedulesStore, useRegularSchedulesStore, useSplatfestSchedulesStore, useXSchedulesStore } from "../../../src/stores/schedules.mjs"; import { useUSSplatfestsStore } from '../../../src/stores/splatfests.mjs'; export default class SchedulesTweet extends TweetGenerator { @@ -14,6 +14,8 @@ export default class SchedulesTweet extends TweetGenerator regular: useRegularSchedulesStore().activeSchedule, anarchySeries: useAnarchySeriesSchedulesStore().activeSchedule, anarchyOpen: useAnarchyOpenSchedulesStore().activeSchedule, + xMatch: useXSchedulesStore().activeSchedule, + league: useLeagueSchedulesStore().activeSchedule, splatfest: useSplatfestSchedulesStore().activeSchedule, tricolor: useUSSplatfestsStore().tricolor, } @@ -40,7 +42,15 @@ export default class SchedulesTweet extends TweetGenerator return `Join the global Splatfest Battle on ${festStages[0].name} and ${festStages[1].name}! #splatfest #maprotation`; } - return `Splatoon 3 map rotation: Anarchy (Series) game mode: ${stages.anarchySeries.settings.vsRule.name}, Anarchy (Open) game mode: ${stages.anarchyOpen.settings.vsRule.name} #maprotation`; + let lines = [ + 'Splatoon 3 map rotation: #maprotation', + '', + `– Anarchy (Series): ${stages.anarchySeries.settings.vsRule.name}`, + `– Anarchy (Open): ${stages.anarchyOpen.settings.vsRule.name}`, + `– X Battle: ${stages.xMatch.settings.vsRule.name}`, + ]; + + return lines.join('\n'); } /** @param {ScreenshotHelper} screenshotHelper */ @@ -72,6 +82,7 @@ export default class SchedulesTweet extends TweetGenerator `Regular Battle: ${detail(stages.regular)}`, `Anarchy Battle (Series): ${detail(stages.anarchySeries)}`, `Anarchy Battle (Open): ${detail(stages.anarchyOpen)}`, + `X Battle: ${detail(stages.xMatch)}`, ]); } diff --git a/src/components/screenshots/ScreenshotScheduleBox.vue b/src/components/screenshots/ScreenshotScheduleBox.vue index 1fb1531..b77b4e8 100644 --- a/src/components/screenshots/ScreenshotScheduleBox.vue +++ b/src/components/screenshots/ScreenshotScheduleBox.vue @@ -2,24 +2,24 @@
-
+
{{ $t(type.name) }}
-
+
- +
{{ store.activeSchedule.settings.vsRule.name }}
- -
+ +
{{ $t(type.badge) }}
@@ -32,20 +32,20 @@ class="flex-1" imgClass="rounded-2xl" :stage="store.activeSchedule.settings.vsStages[0]" - textSize="text-3xl" + textSize="text-xl" />
diff --git a/src/views/screenshots/SchedulesView.vue b/src/views/screenshots/SchedulesView.vue index d1a74c4..2b05ebf 100644 --- a/src/views/screenshots/SchedulesView.vue +++ b/src/views/screenshots/SchedulesView.vue @@ -15,6 +15,7 @@ +