better splitting of selectors (#1440)

* better splitting of selectors - overlapping with #1401 
* Add test from example at https://github.com/PostHog/posthog/pull/21427
* ignore brackets inside selector strings
* Add another test as noticed that it's possible to escape strings
* Ensure we are ignoring commas within strings

Co-authored-by: Eoghan Murray <eoghan@getthere.ie>
This commit is contained in:
David Newell
2024-04-18 23:46:17 +01:00
committed by GitHub
parent bee92c8291
commit c0f83afab8
3 changed files with 60 additions and 1 deletions

View File

@@ -0,0 +1,5 @@
---
'rrweb-snapshot': patch
---
better nested css selector splitting when commas or brackets happen to be in quoted text