|
|
| !("confirmed" in user_groups) & | | !("confirmed" in user_groups) & |
| page_namespace === 0 & | | page_namespace === 0 & |
| ( | | ( |
| toolbar := "(?x)
| | toolbar := "(?x) |
| '''Bold[ ]text''' | | '''Bold[ ]text''' |
| |''Italic[ ]text'' | | |''Italic[ ]text'' |
| |\[\[\|thumb\]\] | | |\[\[\|thumb\]\] |
| |<gallery>\\nExample\.jpg | | |<gallery>[\n]Example\.jpg |
| |<ref></ref> | | |<ref></ref> |
| |==[ ]Heading[ ]text[ ]== | | |==[ ]Heading[ ]text[ ]== |
| |\*[ ]Bulleted[ ]list[ ]item | | |\*[ ]Bulleted[ ]list[ ]item |
| |\#[ ]Numbered[ ]list[ ]item | | |\#[ ]Numbered[ ]list[ ]item |
| |<big>Big[ ]text | | |<big>Big[ ]text |
| |<small>Small[ ]text | | |<small>Small[ ]text |
| |<sup>Superscript[ ]text | | |<sup>Superscript[ ]text |
| |<sub>Subscript[ ]text | | |<sub>Subscript[ ]text |
| |<nowiki>Insert[ ]non-formatted[ ]text[ ]here | | |<nowiki>Insert[ ]non-formatted[ ]text[ ]here |
| |![ ]Header[ ]text | | |![ ]Header[ ]text |
| |[#]REDIRECT[ ]\[\[Target[ ]page[ ]name\]\] | | |[#]REDIRECT[ ]\[\[Target[ ]page[ ]name\]\] |
| "; | | "; |
|
| |
|
| /* When people stab the buttons repeatedly, the results can end up nested, e.g. <ref><small>Small text</small></ref> */ | | /* When people stab the buttons repeatedly, the results can end up nested, e.g. <ref><small>Small text</small></ref> */ |
| trim := toolbar + "|</?sub>|</?sup>|</?small>|</?ref>|</?nowiki>|#REDIRECT"; | | trim := toolbar + "|</?sub>|</?sup>|</?small>|</?ref>|</?nowiki>|#REDIRECT"; |
|
| |
|
| added_lines rlike toolbar & | | added_lines rlike toolbar & |
| !(removed_lines rlike toolbar) & | | !(removed_lines rlike toolbar) & |
| rmwhitespace(rmspecials(str_replace_regexp(added_lines, trim, ""))) == rmwhitespace(rmspecials(str_replace_regexp(removed_lines, trim, ""))) | | rmwhitespace(rmspecials(str_replace_regexp(added_lines, trim, ""))) == rmwhitespace(rmspecials(str_replace_regexp(removed_lines, trim, ""))) |
| ) | | ) |