aurelhubert / aurelhubert/ahbottomnavigation
Elevation issue
- Dominant language
- Java
- Stars
- 3.8k
- Forks
- 672
- PR merge metrics
- No merged PRs in 30d
Description
Hello,
I have a problem with elevation with AhBottomNavigation, here is a final output where elavation is missing:

I have notice when i add a bottom margin, elevation is present but under bar:

here is a layout code:
`
`
and here is initializaion:
` mainBottomNavigation.defaultBackgroundColor = ContextCompat.getColor(this, R.color.colorPrimary)
mainBottomNavigation.accentColor = ContextCompat.getColor(this, R.color.bottomIconSelected)
mainBottomNavigation.inactiveColor = ContextCompat.getColor(this, R.color.bottomIconUnselected)
mainBottomNavigation.setOnTabSelectedListener(presenter::onMenuSelected)
val navigationAdapter = AHBottomNavigationAdapter(this, R.menu.bottom_menu)
navigationAdapter.setupWithBottomNavigation(mainBottomNavigation)
mainBottomNavigation.setOnNavigationPositionListener {
if (isBottomVisible != !mainBottomNavigation.isHidden){
isBottomVisible = !isBottomVisible
bottomBarListener?.invoke(mainBottomNavigation.isHidden)
}
}`
Here is a styles:
`
<!-- Customize your theme here. -->
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorAccent</item>
<item name="android:windowBackground">@color/colorPrimaryDark</item>
<item name="colorControlHighlight">@color/bottomRipple</item>
`
I have miss something? Please provide any suggestions.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by reproducing the report with the supplied CoordinatorLayout XML, BottomBarStyle, and mainBottomNavigation initialization. Compare the elevation with and without the reported bottom margin, and verify that the final layout shows elevation above the AHBottomNavigation bar without relying on the margin.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, kotlin
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100