Permalink
Browse files

remove max children limitation on SwipeableQuickActions

Summary:
**motivation**
Right now `SwipeableQuickActions` only allows two actions. Let this limit be in the userland.

cc fred2028
Closes #8528

Differential Revision: D4211729

Pulled By: ericvicenti

fbshipit-source-id: 903592190b9855ffe9da44864cdc276bc1e18a7c
  • Loading branch information...
chirag04 authored and facebook-github-bot committed Feb 2, 2017
1 parent 1c249e4 commit d21199595e8789cb77b3ee91f7402def5f9ef16f
Showing with 1 addition and 3 deletions.
  1. +1 −3 Libraries/Experimental/SwipeableRow/SwipeableQuickActions.js
@@ -27,8 +27,6 @@ const React = require('React');
const StyleSheet = require('StyleSheet');
const View = require('View');
const MAX_QUICK_ACTIONS = 2;
/**
* A thin wrapper around standard quick action buttons that can, if the user
* chooses, be used with SwipeableListView. Sample usage is as follows, in the
@@ -53,7 +51,7 @@ class SwipeableQuickActions extends React.Component {
// Multiple children
if (children instanceof Array) {
for (let i = 0; i < children.length && i < MAX_QUICK_ACTIONS; i++) {
for (let i = 0; i < children.length; i++) {
buttons.push(children[i]);
// $FlowFixMe found when converting React.createClass to ES6

0 comments on commit d211995

Please sign in to comment.