Commit Graph

37 Commits

Author SHA1 Message Date
Damien Elmes
f248b71707 sanitize deck description HTML with html-sanitize
Committing for reference; will roll back afterwards.

This adds approximately 150k to the bundled .js file in release mode.
html-sanitizer might be useful to replace our custom paste filtering
code in the future, but for now I'm not sure it's worth the extra
page load time over doing the filtering in Rust.
2021-02-06 13:25:34 +10:00
Damien Elmes
971b6726c0 Restore "Merge pull request #1007 from hgiesel/sveltesass2""
This reverts commit ffcf0aa3ca and
points to a new rules_svelte commit.

It looks like we were getting away with not listing the dep on the
rules_svelte end - the failing build turned out to be because we need
to pass sass in to our local svelte_check invocation.
2021-02-06 08:39:36 +10:00
Damien Elmes
77526be5f1 update JS deps 2021-02-03 20:38:41 +10:00
Henrik Giesel
3701abe06a Install types for lodash.throttle 2021-01-30 02:12:44 +01:00
Henrik Giesel
6bf38236b9 Replace individual d3 libraries with encompassing d3 2021-01-30 00:00:22 +01:00
Damien Elmes
3dad3c90d0 add .sql file formatter
Uses the logic from the sqltools VSCode add-on, with a workaround
for the use of 'type' in some table columns.

By detecting the presence of 'BUILD_WORKSPACE_DIRECTORY' we can tell
if the rule is running in test mode or was run directly, avoiding the
need for separate check and fix rules. It might be nice to extend this
to other formatting rules in the future as well.
2021-01-09 14:22:49 +10:00
Henrik Giesel
bfd9c93e61 Add css-browser-selector as bazel rule, and update from 0.4.0 to 0.6.5 2020-12-31 16:27:52 +01:00
Henrik Giesel
079ce6bdf0 Add bazel recipe and update protobufjs to 6.10.2 2020-12-31 16:06:44 +01:00
Henrik Giesel
988d0df3e7 Install jquery-ui-dist 2020-12-30 11:56:49 +01:00
Damien Elmes
9e1eaacc06 Revert "Merge pull request #873 from hgiesel/otherjsdeps"
This reverts commit 62600051ae, reversing
changes made to 88553acb0d.

- Standard graphs render incorrectly on latest version - the wrong number
of days are shown, and the grid lines look wrong. Any version after 0.8.3
seems to suffer from this problem.
- Pie graphs and stack graphs don't render - they are provided in separate
files, and plot.js in previous Anki versions has them included in the one
file. To maintain compatibility with add-ons, we'd need to create a single
file as before, instead of importing multiple files.

If the above issues are fixed I'd be happy to merge this in again, but
as the old graphs are on the way out, it's probably not worth the effort.
2020-12-30 14:13:52 +10:00
Henrik Giesel
6aad58260b Install flot 4.2.1
Old version was 0.8.3
2020-12-29 12:02:41 +01:00
Henrik Giesel
0c95cb3514 Remove jquery from Anki repo and replace with Bazel BUILD 2020-12-28 13:16:12 +01:00
Damien Elmes
02d7e55f9b update to rules_nodejs 3.0.0
Seems to fix the rollup issues on Windows.
2020-12-23 16:05:15 +10:00
Henrik Giesel
6104ea26fb Remove @types/mathjax as it is for MathJax 2 2020-11-14 14:14:25 +01:00
Henrik Giesel
6d4ff1212d Rip out MathJax 2 and setup MathJax 3 environment 2020-11-14 14:14:25 +01:00
Damien Elmes
410987f0a6 relative js package paths 2020-11-12 21:07:59 +10:00
Damien Elmes
eed9ca9885 export runtime js licenses 2020-11-12 20:03:41 +10:00
Damien Elmes
2b9d3a808d update ts deps 2020-11-12 20:03:41 +10:00
Damien Elmes
aea0a6fcc6 initial Bazel conversion
Running and testing should be working on the three platforms, but
there's still a fair bit that needs to be done:

- Wheel building + testing in a venv still needs to be implemented.
- Python requirements still need to be compiled with piptool and pinned;
need to compile on all platforms then merge
- Cargo deps in cargo/ and rslib/ need to be cleaned up, and ideally
unified into one place
- Currently using rustls to work around openssl compilation issues
on Linux, but this will break corporate proxies with custom SSL
authorities; need to conditionally use openssl or use
https://github.com/seanmonstar/reqwest/pull/1058
- Makefiles and docs still need cleaning up
- It may make sense to reparent ts/* to the top level, as we don't
nest the other modules under a specific language.
- rspy and pylib must always be updated in lock-step, so merging
rspy into pylib as a private module would simplify things.
- Merging desktop-ftl and mobile-ftl into the core ftl would make
managing and updating translations easier.
- Obsolete scripts need removing.
- And probably more.
2020-11-01 14:26:58 +10:00
Damien Elmes
70a73b7c60 "fix" ts failing in CI due to improved upstream type signatures
...by throwing non-null assertions everywhere.
2020-09-29 22:13:25 +10:00
Damien Elmes
dcb6bf2cd4 update ts deps to fix svelte-vscode 2020-09-01 10:24:38 +10:00
Damien Elmes
4086042970 switch the card counts to a pie graph 2020-08-12 18:58:21 +10:00
Damien Elmes
b6687f0203 update svelte-check minimum 2020-07-29 12:06:48 +10:00
Damien Elmes
0e4dae8ee1 update ts deps 2020-07-28 11:15:49 +10:00
Damien Elmes
0d8df6be20 run svelte-check as part of check 2020-07-22 14:11:35 +10:00
Damien Elmes
101deb002b graphs now work in night mode 2020-06-30 16:23:46 +10:00
Damien Elmes
1b37398503 add basic calendar graph 2020-06-30 15:13:44 +10:00
evandrocoan
40831ef86e Fixed pbjs not working on Windows because package.json runs by
cmd.exe which does not support pipe | and ; semicolons
6fd444b958 (r40232987)
2020-06-29 15:22:36 -03:00
Damien Elmes
4cc9e2a780 fixes for Chromium 56 (Qt 5.9) 2020-06-29 15:48:01 +10:00
Damien Elmes
41d77b0255 get i18n working in typescript 2020-06-29 15:48:01 +10:00
Damien Elmes
329186f140 qt's js code now shares ts/node_modules; more graph work 2020-06-29 15:48:01 +10:00
Damien Elmes
dcff5e28fa add top level component and pass search/day limit back from frontend 2020-06-29 15:48:00 +10:00
Damien Elmes
6fd444b958 add a new ts/ folder with a new graph proof of concept 2020-06-29 15:48:00 +10:00
Damien Elmes
b23b6fbe35 move the separate components back into this monorepo
Earlier today I pushed a change that split this code up into multiple
repos, but that has proved to complicate things too much. So we're
back to a single repo, except the individual submodules are better
separated than they were before.

The README files need updating again; I will push them out soon.

Aside from splitting out the different modules, the sound code has
moved from from anki to aqt.
2020-01-02 19:43:19 +10:00
Damien Elmes
d7d0d9bf88 add prettier, tidy up makefile 2019-12-18 16:12:02 +10:00
Damien Elmes
de29b02089 deckbrowser and overview 2019-12-18 13:21:58 +10:00
Damien Elmes
9b04a92df2 add typescript to build 2019-12-18 12:53:13 +10:00