how to highlight active nav menu when scrolled in reactjs? - reactjs

how will I show all the nav menus if they don't have any space to show?
I want to make my navbar like site have https://restoranserisentosapj.weeat.asia/cust/#/goods
what I make is https://srbistro.netlify.app/ (please check in the phone or phone view)

Related

How can I make navbar hide further/disappear when keyboard is opened?

I would like to completely hide the react navigation bottom tab navbar when my keyboard appears.
I've already added tabBarHideOnKeyboard: true to my Tab.Navigator, but the issue is that a one of the tabs sticks out when the navbar hides.

React JS : Chakra UI - Split view

I am looking for a split view in react js , i am using chakra ui for my layouts and i am not able to achive it .
Left Pane is Menu which has a fixed height (no scrolling needed)
Right Pane is the page which gets loaded every-time user selects an option in left menu.
Right pane should be scrollable.
You should give a try on the Choc-UI Layouts for achieving this:
https://choc-ui.com/docs/application-shells/sidebar-layouts
Or here too:
https://chakra-templates.dev/navigation/sidebar
On the links you will get previews of components that have a side bar on left side getting th full height of the viewport, also a sidebar and a container for your app content or other components.
This section is independent of the sidebar and navbar showed on the previews. You can access the code with the show code option on each previo (top-right location)
Try removing the navbar and modifying the width of sidebar, and you will get a split version of the layouts as you are reaching for.

scroll to top when tapping on the active tab in react native

I know there is a hook for that https://reactnavigation.org/docs/use-scroll-to-top/ . But at the beginning of my project, i created my own bottom tab component instead of using createBottomTabNavigator(). So i have a code like that <BottomNavigator selected={'Explore'} /> at the bottom of five screen. I want to scroll to top when active tab tapped. I can understand that if active tab is tapped but i get that information in BottomNavigator component. So i have no idea how to retrieve that information back to current screen and scroll to top.

Codename One toolbar sidemenu issue

I created a list using table layout which contains checkbox and message.The list is scroll-able . When i scroll down everything works fine,Where as when i check the check box and scroll down the toolbar side menu is expanding.
My requirement is to open the toolbar sidemenu only on the sidemenu toogle button click other than any click on the screen side menu should be in close mode.

Material-UI: Adding Badge to a Tab in material-ui Tabbar (Tabs)

I have Material-UI Tabs component with 5 Tab components as children. I would like to display a Badge on the Tab. Badge would display unread items under each tab.
I have two versions of tab bar. One for desktop with icon and text and one for mobile containing just icon. How could I position Badge so that it places properly on both versions. Also Badge should be visible even if tab is not selected (if I set Badge as a child to a Tab it will be hidden when tab is not selected).
You can do it like this:
<Tab label={<Badge badgeContent={this.state.messageCount} color="primary">
Messages
</Badge>} value="/messages" />

Resources