Merge branch 'master' into feat/db

This commit is contained in:
Tienson Qin
2023-11-14 20:40:36 +08:00
129 changed files with 5624 additions and 3185 deletions

View File

@@ -12,6 +12,7 @@
[frontend.components.whiteboard :as whiteboard]
[frontend.config :as config]
[frontend.context.i18n :as i18n :refer [t]]
[frontend.colors :as colors]
[frontend.db :as db]
[frontend.db.restore :as db-restore]
[frontend.db.conn :as conn]
@@ -54,13 +55,13 @@
(set! js/window.onerror
(fn [message, _source, _lineno, _colno, error]
(when-not (error/ignored? message)
(log/error :exception error)
(log/error :exception error)))))
;; (notification/show!
;; (str "message=" message "\nsource=" source "\nlineno=" lineno "\ncolno=" colno "\nerror=" error)
;; :error
;; ;; Don't auto-hide
;; false)
))))
(defn- watch-for-date!
@@ -200,6 +201,8 @@
(state/set-component! :block/linked-references reference/block-linked-references)
(state/set-component! :whiteboard/tldraw-preview whiteboard/tldraw-preview)
(state/set-component! :block/single-block block/single-block-cp)
(state/set-component! :block/container block/block-container)
(state/set-component! :block/embed block/block-embed)
(state/set-component! :editor/box editor/box)
(command-palette/register-global-shortcut-commands))
@@ -228,6 +231,8 @@
(instrument/init)
(state/set-online! js/navigator.onLine)
(set-network-watcher!)
(when-let [radix-color (state/get-color-accent)]
(colors/set-radix radix-color))
(-> (util/indexeddb-check?)
(p/catch (fn [_e]