callstack / callstack/masked-view
maskElement not show
- Dominant language
- JavaScript
- Stars
- 1.2k
- Forks
- 131
- PR merge metrics
- No merged PRs in 30d
Description
Hi, please help my problem, the maskview and text not show in simulator:
```
import React from "react";
import {
View,
Image,
Dimensions,
TouchableHighlight,
TouchableOpacity,
Text
} from "react-native";
import FastImage from "react-native-fast-image";
import { ThemeContext } from "../../context/ThemeContext";
import gradientParser from 'gradient-parser'
import LinearGradient from "react-native-linear-gradient";
import MaskedView from '@react-native-masked-view/masked-view';
export const RecentlyUserHeader = (props) => {
const {theme} = React.useContext(ThemeContext)
const generateUserName = (props) => {
console.log('generateUserName', props.user.name)
try {
const gradient = gradientParser.parse(props.user.typeInfo.color)
console.log('regex', gradient)
const colors = gradient[0].colorStops.map((c) => {
const t = c.value
return `rgba(${t[0]}, ${t[1]}, ${t[2]}, ${[3]})`
})
const locations = gradient[0].colorStops.map((c) => {
const l = c.length.value
return l/100
})
// console.log('color', colors)
return (
cacasc
}>
)
} catch(error) {
console.log('make gradient failed', error)
return (
{props.user.name}
)
}
}
return(
{
RootNavigation.push("Setting")
}}>
{generateUserName(props)}
)
}
```
Log result:
```
generateUserName demo4
LOG regex [{"colorStops": [[Object], [Object], [Object]], "orientation": {"type": "angular", "value": "180"}, "type": "linear-gradient"}]
```

Here is the image that maskview not show
And here is the image when only display Text:

Contributor guide
Assessment
This issue has not been assessed yet.