chenxixian 6 anni fa
parent
commit
3282abc27d
2 ha cambiato i file con 24 aggiunte e 0 eliminazioni
  1. 18 0
      Alert.jsx
  2. 6 0
      Alert.mdx

+ 18 - 0
Alert.jsx

@@ -26,3 +26,21 @@ Alert.propTypes = {
 Alert.defaultProps = {
   kind: 'info',
 }
+
+export function EditButton(props) {
+  let encodedStatus = encodeURIComponent(
+      "This live editor looks pretty darn handy #JavaScript"
+  )
+  let encodedURL = encodeURIComponent(
+      "https://ecs.chenxixian.cn/chenxixian/docz/src/master"
+  )
+
+  return (
+      <a
+          href={`https://ecs.chenxixian.cn/chenxixian/docz/_edit/master/ALert.mdx`}
+          target="_blank"
+          className="EditButton">
+        Edit This Page!
+      </a>
+  )
+}

+ 6 - 0
Alert.mdx

@@ -6,6 +6,12 @@ menu: Components
 import { Playground, Props } from 'docz'
 import { Alert } from './Alert'
 
+import { Button, EditButton} from './Alert'
+
+# Button
+<EditButton />
+
+
 # Alert
 
 ## Properties