Skip to content

Commit f5a7c1b

Browse files
committed
replace some Spacer with spacing
1 parent c82af45 commit f5a7c1b

File tree

3 files changed

+3
-15
lines changed

3 files changed

+3
-15
lines changed

src/config/about.swift

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ struct AboutView: View {
6565
@State private var latestAvailable = false
6666

6767
var body: some View {
68-
VStack {
68+
VStack(spacing: gapSize) {
6969
if let iconURL = Bundle.main.url(forResource: "fcitx", withExtension: "icns"),
7070
let icon = NSImage(contentsOf: iconURL)
7171
{
@@ -76,45 +76,37 @@ struct AboutView: View {
7676
Text(String("Fcitx5 macOS")) // no i18n by design
7777
.font(.title)
7878

79-
Spacer().frame(height: gapSize)
80-
8179
HStack {
8280
Text(arch)
8381
if isDebug {
8482
Text("Debug")
8583
}
8684
}
8785

88-
Spacer().frame(height: gapSize)
8986
if releaseTag == "latest" {
9087
urlButton(String(commit.prefix(7)), sourceRepo + "/commit/" + commit)
9188
} else {
9289
urlButton(releaseTag, sourceRepo + "/tree/" + releaseTag)
9390
}
9491

95-
Spacer().frame(height: gapSize)
9692
Text(getDate())
9793

98-
Spacer().frame(height: gapSize)
9994
HStack {
10095
Text("Originally made by")
10196
urlButton("Qijia Liu", "https://github.com/eagleoflqj")
10297
Text("and")
10398
urlButton("ksqsf", "https://github.com/ksqsf")
10499
}
105100

106-
Spacer().frame(height: gapSize)
107101
HStack {
108102
Text("Licensed under")
109103
urlButton("GPLv3", sourceRepo + "/blob/master/LICENSE")
110104
}
111105

112-
Spacer().frame(height: gapSize)
113106
urlButton(
114107
NSLocalizedString("3rd-party source code", comment: ""),
115108
sourceRepo + "/blob/master/README.md#credits")
116109

117-
Spacer().frame(height: gapSize)
118110
HStack {
119111
Button {
120112
if viewModel.state == .notChecked {

src/config/datamanager.swift

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ struct DataView: View {
149149
}
150150

151151
var body: some View {
152-
VStack {
152+
VStack(spacing: gapSize) {
153153
Text("Import data from …")
154154

155155
Button {
@@ -202,8 +202,6 @@ struct DataView: View {
202202
ImportDataView().load(hamsterItems)
203203
}
204204

205-
Spacer().frame(height: gapSize)
206-
207205
Text("Export data to …")
208206

209207
Button {

src/config/importtable.swift

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ struct ImportTableView: View {
4545
}
4646

4747
var body: some View {
48-
VStack {
48+
VStack(spacing: gapSize) {
4949
Button {
5050
NSWorkspace.shared.open(imLocalDir)
5151
} label: {
@@ -57,8 +57,6 @@ struct ImportTableView: View {
5757
Text("Copy \\*.dict/\\*.txt to this directory")
5858
}
5959

60-
Spacer().frame(height: gapSize)
61-
6260
HStack {
6361
Button {
6462
presentationMode.wrappedValue.dismiss()

0 commit comments

Comments
 (0)