mirror of
https://github.com/maxgoedjen/secretive.git
synced 2026-03-10 19:47:24 +01:00
WIP
This commit is contained in:
@@ -32,14 +32,14 @@ struct ConfigurationItemView<Content: View>: View {
|
||||
Spacer()
|
||||
switch action {
|
||||
case .copy(let string):
|
||||
Button("Copy", systemImage: "document.on.document") {
|
||||
Button(.copyButton, systemImage: "document.on.document") {
|
||||
NSPasteboard.general.declareTypes([.string], owner: nil)
|
||||
NSPasteboard.general.setString(string, forType: .string)
|
||||
}
|
||||
.labelStyle(.iconOnly)
|
||||
.buttonStyle(.borderless)
|
||||
case .revealInFinder(let rawPath):
|
||||
Button("Reveal in Finder", systemImage: "folder") {
|
||||
Button(.revealInFinderButton, systemImage: "folder") {
|
||||
// All foundation-based normalization methods replace this with the container directly.
|
||||
let processedPath = rawPath.replacingOccurrences(of: "~", with: "/Users/\(NSUserName())")
|
||||
let url = URL(filePath: processedPath)
|
||||
|
||||
@@ -23,7 +23,7 @@ struct IntegrationsView: View {
|
||||
} detail: {
|
||||
IntegrationsDetailView(selectedInstruction: $selectedInstruction)
|
||||
.fauxToolbar {
|
||||
Button("Done") {
|
||||
Button(.onboardingDoneButton) {
|
||||
dismiss()
|
||||
}
|
||||
.normalButton()
|
||||
@@ -190,7 +190,7 @@ private struct Instructions {
|
||||
zsh
|
||||
}
|
||||
|
||||
var gettingStarted: ConfigurationFileInstructions = ConfigurationFileInstructions("Getting Started", id: .gettingStarted)
|
||||
var gettingStarted: ConfigurationFileInstructions = ConfigurationFileInstructions(LocalizedStringResource.integrationsGettingStartedRowTitle, id: .gettingStarted)
|
||||
|
||||
var ssh: ConfigurationFileInstructions {
|
||||
ConfigurationFileInstructions(
|
||||
@@ -243,17 +243,17 @@ private struct Instructions {
|
||||
|
||||
var instructions: [ConfigurationGroup] {
|
||||
[
|
||||
ConfigurationGroup(name: "Integrations", instructions: [
|
||||
ConfigurationGroup(name: LocalizedStringResource.integrationsGettingStartedSectionTitle, instructions: [
|
||||
gettingStarted
|
||||
]),
|
||||
ConfigurationGroup(
|
||||
name: "System",
|
||||
name: LocalizedStringResource.integrationsSystemSectionTitle,
|
||||
instructions: [
|
||||
ssh,
|
||||
git,
|
||||
]
|
||||
),
|
||||
ConfigurationGroup(name: "Shell", instructions: [
|
||||
ConfigurationGroup(name: LocalizedStringResource.integrationsShellSectionTitle, instructions: [
|
||||
zsh,
|
||||
ConfigurationFileInstructions(
|
||||
tool: "bash",
|
||||
@@ -265,9 +265,9 @@ private struct Instructions {
|
||||
configPath: "~/.config/fish/config.fish",
|
||||
configText: "set -x SSH_AUTH_SOCK \(socketPath)"
|
||||
),
|
||||
ConfigurationFileInstructions("other", id: .otherShell),
|
||||
ConfigurationFileInstructions(LocalizedStringResource.integrationsOtherShellRowTitle, id: .otherShell),
|
||||
]),
|
||||
ConfigurationGroup(name: "Other", instructions: [
|
||||
ConfigurationGroup(name: LocalizedStringResource.integrationsOtherSectionTitle, instructions: [
|
||||
ConfigurationFileInstructions(LocalizedStringResource.integrationsAppsRowTitle, id: .otherApp),
|
||||
]),
|
||||
]
|
||||
|
||||
@@ -55,7 +55,7 @@ struct SetupView: View {
|
||||
systemImage: "firewall",
|
||||
) {
|
||||
OnboardingButton(
|
||||
LocalizedStringResource.onboardingIntegrationsButtonTitle,
|
||||
LocalizedStringResource.onboardingIntegrationsButton,
|
||||
complete: integrations,
|
||||
width: buttonWidth
|
||||
) {
|
||||
@@ -70,7 +70,7 @@ struct SetupView: View {
|
||||
.frame(minWidth: 700, maxWidth: .infinity)
|
||||
HStack {
|
||||
Spacer()
|
||||
Button("Done") {
|
||||
Button(.onboardingDoneButton) {
|
||||
setupComplete = true
|
||||
dismiss()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user