Commit graph

3051 commits

Author SHA1 Message Date
physikerwelt 6d5ddff353
Remove unused environment
Change-Id: I8c94d04c58356afac901de5ed207f110f1b753f7
2024-11-21 17:26:14 +01:00
physikerwelt 62506236ec
WIP add \ when needed
Change-Id: I94887f6ccb45072180a318776ae96aead8658a18
2024-11-21 08:01:26 +01:00
jenkins-bot 44243ad466 Merge "Overwrite spacing for divide" 2024-11-14 09:13:21 +00:00
jenkins-bot fb4e72d64c Merge "Treat ! as operator" 2024-11-14 09:13:19 +00:00
jenkins-bot 0bfd22b57b Merge "Don't stretch delimiters and operators when used as literals" 2024-11-14 09:11:45 +00:00
Translation updater bot 8cded7d7fa
Localisation updates from https://translatewiki.net.
Change-Id: I476d81c4cd7a0c35ab17465612bc681e46550dc2
2024-11-11 08:23:15 +01:00
jenkins-bot 5fbcff7819 Merge "Treat colon as operator" 2024-11-10 21:43:02 +00:00
physikerwelt 758f9c987a
Overwrite spacing for divide
This overwrite should be removed once this is the
default in all browsers.

Bug: T375337
Change-Id: I5ab133f0368ed6eef94b0a87281bb9129fca406c
2024-11-10 16:45:23 +01:00
physikerwelt 5cde747b49
Treat ! as operator
Bug: T375935
Change-Id: Iec8e69d28fa3cc32b2c2e87f81707b9fd7af5576
2024-11-09 08:05:22 +01:00
physikerwelt aee95695b8
Don't stretch delimiters and operators when used as literals
* Adjust tests

Bug: T375959
Change-Id: I02de8244b73c4b98a1467011a0035df059917c13
2024-11-09 08:04:24 +01:00
physikerwelt fcb667f733
Treat colon as operator
Bug: T375974
Change-Id: Ia553e77a04edfee12fa0f236375d67a88eefee67
2024-11-09 06:33:07 +01:00
jenkins-bot a7f8306d18 Merge "Remove menclose in cancel rendering" 2024-11-08 07:27:47 +00:00
physikerwelt cc0a214f56
Remove menclose in cancel rendering
Chrome and similar browsers do not support the
menclose tag. This change introduces a css polyfill
suggested in

https://github.com/w3c/mathml-core/issues/245#issuecomment-2410676518

but keeps the mencose rendering since FF does not
support the polyfill

https://bugzilla.mozilla.org/show_bug.cgi?id=1929800

Bug: T376829
Change-Id: I860e2f2f9bf9eef8eeba35b0999ec50175fdfc4b
2024-11-08 07:58:08 +01:00
jenkins-bot f60ea98236 Merge "Treat \operatorname as a valid operator for limits" 2024-11-08 05:19:01 +00:00
jenkins-bot 0e0d5ff1f7 Merge "Ignore misplaced limits commands" 2024-11-08 05:06:17 +00:00
physikerwelt 775fec5450
Treat \operatorname as a valid operator for limits
* Extend logic for checking for valid operators
* Add tests

Bug: T365170
Change-Id: I4d3762e3258c78ac5fae8b923f12aabcd2175f3d
2024-11-06 23:04:13 +01:00
physikerwelt b058d88bf9 Ignore misplaced limits commands
Instead of rendering \limits or \nolimits when those
commands are misplaced the commands are ignored.

TeX does it the same way, but issues a warning in addition.
Issuing the warning will be taken care of in a follow-up commit.

Bug: T365170
Change-Id: Ic1c28be2a5669183c3dd5d15577a35a1b5a76971
2024-11-06 20:21:29 +00:00
Translation updater bot 4ce41fa717
Localisation updates from https://translatewiki.net.
Change-Id: I56f74ad53b729f7e3657104eb7de7ebd59915a14
2024-11-06 08:23:12 +01:00
physikerwelt 18df3d31a1
Add npm fix script
Change-Id: Iebd8d41d36a3a05d6ff9e07248716ce1ad19668d
2024-11-05 15:12:59 +01:00
Translation updater bot 28648ef9c9
Localisation updates from https://translatewiki.net.
Change-Id: Ibbb4c60dafbb7f2134de1a5ddb7265fe86ff89aa
2024-11-05 08:33:06 +01:00
jenkins-bot 794c5b256b Merge "ext.math.popup: Add mediawiki.user in dependencies" 2024-11-04 00:03:36 +00:00
Ammarpad dab41da0b1 ext.math.popup: Add mediawiki.user in dependencies
Dependency introduced in I46e7641

Bug: T378877
Change-Id: I27f28a7adebba16370ae7010a8dbf3d9e3c5c849
2024-11-03 20:47:03 +01:00
libraryupgrader 217e4c229a build: Updating mediawiki/mediawiki-codesniffer to 45.0.0
Change-Id: Iabfae5b9a80bf2b1d255f17b08085610e278dd66
2024-11-02 19:42:41 +00:00
Translation updater bot 9d31cca568
Localisation updates from https://translatewiki.net.
Change-Id: I1e8ab69cb50f2f4da5c3973cacf157d08388a1fb
2024-10-31 08:15:59 +01:00
physikerwelt 63b47f21ef
Add mathfraktur rendering for chrome
Chrome and similar browsers do not support the
mathvariant attribute that can be used to change
math fonts conveniently. Like for mathcal there is
a table that can be used to translate from latin
to mathfraktur chars.

Bug: T378433
Change-Id: Id8c3e121ed104ba3f08329b4151a7e3bec699754
2024-10-29 11:30:51 +01:00
jenkins-bot cc5c21dd54 Merge "Use cell based table rendering" 2024-10-29 05:22:13 +00:00
physikerwelt dab5364b31
Use cell based table rendering
* Add hline search in matrix construction:
** This avoids a second scan later for the cost of some
   memory overhead
* Parse | in array column specification
* Add CSS based table lines as done by TMML, cf.
https://github.com/w3c/mathml-core/issues/245

Bug: T377167
Change-Id: I6e29b47b1731638ea9b06de3006ce2834e4f0c68
2024-10-29 05:48:34 +01:00
physikerwelt 8fa40914e9 Add more operators that render limit below
* Extend the list of operators that use munder instead
  of msub.
* Use rendering of main operator, as some artificial
  spaces might be added in the operator representation

Bug: T375907
Change-Id: I45e96257411bd7641ad6cc32aaac4c94bfcfa8a3
2024-10-28 08:12:30 +00:00
Translation updater bot 7acc46ef46
Localisation updates from https://translatewiki.net.
Change-Id: If8192290968bc630a5f1da8142297c52c8807daa
2024-10-28 08:23:21 +01:00
Umherirrender cf6271fa06 Replace isset() with null check
isset() should only be used to suppress errors, not for null check.
When the variable is always defined, there is no need to use isset.
Found by a new phan plugin (2efea9f989)
https://www.mediawiki.org/wiki/Manual:Coding_conventions/PHP#isset

Change-Id: I4e797c539d8d7868bfac63fcac6b2f78463f6475
2024-10-27 13:43:45 +01:00
Andre Klapper 5c6bc704a2 Use explicit nullable type on parameter arguments (for PHP 8.4)
Implicitly marking parameter $... as nullable is deprecated in PHP
8.4. The explicit nullable type must be used instead.

Bug: T376276
Change-Id: Idcd0b50c1c01a33c4cabeed3e31828f77c3f6443
2024-10-26 15:15:30 +02:00
Translation updater bot 47edd9b21d
Localisation updates from https://translatewiki.net.
Change-Id: Id88d7d02ecbbcc7ec728e9fcae31e7856a506c30
2024-10-25 09:50:33 +02:00
jenkins-bot 6f597a863a Merge "selenium: Replace Node.js Assert library with WebdriverIO Expect library" 2024-10-24 10:17:32 +00:00
Umherirrender 7038c68f13 Use namespaced classes
Changes to the use statements done automatically via script
Addition of missing use statement done manually

Change-Id: I4cf7903b9700e6366bdf349f99ffd4a04da0c087
2024-10-20 09:27:34 +02:00
Translation updater bot cecbd594d1
Localisation updates from https://translatewiki.net.
Change-Id: I034c2da50b5282ae9038054b3bda5c0921c1baf8
2024-10-18 09:25:18 +02:00
jenkins-bot 9c9c20e09e Merge "Use munder instead of msub for large operators" 2024-10-16 12:38:21 +00:00
jenkins-bot 188d13ca64 Merge "Squash literals in operatornames" 2024-10-16 12:18:09 +00:00
Željko Filipin 97126ba46f selenium: Replace Node.js Assert library with WebdriverIO Expect library
Assertions from Expect library are more readable that assertions from Assert library.

Bug: T325740
Change-Id: I62ccf128e21eb49cbdc97546c643887105bf2c64
2024-10-16 14:11:24 +02:00
jenkins-bot 3c4141423e Merge "Add missing apply after operatorname" 2024-10-16 11:32:32 +00:00
jenkins-bot b236403991 Merge "Use the same formatting for align as MathJax" 2024-10-16 08:56:42 +00:00
physikerwelt 87632766e0 Squash literals in operatornames
Chains of single letter mi elements are rendered with no
space but one mi element with multiple letters gets
space. For example, the operator log will be translated
to <mi>log</mi> rather than <mi>l</mi><mi>o</mi><mi>g</mi>
as done by wikitexvc.

* Squash literals into single element, iff they don't
contain commands

Following the implementation of the literal rendering
it seems that all literals with special behaviour have
a command.

Bug: T375861
Change-Id: I97adf5f5132180503cbeb59d32fdb8d45b08aaa7
2024-10-14 16:02:17 +00:00
physikerwelt 9a27d92c09 Add missing apply after operatorname
* Reapply the logic of \log rendering to \operatorname
* Deduplicate applyFunctionDetection

Note this still does not solve the rendering problem for
operator names with more than one letter as these generate
mrow elements with single letters. Those are not rendered
with space in FF.

Bug: T375861
Change-Id: I913d865b49d5894a63c8b9d244768f9bb1df4e28
2024-10-14 16:01:56 +00:00
physikerwelt 87f0315812
Use the same formatting for align as MathJax
* Copy the default mtable attributes from MathJax
* Adjust the test

Bug: T348791
Bug: T375317
Change-Id: I274577e320056c1ac3a1f74cbc61941184afd61e
2024-10-14 17:59:19 +02:00
physikerwelt ec44827976
Use munder instead of msub for large operators
* Add new class to identify what a (large) operator is
* Add some IDE hints about what methods exist in texutil
* Add tests for operators in display and block style

Bug: T375907
Change-Id: If734f194cd8fa30efaf6d8c8d89f85e3e1c96276
2024-10-13 21:13:56 +02:00
physikerwelt 602043027d
Implement basic column info parsing
* For each letter l c or r that is found in the
  column spec the respective mtable alignment
  information is passed
* if the align information is given externally
  the info will still be ignored

Bug: T376838
Change-Id: I3113f933502df2109b066959e4d001736dbae6e6
2024-10-13 00:55:57 +02:00
Translation updater bot 9321d6ffc7
Localisation updates from https://translatewiki.net.
Change-Id: Ie8ac1996868b8d94edf063686e0a3fb8c6cdd5e7
2024-10-08 09:43:50 +02:00
jenkins-bot 65f3e1bc95 Merge "Add \| to list of special operators" 2024-10-07 12:09:14 +00:00
jenkins-bot 73e1f3d229 Merge "Change appearance for \mathcal A in MathJax" 2024-10-07 12:09:12 +00:00
jenkins-bot 3f0692a9b9 Merge "Only use Munderover for displaystyle formulae" 2024-10-07 10:29:14 +00:00
physikerwelt fec6d16b14 Change appearance for \mathcal A in MathJax
Change the appearance of \mathcal A and similar letters
in MathJax rendering to better match the MathML rendering
as implemented by browsers.

Code generously developed by Davide P. Cervone.

Bug: T375932
Change-Id: Ieee933b9863c2747559769065da6b5369d304f53
2024-10-07 10:28:52 +00:00