-
Notifications
You must be signed in to change notification settings - Fork 90
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[SALAD-23116] WebApp - Connect demand alerts page #1243
base: master
Are you sure you want to change the base?
Conversation
const demandScenario: Record<number, string> = { | ||
0: 'Low Demand', | ||
50: 'Moderate Demand', | ||
80: 'High Demand', | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
packages/web-app/src/modules/demand-alerts-views/constants.ts
let's use this const demandScenario
to avoid data duplication
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agree
Changed
export const demandScenario = [ | ||
{ label: 'High Demand', value: '80' }, | ||
{ label: 'Moderate Demand', value: '50' }, | ||
{ label: 'Low Demand', value: '0' }, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
export const demandScenario = [ | |
{ label: 'High Demand', value: '80' }, | |
{ label: 'Moderate Demand', value: '50' }, | |
{ label: 'Low Demand', value: '0' }, | |
export const demandScenario = { | |
'80': { label: 'High Demand', value: '80' }, | |
'50': { label: 'Moderate Demand', value: '50' }, | |
'0': { label: 'Low Demand', value: '0' }, | |
} |
const withCancelSubscriptionSubmitting = | ||
unsubscribeFromDemandAlertStatus === UnsubscribeFromDemandAlertStatus.SUBMITTING && | ||
isCurrentDemandedSubscriptionId | ||
const withCancelSubscriptionFailure = |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why not name it just
isCancelSubscriptionSubmitting
isCancelSubscriptionFailure
Description: Connect demand alerts page