Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Uplift.xcworkspace/xcshareddata/swiftpm/Package.resolved

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Uplift/Views/Home/GymDetailView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ struct GymDetailView: View {
heroSection
!gym.amenities.isEmpty ? amenitiesSection : nil
slidingTabBar(gymName: viewModel.determineGymNameEnum(gym: gym))
DividerLine()

Group {
if viewModel.selectedTab == .fitnessCenter {
Expand Down
10 changes: 5 additions & 5 deletions Uplift/Views/Supporting/SlidingTabBarView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ struct SlidingTabBarView<T: Hashable>: View {
private func tab(for item: Item) -> some View {
VStack(alignment: .center, spacing: 16) {
Text(item.title)
.font(selectedTab == item.tab ? config.selectedFont : config.unselectedFont)
.foregroundStyle(config.color)
.font(config.font)
.foregroundStyle(selectedTab == item.tab ? config.selectedFontColor : config.unselectedFontColor)
.padding(.top)

if selectedTab == item.tab {
Expand Down Expand Up @@ -68,10 +68,10 @@ extension SlidingTabBarView {

/// Configuration for a tab bar.
struct TabBarConfig {
var color: Color = Constants.Colors.black
var selectedFont: Font = Constants.Fonts.labelBold
var font: Font = Constants.Fonts.labelBold
var selectedFontColor: Color = Constants.Colors.black
var selectedUnderlineColor: Color = Constants.Colors.yellow
var unselectedFont: Font = Constants.Fonts.labelMedium
var unselectedFontColor: Color = Constants.Colors.gray04
var unselectedUnderlineColor: Color = Constants.Colors.white
}

Expand Down