Skip to content

Commit ebf54c8

Browse files
committed
(ios) Adding ability to receive a payment via NFC (bolt card)
1 parent 666cbf2 commit ebf54c8

File tree

5 files changed

+365
-22
lines changed

5 files changed

+365
-22
lines changed

phoenix-ios/phoenix-ios/Localizable.xcstrings

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6916,6 +6916,9 @@
69166916
}
69176917
}
69186918
}
6919+
},
6920+
"Awaiting payment…" : {
6921+
69196922
},
69206923
"Back" : {
69216924
"localizations" : {
@@ -8737,6 +8740,9 @@
87378740
}
87388741
}
87398742
},
8743+
"card" : {
8744+
"comment" : "button label - try to make it short"
8745+
},
87408746
"Caused by" : {
87418747
"localizations" : {
87428748
"ar" : {
@@ -10567,6 +10573,9 @@
1056710573
},
1056810574
"Communicating with card reader." : {
1056910575

10576+
},
10577+
"Communicating with card's host…" : {
10578+
1057010579
},
1057110580
"completed at" : {
1057210581
"comment" : "Label in DetailsView_IncomingPayment",
@@ -12189,6 +12198,12 @@
1218912198
}
1219012199
}
1219112200
},
12201+
"Could not communicate with card's wallet" : {
12202+
"comment" : "Error message - scanning lightning invoice"
12203+
},
12204+
"Could not connect to card's host" : {
12205+
"comment" : "Error message - processing bolt card payment"
12206+
},
1219212207
"Could not connect to host:" : {
1219312208
"localizations" : {
1219412209
"ar" : {
@@ -12391,6 +12406,9 @@
1239112406
}
1239212407
}
1239312408
}
12409+
},
12410+
"Cound not communicate with card's wallet" : {
12411+
1239412412
},
1239512413
"Create new contact" : {
1239612414

@@ -15062,6 +15080,9 @@
1506215080
}
1506315081
}
1506415082
}
15083+
},
15084+
"Does not appear to be a bolt card." : {
15085+
1506515086
},
1506615087
"Don't lose your funds:" : {
1506715088
"localizations" : {
@@ -27596,6 +27617,9 @@
2759627617
}
2759727618
}
2759827619
}
27620+
},
27621+
"No URI detected in NFC tag" : {
27622+
2759927623
},
2760027624
"No URI or text detected in NFC tag" : {
2760127625

@@ -32384,6 +32408,9 @@
3238432408
}
3238532409
}
3238632410
}
32411+
},
32412+
"Reading card…" : {
32413+
3238732414
},
3238832415
"Ready For Swap" : {
3238932416
"localizations" : {
@@ -33231,6 +33258,9 @@
3323133258
}
3323233259
}
3323333260
}
33261+
},
33262+
"Requesting payment…" : {
33263+
3323433264
},
3323533265
"Requesting Swap-In Address..." : {
3323633266
"extractionState" : "manual",
@@ -38692,6 +38722,12 @@
3869238722
}
3869338723
}
3869438724
},
38725+
"The card's host returned error code: %d" : {
38726+
"comment" : "Error message - processing bolt card payment"
38727+
},
38728+
"The card's host returned error message: %@" : {
38729+
"comment" : "Error message - processing bolt card payment"
38730+
},
3869538731
"The closing transaction is in your transactions list." : {
3869638732
"comment" : "label text",
3869738733
"localizations" : {
@@ -43757,6 +43793,9 @@
4375743793
}
4375843794
}
4375943795
},
43796+
"Unreadable response from card's host" : {
43797+
"comment" : "Error message - processing bolt card payment"
43798+
},
4376043799
"Unreadable response from service: %@" : {
4376143800
"comment" : "Error message - scanning lightning invoice",
4376243801
"localizations" : {

phoenix-ios/phoenix-ios/nfc/NfcReader.swift

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,5 +129,9 @@ class NfcReader: NSObject, NFCNDEFReaderSessionDelegate {
129129
finishWithSuccess(message)
130130
}
131131
}
132-
132+
133+
/* Note: When this delegate function exists, it seems to break functionality on iOS 16.
134+
func readerSession(_ session: NFCNDEFReaderSession, didDetect tags: [any NFCNDEFTag]) {
135+
}
136+
*/
133137
}

0 commit comments

Comments
 (0)