question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Snackbars should go above the bottom bar.

See original GitHub issue

I don’t know if it was already reported, but when I implement this library and try to attach a snack bar like so:

Snackbar.make(bottomBar, "Some text", Snackbar.LENGTH_LONG).show();

I get this result (The snackbar overlays the bottom bar).

According to the guidelines it should look like this.

And once again, thank you for this great and quick implementation.

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:10 (3 by maintainers)

github_iconTop GitHub Comments

3reactions
sembozdemircommented, Feb 6, 2017

Hi @roughike, @rosenpin

I am using 2.1.1 version. Snackbar is not visible in anyway. How did you achieve this? Could you provide more detailed code, please? I could not find any method like BottomBar#attach()

That’s my code:

Snackbar.make(coordinatorLayout, "message", Snackbar.LENGTH_LONG).show();
<android.support.design.widget.CoordinatorLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:id="@+id/activityHomeRoot"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:fitsSystemWindows="true">

    <include layout="@layout/layout_cci_toolbar"/>

    <FrameLayout
        android:id="@+id/activityHomeFrameLayoutContainer"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        app:layout_behavior="@string/appbar_scrolling_view_behavior"
        android:layout_marginBottom="@dimen/home_bottom_bar_height_without_shadow"/>

    <com.roughike.bottombar.BottomBar
        android:id="@+id/activityHomeBottomBar"
        android:layout_width="match_parent"
        android:layout_height="@dimen/home_bottom_bar_height"
        android:layout_gravity="bottom"
        style="@style/CCIBottomBar"/>

</android.support.design.widget.CoordinatorLayout>
<resources>

    <style name="CCIBottomBar">
        <item name="bb_tabXmlResource">@xml/home_bottom_bar_tabs</item>
        <item name="bb_activeTabColor">@color/colorPrimary</item>
        <item name="bb_inActiveTabColor">@color/gunmetal</item>
    </style>

</resources>
1reaction
roughikecommented, Mar 19, 2016

Awesome!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Move snackbar above the bottom bar - android - Stack Overflow
This is indeed a very good answer, just pass nested coordinator-layout view to make() method of snackbar and snack bar will start showing...
Read more >
Bottom app bar – Material Design 3
To avoid obstruction, snackbars should animate in place vertically above a bottom app bar. Refer to snackbars for more guidance on its layout...
Read more >
Android : Move snackbar above the bottom bar - YouTube
Android : Move snackbar above the bottom bar [ Beautify Your Computer : https://www.hows.tech/p/recommended.html ] Android : Move snackbar ...
Read more >
Move Snackbar Above The Bottomnavigationview - ADocLib
. that snack bars should appear above persistent bottom sheets. https://material.io/design/components/snackbars.html#placement The current. Implement ...
Read more >
Android Snackbar Example Tutorial - DigitalOcean
A Toast messages can be customised and printed anywhere on the screen, but a Snackbar can be only showed in the bottom of...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found