Skip to content

[Bug]: Safari does not escape : in CSS rule #1208

@billyvg

Description

@billyvg

Preflight Checklist

  • I have searched the issue tracker for a bug report that matches the one I want to file, without success.

What package is this bug report for?

rrweb

Version

v1 + v2

Expected Behavior

Chrome: https://rrwebdebug.com/play/index.html?url=https%3A%2F%2Fgist.githubusercontent.com%2Fbillyvg%2F36b1028063eef73337958955fb494cf0%2Fraw%2Fbfd605b8244fa4e8431046d8aef8a2a45f8f3130%2Fchrome.json&version=2.0.0-alpha.7&play=on

"loading" text should not appear in replay

Actual Behavior

Safari: https://rrwebdebug.com/play/index.html?url=https%3A%2F%2Fgist.githubusercontent.com%2Fbillyvg%2F36b1028063eef73337958955fb494cf0%2Fraw%2Fe4a6ac08edc7f09828444a175332b2b9e765d04e%2Fsafari.json&version=2.0.0-alpha.7&play=on

Notice red box + loading text

Steps to Reproduce

CSS with : does not get escape during recording in the Safari browser.

e.g.

[foo:bar] {
  display: none;
}

In Chrome this gets escaped to [foo\\:bar], but in Safari it is untouched: [foo:bar]. During replay (any browser), the [foo:bar] rule is ignored.

Testcase Gist URL

No response

Additional Information

Note this is a 5 year old bug in Safari: https://bugs.webkit.org/show_bug.cgi?id=184604

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions