mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-04-24 04:16:00 +08:00
Fix inline styles warning in Libraries (#22161)
Summary: Fixes `react-native/no-inline-styles` eslint warnings in the `Libraries` module. Pull Request resolved: https://github.com/facebook/react-native/pull/22161 Differential Revision: D12946899 Pulled By: TheSavior fbshipit-source-id: c97ffa50dd90529dabf30a3d2cb09476acc568cb
This commit is contained in:
committed by
Facebook Github Bot
parent
69213eea95
commit
41eb2da33b
@@ -14,6 +14,7 @@ const Platform = require('Platform');
|
||||
const Position = require('Position');
|
||||
const React = require('React');
|
||||
const ReactNative = require('ReactNative');
|
||||
const StyleSheet = require('StyleSheet');
|
||||
const TVEventHandler = require('TVEventHandler');
|
||||
const TouchEventUtils = require('fbjs/lib/TouchEventUtils');
|
||||
const UIManager = require('UIManager');
|
||||
@@ -858,17 +859,25 @@ const Touchable = {
|
||||
return (
|
||||
<View
|
||||
pointerEvents="none"
|
||||
style={{
|
||||
position: 'absolute',
|
||||
borderColor: hexColor.slice(0, -2) + '55', // More opaque
|
||||
borderWidth: 1,
|
||||
borderStyle: 'dashed',
|
||||
backgroundColor: hexColor.slice(0, -2) + '0F', // Less opaque
|
||||
...debugHitSlopStyle,
|
||||
}}
|
||||
style={[
|
||||
styles.debug,
|
||||
{
|
||||
borderColor: hexColor.slice(0, -2) + '55', // More opaque
|
||||
backgroundColor: hexColor.slice(0, -2) + '0F', // Less opaque
|
||||
...debugHitSlopStyle,
|
||||
},
|
||||
]}
|
||||
/>
|
||||
);
|
||||
},
|
||||
};
|
||||
|
||||
const styles = StyleSheet.create({
|
||||
debug: {
|
||||
position: 'absolute',
|
||||
borderWidth: 1,
|
||||
borderStyle: 'dashed',
|
||||
},
|
||||
});
|
||||
|
||||
module.exports = Touchable;
|
||||
|
||||
Reference in New Issue
Block a user