wgTitle is basically just $title->getText()
wgPageName is $title->getPrefixedDBkey()
So we need to take wgPageName and run getPrefixedText (difference is underscores
get replaced by spaces)
Change-Id: Ib99f0d20f1ba99338f80bbbf39cffd544887c3fa
Double-clicking the "insert" button would double-insert the template. Counting
the close as a pending action avoids that.
Bug: T129725
Change-Id: I41af7c051fd54004cecd563d7a6cf8fdb452840f
New changes:
6cf8864 Follow-up eb97c1f: Fix build for added language 'inh'
d1ce123 SpecialCharacterDialog: Use getReadyProcess promise to wait for char list
Local changes:
* SpecialCharacterDialog: Defer loading of character list.
Saves ~40k for most users who never use it.
Change-Id: I74b30fee96e1ae4463ed28c19bef4b515330220e
Depends-On: I45dc9f788aa5bd702b91ffd9f63b05b1f4760691
New changes:
e661245 Localisation updates from https://translatewiki.net.
d0bac53 ElementLinearData: Add test for sanitize conversions
53988e4 ElementLinearData: Test blacklist unwrapping
8593098 ve.dm.Model: Remove unused, untested method 'hasAttributes'
6247dd2 ce.Surface: Add tests for table strip delete
bee1851 ce.Surface: Add larger table strip-delete test
42d39e7 ce.Surface: Test table navigation with enter/escape/tab/shift-tab
5d248f9 Remove TableCaptionCommand
a86ad04 PreviewElement: Check node is a GCN, and always return a boolean
b518839 Localisation updates from https://translatewiki.net.
8834e9c ce.Surface: Allow any key code in the key handler tests
6b3ea6a ce.Surface: Linear arrow tests for block node
026999d Localisation updates from https://translatewiki.net.
eb97c1f Localisation updates from https://translatewiki.net.
Change-Id: Ic5853116d97623316d9a6bbacda2ecab9e4b49d5
Using the same logic we used for converting pasted URLs, detect
internal links by matching their base.
Currently link pasting is still disabled in the VE target, but
has been enabled elsewhere (Flow).
Change-Id: Iebd61abbe1fe82fd18d129e1dbc815ca75f44e87
Now that some targets support link pasting (Flow) we need to
make sure that pasted links match to an allowed type ('link/mwExternal')
instead of plain 'link' annotations which should never exist
in an MW document.
In a later commit we should auto-detect internal links.
Change-Id: I7faae834aa6e730c3cf93a691331a05fd0fe3d5c
I have noticed that Jenkins job that runs daily fails sometimes because
looking up the element failed after 5 seconds. The time is increased
from 5 to 10 seconds.
Bug: T94150
Change-Id: Ib23f4ac72aa6c734f297e8f9fb5ad4645ac8891e
* Don't just fail to load, action=visualeditor itself should not write to the DB
(we have action=visualeditoredit for that)
* Send notice to the client in the usual way
* Handle read only errors on save, log as unknown
This won't let you review changes because that uses visualeditoredit
Bug: T129501
Change-Id: Id78c06b031423e47a7ddf94ec615b6d6975309d3
VisualEditor_Insert_Menu scenario fails with `Original image height is
too small! (ChunkyPNG::OutOfBounds)`.
Bug: T119482
Change-Id: I30c3a9757c5754a40921fce5225b73897eed865b
Regression from 863a2c2974.
Sometimes when clicking "Switch to source mode" in the toolbar this
error is thrown and the interface freezes because setEditorPreference()
only returns a promise if the value is different.
> Uncaught TypeError: Cannot read property 'done' of undefined
> - ve.init.mw.DesktopArticleTarget.switchToWikitextEditor
Change-Id: Ie59f06a8ed9af9c4fb8199b013c06992d0c4f700
This causes the inspector to take focus early (line 291) on
first load, and is not necessary as this method fires when
needed anyway.
Bug: T129228
Change-Id: Ia69f76b68e89daf5cb01449c40e71de4ec32d400
Make the DOM order sensible so we don't have to
use SearchWidget's position:absolute hacks.
Bug: T129173
Change-Id: I3517e0e0cfe2ab0eee4bed7390e41710d3140eb0
This allows extensions to register their own rules for detecting wikitext,
e.g. matching '<ref>'.
Bonus: Strip the autogenerated <references/> tag which
gets inserted when converting a <ref>.
Bug: T128805
Change-Id: I7a38db45d25e86ff3f3f6199aa04425ec98f7cc4
action=query&prop=info was being used because it can be combined
with action=query&meta=userinfo, while action=tokens cannot.
However, since MediaWiki 1.24 the 'intoken' parameter of
action=query&prop=info is deprecated, while the preferred way of
retrieving tokens is action=query&meta=tokens which not only can
be combined with action=query&meta=userinfo but also spares the
need of dealing with page ids.
Change-Id: I5ded3c303ede20514eeb2840715fe240b3b2c7e1
This can happen when the user gets logged out on a private wiki.
We get a badtoken error, so we try to refetch the token, which
itself returns an error. Token refetches didn't have error handling
at all and got the save dialog stuck in the pending state.
We can't offer the user to proceed with a different identity here,
because we encountered an error while trying to figure out what their
current identity is. The best we can do is encourage them to
log back in in a different tab.
Bug: T128934
Change-Id: I17d4452f688ec22631dbd12af223731635004d66
New changes:
0b7e689 FindAndReplaceDialog: don't use tabindex
17b10a5 Localisation updates from https://translatewiki.net.
a4133e4 [BREAKING CHANGE] Make whitespaceHtmlCharacters a real static property
Local changes:
* MWEntityNode: Fix lookup of whitespaceHtmlCharacters
Property is now in 'static', and use registry to look up
TextNode by symbolic name.
Change-Id: Ied8c0c6feb69141c7c53fc4cc790774dee2cb63c
Depends-On: I7537b46a9fd58dfb2bd18dc4ed469aa221b96e86
Sauce Labs browsers raise
Selenium::WebDriver::Error::StaleElementReferenceError
if a test tries to use an element but VisualEditor is not loaded.
Bug: T128731
Change-Id: Icb01b4dee256a0270d722492d11dabf0cfc4f8c4
Looks like local browsers raise
Selenium::WebDriver::Error::JavascriptError while remote (Sauce Labs)
browsers raise Selenium::WebDriver::Error::UnknownError if a test tries
to use an element but VisualEditor is not loaded.
Bug: T126966
Change-Id: I89c8eaba996e95e7859084fe26e15befee9dce77
Trim the cached image data from the media dialog down so that it only caches
the same information that would have been fetched for a non-uploaded image.
Consistency!
Bug: T126081
Change-Id: I0f057c111b66f29c6360e27f97256384f5320b75
New changes:
0371bbe [BREAKING CHANGE] Refine VisualEditorSupportCheck call and document pattern
Local changes: Use new VisualEditorSupportCheck pattern
Change-Id: I7dc0c360b54a93397180b18d88d72532e439da5c
If the surface is display:none then $.width always
returns 0, which breaks features like FocusableNode's
invisible icon.
Bug: T127319
Change-Id: Ib157ffaeb56fca2bdc26868d830c4bf8feafa2a8
Warn the user about an empty edit summary when the "edit section"
link is used to trigger VE.
Re-does Ic7b456ca a different way.
Bug: T114857
Change-Id: I319c9c5bed47140a81eb409d490c9f82b89a49fe
'Value' comes across as a bit technical. 'e.g.' is more common
for 'example value'. Truncate 'Default value:' to just 'Default:'.
Change-Id: Ie03fb64a01846071ccdcb673439fc568b9d0de78
Zopfli is the most efficient DEFLATE compression algorithm, trading run-time
performance for file sizes that are typically 3-8% smaller than those produced
by zlib with the maximum compression setting. Its output is Deflate-compatible,
so no specialized decoder is needed.
This change was created by running zopflipng against all the PNG files in this
repository. The exact invocation was:
git ls-files --exclude-per-directory=.gitignore -- '*.png' \|
parallel zopflipng -m -y {} {} \;
Files which zopflipng was not able to compress more efficiently were left unmodified.
Bug: T127608
Change-Id: Id5807b1ec56320b3474878290dd05600c1e389d5
Only call setup in ready process, as setup includes setting
focus. Defer fitInput call to category widget until transition
is finished so measurements are correct.
Change-Id: I49a30402cf58e36f16316e3ab04fa3349d19954e
For every title request, store an entry in noramlizedTitle to
avoid ever making an API request for that category again.
This prevents API requests from being fired every time a
category was moved, which in turn prevents the list from
flickering as it waits for the API request to resolve.
Also normalise the spelling of normalize to en-US/en-GB-oxendict
Bug: T127317
Change-Id: Ie26d9d60fb83981c45ff27199e38ae98e5560a28
All scenarios that are passing are enabled to run in Jenkins.
(The commit increases the number of passing scenarios from 2 to 18.)
Bug: T126966
Change-Id: I9789ca42717133120197c4625bb8dad4ea496aa8
New changes:
c02ea46 Clarify documentation of directionality methods
43c9b6f Move initialisation browser support checking from downstream
c89be66 Localisation updates from https://translatewiki.net.
5fb7907 Follow-up c89be66: Fix build for added language 'nan'
fc74fab dm.ElementLinearData.compareElements: Add a few missed test cases
Local changes:
Use initialisation browser support checking from upstream
Depends-On: I27a8e7b4376647f01cee648de987dc3ca6a060d5
Change-Id: I3fc79422ee5e487cf5fae3929fe492f21cd2840a
hideLoading always gets called after activating, not just failing
Follows-up: I13058ae1
Bug: T127184
Change-Id: I47d1892feacbfcf832aa32f689f173601b76c4ba
To get at least some Cucumber scenarios running in Jenkins, disable all
of them that are failing and run only ones that are passing.
The next step will be to fix failing scenarios.
Bug: T94162
Change-Id: Id0338c1d6b86d6b45220c5c0802074be397fb607
* Try to hide loading bar on failure
* Don't set wgAction back to 'view' if we're dropping the user back to the
wikitext editor
Bug: T125580
Change-Id: I13058ae131a1dda3b172e78d9b143d70831c47f1
The title is visibly varied in the context menu separately, and
we don't usually change the link tool's title - so this is just
a performance drain (updateState happens a lot).
Change-Id: I9cf2aa509a6aac3a2914fa52167cb4463843cd72
* Override the static cloneElement. getClonedElement shouldn't
be overridden as doing so misses static invocations.
* Apply the same fix to extension nodes
* Fix DOM loop to reference clone.originalDomElements[ i ]
Logically depends on Id8024c171c to work.
Bug: T126169
Bug: T126114
Change-Id: Icf4d3115db5b12b97a6c805ff3d0b71d9e88b804
* grunt-contrib-jshint: 0.11.3 -> 0.12.0
This version of the linter cleans up a number of options. 'es5' is now assumed to be
true by default, and replaced as 'esversion'; 'latedef' is extended to also cover
functions' defintions, disabled for us for now; 'futurehostile' is introduced to aid
future-incompatible names for ES6+ support.
I adjusted ve.init.mw.DesktopArticleTarget.init.js based on this, as this file is
meant to be loaded by all JS-capable clients to determine if it is (amongst other
things) capable of ES5, so now we assert ES3 compatibility via jshint.
* grunt-jscs: 2.5.0 -> 2.7.0
Minor version bump that doesn't affect us.
* grunt-jsonlint: 1.0.6 -> 1.0.7
Trivial version bump that doesn't affect us.
Change-Id: Ieb7b6748b0cecf275cfc284fc66617189372461f
The cited reasons were that the the logo and search bar
have a z-index of 3, but that doesn't matter as they are
nested in other elements with z-indexes.
Change-Id: I7ff279efe7c01ba1ffb1fa0d460d59a493ccc47a