Tiny markdown parser, makes tutorial screens editing much simpler

This commit is contained in:
relikd
2020-08-31 17:10:11 +02:00
parent ff4218981f
commit 8bb77ef741
13 changed files with 182 additions and 94 deletions

View File

@@ -34,27 +34,8 @@ class TBCMain: UITabBarController {
@objc private func showWelcomeMessage() {
let x = TutorialSheet()
x.addSheet().addArrangedSubview(QuickUI.text(attributed: NSMutableAttributedString()
.h1("Welcome\n")
.normal("\nAppCheck helps you identify which applications communicate with third parties. " +
"It does so by logging network requests. " +
"AppCheck learns only the destination addresses, not the actual data that is exchanged." +
"\n\n" +
"Your data belongs to you. " +
"Therefore, monitoring and analysis take place on your device only. " +
"The app does not share any data with us or any other third-party. " +
"Unless you choose to.")
))
x.addSheet().addArrangedSubview(QuickUI.text(attributed: NSMutableAttributedString()
.h1("How it works\n")
.normal("\nAppCheck creates a local VPN tunnel to intercept all network connections. " +
"For each connection AppCheck looks into the DNS headers only, namely the domain names. " +
"\n" +
"These domain names are logged in the background while the VPN is active. " +
"That means, AppCheck does not have to be active in the foreground. " +
"You can close the app and come back later to see the results."
)
))
x.addSheet().addArrangedSubview(TinyMarkdown.load("tut-welcome-1"))
x.addSheet().addArrangedSubview(TinyMarkdown.load("tut-welcome-2"))
x.present {
Prefs.DidShowTutorial.Welcome = true
}