mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/DiscussionTools
synced 2024-11-27 17:51:09 +00:00
Temporarily disable isPreview in Parsoid's rendering
This will let us render reply links on wikitech and run visual diffs (which runs in anonymous user mode). This will be reverted after the visual diff test run. Change-Id: Ibf175a7f5b1e68f66c257fc26ba9e4b55f752fbd
This commit is contained in:
parent
ba7e8417a6
commit
d004c001be
|
@ -86,9 +86,14 @@ class ParserHooks implements
|
|||
* @inheritDoc
|
||||
*/
|
||||
public function onParserOutputPostCacheTransform( $parserOutput, &$text, &$options ): void {
|
||||
// TEMPORARY for wikitech visualdiff testing: Pin this to false so we
|
||||
// always render reply links (for anon users as well) to match current
|
||||
// behavior which also lets us run a truer visual diff with DT.
|
||||
//
|
||||
// NOTE: This is a temporary proxy for 'isPreview' flag in ParserOptions.
|
||||
// It is not clear whether 'editsectionEditLinks' is disabled only for previews.
|
||||
$isPreview = empty( $options['enableSectionEditLinks'] );
|
||||
// $isPreview = empty( $options['enableSectionEditLinks'] );
|
||||
$isPreview = false;
|
||||
|
||||
// We want to run this hook only on Parsoid HTML for now.
|
||||
// (and leave the onParserAfterTidy handler for legacy HTML).
|
||||
|
|
Loading…
Reference in a new issue