From 9c402152e8fc58a82bdea78056ef347c2f0a420f Mon Sep 17 00:00:00 2001 From: Sabe Jones Date: Thu, 8 Apr 2021 16:26:32 -0500 Subject: [PATCH] feat(event): Shiny Seed and Egg Hunt countdowns --- website/client/src/components/shops/quests/questInfo.vue | 6 +----- website/client/src/components/shops/shopItem.vue | 2 +- website/common/script/content/spells.js | 2 ++ website/common/script/libs/getItemInfo.js | 2 ++ website/common/script/libs/shops-seasonal.config.js | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/website/client/src/components/shops/quests/questInfo.vue b/website/client/src/components/shops/quests/questInfo.vue index c13c980c60..f56308c09b 100644 --- a/website/client/src/components/shops/quests/questInfo.vue +++ b/website/client/src/components/shops/quests/questInfo.vue @@ -36,7 +36,7 @@ -
+
{{ limitedString }}
@@ -131,10 +131,6 @@ export default { quest: { type: Object, }, - popoverVersion: { - type: Boolean, - default: false, - }, }, data () { return { diff --git a/website/client/src/components/shops/shopItem.vue b/website/client/src/components/shops/shopItem.vue index cd9e97955d..b6b60e0145 100644 --- a/website/client/src/components/shops/shopItem.vue +++ b/website/client/src/components/shops/shopItem.vue @@ -107,7 +107,7 @@
{{ limitedString }} diff --git a/website/common/script/content/spells.js b/website/common/script/content/spells.js index 93940c3ba5..495b1f07e1 100644 --- a/website/common/script/content/spells.js +++ b/website/common/script/content/spells.js @@ -5,6 +5,7 @@ import statsComputed from '../libs/statsComputed'; // eslint-disable-line import import setDebuffPotionItems from '../libs/setDebuffPotionItems'; // eslint-disable-line import/no-cycle import crit from '../fns/crit'; // eslint-disable-line import/no-cycle import updateStats from '../fns/updateStats'; +import { EVENTS } from './constants'; /* --------------------------------------------------------------- @@ -352,6 +353,7 @@ spells.special = { previousPurchase: true, target: 'user', notes: t('spellSpecialShinySeedNotes'), + event: EVENTS.spring2021, cast (user, target, req) { if (!user.items.special.shinySeed) throw new NotAuthorized(t('spellNotOwned')(req.language)); target.stats.buffs.snowball = false; diff --git a/website/common/script/libs/getItemInfo.js b/website/common/script/libs/getItemInfo.js index f59f5d0f9a..c9d26ac32c 100644 --- a/website/common/script/libs/getItemInfo.js +++ b/website/common/script/libs/getItemInfo.js @@ -178,6 +178,7 @@ export default function getItemInfo (user, type, item, officialPinnedItems, lang class: `inventory_special_${item.key}`, path: `spells.special.${item.key}`, pinType: 'seasonalSpell', + event: item.event, }; break; case 'debuffPotion': @@ -215,6 +216,7 @@ export default function getItemInfo (user, type, item, officialPinnedItems, lang purchaseType: 'quests', path: `quests.${item.key}`, pinType: 'seasonalQuest', + event: item.event, }; break; case 'gear': diff --git a/website/common/script/libs/shops-seasonal.config.js b/website/common/script/libs/shops-seasonal.config.js index fb50933dda..72bd5db381 100644 --- a/website/common/script/libs/shops-seasonal.config.js +++ b/website/common/script/libs/shops-seasonal.config.js @@ -37,7 +37,7 @@ export default { } : {}, - availableSpells: moment().isBetween('2021-04-06T08:00-05:00', '2021-04-30T20:00-05:00') + availableSpells: SHOP_OPEN && moment().isAfter('2021-04-06T08:00-05:00') ? [ 'shinySeed', ]