Tinderbar is a recreation of the Tinder iOS app's navigation hierarchy using Tabman, a showcase of creating custom Tabman components.
Latest version of Xcode.
Tinderbar uses Tabman for its primary navigation bar and also sub navigation within the Messages section.
A TMBarView
embedded in a TMSystemBar
, added to the .top
.
TMBarView<TinderBarLayout, TinderBarButton, TMBarIndicator.None>
It uses a custom layout in the form of TinderBarLayout
and custom TinderBarButton
bar buttons.
- Uses a horizontal stack view for buttons.
- Buttons are inserted into a container, which is constrained to be
0.5x
the width of thelayoutGuide
. - Padding views of
0.25x
thelayoutGuide
are inserted at the leading and trailing edges of the stack. - Buttons are centered along the X-axis of their container, with a constant that is updated as the layout
focusArea
is adjusted (they are centered when selected, and offsetted when unselected to ensure they don't venture off screen).
- A
TMBarButton
which consists of an image view. - Image view tint color transitions between
unselectedTintColor
andtintColor
. - Image view scales to
1.0
when selected and0.8
when unselected.
A more regular TMBarView
using stock Tabman components, added to the .top
.
TMBarView<TMHorizontalBarLayout, TMLabelBarButton, TMBarIndicator.None>
contentMode
of the layout is set to.fit
.
- Created by Merrick Sapsford (@MerrickSapsford).
The library is available as open source under the terms of the MIT License.