[DocsUI M3] Add navigation rail layout for medium size screen
* Add a new layout nav_rail_layout for medium size >=600 && <900 which also uses DrawerLayout but adds a narrower sidebar with icon/label only. * Reuse RootsFragment to render Navigation rail so we can keep all existing functionality for navigation drawer on navigation rail. We store the layout ID on the RootsFragment argument to distinguish which layout is rendering, in medium size layout, 2 instances of RootsFragment will be rendered: one for the navigation drawer, the other for navigation rail. * A new layout nav_rail_item_root is created to cater the layout for navigation rail items. * Extend the existing navigation drawer item classes to create the corresponding navigation rail item classes so we can use different layout for navigation rail items. Check the bug item for demo. Bug: 381958615 Test: Manual inpsection Flag: com.android.documentsui.flags.use_material3 Change-Id: I8fac4646031e248020755327caed6b427b5d08cf
Loading
Please register or sign in to comment