FluidBottomNavigation-ios icon indicating copy to clipboard operation
FluidBottomNavigation-ios copied to clipboard

Add badge to items

Open abdoh476 opened this issue 4 years ago • 7 comments

abdoh476 avatar Dec 08 '20 10:12 abdoh476

Please accept we need this added feature :)

ssdjordan avatar Mar 14 '21 08:03 ssdjordan

you can use this until they merge pod 'FluidTabBarController', :git => 'https://github.com/abdoh476/FluidBottomNavigation-ios'

abdoh476 avatar Mar 14 '21 08:03 abdoh476

Thank you a lot...

ssdjordan avatar Mar 14 '21 08:03 ssdjordan

This is how to make badge and put number to it (self.tabBarController!.tabBar.items![index] as! FluidTabBarItem).isBadged = true (self.tabBarController!.tabBar.items![index] as! FluidTabBarItem).badgeNumber = "\(value.data.messagesNumber)"

you may want to handle making the badge false when clicking on the page the badge have

abdoh476 avatar Mar 14 '21 09:03 abdoh476

Dear, I have a compiler error when the above two lines were added. Value of type 'FluidTabBarItem' has no member 'badgeNumber' Value of type 'FluidTabBarItem' has no member 'isBadged'

ssdjordan avatar Mar 14 '21 10:03 ssdjordan

Did you put pod 'FluidTabBarController', :git => 'https://github.com/abdoh476/FluidBottomNavigation-ios' in your pod file then made pod install ?

abdoh476 avatar Mar 14 '21 11:03 abdoh476

it is working fine now Thank You again :)

ssdjordan avatar Mar 14 '21 13:03 ssdjordan