Skip to content

Commit 7ab211e

Browse files
committed
Add Google Drive and OneDrive sync pages with login buttons and sync toggle header
- Refactor database and UI logic into shared modules (shared-database.ts, shared-ui.ts) - Add Google Drive sync page using rxdb replication-google-drive plugin with OAuth login - Add Microsoft OneDrive sync page using rxdb replication-microsoft-onedrive plugin with OAuth login - Add sync method navigation header to all pages (WebRTC, Google Drive, OneDrive) - Update webpack config for multi-page output with separate entry points https://claude.ai/code/session_01WoskKBdRqYXaUNYptTsTA8
1 parent f30fd0e commit 7ab211e

29 files changed

Lines changed: 694 additions & 145 deletions

docs/0e7be46f875d1fbd90bc.bundle.js

Lines changed: 0 additions & 3 deletions
This file was deleted.

docs/0e7be46f875d1fbd90bc.bundle.js.map

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/234.8260e7ed99818d35cccb.bundle.js.map

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/f26f514b1caf2e345402.bundle.js.map

Lines changed: 0 additions & 1 deletion
This file was deleted.

docs/google-drive.4ce3cf22cb8133065576.bundle.js

Lines changed: 3 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/0e7be46f875d1fbd90bc.bundle.js.LICENSE.txt renamed to docs/google-drive.4ce3cf22cb8133065576.bundle.js.LICENSE.txt

File renamed without changes.

docs/google-drive.4ce3cf22cb8133065576.bundle.js.map

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/google-drive.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<!doctype html><html lang="en" data-framework="rxdb"><head><meta charset="utf-8"><title>RxDB Quickstart - Google Drive Sync</title><script defer="defer" src="google-drive.4ce3cf22cb8133065576.bundle.js"></script><link href="src/style.css" rel="stylesheet"></head><body><span id="forkongithub"><a href="https://github.com/pubkey/rxdb-quickstart" target="_blank">Fork me on GitHub</a></span><nav class="sync-nav"><span class="sync-nav-label">Sync method:</span> <a href="index.html" class="sync-nav-link">WebRTC</a> <a href="google-drive.html" class="sync-nav-link active">Google Drive</a> <a href="onedrive.html" class="sync-nav-link">OneDrive</a></nav><section class="todoapp"><header class="header"><h1>Google Drive todos</h1><p class="description">This is a <a href="https://rxdb.info/offline-first.html" target="_blank">local first</a> todo app that stores data locally with <a href="https://rxdb.info/" target="_blank">RxDB</a> and replicates it to <a href="https://rxdb.info/replication-google-drive.html" target="_blank">Google Drive</a> so your data syncs across all your devices.</p><div class="cloud-login"><button id="google-login-btn" class="login-btn login-btn-google">Sign in with Google</button> <span id="login-status" class="login-status">Not connected</span></div><hr><input id="insert-todo" class="new-todo" placeholder="What needs to be done? (Enter to submit)" autofocus></header><section class="main"><input id="toggle-all" class="toggle-all" type="checkbox"> <label for="toggle-all">Mark all as complete</label><ul class="todo-list" id="todo-list"></ul><footer class="footer"><span class="todo-count"></span><ul class="filters"></ul><button class="clear-completed" id="clear-completed">Clear completed</button></footer></section></section><footer class="info"><p>Written by <a href="https://github.com/pubkey" target="_blank">Daniel</a></p><p><a href="https://rxdb.info">Powered by RxDB</a></p></footer></body></html>

docs/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
<!doctype html><html lang="en" data-framework="rxdb"><head><meta charset="utf-8"><title>RxDB Quickstart • TodoMVC</title><script defer="defer" src="0e7be46f875d1fbd90bc.bundle.js"></script><link href="src/style.css" rel="stylesheet"></head><body><span id="forkongithub"><a href="https://github.com/pubkey/rxdb-quickstart" target="_blank">Fork me on GitHub</a></span><section class="todoapp"><header class="header"><h1>p2p todos</h1><p class="description">This is a <a href="https://rxdb.info/offline-first.html" target="_blank">local first</a> todo app that stores data locally with <a href="https://rxdb.info/" target="_blank">RxDB</a> and replicates it <a href="https://rxdb.info/replication-p2p.html" target="_blank">peer-to-peer with WebRTC</a> to other devices without sending the data through any central server. Open this url in another browser/device/tab to test the replication:<br/><code id="copy-url"></code><br/>The whole app is implemented without a framework in about 200 lines of TypeScript code. To learn more about how it works, I recommend looking at the <a href="https://github.com/pubkey/rxdb-quickstart/blob/master/src/index.ts" target="_blank">source code</a> and read the <a href="https://rxdb.info/quickstart.html" target="_blank">RxDB Quickstart Guide</a>.</p><hr><input id="insert-todo" class="new-todo" placeholder="What needs to be done? (Enter to submit)" autofocus></header><section class="main"><input id="toggle-all" class="toggle-all" type="checkbox"> <label for="toggle-all">Mark all as complete</label><ul class="todo-list" id="todo-list"></ul><footer class="footer"><span class="todo-count"></span><ul class="filters"></ul><button class="clear-completed" id="clear-completed">Clear completed</button></footer></section></section><footer class="info"><p>Written by <a href="https://github.com/pubkey" target="_blank">Daniel</a></p><p><a href="https://rxdb.info">Powered by RxDB</a></p></footer></body></html>
1+
<!doctype html><html lang="en" data-framework="rxdb"><head><meta charset="utf-8"><title>RxDB Quickstart - WebRTC Sync</title><script defer="defer" src="webrtc.eef27db053fa9b81b8b7.bundle.js"></script><link href="src/style.css" rel="stylesheet"></head><body><span id="forkongithub"><a href="https://github.com/pubkey/rxdb-quickstart" target="_blank">Fork me on GitHub</a></span><nav class="sync-nav"><span class="sync-nav-label">Sync method:</span> <a href="index.html" class="sync-nav-link active">WebRTC</a> <a href="google-drive.html" class="sync-nav-link">Google Drive</a> <a href="onedrive.html" class="sync-nav-link">OneDrive</a></nav><section class="todoapp"><header class="header"><h1>p2p todos</h1><p class="description">This is a <a href="https://rxdb.info/offline-first.html" target="_blank">local first</a> todo app that stores data locally with <a href="https://rxdb.info/" target="_blank">RxDB</a> and replicates it <a href="https://rxdb.info/replication-p2p.html" target="_blank">peer-to-peer with WebRTC</a> to other devices without sending the data through any central server. Open this url in another browser/device/tab to test the replication:<br/><code id="copy-url"></code><br/>The whole app is implemented without a framework in about 200 lines of TypeScript code. To learn more about how it works, I recommend looking at the <a href="https://github.com/pubkey/rxdb-quickstart/blob/master/src/index.ts" target="_blank">source code</a> and read the <a href="https://rxdb.info/quickstart.html" target="_blank">RxDB Quickstart Guide</a>.</p><hr><input id="insert-todo" class="new-todo" placeholder="What needs to be done? (Enter to submit)" autofocus></header><section class="main"><input id="toggle-all" class="toggle-all" type="checkbox"> <label for="toggle-all">Mark all as complete</label><ul class="todo-list" id="todo-list"></ul><footer class="footer"><span class="todo-count"></span><ul class="filters"></ul><button class="clear-completed" id="clear-completed">Clear completed</button></footer></section></section><footer class="info"><p>Written by <a href="https://github.com/pubkey" target="_blank">Daniel</a></p><p><a href="https://rxdb.info">Powered by RxDB</a></p></footer></body></html>

0 commit comments

Comments
 (0)