-
Notifications
You must be signed in to change notification settings - Fork 399
feat: [M3-7063] - Provide dynamic price error handling for DC-specific pricing #9660
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
Merged
Merged
Changes from all commits
Commits
Show all changes
61 commits
Select commit
Hold shift + click to select a range
8449fb1
feat: [M3-7063] - Provide error handling when DC-specific pricing can…
cpathipa 9549003
Code clean up
cpathipa d9071f4
Merge remote-tracking branch 'origin/develop' into M3-7063
cpathipa 042de12
Adjust unit tests
cpathipa 1e005d2
Update Currency.test.tsx
cpathipa 3f6cd69
Update kubernetes.test.tsx
cpathipa 0fa33a6
Merge remote-tracking branch 'origin/develop' into M3-7063
cpathipa 99d1297
Update linodes.test.ts
cpathipa 552eb9c
Delete linodes.test.tsx
cpathipa 241cd20
Merge remote-tracking branch 'origin/develop' into M3-7063
cpathipa 047360b
Code cleanup
cpathipa faa46ab
UX changes for UX-427
cpathipa d51b65e
pricing util getPrice
cpathipa 7fca053
Update packages/manager/src/features/Kubernetes/KubernetesClusterDeta…
cpathipa ea6d809
Update packages/manager/src/features/Kubernetes/KubernetesClusterDeta…
cpathipa 7d8957c
Update packages/manager/src/utilities/pricing/backups.ts
cpathipa 3c92068
Update packages/manager/src/features/Linodes/MigrateLinode/ConfigureF…
cpathipa 5961de5
Update packages/manager/src/features/Linodes/LinodesCreate/AddonsPane…
cpathipa ea425fa
Update packages/manager/src/features/components/PlansPanel/PlanSelect…
cpathipa ceaebc9
Update packages/manager/src/features/components/PlansPanel/PlanSelect…
cpathipa acb0d31
Update packages/manager/src/utilities/pricing/dynamicPricing.test.ts
cpathipa 7dbe600
Update packages/manager/src/utilities/pricing/linodes.test.ts
cpathipa 0d2913a
Update packages/manager/src/utilities/pricing/linodes.test.ts
cpathipa 2cb3a0d
Update packages/manager/src/utilities/pricing/linodes.ts
cpathipa 7784f6f
Update packages/manager/src/components/Currency/Currency.test.tsx
cpathipa ec8aef8
Update packages/manager/src/utilities/pricing/dynamicPricing.ts
cpathipa ddd78cd
Merge remote-tracking branch 'origin' into M3-7063
cpathipa 623abb6
Update packages/manager/src/components/Currency/Currency.tsx
cpathipa bca3a70
Update packages/manager/src/components/DisplayPrice/DisplayPrice.tsx
cpathipa 0181e55
Update packages/manager/src/utilities/pricing/dynamicPricing.ts
cpathipa 799de0b
Update packages/manager/src/features/Linodes/LinodesCreate/AddonsPane…
cpathipa af73c35
PR - Feedback
cpathipa 58747ee
Merge remote-tracking branch 'origin/develop' into M3-7063
cpathipa eb867e7
Resolve type error
cpathipa fbc197f
User const UNKNOWN_PRICE
cpathipa 3f3fd64
Update packages/manager/src/components/DisplayPrice/DisplayPrice.tsx
cpathipa 379a0eb
Use const PRICE_ERROR_NOTICE_TEXT
cpathipa d80ec29
Merge branch 'M3-7063' of github.com:cpathipa/manager into M3-7063
cpathipa 14470f9
use const PRICES_RELOAD_ERROR_NOTICE_TEXT
cpathipa ece46f1
use const PRICES_RELOAD_ERROR_NOTICE_TEXT
cpathipa 112d8b0
PR Feedback
cpathipa 58f9161
Code cleanup
cpathipa a10a09e
Update constant name for accuracy
b0139a5
Clean up in Add Node Pool drawer
d4288d3
Clean up; match prod for Create Linode addons, summary
9196d1f
Fix a typo in a ternary
e45e5ba
Merge branch 'develop' into M3-7063
869718a
Address feedback
a6b3353
Added changeset: Dynamic price error handling for DC-specific pricing
3586a2a
Fix table cell error tooltip on plans table
bbc4602
Fix copy in resize node pools drawer causing e2e failure
70210ef
Clean up; fix failing backups test
da5bea8
PR feedback - handle NAN in calculating getTotalBackupsPrice
cpathipa 44d2642
Reattempted, hopefully passing, not ideal backup linode types fix
df760f6
Merge remote-tracking branch 'origin/develop' into M3-7063
cpathipa b93982d
Update packages/manager/src/utilities/pricing/linodes.ts
cpathipa ac0b29c
Merge branch 'develop' into M3-7063
0338b09
Update smoke-create-nodebal.spec.ts rendering of price
8f08a48
Address feedback - remove unnecessary fallback
1102555
Address feedback - missing error icon
4646b77
Address feedback - disable Add button on pricing error
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| --- | ||
| "@linode/manager": Added | ||
| --- | ||
|
|
||
| Dynamic price error handling for DC-specific pricing ([#9660](https://github.com/linode/manager/pull/9660)) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -8,7 +8,7 @@ export interface DisplayPriceProps { | |
| decimalPlaces?: number; | ||
| fontSize?: string; | ||
| interval?: string; | ||
| price: number; | ||
| price: '--.--' | number; | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We expect display price to be either a number or an UNKNOWN_PRICE, which we define as |
||
| } | ||
|
|
||
| export const displayPrice = (price: number) => `$${price.toFixed(2)}`; | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
We expect currency to be either a number or an UNKNOWN_PRICE, which we define as
--.--. We use the literal here, rather thantypeoforstringso that we avoid introducing other ways of displaying unknown prices.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.
I like it, that's a nice fallback 👍