diff options
| author | Dustin Mierau <dustin@mierau.me> | 2023-12-12 15:27:00 -0800 |
|---|---|---|
| committer | Dustin Mierau <dustin@mierau.me> | 2023-12-12 15:27:00 -0800 |
| commit | 248fcbbd5dca84747e6f3fd9d1d52c41ab8640c3 (patch) | |
| tree | f8f76c7b071aff2fe56c4e900c72dcbaddd3c62a /Hotline/Views/NewsView.swift | |
| parent | f71c4cae3b21db506573bcdfa9fdb6cde41cc0ca (diff) | |
New category listing is working again. Added optionset for user access info. Some UI cleanup across the board.
Diffstat (limited to 'Hotline/Views/NewsView.swift')
| -rw-r--r-- | Hotline/Views/NewsView.swift | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/Hotline/Views/NewsView.swift b/Hotline/Views/NewsView.swift index 431b3ce..ad7904e 100644 --- a/Hotline/Views/NewsView.swift +++ b/Hotline/Views/NewsView.swift @@ -9,7 +9,7 @@ struct NewsView: View { @State private var topListHeight: CGFloat = 200 @State private var dividerHeight: CGFloat = 30 - var topList: some View { + var articleList: some View { // Your list content goes here List { @@ -30,10 +30,11 @@ struct NewsView: View { } } } + .scrollBounceBehavior(.basedOnSize) // .listStyle(.plain) } - var bottomList: some View { + var readerView: some View { // Your list content goes here ScrollView(.vertical) { HStack(alignment: .top, spacing: 0) { @@ -43,13 +44,14 @@ struct NewsView: View { } .padding() } + .scrollBounceBehavior(.basedOnSize) .background(colorScheme == .dark ? Color(white: 0.1) : Color(uiColor: UIColor.systemBackground)) } var body: some View { NavigationStack { VStack(spacing: 0) { - topList + articleList .frame(height: topListHeight) VStack(alignment: .center) { Divider() @@ -73,7 +75,7 @@ struct NewsView: View { // bottomListHeight = max(min(bottomListHeight - delta, 400), 0) } ) - bottomList + readerView } .task { if !fetched { |