Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Linkify experiment breaks Slack and Twitter #503

Closed
lidel opened this issue Jun 26, 2018 · 0 comments · Fixed by #504
Closed

Linkify experiment breaks Slack and Twitter #503

lidel opened this issue Jun 26, 2018 · 0 comments · Fixed by #504
Assignees
Labels
kind/bug A bug in existing code (including security flaws) status/in-progress In progress

Comments

@lidel
Copy link
Member

lidel commented Jun 26, 2018

Background

The linkifyDOM.js content script script itself is very old, was copied from the legacy-sdk branch when we moved to WebExtensions. It is disabled by default, but some people opt-in to enable it.

@lgierth noted that "Linkify" experiment breaks Slack/Twitter.

Reproducing

I was able to reproduce issue with slack by enabling Linkify experiment and pasting below line to the chat input:

foo dweb:/ipfs/QmbWqxBEKC3P8tqsKc98xmWNzrzDtRLMiMPL8wBuTGsMnR bar

and trying to write something after bar

Fix

It seems linkification works fine on initial page load, and the issue is related to handling of dynamic DOM updates that happen after that.

@lidel lidel added the kind/bug A bug in existing code (including security flaws) label Jun 26, 2018
@lidel lidel self-assigned this Jun 26, 2018
@lidel lidel added the status/in-progress In progress label Jun 26, 2018
lidel added a commit that referenced this issue Jun 26, 2018
- support dynamic JS apps by rate-limiting operations
  - run only one DOM-mutating task at the time
  - ignore Elements that have or are under a parents marked
    with HTMLElement.contentEditable property
- closes #503
lidel added a commit that referenced this issue Jun 26, 2018
- support dynamic JS apps by rate-limiting operations
  - run only one DOM-mutating task at the time
  - ignore Elements that have or are under a parents marked
    with HTMLElement.contentEditable property
- closes #503
@lidel lidel closed this as completed in #504 Jul 2, 2018
lidel added a commit that referenced this issue Jul 2, 2018
This PR updates very old content script responsible for making plain text IPFS paths clickable.

- Support dynamic JS apps by rate-limiting operations via global job queue
  - Run only one DOM-mutating task at the time
  - Ignore DOM nodes under a parent with  `contentEditable` property equal true
    - This fixes heavily customized input fields on Slack and Twitter and closes #503
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug A bug in existing code (including security flaws) status/in-progress In progress
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant