Skip to content

Commit 470917a

Browse files
committed
disable right click
1 parent f4f8576 commit 470917a

File tree

3 files changed

+30
-4
lines changed

3 files changed

+30
-4
lines changed

index.html

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8">
5+
<title>docsify-edit-on-github - edit on github plugin for docsify</title>
6+
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
7+
<meta name="description" content="edit on github plugin for docsify">
8+
<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
9+
<link rel="stylesheet" href="//unpkg.com/docsify/lib/themes/vue.css">
10+
</head>
11+
<body>
12+
<div id="app"></div>
13+
<script src="./index.js"></script>
14+
<script>
15+
window.$docsify = {
16+
name: 'docsify-edit-on-github',
17+
repo: 'https://github.com/njleonzhang/docsify-edit-on-github',
18+
plugins: [
19+
EditOnGithubPlugin.create(
20+
'https://github.com/njleonzhang/docsify-edit-on-github/blob/master/'
21+
)
22+
]
23+
}
24+
</script>
25+
<script src="//unpkg.com/docsify/lib/docsify.min.js"></script>
26+
</body>
27+
</html>

index.js

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,8 @@
2727

2828
var header = [
2929
'<div style="overflow: auto">',
30-
'<p style="float: right"><a href="',
31-
docBase,
32-
'" target="_blank" onclick="EditOnGithubPlugin.onClick(event)">',
30+
'<p style="float: right"><a style="text-decoration: underline; cursor: pointer"',
31+
'target="_blank" onclick="EditOnGithubPlugin.onClick(event)">',
3332
title,
3433
'</a></p>',
3534
'</div>'

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"description": "edit on github plugin for docsify",
55
"main": "index.js",
66
"scripts": {
7-
"test": "echo \"Error: no test specified\" && exit 1"
7+
"test": "docsify serve test"
88
},
99
"repository": {
1010
"type": "git",

0 commit comments

Comments
 (0)