diff --git a/Stats.swift b/Stats.swift index 1580f4e..26b24ed 100644 --- a/Stats.swift +++ b/Stats.swift @@ -14,8 +14,12 @@ struct StatsPanel: View { @Query(SelectedRibbonRequest()) private var selectedRibbon: [Ribbon] @Environment(\.appDatabase) private var appDatabase + let columnCount = 2 + var columns: [GridItem] { + Array(repeatElement(GridItem(.flexible()), count: columnCount)) + } var body: some View { - VStack (spacing: 10) { + LazyVGrid (columns:columns , spacing: 5) { VStack { Text("back Ribbon") .foregroundColor(Color(UIColor(red: 0.76, green: 0.76, blue: 0.76, alpha: 1.00))) diff --git a/gloss/ContentView.swift b/gloss/ContentView.swift index ed64ed5..cbf9536 100644 --- a/gloss/ContentView.swift +++ b/gloss/ContentView.swift @@ -308,18 +308,13 @@ struct ContentView: View { .background(Color(red: 0.1, green: 0.1, blue: 0.1)) .frame(alignment: .topLeading) - VStack { - Text("pc offset: \(paneConnector.currentOffset)") - .foregroundColor(Color(UIColor(red: 0.76, green: 0.76, blue: 0.76, alpha: 1.00))) - .font(Font.custom("AveriaSerifLibre-Regular", size: fontSize)) - } VStack { NaviBar(paneConnector: paneConnector) StatsPanel(paneConnector: paneConnector) } .frame(maxWidth: 250) - .offset(x: geometry.size.width - 250) + .offset(x: geometry.size.width - 330) VStack { // Top pane @@ -400,7 +395,7 @@ struct ContentView: View { } else if viewState.width > 0 && pulledOut.width < 0 { setPulledOutWith = CGFloat(0) } else if viewState.width < 0 && pulledOut.width == 0 { - setPulledOutWith = CGFloat(-200) + setPulledOutWith = CGFloat(-300) } else if abs(viewState.width + pulledOut.width) > 30 { setPulledOutWith = CGFloat(200) }