Skip to content

Commit

Permalink
Fix Popover problem for RTL 1/n
Browse files Browse the repository at this point in the history
Summary: Change modal.js to support RTL

Reviewed By: javache

Differential Revision: D3580776

fbshipit-source-id: e9ef3f340f52e38fd905dce6d14a74d3bd7b7982
  • Loading branch information
MengjueW authored and Facebook Github Bot 2 committed Jul 19, 2016
1 parent 6d12770 commit a527ef2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Libraries/Modal/Modal.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
*/
'use strict';

const I18nManager = require('I18nManager');
const Platform = require('Platform');
const PropTypes = require('react/lib/ReactPropTypes');
const React = require('React');
Expand Down Expand Up @@ -157,13 +158,14 @@ class Modal extends React.Component {
}
}

const side = I18nManager.isRTL ? 'right' : 'left';
const styles = StyleSheet.create({
modal: {
position: 'absolute',
},
container: {
position: 'absolute',
left: 0,
[side] : 0,
top: 0,
}
});
Expand Down

0 comments on commit a527ef2

Please sign in to comment.