-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathwhitboard.html
More file actions
68 lines (61 loc) · 2.6 KB
/
Copy pathwhitboard.html
File metadata and controls
68 lines (61 loc) · 2.6 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Axinote Whiteboard</title>
<script src="https://www.gstatic.com/firebasejs/9.23.0/firebase-app-compat.js"></script>
<script src="https://www.gstatic.com/firebasejs/9.23.0/firebase-auth-compat.js"></script>
<script src="https://www.gstatic.com/firebasejs/9.23.0/firebase-database-compat.js"></script>
<script>
firebase.initializeApp({
apiKey: "AIzaSyCmmnXzel_rrxE7xM2mm0htu4Ehh9Eo6Rs",
authDomain: "studypilot-92014.firebaseapp.com",
databaseURL: "https://studypilot-92014-default-rtdb.asia-southeast1.firebasedatabase.app",
projectId: "studypilot-92014",
storageBucket: "studypilot-92014.firebasestorage.app",
messagingSenderId: "267953191976",
appId: "1:267953191976:web:0c625dc16e7fa8b822c91d"
});
const _auth = firebase.auth();
const _db = firebase.database();
_auth.setPersistence(firebase.auth.Auth.Persistence.LOCAL).catch(() => {});
window.fb = {
auth: _auth,
database: _db,
createUserWithEmailAndPassword: (auth, email, pass) => auth.createUserWithEmailAndPassword(email, pass),
signInWithEmailAndPassword: (auth, email, pass) => auth.signInWithEmailAndPassword(email, pass),
signOut: (auth) => auth.signOut(),
onAuthStateChanged: (auth, cb) => auth.onAuthStateChanged(cb),
ref: (db, path) => db.ref(path),
set: (ref, data) => ref.set(data),
get: (ref) => ref.get(),
update: (ref, data) => ref.update(data),
remove: (ref) => ref.remove(),
push: (ref, data) => data !== undefined ? ref.push(data) : ref.push(),
onValue: (ref, cb) => { ref.on('value', cb); return () => ref.off('value', cb); },
onDisconnect: (ref) => ref.onDisconnect(),
};
</script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/pdf.js/3.11.174/pdf.min.js"></script>
<script>
if (typeof pdfjsLib !== 'undefined') {
pdfjsLib.GlobalWorkerOptions.workerSrc =
'https://cdnjs.cloudflare.com/ajax/libs/pdf.js/3.11.174/pdf.worker.min.js';
}
</script>
<link rel="stylesheet" href="/css/styles.css">
</head>
<body>
<div id="auth-screen"></div>
<div id="app" class="hidden"></div>
<script>
if (!window.location.pathname.startsWith('/app/')) {
const target = `/app/collab${window.location.search || ''}${window.location.hash || ''}`;
history.replaceState({ flowday: true, entry: 'whiteboard' }, '', target);
}
</script>
<script src="/js/flowai-runtime.js"></script>
<script src="/js/app.js"></script>
</body>
</html>