Commit graph

19809 commits

Author SHA1 Message Date
Dennis Francis
1d0a406e5d mocha: add unit test for L.LOUtil.Rectangle
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: Ib0708c41c93fd2d7680c9bc2876b75216fc5377c
2023-01-18 16:45:02 +05:30
Dennis Francis
688ea1d4ea browser: convert createRectangle() to typescript
The logic is simplified by not having to maintain redundant states for
x2, y2, area and rounded versions of all variables. Here they are
automatically calculated by using getters.

Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I0125c74d06bceaa69896029ce85c6437ffd3d0dc
2023-01-18 16:45:02 +05:30
Dennis Francis
cb1b2611bd ts: use let/const instead of var in group controls
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I217a741cb3b0a138cfd67cb631a73c9881d9d5f8
2023-01-18 16:45:02 +05:30
Dennis Francis
291494eaa9 eslint: fix errors in Control.RowGroup.ts
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: Ib5f24e6abe73576d63006a087bf0c7000973085b
2023-01-18 16:45:02 +05:30
Dennis Francis
efbeea569c eslint: fix errors in Control.GroupBase.ts
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: Ibbca537988e846bf9e3c8dea72c3d46702cb5c8e
2023-01-18 16:45:02 +05:30
Dennis Francis
0a97f16b9e eslint: fix errors in Control.CornerGroup.ts
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I007439abce299452a39285d3498331828413dcbe
2023-01-18 16:45:02 +05:30
Dennis Francis
cac5ab0315 eslint: fix errors in Control.ColumnGroup.ts
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: Ifb7d2685ef2fe3c85585bf42ff7a9095788dc7fc
2023-01-18 16:45:02 +05:30
Dennis Francis
b6a107291a browser: convert group controls to TS
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: Iab63fbee8480c40a29635985e97764c1f62fc561
2023-01-18 16:45:02 +05:30
Dennis Francis
a4c890a12a use existing section/container types everywhere
Before this patch the section types were not used outside of
CanvasSectionContainer.ts and new sections were created by using objects
that looked like CanvasSectionObject.

Let us take advantage of typescript type checks by using
CanvasSectionObject class as the base class for all sections added using
addSection().

To make this happen we need to separate callbacks from member functions
of CanvasSectionObject class because typescript does not treat them as
same.

TODO: Other non-typescript sections need to be converted by follow-up patches.

Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: Ieeac168b6a4f82a0d55accd88a07708bf9da2587
2023-01-18 16:45:02 +05:30
Dennis Francis
bd40bca37f browser: add type for createSection parameter
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: Ic23aa1f686644de9b18daecc3a993af71add1114
2023-01-18 16:45:02 +05:30
Dennis Francis
a0932fd840 browser: avoid duplication of check command
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I9a31f5abb20ce230925205501b7f1e67b53cb328
2023-01-18 16:45:02 +05:30
Dennis Francis
e2ef62aabd mocha: add tests for '-left' anchor flag
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: Ibb359bb596994204d4641b2929ac2d3cd329caf1
2023-01-18 16:45:02 +05:30
Dennis Francis
f19948de9c mocha: avoid assert with absolute coordinates
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: Iffb3ad4e35621bb7d57e8379d59940fa2caae288
2023-01-18 16:45:02 +05:30
Dennis Francis
4ac90db720 mocha: tests for 2-vert section container
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I22a1b72917508e1a1615251aa9b6183f79299432
2023-01-18 16:45:02 +05:30
Dennis Francis
98da29a609 mocha: tests for 2-horiz section container
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I26b29113fcb627e1f22a3578eb82641d105a67ae
2023-01-18 16:45:02 +05:30
Dennis Francis
c744ed64dc mocha: move container setup code
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I5f31276c3570d2ab02a2820848cb2393dfb0b760
2023-01-18 16:45:02 +05:30
Dennis Francis
df14c25fbe mocha: move Rectangle utility functions
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: Id441837e6939297d40870761dd191c7f4240b677
2023-01-18 16:45:02 +05:30
Dennis Francis
ad71d399ef mocha: move Rectangle type to its own file
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I8bfa41e9a25d5d13da62065186f8d7e7d2466b5f
2023-01-18 16:45:02 +05:30
Dennis Francis
13f746781b mocha: move jsdom setup string to helper function
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I8a04aabee4691d1c0d914618a1be49bd8dac7fb2
2023-01-18 16:45:02 +05:30
Dennis Francis
ee7a6e7539 add mocha tests for singleton section-container
Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I2d6cb530b527d891ed1490e535105c7362fcc0de
2023-01-18 16:45:02 +05:30
Tor Lillqvist
366b94a5fb Limit line length in uglified bundle.js file
Helps in the hopefully rare cases where you need to see what code some
error message points to. Otherwise bundle.js will have extremely long
lines, and many editors have a hard time with such. (For example: Line
1, column 2949562.)

Signed-off-by: Tor Lillqvist <tml@collabora.com>
Change-Id: I229814e985348e94c8cda2d88b77ad1ea4b74ae7
2023-01-18 02:19:26 +02:00
Pranam Lashkari
7c82370446 zotero: added unlink citation support for refmarks
Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: I8b92d6187c60ee6656d84c4fec0cebb0eb3a1b58
2023-01-17 15:11:05 +01:00
Pranam Lashkari
4dd5c23fcf zotero: added unlink citation support for bookmark
Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: I8a1e8019997af230ab19ad2161153ba603af2ee9
2023-01-17 15:11:05 +01:00
Pranam Lashkari
6399d5722a zotero: added unlink citation support for field mark
Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: I4dd4f0e7e58c5272a965eac10537903024314029
2023-01-17 15:11:05 +01:00
Pedro Pinto Silva
f5c31c89ec Inform user about all the implication related to unlinking citations
Add also notification once they are unlinked

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Id26f7228f5a845b79f941256738a0d83bd12e43f
2023-01-17 15:11:05 +01:00
Andras Timar
7b10bd0a16 Update l10n files for Weblate
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: Ia5d7a453c1b73ea6bf52fdf5557b855a8a357484
2023-01-16 20:20:14 +01:00
Andras Timar
8e3e2c61b7 fix a few translatable messages
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: If8313ceb7d4f7acf08958b310c378d8bea9d1887
2023-01-16 20:12:32 +01:00
Nathan
5d391a74ea Translated using Weblate (French)
Currently translated at 100.0% (479 of 479 strings)

Translation: Collabora Online/UI
Translate-URL: https://hosted.weblate.org/projects/collabora-online/ui/fr/
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: Id2034def8b97d54ea537c47348bfb20b8173e0cb
2023-01-16 19:35:31 +01:00
ERYpTION
ec260d99c8 Translated using Weblate (Danish)
Currently translated at 73.4% (352 of 479 strings)

Translation: Collabora Online/UI
Translate-URL: https://hosted.weblate.org/projects/collabora-online/ui/da/
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I2f762de7d5df820dc40e446c174b775f91c93044
2023-01-16 19:35:31 +01:00
ERYpTION
e8598e2205 Translated using Weblate (Danish)
Currently translated at 100.0% (22 of 22 strings)

Translation: Collabora Online/Android lib
Translate-URL: https://hosted.weblate.org/projects/collabora-online/android-lib/da/
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I6c3f5804ad030d6917c364bd2f6816e12aa5e32a
2023-01-16 19:35:31 +01:00
ERYpTION
8ab5a56695 Translated using Weblate (Danish)
Currently translated at 100.0% (110 of 110 strings)

Translation: Collabora Online/Android app
Translate-URL: https://hosted.weblate.org/projects/collabora-online/android-app/da/
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: Ibe1d5e8e978e340a1b78cc6531da5f3e49d419f0
2023-01-16 19:35:31 +01:00
Herve FARNER
cf841bc6e6 Translated using Weblate (French)
Currently translated at 98.7% (473 of 479 strings)

Translation: Collabora Online/UI
Translate-URL: https://hosted.weblate.org/projects/collabora-online/ui/fr/
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I87cfcbbd0c11a386b19eb05fadc6ab9a3a42e44a
2023-01-16 19:35:31 +01:00
Adolfo Jayme Barrientos
812ca1b942 Translated using Weblate (Catalan)
Currently translated at 100.0% (457 of 457 strings)

Translation: Collabora Online/Help
Translate-URL: https://hosted.weblate.org/projects/collabora-online/help/ca/
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I86d9d6f7c30f455f3f306b1cd40b3cb1a27a82cd
2023-01-16 19:35:31 +01:00
Adolfo Jayme Barrientos
9178c00aa3 Translated using Weblate (Catalan)
Currently translated at 100.0% (479 of 479 strings)

Translation: Collabora Online/UI
Translate-URL: https://hosted.weblate.org/projects/collabora-online/ui/ca/
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I227375ec73351ae640a3a02aa5673d6021747fb5
2023-01-16 19:35:30 +01:00
Allan Nordhøy
dabcb04be1 Translated using Weblate (Norwegian Bokmål)
Currently translated at 77.0% (369 of 479 strings)

Translation: Collabora Online/UI
Translate-URL: https://hosted.weblate.org/projects/collabora-online/ui/nb_NO/
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: Iefd8ee90aa007c0367ccd7767c8f5da40289366c
2023-01-16 19:35:30 +01:00
Adolfo Jayme Barrientos
de37e40c7e Translated using Weblate (Portuguese (Brazil))
Currently translated at 90.9% (20 of 22 strings)

Translation: Collabora Online/Android lib
Translate-URL: https://hosted.weblate.org/projects/collabora-online/android-lib/pt_BR/
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I4cc09f637774043d26ad1032be7c43b748e17a48
2023-01-16 19:35:30 +01:00
Adolfo Jayme Barrientos
5441da8895 Translated using Weblate (Asturian)
Currently translated at 81.8% (18 of 22 strings)

Translation: Collabora Online/Android lib
Translate-URL: https://hosted.weblate.org/projects/collabora-online/android-lib/ast/
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: Ie14b952074a1919a54e4de191515a729693ca222
2023-01-16 19:35:30 +01:00
Adolfo Jayme Barrientos
b04320f34d Translated using Weblate (Portuguese (Brazil))
Currently translated at 90.9% (20 of 22 strings)

Translation: Collabora Online/Android lib
Translate-URL: https://hosted.weblate.org/projects/collabora-online/android-lib/pt_BR/
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: Ie1fc29fe1c10cdedb650dd0af97135b83b70ad15
2023-01-16 19:35:30 +01:00
Flavio F. M
5d55443d24 Translated using Weblate (Portuguese (Brazil))
Currently translated at 90.9% (20 of 22 strings)

Translation: Collabora Online/Android lib
Translate-URL: https://hosted.weblate.org/projects/collabora-online/android-lib/pt_BR/
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I238c07175cc948a786b14f7b287f6e6787924358
2023-01-16 19:35:30 +01:00
Flavio F. M
29374b869b Translated using Weblate (Portuguese (Brazil))
Currently translated at 86.3% (19 of 22 strings)

Translation: Collabora Online/Android lib
Translate-URL: https://hosted.weblate.org/projects/collabora-online/android-lib/pt_BR/
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I6c3624dd3d48a3f0c9ee1ef49c0c0e393ca7bb0e
2023-01-16 19:35:30 +01:00
Adolfo Jayme Barrientos
528f31b004 Translated using Weblate (Portuguese (Brazil))
Currently translated at 99.7% (478 of 479 strings)

Translation: Collabora Online/UI
Translate-URL: https://hosted.weblate.org/projects/collabora-online/ui/pt_BR/
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: Ic1aaad94dc508f1d13c4583a0f7c821fc65351b9
2023-01-16 19:35:30 +01:00
Flavio F. M
b88b852e6c Translated using Weblate (Portuguese (Brazil))
Currently translated at 98.1% (108 of 110 strings)

Translation: Collabora Online/Android app
Translate-URL: https://hosted.weblate.org/projects/collabora-online/android-app/pt_BR/
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I50b19f424db9d6acca1d30d2e596d109490edfe3
2023-01-16 19:35:30 +01:00
Flavio F. M
b820df9947 Translated using Weblate (Portuguese (Brazil))
Currently translated at 99.7% (478 of 479 strings)

Co-authored-by: Flavio F. M <flavius_androiduser@protonmail.com>
Translate-URL: https://hosted.weblate.org/projects/collabora-online/ui/pt_BR/
Translation: Collabora Online/UI
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I9b14ed8c7ce1ed059206431c72ebff801ed176da
2023-01-16 19:35:30 +01:00
Adolfo Jayme Barrientos
856bae94b8 Translated using Weblate (Portuguese (Brazil))
Currently translated at 99.7% (478 of 479 strings)

Co-authored-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
Translate-URL: https://hosted.weblate.org/projects/collabora-online/ui/pt_BR/
Translation: Collabora Online/UI
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I0d2ce743f6e3c67a89012008afffc7743621a796
2023-01-16 19:35:30 +01:00
Luna Jernberg
60dfb52b8e Translated using Weblate (Swedish)
Currently translated at 100.0% (479 of 479 strings)

Co-authored-by: Luna Jernberg <droidbittin@gmail.com>
Translate-URL: https://hosted.weblate.org/projects/collabora-online/ui/sv/
Translation: Collabora Online/UI
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I26bb3e8f909c2aba4179b3aa9a438af4033c8e97
2023-01-16 19:35:30 +01:00
Translator-3000
086d7010e9 Translated using Weblate (Italian)
Currently translated at 100.0% (479 of 479 strings)

Co-authored-by: Translator-3000 <weblate.m1d0h@8shield.net>
Translate-URL: https://hosted.weblate.org/projects/collabora-online/ui/it/
Translation: Collabora Online/UI
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I04fb3f4a21b35a01c6a5b062e0853536a3d52bb3
2023-01-16 19:35:30 +01:00
Tor Lillqvist
3c39657ae5 Add debug output and simplify use of QtLoader
Also, don't load online.js. It seems that it will be loaded into the
JS "web worker" for each thread automatically by
online.worker.js. (But hmm, what loads online.worker.js? I am probably
completely confused here. Probably getting rid of Qt things
(qtloader.js) and using only JS that Emscripten produces (modified if
necessary) will make things simpler to understand.)

Signed-off-by: Tor Lillqvist <tml@collabora.com>
Change-Id: I050a20a553b7c0f6ebe9db0e7cb9cab2f9829f9e
2023-01-16 18:43:21 +02:00
Tor Lillqvist
7978e74434 Try to send the HULLO message only after the WASM runting has been initialised
Signed-off-by: Tor Lillqvist <tml@collabora.com>
Change-Id: Ida3e01482db0e18d17e8e6db0c75667c39adae59
2023-01-16 18:43:21 +02:00
Tor Lillqvist
2c5522aebe Add some debugging output
Signed-off-by: Tor Lillqvist <tml@collabora.com>
Change-Id: I2db4a002dfafd5db15362a3ab8d8df33b1153138
2023-01-16 18:43:21 +02:00
Tor Lillqvist
cd592a4ec2 We use String.locale unconditionally so make sure it always gets set
Even if the URL did not have a query parameter called "lang".

And yes, we should stop using String.locale for that, and instead add
our locale property to window.app, which seems to be the place for our
code to store various global state. Using String.locale is hugely
confusing. I naturally thought it was some built-in JavaScript thing
and was very confused when it was undefined and I couldn't find any
documentation on it.

Signed-off-by: Tor Lillqvist <tml@collabora.com>
Change-Id: I549d3dac1be0991f87f1ca3aa3f147b081e898b1
2023-01-16 18:43:21 +02:00