-
Notifications
You must be signed in to change notification settings - Fork 1
/
lib1.html
65 lines (64 loc) · 2.96 KB
/
lib1.html
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
<!DOCTYPE html>
<!-- This file is not served in the built package. It's only used in dev mode -->
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" href="/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<script>
// On the real env, these globals are defined in the GTM template
var setInWindow = function(key, val) {
window[key] = val;
}
setInWindow("KUROCO_API_HOST", "https://docdog.g.kuroco.app");
setInWindow("KUROCO_CONFIG", {
"use_float_button": true,
//"hubId": 21706870 // Disable hubspot tracking for local dev
});
setInWindow("KUROCO_OAUTH_SETTINGS", {
"google": {"action_url": "https://docdog.g.kuroco.app/direct/login/oauth_login/?spid=1"},
"facebook": {},
"yahoo": {},
"line": {},
"apple": {}
});
</script>
<script type="module" src="/src/main-lib1.iife.js"></script>
<title>Testing Page - Lib1</title>
</head>
<body>
<!-- <a href="https://docdog.g.kuroco.app/header">My header A</a> -->
<a href="https://docdog.g.kuroco.app/download?id=3">Docdog id=3 download (PRIVATE)</a><br/>
<a href="https://docdog.g.kuroco.app/download?id=4&public=true">Docdog id=4 download (PUBLIC)</a><br/>
<a href="https://docdog.g.kuroco.app/logout">Docdog Logout</a><br/>
<a href="https://docdog.g.kuroco.app/login">Docdog Login</a><br/>
<a href="https://docdog.g.kuroco.app/signup">Docdog SignUp</a><br/>
<a href="https://docdog.g.kuroco.app/profile">Docdog Profile</a><br/>
<a href="https://docdog.g.kuroco.app/list?cnt=1">Docdog List</a><br/>
<br/>
Alternative using data-kuroco attribute :<br/>
<button data-kuroco="list">Docdog List</button><br/>
<button data-kuroco="download?id=4&public=true">Docdog Download 4</button><br/>
<br/>
Demo of isLogin toggle :<br/>
<button type="button" data-kuroco="login?show=!isLogin">ログイン</button>
<button type="button" data-kuroco="reminder?show=!isLogin">PWリマインダー</button>
<button type="button" data-kuroco="?show=isLogin" onclick="toggleDocdogMemberMenu()">Member</button>
<a href="https://docdog.g.kuroco.app/mypage?show=isLogin">Docdog Mypage</a><br/>
<nav style="display:none" name="docdogMemberMenu">
<button type="button" class="l-header__nav--user__button" data-kuroco="profile" onclick="toggleDocdogMemberMenu()">アカウント情報の編集</button>
<button type="button" class="l-header__nav--user__button" data-kuroco="logout" onclick="toggleDocdogMemberMenu()">ログアウト</button>
</nav>
<script>
function toggleDocdogMemberMenu() {
document.getElementsByName("docdogMemberMenu").forEach(function(el) {
if (el.style.display === "none") {
el.style.display = "block";
} else {
el.style.display = "none";
}
});
}
</script>
</body>
</html>