From 68ac505d8198286702cbc429b1d2298b505f944d Mon Sep 17 00:00:00 2001 From: Henrik Giesel Date: Mon, 12 Jul 2021 16:04:27 +0200 Subject: [PATCH] Include css-browser-selector via ts/reviewer --- qt/aqt/browser/previewer.py | 1 - qt/aqt/clayout.py | 1 - ts/reviewer/BUILD.bazel | 10 +++++++--- ts/reviewer/index.ts | 2 ++ 4 files changed, 9 insertions(+), 5 deletions(-) diff --git a/qt/aqt/browser/previewer.py b/qt/aqt/browser/previewer.py index b18512267..02fbe35af 100644 --- a/qt/aqt/browser/previewer.py +++ b/qt/aqt/browser/previewer.py @@ -126,7 +126,6 @@ class Previewer(QDialog): def _setup_web_view(self) -> None: jsinc = [ "js/vendor/jquery.min.js", - "js/vendor/css_browser_selector.min.js", "js/mathjax.js", "js/vendor/mathjax/tex-chtml.js", "js/vendor/protobuf.min.js", diff --git a/qt/aqt/clayout.py b/qt/aqt/clayout.py index 0f2077bc2..f951f8e4d 100644 --- a/qt/aqt/clayout.py +++ b/qt/aqt/clayout.py @@ -332,7 +332,6 @@ class CardLayout(QDialog): jsinc = [ "js/vendor/jquery.min.js", - "js/vendor/css_browser_selector.min.js", "js/mathjax.js", "js/vendor/mathjax/tex-chtml.js", "js/vendor/protobuf.min.js", diff --git a/ts/reviewer/BUILD.bazel b/ts/reviewer/BUILD.bazel index 798268bae..e90e5f6c1 100644 --- a/ts/reviewer/BUILD.bazel +++ b/ts/reviewer/BUILD.bazel @@ -16,9 +16,13 @@ compile_sass( ts_library( - name = "lib", + name = "reviewer_ts", srcs = glob(["*.ts"]), - deps = ["//ts/lib"], + deps = [ + "//ts/lib", + "//ts/lib:backend_proto", + "@npm//css-browser-selector", + ], ) esbuild( @@ -36,7 +40,7 @@ esbuild( ], visibility = ["//visibility:public"], deps = [ - ":lib", + ":reviewer_ts", "//ts/lib", "@npm//protobufjs", ], diff --git a/ts/reviewer/index.ts b/ts/reviewer/index.ts index 45159af4d..52a8e46d8 100644 --- a/ts/reviewer/index.ts +++ b/ts/reviewer/index.ts @@ -1,6 +1,8 @@ // Copyright: Ankitects Pty Ltd and contributors // License: GNU AGPL, version 3 or later; http://www.gnu.org/licenses/agpl.html +import "css-browser-selector/css_browser_selector"; + import { bridgeCommand } from "lib/bridgecommand"; export { mutateNextCardStates } from "./answering";