Skip to content

Commit

Permalink
update: Add new Notification strings (#197)
Browse files Browse the repository at this point in the history
  • Loading branch information
jaredvu authored Dec 8, 2023
1 parent 6731440 commit 87e3151
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 5 deletions.
1 change: 1 addition & 0 deletions config/localization/en/app.json
Original file line number Diff line number Diff line change
Expand Up @@ -1001,6 +1001,7 @@
"FEE": "Fee",
"FILL_OR_KILL": "Fill Or Kill",
"FILLS_EMPTY_STATE": "You have no fills.",
"FINAL_SETTLEMENT": "Final Settlement",
"FULL_CLOSE": "Full close",
"FUNDING_PAYMENTS_EMPTY_STATE": "You have no past funding payments.",
"FUNDING_PAYMENTS_SHORT": "Funding",
Expand Down
14 changes: 13 additions & 1 deletion config/localization_notifications/en/app.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
{
"NOTIFICATIONS": {
"DELEVERAGED": {
"TITLE": "Position Deleveraged",
"BODY": "Your {SIDE} position on {MARKET} has been deleveraged."
},
"FINAL_SETTLEMENT": {
"TITLE": "Position Settled",
"BODY": "{MARKET} has closed. Your {SIDE} position on {MARKET} has reached final settlement."
},
"OFFSETTING": {
"TITLE": "Position Offsetting",
"BODY": "Your {SIDE} position on {MARKET} was used to offset a deleveraged position."
},
"ORDER_FILL": {
"TITLE": "Order Filled",
"BODY": "Your order to {SIDE} {AMOUNT} {MARKET} has been filled at ${AVERAGE_PRICE}."
Expand Down Expand Up @@ -49,4 +61,4 @@
"BODY": "Your withdrawal of {AMOUNT} {ASSET} has been confirmed."
}
}
}
}
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dydxprotocol/v4-localization",
"version": "1.0.17",
"version": "1.0.18",
"description": "v4 localization",
"main": "index.ts",
"scripts": {
Expand Down
3 changes: 2 additions & 1 deletion scripts/generated/app.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// !! GENERATED FILE - DO NOT EDIT

// Generated from ../config/localization/en/app.json using ./codegen_localization_app.swift
// Generated from ../config/localization/en/app.json using codegen_localization_app.swift

export const APP_STRING_KEYS = {

Expand Down Expand Up @@ -1216,6 +1216,7 @@ export const APP_STRING_KEYS = {
FEE_PERCENT: 'APP.TRADE.FEE_PERCENT',
FILLS_EMPTY_STATE: 'APP.TRADE.FILLS_EMPTY_STATE',
FILL_OR_KILL: 'APP.TRADE.FILL_OR_KILL',
FINAL_SETTLEMENT: 'APP.TRADE.FINAL_SETTLEMENT',
FULL_CLOSE: 'APP.TRADE.FULL_CLOSE',
FUNDING_PAYMENTS: 'APP.TRADE.FUNDING_PAYMENTS',
FUNDING_PAYMENTS_EMPTY_STATE: 'APP.TRADE.FUNDING_PAYMENTS_EMPTY_STATE',
Expand Down
6 changes: 6 additions & 0 deletions scripts/generated/notifications.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,18 @@
// Generated from ../config/localization_notifications/en/app.json using ../config/localization_notifications/en/app.json

export const NOTIFICATIONS_STRING_KEYS = {
DELEVERAGED_BODY: 'NOTIFICATIONS.DELEVERAGED.BODY',
DELEVERAGED_TITLE: 'NOTIFICATIONS.DELEVERAGED.TITLE',
DEPOSIT_SUCCESS_BODY: 'NOTIFICATIONS.DEPOSIT_SUCCESS.BODY',
DEPOSIT_SUCCESS_TITLE: 'NOTIFICATIONS.DEPOSIT_SUCCESS.TITLE',
FAST_WITHDRAW_SUCCESS_BODY: 'NOTIFICATIONS.FAST_WITHDRAW_SUCCESS.BODY',
FAST_WITHDRAW_SUCCESS_TITLE: 'NOTIFICATIONS.FAST_WITHDRAW_SUCCESS.TITLE',
FINAL_SETTLEMENT_BODY: 'NOTIFICATIONS.FINAL_SETTLEMENT.BODY',
FINAL_SETTLEMENT_TITLE: 'NOTIFICATIONS.FINAL_SETTLEMENT.TITLE',
LIQUIDATION_BODY: 'NOTIFICATIONS.LIQUIDATION.BODY',
LIQUIDATION_TITLE: 'NOTIFICATIONS.LIQUIDATION.TITLE',
OFFSETTING_BODY: 'NOTIFICATIONS.OFFSETTING.BODY',
OFFSETTING_TITLE: 'NOTIFICATIONS.OFFSETTING.TITLE',
ORDER_CANCEL_BODY: 'NOTIFICATIONS.ORDER_CANCEL.BODY',
ORDER_CANCEL_TITLE: 'NOTIFICATIONS.ORDER_CANCEL.TITLE',
ORDER_CANCEL_WITH_PARTIAL_FILL_BODY: 'NOTIFICATIONS.ORDER_CANCEL_WITH_PARTIAL_FILL.BODY',
Expand Down

0 comments on commit 87e3151

Please sign in to comment.