MCPcopy
hub / github.com/Kureev/react-native-navbar

github.com/Kureev/react-native-navbar @v2.1.0 sqlite

repository ↗ · DeepWiki ↗ · release v2.1.0 ↗
37 symbols 72 edges 18 files 0 documented · 0%
README

Customizable navbar for react-native

react-native-side-menu demo

Content

Examples

Getting started

  • Install react-native-navbar:
  • By using yarn: $ yarn add react-native-navbar
  • By using npm: $ npm install react-native-navbar --save

  • Import it in the file where you want to use it: jsx import NavigationBar from 'react-native-navbar';

  • Add it to your React element tree:

const styles = {
  container: {
    flex: 1,
  },
};

const rightButtonConfig = {
  title: 'Next',
  handler: () => alert('hello!'),
};

const titleConfig = {
  title: 'Hello, world',
};

function ComponentWithNavigationBar() {
  return (
    <View style={styles.container}>
      <NavigationBar
        title={titleConfig}
        rightButton={rightButtonConfig}
      />
    </View>
  );
}

That's it, you're ready to go!

API

  • style - (Object, Array) - Style object or array of style objects
  • containerStyle - (Object) - Style object for styling navbar container
  • tintColor - (String) - NavigationBar's tint color
  • statusBar - (Object):
  • style - ('light-content' or 'default') - Style of statusBar
  • hidden - (Boolean)
  • tintColor - (String) - Status bar tint color
  • hideAnimation - ('fade', 'slide', 'none') - Type of statusBar hide animation
  • showAnimation - ('fade', 'slide', 'none') - Type of statusBar show animation
  • leftButton / rightButton - (Object, React Element) - Either plain object with configuration, or React Element which will be used as a custom left/right button element. Configuration object has following keys:
  • title - (String) - Button's title
  • tintColor - (String) - Button's text color
  • style - (Object, Array) - Style object or array of style objects
  • handler - (Function) - onPress function handler
  • disabled - (Boolean) - If true, disable interactions for this button.
  • accessible - (Boolean) - Indicates that the view is an accessibility element
  • accessibilityLabel - (String, React Element) - Overrides the text that's read by the screen reader for the button.
  • title - (Object, React Element) - Either plain object with configuration, or React Element which will be used as a custom title element. Configuration object has following keys:
  • title - (String) - Button's title
  • style - (Object, Array, Number) - Style object or array of style objects
  • tintColor - (String) - Title's text color
  • ellipsizeMode - ('head', 'middle', 'tail', 'clip') - How to display the text
  • numberOfLines - (Number) - How to truncate the text

Usage with Webpack

This module uses JSX syntax and requires a compiler such as babel. React Native's packager runs this automatically but if you use Webpack be sure to compile this module from your dependencies

loaders: [{
  test: /\.js$/,
   include: [
     path.resolve(__dirname, "src"),
     path.resolve(__dirname, "node_modules/react-native-navbar")
   ],
  loader: 'babel',
  query: { stage: 0, plugins: [] }
}]

Questions?

Feel free to ping me on twitter If you want to report a bug, please submit an issue!

Core symbols most depended-on inside this repo

onBackPressed
called by 1
examples/Basic/android/app/src/main/java/com/basic/MainActivity.java
onBackPressed
called by 1
examples/Routing/android/app/src/main/java/com/routing/MainActivity.java
onBackPressed
called by 1
examples/CustomElements/android/app/src/main/java/com/customelements/MainActivity.java
componentDidMount
called by 0
index.js
componentWillReceiveProps
called by 0
index.js
customizeStatusBar
called by 0
index.js
getTitleElement
called by 0
index.js
NavbarButton
called by 0
NavbarButton.js

Shape

Method 19
Class 13
Function 5

Languages

Java57%
TypeScript43%

Modules by API surface

examples/Routing/android/app/src/main/java/com/routing/MainActivity.java7 symbols
examples/CustomElements/android/app/src/main/java/com/customelements/MainActivity.java7 symbols
examples/Basic/android/app/src/main/java/com/basic/MainActivity.java7 symbols
index.js5 symbols
examples/Routing/index.ios.js3 symbols
examples/Routing/components/InitialScreen.js1 symbols
examples/Routing/components/CustomScreen.js1 symbols
examples/CustomElements/index.ios.js1 symbols
examples/CustomElements/components/Pickachu.js1 symbols
examples/CustomElements/components/Charmander.js1 symbols
examples/CustomElements/components/Bulbazavr.js1 symbols
examples/Basic/index.ios.js1 symbols

Dependencies from manifests, versioned

babel-eslint7.1.1 · 1×
eslint3.16.1 · 1×
eslint-config-airbnb14.1.0 · 1×
eslint-plugin-import2.2.0 · 1×
eslint-plugin-jsx-a11y4.0.0 · 1×
eslint-plugin-react6.10.0 · 1×
prop-types15.5.10 · 1×
react-native0.17.0 · 1×
react-native-navbargit+https://github.c · 1×

For agents

$ claude mcp add react-native-navbar \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact