1
0
mirror of https://github.com/nicoverbruggen/phpmon.git synced 2025-08-07 12:00:09 +02:00

🍱 Tweaked onboarding screen

This commit is contained in:
2022-07-13 11:27:32 +02:00
parent 6e3bb1d322
commit 8a8d32cb5d
9 changed files with 131 additions and 25 deletions

View File

@ -0,0 +1,6 @@
{
"info" : {
"author" : "xcode",
"version" : 1
}
}

View File

@ -0,0 +1,21 @@
{
"images" : [
{
"filename" : "tour3.heic",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

Binary file not shown.

View File

@ -0,0 +1,21 @@
{
"images" : [
{
"filename" : "tour4.heic",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

Binary file not shown.

View File

@ -0,0 +1,21 @@
{
"images" : [
{
"filename" : "tour2.heic",
"idiom" : "universal",
"scale" : "1x"
},
{
"idiom" : "universal",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}

Binary file not shown.

View File

@ -10,41 +10,66 @@ import SwiftUI
struct OnboardingView: View {
var body: some View {
HStack(alignment: .top) {
VStack(alignment: .center) {
Image(nsImage: NSApp.applicationIconImage)
.resizable()
.padding()
.frame(width: 120, height: 120)
VStack(alignment: .leading) {
Text("Welcome to PHP Monitor!")
.frame(width: 90, height: 90)
Text("onboarding.welcome".localized)
.font(.title)
.bold()
.padding(.bottom, 5)
Text("If you're seeing this message, then the app has successfully started without any issues. That's honestly the hardest part — from now on I hope it's smooth sailing for you.")
Text("onboarding.explore".localized)
.padding(.bottom)
VStack(alignment: .leading) {
Text("Switch PHP versions").font(.headline)
Text("Manage your domains").font(.headline)
Text("Domain-specific PHP version isolation").font(.headline)
Text("Find your configuration files").font(.headline)
}
Text("I hope you find the app as useful as I do. Enjoy, and if you can, please consider supporting the app. Thank you!")
TabView {
VStack {
Image("Tour.MenuBar")
.resizable()
.aspectRatio(contentMode: .fit)
.padding(.top)
.padding(.bottom)
VStack(alignment: .leading) {
Button("Get Started") {
//
Text("onboarding.tour.menu_bar".localized)
.padding(.init(top: 5, leading: 20, bottom: 20, trailing: 20))
}.tabItem { Label("onboarding.tour.menu_bar.title".localized, systemImage: "") }
VStack {
Image("Tour.Domains")
.resizable()
.aspectRatio(contentMode: .fit)
.padding(.top)
Text("onboarding.tour.domains".localized)
.padding(.init(top: 5, leading: 20, bottom: 20, trailing: 20))
}.tabItem { Label("onboarding.tour.domains.title".localized, systemImage: "") }
VStack {
Image("Tour.Isolation")
.resizable()
.aspectRatio(contentMode: .fit)
.padding(.top)
Text("onboarding.tour.isolation".localized)
.padding(.init(top: 5, leading: 20, bottom: 20, trailing: 20))
}.tabItem { Label("onboarding.tour.isolation.title".localized, systemImage: "") }
}
Text("onboarding.tour.once".localized)
.font(.subheadline)
.foregroundColor(.gray)
.padding(.top, 5)
Button("Close Tour") {
}
}
}.frame(maxWidth: .infinity)
}.padding(20)
.frame(maxWidth: .infinity)
.padding()
}
}
struct OnboardingView_Previews: PreviewProvider {
static var previews: some View {
Group {
OnboardingView().frame(
width: 600
width: 600,
height: 600
)
OnboardingView().preferredColorScheme(.dark).frame(
width: 600,
height: 600
)
}
}
}

View File

@ -497,3 +497,15 @@ You can do this by running `composer global update` in your terminal. After that
"alert.warnings.tld_issue.title" = "You are not using `.test` as the TLD for Valet.";
"alert.warnings.tld_issue.subtitle" = "Using a non-default TLD may not work correctly and is not officially supported.";
"alert.warnings.tld_issue.description" = "PHP Monitor will remain functional, but there might be issues: the app might not correctly show which domains have been secured. For optimal results, go to your Valet configuration file (config.json in the Valet directory) and change the TLD back to `test`.";
// ONBOARDING
"onboarding.welcome" = "Welcome to PHP Monitor!";
"onboarding.explore" = "Explore some of the features below, or close the tour and get started.";
"onboarding.tour.menu_bar.title" = "Get Started";
"onboarding.tour.menu_bar" = "PHP Monitor lives in your menu bar. From here, you can switch the globally linked PHP version, start or stop services, locate configuration files, and more.";
"onboarding.tour.domains.title" = "Domains";
"onboarding.tour.domains" = "By opening the Domains window via the Menu Bar item, you can view which domains are linked and parked.";
"onboarding.tour.isolation.title" = "Isolation";
"onboarding.tour.isolation" = "If you have Valet 3 installed, you can even use domain isolation by right-clicking on a given domain in the Domains window. This allows you to pick a specific version of PHP to use for that domain!";
"onboarding.tour.once" = "You will only see the Welcome Tour once. You can re-open the Welcome Tour later via the menu bar icon.";