From 07986ba86c47c66258f6384e4a546186691f592d Mon Sep 17 00:00:00 2001 From: Surinder Pal Singh Date: Fri, 9 Jun 2023 02:03:06 +1000 Subject: [PATCH] Fix native style warnings --- src/styles/styles.js | 10 ++-------- src/styles/utilities/textUnderline/index.js | 9 +++++++++ src/styles/utilities/textUnderline/index.native.js | 4 ++++ 3 files changed, 15 insertions(+), 8 deletions(-) create mode 100644 src/styles/utilities/textUnderline/index.js create mode 100644 src/styles/utilities/textUnderline/index.native.js diff --git a/src/styles/styles.js b/src/styles/styles.js index 70cfac3de847..4178134a6639 100644 --- a/src/styles/styles.js +++ b/src/styles/styles.js @@ -22,6 +22,7 @@ import overflowXHidden from './overflowXHidden'; import CONST from '../CONST'; import cursor from './utilities/cursor'; import userSelect from './utilities/userSelect'; +import textUnderline from './utilities/textUnderline'; const picker = { backgroundColor: themeColors.transparent, @@ -162,6 +163,7 @@ const styles = { ...cursor, ...userSelect, ...themeColors, + ...textUnderline, rateCol: { margin: 0, @@ -275,14 +277,6 @@ const styles = { textDecorationLine: 'underline', }, - textUnderlinePositionUnder: { - textUnderlinePosition: 'under', - }, - - textDecorationSkipInkNone: { - textDecorationSkipInk: 'none', - }, - label: { fontSize: variables.fontSizeLabel, lineHeight: variables.lineHeightLarge, diff --git a/src/styles/utilities/textUnderline/index.js b/src/styles/utilities/textUnderline/index.js new file mode 100644 index 000000000000..3ec9ce507765 --- /dev/null +++ b/src/styles/utilities/textUnderline/index.js @@ -0,0 +1,9 @@ +const textUnderlinePositionUnder = { + textUnderlinePosition: 'under', +}; + +const textDecorationSkipInkNone = { + textDecorationSkipInk: 'none', +}; + +export default {textUnderlinePositionUnder, textDecorationSkipInkNone}; diff --git a/src/styles/utilities/textUnderline/index.native.js b/src/styles/utilities/textUnderline/index.native.js new file mode 100644 index 000000000000..ce2e2e7d6c20 --- /dev/null +++ b/src/styles/utilities/textUnderline/index.native.js @@ -0,0 +1,4 @@ +// following styles are not supported +const textUnderlinePositionUnder = {}; +const textDecorationSkipInkNone = {}; +export default {textUnderlinePositionUnder, textDecorationSkipInkNone};