-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
merge(#10): remove Passbase, add logging, refactor code, add SDK vers…
…ion params
- Loading branch information
Showing
16 changed files
with
89 additions
and
216 deletions.
There are no files selected for viewing
This file contains 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 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 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 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 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 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 |
---|---|---|
@@ -1,8 +1,18 @@ | ||
import Foundation | ||
|
||
// use | ||
// genstrings -o Sources/Ramp/Resources/en.lproj Sources/Ramp/*.swift | ||
// to regenerate Localizable.strings | ||
|
||
struct Localizable { | ||
static var closeAlertTitle: String { NSLocalizedString("Do you really want to close Ramp?", comment: "Alert title for closing Ramp") } | ||
static var closeAlertMessage: String { NSLocalizedString("You will loose all progress and will have to start over", comment: "Alert message for closing Ramp") } | ||
static var closeAlertTitle: String { | ||
NSLocalizedString("Do you really want to close Ramp?", | ||
comment: "Alert title for closing Ramp") | ||
} | ||
static var closeAlertMessage: String { | ||
NSLocalizedString("You will loose all progress and will have to start over", | ||
comment: "Alert message for closing Ramp") | ||
} | ||
static var yes: String { NSLocalizedString("Yes", comment: "Yes") } | ||
static var no: String { NSLocalizedString("No", comment: "No") } | ||
} |
This file contains 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,15 @@ | ||
import Foundation | ||
|
||
struct Logger { | ||
static func debug(_ message: String) { | ||
#if DEBUG | ||
print("[debug]", message) | ||
#endif | ||
} | ||
|
||
static func error(_ error: Error) { | ||
#if DEBUG | ||
print("[error]", String(describing: error)) | ||
#endif | ||
} | ||
} |
This file contains 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 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 was deleted.
Oops, something went wrong.
This file contains 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 |
---|---|---|
@@ -1,8 +1,16 @@ | ||
import Foundation | ||
|
||
public protocol RampDelegate: AnyObject { | ||
func ramp(_ rampViewController: RampViewController, didCreateOnrampPurchase purchase: OnrampPurchase, _ purchaseViewToken: String, _ apiUrl: URL) | ||
func ramp(_ rampViewController: RampViewController, didRequestSendCrypto payload: SendCryptoPayload, responseHandler: @escaping (SendCryptoResultPayload) -> Void) | ||
func ramp(_ rampViewController: RampViewController, didCreateOfframpSale sale: OfframpSale, _ saleViewToken: String, _ apiUrl: URL) | ||
func ramp(_ rampViewController: RampViewController, | ||
didCreateOnrampPurchase purchase: OnrampPurchase, | ||
_ purchaseViewToken: String, | ||
_ apiUrl: URL) | ||
func ramp(_ rampViewController: RampViewController, | ||
didRequestSendCrypto payload: SendCryptoPayload, | ||
responseHandler: @escaping (SendCryptoResultPayload) -> Void) | ||
func ramp(_ rampViewController: RampViewController, | ||
didCreateOfframpSale sale: OfframpSale, | ||
_ saleViewToken: String, | ||
_ apiUrl: URL) | ||
func rampDidClose(_ rampViewController: RampViewController) | ||
} |
Oops, something went wrong.