From fa10aa6ca08a4e5edc19658268f3ee788c5d2107 Mon Sep 17 00:00:00 2001 From: liteng <930372551@qq.com> Date: Fri, 28 Jun 2019 07:19:36 +0800 Subject: [PATCH] HelpMenu --- .../src/editor2/menu/HelpMenu.jsx | 41 ++++++++++++++----- 1 file changed, 31 insertions(+), 10 deletions(-) diff --git a/ShadowEditor.Web/src/editor2/menu/HelpMenu.jsx b/ShadowEditor.Web/src/editor2/menu/HelpMenu.jsx index d9349ba2..0db335f7 100644 --- a/ShadowEditor.Web/src/editor2/menu/HelpMenu.jsx +++ b/ShadowEditor.Web/src/editor2/menu/HelpMenu.jsx @@ -8,22 +8,43 @@ class HelpMenu extends React.Component { constructor(props) { super(props); - this.handleClick = this.handleClick.bind(this); - } - - handleClick(event) { - event.stopPropagation(); - alert('Hello, world!'); + this.handleSource = this.handleSource.bind(this); + this.handleExamples = this.handleExamples.bind(this); + this.handleDocuments = this.handleDocuments.bind(this); + this.handleAbout = this.handleAbout.bind(this); } render() { return - - - - + + + + ; } + + handleSource() { + window.open('https://github.com/tengge1/ShadowEditor', '_blank'); + } + + handleExamples() { + window.open('https://github.com/tengge1/ShadowEditor-examples', '_blank'); + } + + handleDocuments() { + window.open('https://tengge1.github.io/ShadowEditor/', '_blank'); + } + + handleAbout() { + // UI.alert( + // L_ABOUT, + // `${L_NAME}: ShadowEditor
+ // ${L_AUTHOR}: tengge
+ // ${L_LISENSE}: MIT
+ // ${L_SOURCE}1: https://github.com/tengge1/ShadowEditor
+ // ${L_SOURCE}2: https://gitee.com/tengge1/ShadowEditor` + // ); + } } export default HelpMenu; \ No newline at end of file