1
1
import type { ForwardedRef , ReactNode , RefObject } from 'react' ;
2
- import React , { forwardRef , useState } from 'react' ;
2
+ import React , { forwardRef , useLayoutEffect , useState } from 'react' ;
3
3
import { View } from 'react-native' ;
4
4
import type { StyleProp , TextInputProps , ViewStyle } from 'react-native' ;
5
5
import { useOnyx } from 'react-native-onyx' ;
@@ -11,6 +11,7 @@ import useCurrentUserPersonalDetails from '@hooks/useCurrentUserPersonalDetails'
11
11
import useLocalize from '@hooks/useLocalize' ;
12
12
import useNetwork from '@hooks/useNetwork' ;
13
13
import useThemeStyles from '@hooks/useThemeStyles' ;
14
+ import { parseFSAttributes } from '@libs/Fullstory' ;
14
15
import { parseForLiveMarkdown } from '@libs/SearchAutocompleteUtils' ;
15
16
import handleKeyPress from '@libs/SearchInputOnKeyPress' ;
16
17
import shouldDelayFocus from '@libs/shouldDelayFocus' ;
@@ -97,12 +98,16 @@ function SearchAutocompleteInput(
97
98
98
99
const inputWidth = isFullWidth ? styles . w100 : { width : variables . popoverWidth } ;
99
100
101
+ // Parse Fullstory attributes on initial render
102
+ useLayoutEffect ( parseFSAttributes , [ ] ) ;
103
+
100
104
return (
101
105
< View style = { [ outerWrapperStyle ] } >
102
106
< View style = { [ styles . flexRow , styles . alignItemsCenter , wrapperStyle ?? styles . searchRouterTextInputContainer , isFocused && wrapperFocusedStyle ] } >
103
107
< View
104
108
style = { styles . flex1 }
105
- fsClass = "fs-unmask"
109
+ fsClass = { CONST . FULL_STORY . UNMASK }
110
+ testID = { CONST . FULL_STORY . UNMASK }
106
111
>
107
112
< TextInput
108
113
testID = "search-autocomplete-text-input"
0 commit comments