Skip to content

Not able to make Appbar.Header background color transparent #920

@yingapp

Description

@yingapp

Environment

"@reach/router": "^1.2.1",
"create-react-context": "^0.2.3",
"react": "^16.8.4",
"react-art": "^16.8.4",
"react-dom": "^16.8.4",
"react-native": "^0.58.6",
"react-native-gesture-handler": "^1.1.0",
"react-native-paper": "^2.12.0",
"react-native-vector-icons": "^6.3.0",
"react-native-web": "^0.10.0-alpha.3",
"react-native-webview": "^5.3.0",
"react-navigation": "^3.3.2"

Description

const RootStack = createStackNavigator(
    {
        home: TaskList,
        ...routes,
    },
    {
        defaultNavigationOptions: ({navigation}) => ({
            gestureResponseDistance: {
                horizontal: 45,
            },
            header: (
                <Appbar.Header
                    style={{backgroundColor:'transparent'}}
                    statusBarHeight={Platform.OS === "ios" ? 0 : StatusBar.currentHeight}
                >
                    <Appbar.Action icon="menu" onPress={() => navigation.openDrawer()}/>
                    <Appbar.Content title=""/>
                </Appbar.Header>
            ),
        }),
        headerMode: 'float',
        headerTransparent:true,
    },
);

Reproducible Demo

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions