Commit graph

287 commits

Author SHA1 Message Date
Moritz Schubotz (physikerwelt) fa9a689be6
Explain the significance of the img.tex css element
* PNG images are no longer displayed as of
  I595926027433182cc0396570bc3f1ce0cd2cafb3
* There is only one use of the img.tex css
  class, in combination with the source
  rendering mode.

Bug: T311620
Bug: T348938
Change-Id: Ife1f069546d5132a112643b68de2c17115981053
2023-10-29 15:21:19 +01:00
Ed Sanders c0f9269512 Use white-space:break-spaces where appropriate
Bug: T348006
Change-Id: Iac89f5c70ed6717a8ec662e85e68d9ccf9b7e5ad
2023-10-03 16:54:18 +01:00
Ed Sanders e1f5f5487f build: Update linters
Change-Id: I19e2482fa377342b15733f5ef0bebe18e3238cef
2023-09-27 16:07:55 +01:00
Ed Sanders 149e5db0a0 Fix ContextItem documentation
* Be more specific about the type of context which a
  context item belongs to.
* Make grammar clearer.

Change-Id: I6f7abc777c378be2f1ac3f8db678363664d46ccd
2023-07-10 14:33:51 +01:00
Umherirrender 4e08e000e0 build: Updating npm dependencies
* eslint-config-wikimedia: 0.22.1 → 0.24.0

Resolve newly detected error:
* mediawiki/no-nodelist-unsupported-methods

Change-Id: If43479e88a3d39f507541f3f6b53f23004bd0e1e
2023-03-29 21:24:34 +00:00
Umherirrender 83a00d41f8 build: Remove unneeded inline stylelint-disable-next-line
modules/ve-math/ve.ce.MWLatexNode.css
 6:59  ✖  Needless disable for "media-feature-name-no-vendor-prefix"
--report-needless-disables

Change-Id: Icb4738d7435cb7cc744a3d82b5e8130111f9b567
2023-03-22 21:57:19 +01:00
Moritz Schubotz (physikerwelt) c560ff0cd8
Remove MathPlayer
* MathPlayer stopped working around IE8

Bug: T298971
Change-Id: I759a5dc61eaf27a99d952366cf9c4380748f8e82
2023-03-15 10:20:13 +01:00
AndreG-P 95c5757ee5 Enable popups for annotated math formulae
Enable popup extension for annotated math expressions. The popup shows a short summary of the formula and is generated via the Popup API introduced with I65fcbf25ac5818f6c649daf494c719921247e8f5. It is a follow up of Iefe98c1f0422dbf034e385b1a41a859d030a2cf4.

Bug: T208758
Change-Id: I8c45b7e441083c240bbf2e0217ec219df7dcc351
2022-12-06 06:07:22 +00:00
jenkins-bot 4d3cb0dc69 Merge "Simplify VE data modules using 'packageFiles'" 2022-11-29 01:14:00 +00:00
Bartosz Dziewoński 9207931f53 Simplify VE data modules using 'packageFiles'
We can now serve the JSON data almost directly (although, curiously,
we need a main file in the module that is JavaScript, not JSON),
and without using global state in the JS code.

Change-Id: I203b3e396b28f4b4ef49c3c0918a4025082308c4
2022-11-22 18:43:04 +01:00
Moritz Schubotz (physikerwelt) 110656335f Remove PNG rendering mode
Removes functionality to
* select PNG rendering mode
* automated fallback to PNG images for SVG rendering
* PNG mode related class and tests

However, PNG images received from mathoid / restbase are still stored.

Bug: T311620
Change-Id: I595926027433182cc0396570bc3f1ce0cd2cafb3
2022-11-21 18:57:27 +00:00
jenkins-bot 4fde31757c Merge "Improve use of gadgets for LatexDialog" 2022-09-30 17:29:05 +00:00
Fwolz 409cc54217 Improve use of gadgets for LatexDialog
Add a mw.hook to enable gadget for T316816 reacting on opening the LatexDialog and
assign classes to ooui components to enable browser-JS manipulation.

Change-Id: Ib004c3e8b0926a0bd5febfaf4910bb4d9ed6bc58
2022-09-30 18:47:23 +02:00
Ed Sanders fe5b350c89 Add \neg to "Logic" section
Bug: T317065
Change-Id: I261768fdddebcf0dd8776b69286edd1b541f0c5b
2022-09-07 00:40:01 +01:00
Moritz Schubotz (physikerwelt) 480d241f97
Make dependency to Wikibase client config optional
The MathEntitySelector gets its config from wbRepo which caused a hard
dependency on the Wikibase client.
If the Wikibase client config is not available a default value (wikidata)
is used to determine the URL of the foreign repo.
As the dropdown will never do write operations, we restrict the repo
access to anonymous read only.

Bug: T313143
Change-Id: Iba33dfd32a78f4ad7c2e99a1f56218458ab884b4
2022-07-25 09:51:47 +02:00
Physikerwelt 63e19a8c69 Revert "Revert "Add wbEntitySelector widget to edit qid in VE""
This reverts commit 2dc6bcac48.

Reason for revert: Re-enable functionality with fix

Bug: T313143 
Change-Id: I7536ae187872b9c0a6abab18861499290ad621e0
2022-07-23 07:57:54 +00:00
Reedy 2dc6bcac48 Revert "Add wbEntitySelector widget to edit qid in VE"
This reverts commit 422be143f6.

Reason for revert: Caused hard dependancy on Wikibase

Bug: T313143
Change-Id: Ia6f551307f0fbaa2a3fc5747ed180e588c60b02f
2022-07-16 17:40:09 +00:00
Fwolz 422be143f6 Add wbEntitySelector widget to edit qid in VE
Add the MathWbEntitySelector field to provide a dropdown menu which retrieves
the expression or qid from wikidata instead of the simple  TextInputWidget to
edit the qid in the Visual Editor.

Change-Id: I0a6fddd2c2978c9c4f195d668458b8d2ed478d98
2022-07-06 12:13:28 +00:00
Fwolz 74bd7c4730 Add text field in VE to change QID
Makes it possilbe to change the QID of a formula in the visual editor
quick editor and in the dialog editor inside the options panel.

Change-Id: Ie4cb651939a59bf4446cd3e5327522d100eac5bf
2022-06-01 12:27:43 +02:00
Ed Sanders 94d6b81d2f tests: Use ve.test.utils.newMwEnvironment()
Depends-On: Ib20c1f5277c5d5a99f5117c82b7cbdeab75d3279
Change-Id: Id551b4c8ae3a857f1318d4b7f5e5518c889bc9d2
2022-03-04 13:52:59 +00:00
Ed Sanders 73cbed9cd1 eslint: Lint Gruntile.js using server rules
Change-Id: I87efd77d71d8787300539813da04d8679dca764b
2022-02-07 16:35:42 +00:00
Ed Sanders a5e976baee build: Update eslint-config-wikimedia to 0.21.0
Change-Id: Ia97b44767e31fe1c2d075e3627c7f7bea0845751
2021-11-15 16:27:57 +00:00
Ed Sanders 1091cf6458 Move var declarations inline
Change-Id: Ib550a7443daea339d3e40f3ff1d9c0febf5159f8
2021-10-05 17:04:47 +01:00
Volker E 0bd9089692 styles: Remove obsolete -moz- vendor prefixed rules
Bug: T278670
Change-Id: If785ee709db742de7790fc4febe9fe89451c8924
2021-09-14 04:22:48 -07:00
physikerwelt (Moritz Schubotz) be9d701825
Add JS unit test
Add a first test to check that the testing framework is functional.

Bug: T288074
Change-Id: If4a6d14f14d7b964db31781b3caf23eb383c06c1
2021-08-05 09:54:10 +02:00
libraryupgrader d0c06ea19f build: Updating eslint-config-wikimedia to 0.20.0
Change-Id: I2d9f2665a2ce82abbe03c61c284c14d1d57bdb41
2021-04-17 02:59:17 +00:00
libraryupgrader 79a7324eed build: Updating dependencies
composer:
* mediawiki/mediawiki-codesniffer: 34.0.0 → 35.0.0
  The following sniffs are failing and were disabled:
  * MediaWiki.Commenting.PropertyDocumentation.MissingDocumentationPrivate
  * MediaWiki.Commenting.PropertyDocumentation.MissingDocumentationProtected
  * MediaWiki.Commenting.PropertyDocumentation.MissingDocumentationPublic
  * MediaWiki.Commenting.PropertyDocumentation.WrongStyle

* mediawiki/minus-x: 1.1.0 → 1.1.1

npm:
* eslint-config-wikimedia: 0.17.0 → 0.18.1
  The following rules are failing and were disabled:
  * no-useless-escape

Additional changes:
* Added the "composer phan" command to conveniently run phan.

Change-Id: I1c641a4945f94337ca22763920601400ee9ab691
2021-02-06 12:19:19 +00:00
Moritz Schubotz (physikerwelt) ba19b3e1cd Implement wikidata entity selector
The current wikidata entity selector requires WikibaseRepo to be enabled on the client wiki, which is only the case for very small installations.

We implement our custom entity selector that
* displays the item label and
* uses the description as tool-tip.

The implementation was inspired by
mw.widgets.TitleInputWidget.

Bug: T229939
Change-Id: I35d6cc317cf2984d9de6e062f79030f5c31c0811
2020-12-19 09:11:40 +01:00
Umherirrender f2cb640687 Avoid shadowed variables in javascript
Change-Id: I4d7148c46c04447a7aba5ce96379ce9038be5752
2020-09-19 18:19:08 +00:00
Ed Sanders 74561b1db6 Fix script to exclude duplicate classes and regenerate math symbols
Change-Id: Iac62e385f54f3f75812c31ab4792d88cb5f31331
2020-06-16 16:01:27 +01:00
Ed Sanders e489beac5b build: Update eslint-config-wikimedia to 0.16.1
Change-Id: I9c2de727e1a4c7657ccca4dd22a175bfad06a852
2020-06-16 15:59:33 +01:00
jenkins-bot a406f9eae3 Merge "Add special page and API endpoint that show information from math Wikibase items" 2019-11-15 12:45:34 +00:00
Moritz Schubotz (physikerwelt) 4a7bc3ee31 Add special page and API endpoint that show information from math Wikibase items
Add a special page and an API endpoint to fetch data from Wikibase
items with a given qID. The special page summarizes information from
Wikibase. The API endpoint allows to request the information
directly. Both, the API endpoint and the special page, fetch the data
from a new helper class for consistency.

Bug: T208758
Bug: T229939
Change-Id: Idd22057a88312bf1a1cb5546d0a6edca5678d80d
2019-11-14 23:42:35 +09:00
Ed Sanders e9bd09f2b3 build: Update linters
Change-Id: I9fc31886e09a0dc0a77449907054136a61eda248
2019-11-01 16:33:18 -07:00
Ed Sanders 15352b3751 build: Update eslint-config-wikimedia
Change-Id: I0d650a842da003693275ecee565cf923dc2605d6
2019-10-04 15:38:36 +01:00
Ed Sanders 085ee7dcec build: Update linters
Change-Id: I0d6b323864a0e24f72ec6a823611927ea66ce025
2019-09-17 14:46:05 +01:00
Volker E 09b8a0830c Use renamed OOUI icon 'labFlask'
Change-Id: I1c6ffd18f97e6a0e95f9e8e88842743caf887fe8
2019-09-11 13:36:37 -07:00
Ed Sanders 3927e65c61 makeSvgsAndCss.js: Add more logging and an '--all' flag
Change-Id: Iaa00e52e04800d0708f8dfc715b8cf6228e7f469
2019-08-30 20:17:11 +01:00
Ed Sanders 44b88c6e77 Re-render MWChemSymbols.css
Bug: T166936
Change-Id: Ie711e3715e6a8aef7e00e7f120d2d39b9511d0fc
2019-08-30 19:35:11 +01:00
Ed Sanders 1ce95efb54 Show latex source in context items
Change-Id: I32af1c13c31dc0f94434daa4a4db8c94a7033582
2019-07-31 22:55:03 +01:00
Ed Sanders ba39eb0303 Use setReadOnly when possible
Change-Id: I410967531229ba31c985488fc73ec7e315ecfad6
2019-04-16 12:04:58 +01:00
James D. Forrester 0eac1464c4 build: Upgrade eslint-config-wikimedia from 0.10.0 to 0.11.0
Change-Id: Ia1dc32374abf4756b2d2333aa087a28b6b282ebd
2019-04-03 15:29:36 -07:00
Ed Sanders f22a61c000 Add support for read-only mode
Change-Id: Ibf8ab22ead2ceb80e39dcab50f4fc6c1ee0ae1f0
Depends-On: Iedd1bd9ce17750ad8528c1a053293c4a7321c5de
2019-02-19 14:58:41 +00:00
Volker E c131018ad1 Replace extension icons with standard OOUI icons
Replacing outdated 'chem' and 'math*' icons with standardized
OOUI icons from 'editing-advanced' pack.

Bug: T195480
Change-Id: Iefc02ca5c2f0c310fdc83fe26a17f7fcba5195b8
2019-01-23 23:48:02 +00:00
Ed Sanders 94335db392 build: Update eslint-config-wikimedia to 0.10.0
Change-Id: Iec4ea5f8e74ad6f73232b01bdca3b19d93e36dfb
2019-01-08 23:17:15 +00:00
Ed Sanders 5f7f535c28 Update eslint-config-wikimedia to 0.9.0
Change-Id: I4c7dcb1b3cd3d03e3ea3d1e17bfcf63f3b553e50
2018-11-30 21:08:28 +00:00
jenkins-bot 9962f9d16c Merge "VE dialog: Reset scroll offsets on teardown" 2018-11-15 23:51:40 +00:00
Ed Sanders 3986634d8a Remove obsolete aliases from closures
Bug: T208951
Change-Id: Ia4b1a813c9eb8c24db42ded937d40feea539f9c5
2018-11-12 17:08:20 +00:00
Ed Sanders c4e0340e46 VE dialog: Reset scroll offsets on teardown
Change-Id: Ieb252188948249c992a7e43117781f5fdf159d5b
2018-11-12 16:15:00 +00:00
James D. Forrester 428f5a847b Drop support for MediaWiki core's removed "2006 wikitext editor"
Change-Id: I59bad8faee3f0f998344f985eb675087533d3d8f
2018-11-06 17:19:43 -08:00