CXTDT-423141 - Tabs - Incorrect spacing on top-aligned Fill container
Signed-off-by: Matt Bruce <matt.bruce@verizon.com>
This commit is contained in:
parent
a9b39c0fbf
commit
8c6fcee828
@ -47,17 +47,6 @@ open class Tabs: View {
|
||||
public enum Size: String, CaseIterable {
|
||||
case medium
|
||||
case large
|
||||
|
||||
public var textStyle: TextStyle {
|
||||
if self == .medium {
|
||||
return .boldBodyLarge
|
||||
} else {
|
||||
//specs show that the font size shouldn't change however boldTitleSmall does
|
||||
//change point size between iPad/iPhone. This is a "fix" so each device will
|
||||
//load the correct pointSize
|
||||
return UIDevice.isIPad ? .boldTitleSmall : .boldTitleMedium
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------
|
||||
@ -220,6 +209,7 @@ open class Tabs: View {
|
||||
// Create new tab items from the models
|
||||
for model in models {
|
||||
let tabItem = Tab()
|
||||
tabItem.size = size
|
||||
tabItem.text = model.text
|
||||
tabItem.onClick = model.onClick
|
||||
tabItem.width = model.width
|
||||
@ -258,10 +248,10 @@ open class Tabs: View {
|
||||
|
||||
// Update tab appearance based on properties
|
||||
for (index, tabItem) in tabViews.enumerated() {
|
||||
tabItem.size = size
|
||||
tabItem.selected = selectedIndex == index
|
||||
tabItem.index = index
|
||||
tabItem.minWidth = minWidth
|
||||
tabItem.size = size
|
||||
tabItem.textPosition = textPosition
|
||||
tabItem.orientation = orientation
|
||||
tabItem.surface = surface
|
||||
|
||||
Loading…
Reference in New Issue
Block a user