Commit graph

3592 commits

Author SHA1 Message Date
Ed Sanders 3966573f02 build: Update ESLint to 0.26.0 and autofix
Change-Id: Ia5e15684c1c3dcd69985445a09fc4e4910368b5b
2023-11-28 11:18:09 +00:00
Ed Sanders 60f9dc2191 Fix width of preview in Vector 2022
Change-Id: Iea3109239a8d6519e7f93c8447ccfd40f1dc3aab
2023-11-27 16:29:31 +00:00
jenkins-bot 3c609d13c5 Merge "Convert MWSaveDialog.css to less" 2023-11-17 13:41:27 +00:00
Ed Sanders 7545b46d16 Convert MWSaveDialog.css to less
Change-Id: I13d23492bcd7264076df0679a6405d2e5969919e
2023-11-17 13:12:09 +00:00
Nardog 9b9f2c50b0 Recognize DEFAULTSORT again
Since Parsoid now treats DEFAULTSORT like any other template, we have to
scan mw:Transclusion spans.

Bug: T337398
Change-Id: Icba92fc14c1c56ec4711ba49407e8be368d57842
2023-11-09 21:26:20 +00:00
Ed Sanders 7a3120d9d5 Remove unused CSS classes
Unused since I5839ba62fe4.

Change-Id: I927e64f14f672b9fca6c7e8c6806a38cea07382a
2023-11-08 19:25:32 +00:00
Bartosz Dziewoński 5667832c1b Attach content to teleport target instead of <body>, remove Vector hacks
In MediaWiki, OO.ui.getTeleportTarget() is overridden to return
a different element (itself attached to body), which is supposed
to be styled appropriately by skins (e.g. z-index above any
floating header, font-size same as body text, etc.).

As a result, we no longer need to do weird things with the
'vector-body' class to achieve correct font size on Vector,
and we can remove some font-size overrides for Vector and MonoBook.

Bug: T348288
Bug: T339058
Change-Id: I6329b3023573b3dcfc8f471c4693be9bb1e9e430
2023-11-06 14:29:12 +00:00
Ed Sanders 3bbcb66e9a Wikitext table tool: Use different message for caption placeholder
The wikitext table tool is re-using messages meant for other
things anyway, so might as well use a message that is still
in use elsewhere, as opposed to one for a tool that was removed
7 years ago (in Ife3f3505b845d).

Change-Id: I305f5f5a67e0340f89160e6654ad86f81609f9ab
2023-11-03 15:48:55 +00:00
Ed Sanders 284fb20da4 Restore help toolbar title
Was lost when we converted it from a PopupTool
in I81d217bc1ab9.

Also visualeditor-help-title is unused since that commit,
and remove debugging code.

Change-Id: Ic1d40bac8ef76fbb6f009dd8cecec8dc74c1aa4b
2023-11-03 15:38:40 +00:00
jenkins-bot a7b7f659c7 Merge "Roundtrip media tag name in galleries" 2023-11-02 21:40:12 +00:00
jenkins-bot 979cc39472 Merge "Set alt in data-mw for non-img media" 2023-11-02 21:39:02 +00:00
Ed Sanders 09d60e784b Fix remaining uses of 'parent'->'super'
Bug: T120821
Change-Id: Id6ccb82d6d6027265d1595dbf11c1c4abeabc392
2023-11-02 16:42:31 +00:00
jenkins-bot a87cc5cb9f Merge "styles: Use 'mediawiki.skin.variables.less', remove WikimediaUI Base ref" 2023-10-30 18:07:49 +00:00
Volker E ba0ca0f0e3 styles: Use 'mediawiki.skin.variables.less', remove WikimediaUI Base ref
Using 'mediawiki.skin.variables.less' with Codex tokens now that
it's available. Also removing a comment that's OOUI variable specific.

Bug: T334934
Change-Id: Id697baa9537013c9e240dbfaa9ead1eb15280133
2023-10-26 17:18:54 -07:00
jenkins-bot e5c81199c9 Merge "Template dialog: Use wrapping/expanding input for "line" inputs" 2023-10-26 16:11:45 +00:00
jenkins-bot aac7f99742 Merge "ve.ui.MWEditSummaryWidget: Use built-in 'allowLinebreaks' option" 2023-10-26 15:55:41 +00:00
Ed Sanders 1fcf167028 Template dialog: Use wrapping/expanding input for "line" inputs
Bug: T348482
Change-Id: I5cbbd84723c042dee176be8d77a7beec7d86e226
2023-10-26 09:16:24 -05:00
Ed Sanders c6f732914f Template dialog: Remove height override of collapsed LazyMultilineTextInputWidget
The default rendering is already correct unless there are more
than 2 lines of text present.

Change-Id: I5be936d75f81dcbbb58793d93796240540555124
2023-10-26 14:22:10 +01:00
jenkins-bot 60b7420e3f Merge "Media Dialog: make the alt field wrap and autosize for longer values" 2023-10-26 12:48:31 +00:00
David Lynch e2a7592bab Media Dialog: make the alt field wrap and autosize for longer values
Bug: T349319
Change-Id: I60e0a9c85f24132651007b436f146be801e77ebb
2023-10-26 12:20:05 +00:00
Arlo Breault f909f87b02 Roundtrip media tag name in galleries
This should have been part of
If5dc6b794dacd6973d3b2093e6b385591b91d539

Bug: T348703
Change-Id: I85f83d8b336ab4d6799bbe8007ef0441570a84ca
2023-10-25 13:29:19 -04:00
Arlo Breault 2497a5254e Set alt in data-mw for non-img media
Follow up to I02ea8421e468635ba6297bb5cda488a5a79c9a1d the depends on
I7a5c24f6ffc15ff0455adf5b025b695ee71501b6 in Parsoid.

Note that the mediaTag isn't currently being passed around for gallery
image nodes so, for example, a <video> becomes an <img> as is.  But,
that's independent of this patch, and a follow up will fix it.
Noted in T348703#9278332

Bug: T348703
Bug: T214603
Change-Id: I5f7d3dfe0a41fac1568c97dccc41209c14e741d0
2023-10-25 13:23:47 -04:00
Bartosz Dziewoński 0167346cbb ve.ui.MWEditSummaryWidget: Use built-in 'allowLinebreaks' option
New in OOUI v0.48.2.

Change-Id: I28dfa2405167ee4b9d9cd2fd3bb3e15498247ac6
2023-10-25 08:26:59 -04:00
Volker E fa3f2781b7 styles: Replace WikimediaUI Base vars with equivalent skin variables
Replacing several values with MediaWiki skin variables featuring new
Codex design tokens, available since >= v1.41.0.

The values are 1:1 visual replacements in the default Codex
'WikimediaUI' theme, a continuation of the base vars, and the default
for Vector and MinervaNeue skins.

Also replacing
- other static color values with variables
- and outline value as the Codex default brings an accessibility
  advancement for free

Bug: T334934
Change-Id: I512427803cffce1c16879015c45cf1e35fe17480
2023-10-25 09:30:56 +02:00
thiemowmde c581f0e3bc Favor jQuery's .toggleClass() to reduce code duplication
Change-Id: Ic616ffbfac410849413e8fad6dde260514884efb
2023-09-25 18:59:10 +00:00
jenkins-bot a2d601b4ab Merge "Add mw-no-invert class to thumbnails" 2023-09-11 17:19:17 +00:00
Ed Sanders 1053204077 Add mw-no-invert class to thumbnails
Bug: T345281
Change-Id: I49d9b65fefd4fae15715d2a10db83b90c7021027
2023-08-30 19:02:52 +01:00
David Lynch 481dd52067 Track when edit notices are shown
VisualEditorFeatureUse as feature: notices, action: show.

This doesn't distinguish between the automatic on-load show and manually
showing them from the toolbar.

Bug: T344465
Change-Id: I5a0d7e87592c286afe51e02ae8436f7d2ce71021
2023-08-24 14:03:42 -05:00
Ed Sanders 2b4dab6703 build: Update stylelint-config-wikimedia
Change-Id: I4e56a07c0cd478fb2ea1908c79f584ea3e4d788e
2023-08-21 16:06:40 +01:00
Ed Sanders 241d3da05d Remove extra margins from visual diff in Minerva
Bug: T344181
Change-Id: I5a2a9413ee5125ca7dc416ce3e8b75060dc96b83
2023-08-14 19:13:50 +01:00
Ed Sanders 916b7beb22 Convert WikitextPasteContextItem to PersistentContextItem
Depends-On: Id2900c2d2c692b611e611b7eee6cacb74a737a8c
Change-Id: Ic539a41e8623c4ed12e4fa0e24db826ca967ee5a
2023-08-11 12:54:38 +01:00
jenkins-bot 8be133fe66 Merge "Reduce code duplication in ve.ui.MWGalleryDialog" 2023-08-08 18:55:30 +00:00
jenkins-bot 16623ac116 Merge "Simplify code for showing "Loading" message in template context" 2023-07-31 10:16:40 +00:00
James D. Forrester 325ca8a40a build: Upgrade stylelint-config-wikimedia from 0.15.0 to 0.16.0
Change-Id: I993074948832a50997255bd413192c8fdeaf9edb
2023-07-14 13:02:49 -04:00
Ed Sanders 3d8315f4c3 Simplify code for showing "Loading" message in template context
Instead of passing a "teardown callback" to a specific dialog,
run the command as usual and clear the loading message once
the dialog has successfully opened.

Change-Id: Icacabb298f1a0d7a587ab8b992759b04ff59c5c3
2023-07-12 11:04:59 +01:00
jenkins-bot 82f72cfeda Merge "Merge mobile and desktop save buttons" 2023-07-11 21:34:17 +00:00
jenkins-bot 067cbd3438 Merge "Fix ContextItem documentation" 2023-07-11 21:32:59 +00:00
Ed Sanders 4f90ce2594 Merge mobile and desktop save buttons
Use toolbar groups where appropriate.

Change-Id: If4e0d157f04ba741ed4cf891e4183fe351d537b8
2023-07-10 17:06:58 +01:00
Ed Sanders 2a1076e295 Fix ContextItem documentation
* Be more specific about the type of context which a
  context item belongs to.
* Make grammar clearer.

Change-Id: Ic480411cead80a1651c61ce9841dfbdc24a7b915
2023-07-10 14:32:12 +01:00
Ed Sanders 0f33f7193f Drop visualeditor-beta-warning from help menu
Bug: T341350
Change-Id: I69b886e7681281057c92ddb4175de2998512f0ed
2023-07-07 15:54:15 +01:00
thiemowmde 60409599f5 Reduce code duplication in ve.ui.MWGalleryDialog
Change-Id: I7e3f831b9abd8834cc55460e579261cbf9d5fcff
2023-07-07 10:25:55 +02:00
Ed Sanders ea03287908 Convert MWPopupTool into MWHelpListToolGroup
The popup contains three buttons, one of which already exists
in core as a tool. By converting them all to tools we can reduce
some duplication, and better integrate with other features
that use the tool factory, such as HelpCompletionAction.

Bug: T339153
Change-Id: I81d217bc1ab9a1a6a9bf7c7ad588c2a3216b10db
2023-07-01 11:10:53 +01:00
Ed Sanders d857750e12 Make better use of toolbar groups
Bug: T340751
Depends-On: Ie7ca24cbcd95baa082b3b1cb907354f6da21d93c
Change-Id: Ibcc81c90bc9ba6c5fd012c512daf861973b03b2e
2023-06-29 16:58:38 +00:00
jenkins-bot 1f76a0e8f7 Merge "Make "add undocumented parameter" hotkey ctrl+shift+d work much better" 2023-06-21 19:52:11 +00:00
thiemowmde a6a61983c1 Make "add undocumented parameter" hotkey ctrl+shift+d work much better
* Make it always work when there is only a single template anyway, no
  matter if the template is selected or not.
* Auto-expand the widget and focus the input field when it receives
  focus. The only way it can receive focus is via the hotkey. It can
  not be selected from the sidebar.

Bug: T338108
Change-Id: I567a0b99a8ad2e837993437e47f07d62e8b003d2
2023-06-06 17:22:30 +02:00
Ed Sanders f923081e3f Autosize the EditSummaryWidget
Change-Id: I4df49b1ea202dcb7bbb82cb99d26f0dec17133bc
2023-06-02 12:39:33 +01:00
Bartosz Dziewoński 3109c82cc4 ve.ui.MWGalleryDialog: Fix showing the search panel
Due to changes in StackLayout in OOUI v0.47.0 it is no longer able to
show a panel that was hidden using `.toggle( false )`.

Hiding it in this way seems to not have been needed anyway.

Bug: T337638
Change-Id: I81ed015986ed03fab1e65a7f3a826ac4296077b7
2023-05-29 01:30:29 +02:00
David Lynch 50c646050d Update VE core submodule to master (fd2f048e4)
Also supporting changes to support the new HelpCompletionAction,
including adding a preference to disable it if required.

New changes:
985b553cc Localisation updates from https://translatewiki.net.
aa26e27dc Localisation updates from https://translatewiki.net.
4cdc753ab Update OOUI to v0.47.0
bfc96a7ee Completions: always abandon if the first input is a space
616a6458f Fuzzy command bar
92b6525a2 Tweak the fuzzy command bar's behavior
fd2f048e4 Fuzzy bar: change how command groups are generated

Change-Id: Ic77b8822baecf5ad1ab466d94df29bb945172b55
2023-05-20 22:04:27 +03:00
Arlo Breault 780639f8c5 Preserve classes on all file elements, not just broken images
This also adds mw-file-element to new image nodes.

Bug: T270150
Bug: T314097
Change-Id: I545ed75ed3c87e88b5e776696754e23c05645f81
2023-05-12 10:12:15 +00:00
jenkins-bot 7c0259a3c3 Merge "Handle temporary users when dealing with user preferences" 2023-05-05 15:55:49 +00:00