Krinkle has uploaded a new change for review.

Change subject: (bug 43013) Exclude edit notices with no visible text.
......................................................................

(bug 43013) Exclude edit notices with no visible text.

en.wikipedia.org has a template gala for edit notices with a whole
bunch of html framework outputted by default from
MediaWiki:Editnotice-0 (even if their underlying system has no
matches for the current page).

In the core editor from EditPage.php this isn't a problem as the
element is just idling hidden above the editor.

In the case of VisualEditor (where we have a custom delivery for
the edit notices) we don't want to say "1 notice available" on
every page, so we need to be smart and quickly walk the dom of the
notice, filter out invisible nodes, and if the resulting nodes
have no contents, ignore the notice all together.

Change-Id: I65447da8b88a9bae9c24ff155544ff66b3fe9100
---
M VisualEditor.php
A modules/jquery/jquery.visibleText.js
M modules/ve/init/mw/targets/ve.init.mw.ViewPageTarget.js
M modules/ve/init/mw/ve.init.mw.Target.js
4 files changed, 90 insertions(+), 7 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/VisualEditor 
refs/changes/62/38462/1
--
To view, visit https://gerrit.wikimedia.org/r/38462
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I65447da8b88a9bae9c24ff155544ff66b3fe9100
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/VisualEditor
Gerrit-Branch: master
Gerrit-Owner: Krinkle <ttij...@wikimedia.org>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to