-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
201 lines (185 loc) · 8.23 KB
/
index.html
File metadata and controls
201 lines (185 loc) · 8.23 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>CocoBlockly 幫助文檔</title>
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
<meta name="description" content="Description">
<meta name="viewport"
content="width=device-width, user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0">
<!--<link rel="stylesheet" href="https://unpkg.com/docsify-themeable/dist/css/theme-simple.css">-->
<link rel="stylesheet" href="vue.css">
<meta name="theme-color" content="#2C4FCD">
<link rel="apple-touch-icon" sizes="57x57" href="http://cocorobo.hk/cocoblockly/dev/img/apple-icon-57x57.png">
<link rel="apple-touch-icon" sizes="60x60" href="http://cocorobo.hk/cocoblockly/dev/img/apple-icon-60x60.png">
<link rel="apple-touch-icon" sizes="72x72" href="http://cocorobo.hk/cocoblockly/dev/img/apple-icon-72x72.png">
<link rel="apple-touch-icon" sizes="76x76" href="http://cocorobo.hk/cocoblockly/dev/img/apple-icon-76x76.png">
<link rel="apple-touch-icon" sizes="114x114" href="http://cocorobo.hk/cocoblockly/dev/img/apple-icon-114x114.png">
<link rel="apple-touch-icon" sizes="120x120" href="http://cocorobo.hk/cocoblockly/dev/img/apple-icon-120x120.png">
<link rel="apple-touch-icon" sizes="144x144" href="http://cocorobo.hk/cocoblockly/dev/img/apple-icon-144x144.png">
<link rel="apple-touch-icon" sizes="152x152" href="http://cocorobo.hk/cocoblockly/dev/img/apple-icon-152x152.png">
<link rel="apple-touch-icon" sizes="180x180" href="http://cocorobo.hk/cocoblockly/dev/img/apple-icon-180x180.png">
<link rel="icon" type="image/png" sizes="192x192"
href="http://cocorobo.hk/cocoblockly/dev/img/android-icon-192x192.png">
<link rel="icon" type="image/png" sizes="32x32" href="http://cocorobo.hk/cocoblockly/dev/img/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="96x96" href="http://cocorobo.hk/cocoblockly/dev/img/favicon-96x96.png">
<link rel="icon" type="image/png" sizes="16x16" href="http://cocorobo.hk/cocoblockly/dev/img/favicon-16x16.png">
<link rel="manifest" href="http://cocorobo.hk/cocoblockly/dev/img/manifest.json">
<meta name="msapplication-TileColor" content="#ffffff">
<meta name="msapplication-TileImage" content="http://cocorobo.hk/cocoblockly/dev/img/ms-icon-144x144.png">
<script type="text/javascript" src="colorpicker.js"></script>
<link href="./lightbox.min.css" rel="stylesheet" />
<script type="text/javascript">
document.domain = "cocorobo.hk"
</script>
<style type="text/css">
#picker {
width: 200px;
height: 200px
}
#slide {
width: 30px;
height: 200px
}
.headerInProgress {
font-weight: bold;
background-color: rgba(247, 114, 16, .9);
color: white;
padding: 16px 18px;
margin-bottom: 40px;
border-radius: 10px;
border-left: 5px solid rgba(238, 91, 10, 1.0);
}
</style>
</head>
<body>
<nav class="body-nav">
<a href="#/" id="aa" class="active">繁</a>
<a href="#/" id="cn">简</a>
<a href="#/" id="english">EN</a>
</nav>
<div id="app">Please wait...</div>
<script>
window.$docsify = {
name: 'CocoBlockly',
// repo: '',
logo: '/media/help-logo.png',
themeColor: '#225dd5',
homepage: 'index.md',
auto2top: true,
loadSidebar: true,
loadSidebar: 'summary.md',
maxLevel: 2,
subMaxLevel: 1,
// Search feature
search: 'auto', // default
search: [
'/index.md',
'/cocomod/overview.md',
'/cocomod/audio-analyzer.md',
'/cocomod/bluetooth.md',
'/cocomod/coco-cloud.md',
'/cocomod/environment.md',
'/cocomod/hub.md',
'/cocomod/led-matrix.md',
'/cocomod/main-controller.md',
'/cocomod/motion.md',
'/cocomod/motor-driver.md',
'/cocomod/music.md',
'/cocomod/power-management.md',
'/cocomod/screen.md',
'/cocomod/sensor-101.md',
'/cocomod/servo.md',
'/cocomod/touch.md',
'/cocomod/wifi.md',
'/getting-started/info.md',
'/getting-started/local-storage.md',
'/getting-started/cloud-storage.md',
'/getting-started/project-snapshot.md',
'/getting-started/serial-monitor.md',
'/kit/overview.md',
'/kit/smart-home.md',
'/kit/creative-electronics.md',
'/kit/robot-car.md',
'/kit/robot-arm.md',
'/faq/NB-IoT.md'
],
// complete configuration parameters
search: {
maxAge: 86400000, // Expiration time, the default one day
paths: 'auto', // or 'auto'
placeholder: '點此處搜尋內容',
// Localization
placeholder: {
'/': '點此處搜尋內容'
},
noData: '沒有搜尋到結果',
// Localization
noData: {
'/': '沒有搜尋到結果'
},
// Headline depth, 1 - 6
depth: 6
},
ga: 'UA-110081781-1'
}
</script>
<!-- docsify -->
<script src="docsify.min.js"></script>
<script src="search.min.js"></script>
<!-- docsify-themeable -->
<!-- <script src="//unpkg.com/docsify-themeable"></script>-->
<script>
var hash = window.location.hash;
if (window.addEventListener) {
window.addEventListener("hashchange", myFunction, false);
} else if (window.attachEvent) {
window.attachEvent("hashchange", myFunction);
}
// window.onhashchange(function () {
// console.log(myFunction())
// })
function myFunction() {
hash = window.location.hash
setTimeout(() => {
imgload();
}, 500)
}
document.getElementById('english').onclick = function () {
window.location.href = `http://help-english.cocorobo.hk/${hash}`
}
document.getElementById('cn').onclick = function () {
window.location.href = `http://help.cocorobo.cn/${hash}`
}
</script>
<script type="text/javascript" src="lightbox-plus-jquery.min.js"></script>
<script>
window.onload = imgload = function () {
let imgs = document.getElementsByTagName('img')
for (let i = 0; i < imgs.length - 1; i++) {
imgs[i].onclick = function () {
let parent = imgs[i].parentNode;
let num = 0
for (let j = 0; j < parent.children.length; j++) {
let parentStr = decodeURI(parent.children[j] && parent.children[j].src) || '';
let imgSrc = imgs[i].src
if ((parentStr && parentStr.slice(parentStr.lastIndexOf('/') + 1, parentStr.lastIndexOf('.'))) === imgSrc.slice(imgSrc.lastIndexOf('/') + 1, imgSrc.lastIndexOf('.'))) {
num = j;
console.log(num)
}
}
if (parent.tagName !== "A") {
imgs[i].style.marginRight = 5 + 'px';
let A = document.createElement('a')
A.href = imgs[i].src;
A.setAttribute('data-lightbox', imgs[i].src);
A.appendChild(imgs[i]);
parent.insertBefore(A, parent.children[num]);
A.addEventListener('click', function () { })
}
}
}
}
</script>
</body>
</html>