mirror of
https://github.com/XcodesOrg/XcodesApp.git
synced 2026-04-27 15:07:39 +00:00
Merge branch 'main' into l10n/zh-TW/230210
This commit is contained in:
commit
c7f9e54796
9 changed files with 144 additions and 748 deletions
|
|
@ -26,18 +26,20 @@ struct NavigationSplitViewWrapper<Sidebar, Detail>: View where Sidebar: View, De
|
||||||
|
|
||||||
if #available(macOS 14, *) {
|
if #available(macOS 14, *) {
|
||||||
sidebar
|
sidebar
|
||||||
.toolbar(removing: .sidebarToggle)
|
.navigationSplitViewColumnWidth(min: 250, ideal: 300)
|
||||||
} else {
|
} else {
|
||||||
sidebar
|
sidebar
|
||||||
}
|
}
|
||||||
} detail: {
|
} detail: {
|
||||||
detail
|
detail
|
||||||
}
|
}
|
||||||
|
.navigationSplitViewStyle(.balanced)
|
||||||
} else {
|
} else {
|
||||||
// Alternative code for earlier versions of OS.
|
// Alternative code for earlier versions of OS.
|
||||||
NavigationView {
|
NavigationView {
|
||||||
// The first column is the sidebar.
|
// The first column is the sidebar.
|
||||||
sidebar
|
sidebar
|
||||||
|
.frame(minWidth: 250)
|
||||||
detail
|
detail
|
||||||
}
|
}
|
||||||
.navigationViewStyle(.columns)
|
.navigationViewStyle(.columns)
|
||||||
|
|
|
||||||
|
|
@ -29,7 +29,7 @@ extension View {
|
||||||
struct Previews_CornerRadius_Previews: PreviewProvider {
|
struct Previews_CornerRadius_Previews: PreviewProvider {
|
||||||
static var previews: some View {
|
static var previews: some View {
|
||||||
HStack {
|
HStack {
|
||||||
Text("XCODES RULES!")
|
Text(verbatim: "XCODES RULES!")
|
||||||
}.xcodesBackground()
|
}.xcodesBackground()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -29,7 +29,7 @@ struct IdenticalBuildsView: View {
|
||||||
.font(.headline)
|
.font(.headline)
|
||||||
|
|
||||||
ForEach(builds, id: \.description) { version in
|
ForEach(builds, id: \.description) { version in
|
||||||
Text("• \(version.appleDescription)")
|
Text(verbatim: "• \(version.appleDescription)")
|
||||||
.font(.subheadline)
|
.font(.subheadline)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -20,7 +20,6 @@ struct MainWindow: View {
|
||||||
var body: some View {
|
var body: some View {
|
||||||
NavigationSplitViewWrapper {
|
NavigationSplitViewWrapper {
|
||||||
XcodeListView(selectedXcodeID: $selectedXcodeID, searchText: searchText, category: category, isInstalledOnly: isInstalledOnly)
|
XcodeListView(selectedXcodeID: $selectedXcodeID, searchText: searchText, category: category, isInstalledOnly: isInstalledOnly)
|
||||||
.frame(minWidth: 250)
|
|
||||||
.layoutPriority(1)
|
.layoutPriority(1)
|
||||||
.alert(item: $appState.xcodeBeingConfirmedForUninstallation) { xcode in
|
.alert(item: $appState.xcodeBeingConfirmedForUninstallation) { xcode in
|
||||||
Alert(title: Text(String(format: localizeString("Alert.Uninstall.Title"), xcode.description)),
|
Alert(title: Text(String(format: localizeString("Alert.Uninstall.Title"), xcode.description)),
|
||||||
|
|
|
||||||
|
|
@ -80,12 +80,14 @@ struct AdvancedPreferencePane: View {
|
||||||
|
|
||||||
GroupBox(label: Text("Active/Select")) {
|
GroupBox(label: Text("Active/Select")) {
|
||||||
VStack(alignment: .leading) {
|
VStack(alignment: .leading) {
|
||||||
Picker("OnSelect", selection: $appState.onSelectActionType) {
|
Picker(selection: $appState.onSelectActionType) {
|
||||||
|
|
||||||
Text(SelectedActionType.none.description)
|
Text(SelectedActionType.none.description)
|
||||||
.tag(SelectedActionType.none)
|
.tag(SelectedActionType.none)
|
||||||
Text(SelectedActionType.rename.description)
|
Text(SelectedActionType.rename.description)
|
||||||
.tag(SelectedActionType.rename)
|
.tag(SelectedActionType.rename)
|
||||||
|
} label: {
|
||||||
|
Text(verbatim: "OnSelect")
|
||||||
}
|
}
|
||||||
.labelsHidden()
|
.labelsHidden()
|
||||||
.pickerStyle(.inline)
|
.pickerStyle(.inline)
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,9 @@ struct SignInCredentialsView: View {
|
||||||
HStack {
|
HStack {
|
||||||
Text("AppleID")
|
Text("AppleID")
|
||||||
.frame(minWidth: 100, alignment: .trailing)
|
.frame(minWidth: 100, alignment: .trailing)
|
||||||
TextField("example@icloud.com", text: $username)
|
TextField(text: $username) {
|
||||||
|
Text(verbatim: "example@icloud.com")
|
||||||
|
}
|
||||||
}
|
}
|
||||||
HStack {
|
HStack {
|
||||||
Text("Password")
|
Text("Password")
|
||||||
|
|
|
||||||
|
|
@ -14,10 +14,10 @@ extension View {
|
||||||
struct View_IsHidden_Previews: PreviewProvider {
|
struct View_IsHidden_Previews: PreviewProvider {
|
||||||
static var previews: some View {
|
static var previews: some View {
|
||||||
Group {
|
Group {
|
||||||
Text("Not Hidden")
|
Text(verbatim: "Not Hidden")
|
||||||
.isHidden(false)
|
.isHidden(false)
|
||||||
|
|
||||||
Text("Hidden")
|
Text(verbatim: "Hidden")
|
||||||
.isHidden(true)
|
.isHidden(true)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -97,33 +97,45 @@ struct AppStoreButtonStyle_Previews: PreviewProvider {
|
||||||
Group {
|
Group {
|
||||||
ForEach([ColorScheme.light, .dark], id: \.self) { colorScheme in
|
ForEach([ColorScheme.light, .dark], id: \.self) { colorScheme in
|
||||||
Group {
|
Group {
|
||||||
Button("OPEN", action: {})
|
Button{ } label: {
|
||||||
|
Text(verbatim: "OPEN")
|
||||||
|
}
|
||||||
.buttonStyle(AppStoreButtonStyle(primary: true, highlighted: false))
|
.buttonStyle(AppStoreButtonStyle(primary: true, highlighted: false))
|
||||||
.padding()
|
.padding()
|
||||||
.background(Color(.textBackgroundColor))
|
.background(Color(.textBackgroundColor))
|
||||||
.previewDisplayName("Primary")
|
.previewDisplayName("Primary")
|
||||||
Button("OPEN", action: {})
|
Button{ } label: {
|
||||||
|
Text(verbatim: "OPEN")
|
||||||
|
}
|
||||||
.buttonStyle(AppStoreButtonStyle(primary: true, highlighted: true))
|
.buttonStyle(AppStoreButtonStyle(primary: true, highlighted: true))
|
||||||
.padding()
|
.padding()
|
||||||
.background(Color(.controlAccentColor))
|
.background(Color(.controlAccentColor))
|
||||||
.previewDisplayName("Primary, Highlighted")
|
.previewDisplayName("Primary, Highlighted")
|
||||||
Button("OPEN", action: {})
|
Button{ } label: {
|
||||||
|
Text(verbatim: "OPEN")
|
||||||
|
}
|
||||||
.buttonStyle(AppStoreButtonStyle(primary: true, highlighted: false))
|
.buttonStyle(AppStoreButtonStyle(primary: true, highlighted: false))
|
||||||
.padding()
|
.padding()
|
||||||
.disabled(true)
|
.disabled(true)
|
||||||
.background(Color(.textBackgroundColor))
|
.background(Color(.textBackgroundColor))
|
||||||
.previewDisplayName("Primary, Disabled")
|
.previewDisplayName("Primary, Disabled")
|
||||||
Button("INSTALL", action: {})
|
Button{ } label: {
|
||||||
|
Text(verbatim: "INSTALL")
|
||||||
|
}
|
||||||
.buttonStyle(AppStoreButtonStyle(primary: false, highlighted: false))
|
.buttonStyle(AppStoreButtonStyle(primary: false, highlighted: false))
|
||||||
.padding()
|
.padding()
|
||||||
.background(Color(.textBackgroundColor))
|
.background(Color(.textBackgroundColor))
|
||||||
.previewDisplayName("Secondary")
|
.previewDisplayName("Secondary")
|
||||||
Button("INSTALL", action: {})
|
Button{ } label: {
|
||||||
|
Text(verbatim: "INSTALL")
|
||||||
|
}
|
||||||
.buttonStyle(AppStoreButtonStyle(primary: false, highlighted: true))
|
.buttonStyle(AppStoreButtonStyle(primary: false, highlighted: true))
|
||||||
.padding()
|
.padding()
|
||||||
.background(Color(.controlAccentColor))
|
.background(Color(.controlAccentColor))
|
||||||
.previewDisplayName("Secondary, Highlighted")
|
.previewDisplayName("Secondary, Highlighted")
|
||||||
Button("INSTALL", action: {})
|
Button{ } label: {
|
||||||
|
Text(verbatim: "INSTALL")
|
||||||
|
}
|
||||||
.buttonStyle(AppStoreButtonStyle(primary: false, highlighted: false))
|
.buttonStyle(AppStoreButtonStyle(primary: false, highlighted: false))
|
||||||
.padding()
|
.padding()
|
||||||
.disabled(true)
|
.disabled(true)
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load diff
Loading…
Reference in a new issue