Chrome扩展程序会添加主页按钮并显示书签栏

时间:2017-09-26 07:22:45

标签: google-chrome google-chrome-extension

是否可以使用Chrome扩展程序添加“主页”按钮并显示书签栏?

1 个答案:

答案 0 :(得分:0)

不,不。

import React from 'react'; import Button from 'react-native-button'; import Modal from 'react-native-modalbox'; import Slider from 'react-native-slider'; import { AppRegistry, Text, StyleSheet, ScrollView, View, Dimensions, TextInput } from 'react-native'; var screen = Dimensions.get('window'); class AccessibilityApp extends React.Component { constructor() { super(); this.state = { isOpen: false, isDisabled: false, swipeToClose: true, sliderValue: 0.3 }; } onClose() { console.log('Modal just closed'); } onOpen() { console.log('Modal just openned'); } onClosingState(state) { console.log('the open/close of the swipeToClose just changed'); } renderList() { var list = []; for (var i=0;i<50;i++) { list.push(<Text style={styles.text} key={i}>Elem {i}</Text>); } return list; } render() { var BContent = <Button onPress={() => this.setState({isOpen: false})} style={[styles.btn, styles.btnModal]}>X</Button>; return ( <View style={styles.wrapper}> <Button onPress={() => this.refs.modal3.open()} style={styles.btn}>Position centered + backdrop + disable</Button> <Modal accessibilityViewIsModal={true} style={[styles.modal, styles.modal3]} position={"center"} ref={"modal3"} isDisabled={this.state.isDisabled}> <Text style={styles.text}>Modal centered</Text> <Button onPress={() => this.setState({isDisabled: !this.state.isDisabled})} style={styles.btn}>Disable ({this.state.isDisabled ? "true" : "false"})</Button> </Modal> </View> ); } } const styles = StyleSheet.create({ wrapper: { paddingTop: 50, flex: 1 }, modal: { justifyContent: 'center', alignItems: 'center' }, modal2: { height: 230, backgroundColor: "#3B5998" }, modal3: { height: 300, width: 300 }, btn: { margin: 10, backgroundColor: "#3B5998", color: "white", padding: 10 }, btnModal: { position: "absolute", top: 0, right: 0, width: 50, height: 50, backgroundColor: "transparent" }, text: { color: "black", fontSize: 22 } }); AppRegistry.registerComponent('AccessibilityApp', () => AccessibilityApp); API不允许您切换书签栏的可见性,也没有API公开主页按钮可见性设置。