mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-15 21:57:22 +01:00
* feat(subscription): promo banner in modal * feat(subscription): promo banner on main page * fix(banners): remove extraneous margin adjustment * fix(banners): various * feat(promotion): gift 1, get 1 * fix(promo): various * chore(promo): add Bailey * fix(promo): use different email template for promo beneficiary * fix(promo): turns out Winter is meaningful
42 lines
967 B
JavaScript
42 lines
967 B
JavaScript
// @TODO: This might become too generic. If so, check the refactor docs
|
|
const CONSTANTS = {
|
|
keyConstants: {
|
|
SPELL_DRAWER_STATE: 'spell-drawer-state',
|
|
EQUIPMENT_DRAWER_STATE: 'equipment-drawer-state',
|
|
CURRENT_EQUIPMENT_DRAWER_TAB: 'current-equipment-drawer-tab',
|
|
STABLE_SORT_STATE: 'stable-sort-state',
|
|
GIFTING_BANNER_DISPLAY: 'gifting-banner-display',
|
|
},
|
|
drawerStateValues: {
|
|
DRAWER_CLOSED: 'drawer-closed',
|
|
DRAWER_OPEN: 'drawer-open',
|
|
},
|
|
equipmentDrawerTabValues: {
|
|
COSTUME_TAB: 'costume-tab',
|
|
EQUIPMENT_TAB: 'equipment-tab',
|
|
},
|
|
savedAppStateValues: {
|
|
SAVED_APP_STATE: 'saved-app-state',
|
|
},
|
|
};
|
|
|
|
function setLocalSetting (key, value) {
|
|
localStorage.setItem(key, value);
|
|
}
|
|
|
|
function getLocalSetting (key) {
|
|
return localStorage.getItem(key);
|
|
}
|
|
|
|
function removeLocalSetting (key) {
|
|
return localStorage.removeItem(key);
|
|
}
|
|
|
|
|
|
export {
|
|
CONSTANTS,
|
|
getLocalSetting,
|
|
setLocalSetting,
|
|
removeLocalSetting,
|
|
};
|