Skip to content

Commit b1d1675

Browse files
committed
fix: use native Picker labels instead of separate Text + labelsHidden
1 parent 377d312 commit b1d1675

1 file changed

Lines changed: 6 additions & 18 deletions

File tree

TablePro/Views/Structure/CreateTableView.swift

Lines changed: 6 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -85,38 +85,26 @@ struct CreateTableView: View {
8585
Divider()
8686
.frame(height: 20)
8787

88-
Text("Engine:")
89-
.font(.system(size: ThemeEngine.shared.activeTheme.typography.small))
90-
.foregroundStyle(.secondary)
91-
Picker("", selection: $tableOptions.engine) {
88+
Picker("Engine:", selection: $tableOptions.engine) {
9289
ForEach(CreateTableOptions.engines, id: \.self) { engine in
9390
Text(engine).tag(engine)
9491
}
9592
}
96-
.labelsHidden()
97-
.frame(width: 100)
93+
.fixedSize()
9894

99-
Text("Charset:")
100-
.font(.system(size: ThemeEngine.shared.activeTheme.typography.small))
101-
.foregroundStyle(.secondary)
102-
Picker("", selection: $tableOptions.charset) {
95+
Picker("Charset:", selection: $tableOptions.charset) {
10396
ForEach(CreateTableOptions.charsets, id: \.self) { cs in
10497
Text(cs).tag(cs)
10598
}
10699
}
107-
.labelsHidden()
108-
.frame(width: 100)
100+
.fixedSize()
109101

110-
Text("Collation:")
111-
.font(.system(size: ThemeEngine.shared.activeTheme.typography.small))
112-
.foregroundStyle(.secondary)
113-
Picker("", selection: $tableOptions.collation) {
102+
Picker("Collation:", selection: $tableOptions.collation) {
114103
ForEach(CreateTableOptions.collations[tableOptions.charset] ?? [], id: \.self) { col in
115104
Text(col).tag(col)
116105
}
117106
}
118-
.labelsHidden()
119-
.frame(width: 180)
107+
.fixedSize()
120108
}
121109

122110
Spacer()

0 commit comments

Comments
 (0)