https://bugzilla.wikimedia.org/show_bug.cgi?id=62454
Bug ID: 62454
Summary: $.byteLimit gets confused when pasting text at the
beginning of the input field that has a common prefix
with the current text
Product: MediaWiki
Version: 1.23-git
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: Unprioritized
Component: JavaScript
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected], [email protected],
[email protected]
Web browser: ---
Mobile Platform: ---
If you paste text at the beginning of the input field that has a common prefix
with the current text (or, simply, is identical), $.byteLimit gets confused
about which part was there already and which is new. It doesn't seem possible
to work around this without a larger rewrite, as we do not track this
information. :/
Simplified test case:
* Have input with with bytelimit=12:
$('#mw-content-text').replaceWith( $('<input>').byteLimit(12) )
* Have text in it "ążśó" (8 bytes, 4 characters)
* Paste "ążśó" at the beginning
* Expected result: "ążążśó", actual result: "ążśóąż"
--
You are receiving this mail because:
You are the assignee for the bug.
You are on the CC list for the bug.
_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l