Skip to content

mp.weixin.qq.com - Unable to copy/paste Chinese text #68871

Open

Description

@webcompat-bot

URL: https://mp.weixin.qq.com/s/od-pv-OcQOi1FA3uF0gorA

Browser / Version: Firefox Mobile 89.0
Operating System: Android 11
Tested Another Browser: Yes Edge

Problem type: Something else
Description: cannot copy content
Steps to Reproduce:
I cannot copy the content of the artical.

View the screenshot Screenshot
Browser Configuration
  • gfx.webrender.all: false
  • gfx.webrender.blob-images: true
  • gfx.webrender.enabled: false
  • image.mem.shared: true
  • buildID: 20210323094659
  • channel: nightly
  • hasTouchScreen: true
  • mixed active content blocked: false
  • mixed passive content blocked: false
  • tracking content blocked: false

View console log messages

From webcompat.com with ❤️

Activity

  1. added
    action-needsmoderation
    on Mar 27, 2021
  2. added this to the needstriage milestone on Mar 27, 2021
  3. added
    browser-fixme
    on Mar 27, 2021
  4. changed the title [-]In the moderation queue.[/-] [+]mp.weixin.qq.com - see bug description[/+] on Mar 29, 2021
  5. added
    engine-gecko
    ml-needsdiagnosis-false
    and removed
    action-needsmoderation
    browser-fixme
    on Mar 29, 2021
  6. softvision-oana-arbuzov commented on Mar 29, 2021

    @softvision-oana-arbuzov
    Member

    Thanks for the report, I was to reproduce the issue. Context menu is shown I can use "Copy" but pasting the text is not performed.

    Copied "病例详情"
    image

    Paste (it pasted a previous copied text from a different page)
    image

    Note: The issue is not reproducible on Chrome.
    Copied "据济南市卫健委消息"
    image

    Tested with:
    Browser / Version: Firefox Nightly 210329 (🦎 89.0a1-20210328095625)
    Operating System: Google Pixel 5 (Android 11) - 1080 x 2340 pixels, 19.5:9 ratio (~432 ppi density)

    Moving to Needsdiagnosis for further investigation.

  7. changed the title [-]mp.weixin.qq.com - see bug description[/-] [+]mp.weixin.qq.com - Unable to copy/paste Chinese text[/+] on Mar 29, 2021
  8. added
    severity-critical
    on Mar 29, 2021
  9. karlcow commented on Feb 14, 2022

    @karlcow
    Member

    it goes to:
    https://appwritefunc.yet-another-testing-domain.com/api/grab/res.wx.qq.com/mmbizwap/en_US/htmledition/js/biz_wap/ui/weui_css5acc2d.js,/mmbizwap/en_US/htmledition/js/sougou/index4fe01d.js,/mmbizwap/en_US/htmledition/js/biz_wap/safe/mutation_observer_report47cb35.js,/mmbizwap/en_US/htmledition/js/appmsg/fereport4c4c9a.js,/mmbizwap/en_US/htmledition/js/appmsg/fereport_without_localstorage4c4c9a.js,/mmbizwap/en_US/htmledition/js/appmsg/report4c4c9a.js,/mmbizwap/en_US/htmledition/js/appmsg/report_and_source5b0987.js,/mmbizwap/en_US/htmledition/js/appmsg/appmsg_copy_report54f00e.js,/mmbizwap/en_US/htmledition/js/appmsg/cdn_speed_report47cb35.js,/mmbizwap/en_US/htmledition/js/appmsg/wxtopic47cb35.js,/mmbizwap/en_US/htmledition/js/appmsg/minishop/minishop57f5bb.js,/mmbizwap/en_US/htmledition/js/appmsg/live507426.js,/mmbizwap/en_US/htmledition/js/appmsg/profile/mp_insert_profile59da4e.js,/mmbizwap/en_US/htmledition/js/appmsg/channel/channels5b4296.js,/mmbizwap/en_US/htmledition/js/question_answer/appmsg5b36fc.js?v=1003

    which has a getContentData function

      o.prototype.getContentData = function () {
        var t = document.getSelection(),
        e = this.container,
        n = '';
        if (t && t.rangeCount) {
          var o = t.getRangeAt(0);
          if (!o.collapsed) {
            var a = o.startContainer,
            r = o.startOffset,
            s = o.endContainer,
            c = o.endOffset,
            p = i(a, e),
            u = i(s, e);
            if (p && u) n = o.toString();
             else if (p || u) {
              var f = document.createRange();
              f.setStart(a, r),
              f.setEnd(s, c),
              !u && f.setEndAfter(e),
              !p && f.setStartBefore(e),
              n = f.toString();
            } else if (t.containsNode && t.containsNode(e, !0)) {
              var f = document.createRange();
              f.setEndAfter(e),
              f.setStartBefore(e),
              n = f.toString();
            }
          }
        }
        return n;
      },

    which ever part of the text I'm selecting I always end up with document.getSelection() seems to return the right thing.

    Selection { anchorNode: #text, anchorOffset: 64, focusNode: #text, focusOffset: 64, isCollapsed: true, rangeCount: 1, type: "Caret", caretBidiLevel: 0 }
    

    and t.getRangeAt(0)

    Range { commonAncestorContainer: #text, startContainer: #text, startOffset: 64, endContainer: #text, endOffset: 64, collapsed: true }
    

    which has collapsed: true so it never executes the rest of the code.

    document.getSelection().anchorNode in my case returns:

    #text "\n                    \n                    \n                    \n确诊病例曾搭乘这趟高铁!急寻同乘\n                "
    

    The behavior looks a bit like https://bugzilla.mozilla.org/show_bug.cgi?id=1569211
    but I don't see any unselectable text in there.

    @masayuki-nakano do you think it's the same issue than https://bugzilla.mozilla.org/show_bug.cgi?id=1569211 or should I open another issue?

  10. masayuki-nakano commented on Feb 15, 2022

    @masayuki-nakano

    @karlcow Although I'm investigating that I cannot debug the web site on Android (not connectable to my device...) Did you mean that the images around the text is SVG on Android? I don't see SVG images around "病例详情" on desktop.

  11. karlcow commented on Feb 16, 2022

    @karlcow
    Member

    @masayuki-nakano nope I don't see SVG images too. I wonder if invisible characters could do that too, but I do not see any either. :/

  12. masayuki-nakano commented on Feb 17, 2022

    @masayuki-nakano

    @karlcow If there are some ::before or ::after pseudo elements, they may split selection ranges IIRC.

  13. added
    action-needstestcase
    on Feb 21, 2022
  14. karlcow commented on Feb 21, 2022

    @karlcow
    Member

    Oh! Thanks. @masayuki-nakano

    Probably we should create a test case to see if there's a diff behavior in between blink and gecko.

  15. softvision-raul-bucata commented on Nov 15, 2022

    @softvision-raul-bucata
    Collaborator

    The issue is still reproducible.

    Tested with:

    Browser / Version: Firefox Nightly 109.0a1 (2015915883-🦎109.0a1-20221114151331🦎)
    Operating System: Samsung A51 (Android 11) -1080 × 2400 pixels 20:9 aspect ratio (~405 ppi density)
    Operating System: Google Pixel 3 (Android 12) -1080 x 2160 pixels, 18:9 ratio (~443 ppi density)

    [inv_46/2022]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

action-needstestcasebrowser-fenixdiagnosis-priority-p2engine-geckoml-needsdiagnosis-falsepriority-criticalseverity-critical

Type

No type

Projects

No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions