Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

react-native-raw-bottom-sheet

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-native-raw-bottom-sheet - npm Package Compare versions

Comparing version 2.0.4 to 2.0.5

1

index.d.ts

@@ -12,2 +12,3 @@ import { Component } from "react";

closeOnPressMask?: boolean;
closeOnPressBack?: boolean;
onClose?: () => void;

@@ -14,0 +15,0 @@ customStyles?: {

5

package.json
{
"name": "react-native-raw-bottom-sheet",
"version": "2.0.4",
"version": "2.0.5",
"description": "Add Your Own Component To Bottom Sheet Whatever You Want (Android & iOS)",

@@ -18,4 +18,5 @@ "main": "index.js",

"raw-bottom-sheet",
"bottomsheet",
"bottom-drawer",
"bottom-animated",
"drawer",
"picker",

@@ -22,0 +23,0 @@ "swipper",

@@ -85,3 +85,3 @@ # react-native-raw-bottom-sheet

}}>
<YourOwnComponent />
<YourOwnComponent onPress={() => this[RBSheet + index].close() />
</RBSheet>

@@ -94,12 +94,13 @@ </View>

| Props | Type | Description | Default |
| ---------------- | -------- | ---------------------------------------------- | -------- |
| animationType | string | Background animation ("none", "fade", "slide") | "none" |
| height | number | Height of Bottom Sheet | 260 |
| minClosingHeight | number | Minimum height of Bottom Sheet before close | 0 |
| duration | number | Duration of Bottom Sheet animation | 300 (ms) |
| closeOnDragDown | boolean | Use gesture drag down to close Bottom Sheet | false |
| closeOnPressMask | boolean | Press the area outside to close Bottom Sheet | true |
| onClose | function | Callback function when Bottom Sheet has closed | null |
| customStyles | object | Custom style to Bottom Sheet | {} |
| Props | Type | Description | Default |
| ---------------- | -------- | ------------------------------------------------------- | -------- |
| animationType | string | Background animation ("none", "fade", "slide") | "none" |
| height | number | Height of Bottom Sheet | 260 |
| minClosingHeight | number | Minimum height of Bottom Sheet before close | 0 |
| duration | number | Duration of Bottom Sheet animation | 300 (ms) |
| closeOnDragDown | boolean | Use gesture drag down to close Bottom Sheet | false |
| closeOnPressMask | boolean | Press the area outside to close Bottom Sheet | true |
| closeOnPressBack | boolean | Press back android to close Bottom Sheet (Android only) | true |
| onClose | function | Callback function when Bottom Sheet has closed | null |
| customStyles | object | Custom style to Bottom Sheet | {} |

@@ -110,3 +111,3 @@ ### Available Custom Style

customStyles: {
wrapper: {...}, // The Root of Component
wrapper: {...}, // The Root of Component (You can change the `backgroundColor` or any styles)
container: {...}, // The Container of Bottom Sheet

@@ -113,0 +114,0 @@ draggableIcon: {...} // The Draggable Icon (If you set closeOnDragDown to true)

@@ -88,3 +88,10 @@ import React, { Component } from "react";

render() {
const { animationType, closeOnDragDown, closeOnPressMask, children, customStyles } = this.props;
const {
animationType,
closeOnDragDown,
closeOnPressMask,
closeOnPressBack,
children,
customStyles
} = this.props;
const { animatedHeight, pan, modalVisible } = this.state;

@@ -102,3 +109,3 @@ const panStyle = {

onRequestClose={() => {
this.setModalVisible(false);
if (closeOnPressBack) this.setModalVisible(false);
}}

@@ -140,2 +147,3 @@ >

closeOnPressMask: PropTypes.bool,
closeOnPressBack: PropTypes.bool,
customStyles: PropTypes.objectOf(PropTypes.object),

@@ -153,2 +161,3 @@ onClose: PropTypes.func,

closeOnPressMask: true,
closeOnPressBack: true,
customStyles: {},

@@ -155,0 +164,0 @@ onClose: null,

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc