* Add config option to turn off all snapshotting and related observers
- allows RRWEB to be used for click/movement tracking alone, e.g. for a heatmaps use case
- could also be used if there was a separate process for recording the DOM (in which case a 3rd party library like https://github.com/antonmedv/finder could be added to record targets instead of the mirror)
---------
Authored-by: eoghanmurray <eoghanmurray@users.noreply.github.com>
Co-authored-by: Justin Halsall <Juice10@users.noreply.github.com>
* Extend to run fixBrowserCompatibilityIssuesInCSS over styles in inline style sheets
* Apply formatting changes
---------
Co-authored-by: eoghanmurray <eoghanmurray@users.noreply.github.com>
* Upgrade jest to 29 and puppeteer to 16 in rrweb
* Apply formatting changes
* Upgrade rrweb's puppeteer to v20
* Apply formatting changes
* Canvas: Reduce flickering and capturing of empty canvas elements
Turn on `preserveDrawingBuffer` by default for canvas FPS recording.
Has some negative performance implications, but really helps when capturing canvas.
* Apply formatting changes
* Include all test image snapshots in ci
* Apply formatting changes
* Allow more flexibility when capturing hover
* Apply formatting changes
* Create tiny-chairs-build.md
* Apply formatting changes
* Update hover.test.ts
* Apply formatting changes
* Document snapshotFormat jest config
* Freeze `yarn.lock` in ci for reproducible dependencies
* Apply formatting changes
* Apply formatting changes
* Revert to old style of puppeteer evaluation script notation
* Apply formatting changes
* Make test less flaky
* Apply formatting changes
* Apply formatting changes
* Make tests less flaky
* Apply formatting changes
* Make test more robust
* Apply formatting changes
* Apply formatting changes
* Add debugging code for test
* Apply formatting changes
* Also test not ignored input
* Apply formatting changes
* Apply formatting changes
* Apply formatting changes
* escape ignoreSelector
* Apply formatting changes
* Apply formatting changes
* feat: Add `ignoreSelector` option
Similar to `ignoreClass`, but accepts a CSS selector so that you can use any CSS selector.
* Apply formatting changes
* Create clean-shrimps-lay.md
* Apply formatting changes
* Add a test which demonstrates how no mutations are generated when an element is created & destroyed in the same 'cycle' (a cylce here being enforced by freezePage)
* Test demonstrating current behaviour I'm about to modify; the data-test="x" attribute is present twice in the mutation, as is the textContent value of 'y'
* Attribute or text modifications on just-added nodes are redundant as demonstrated in test case
* Some correct test changes from other tests; I've manually inspected each of these mutation removals and confirmed that the attribute values are already present in the newly added nodes elsewhere in the same mutation
* Improve reliability of test case as per Justin's advice
* Don't use the CSSOM when there's `var()` present as it fails badly https://github.com/rrweb-io/rrweb/pull/1246
* As the CSS Object Model expands out shorthand properties, do a check on the string length before choosing which format to go for
- this approach allows 'var()' in a styleOMValue as it's only a problem when combined with a shorthand property
- before this change background:black; was getting expaned to 10 OM properties as follows:
'style': {
'background-color': 'black',
'background-image': false,
'background-position-x': false,
'background-position-y': false,
'background-size': false,
'background-repeat-x': false,
'background-repeat-y': false,
'background-attachment': false,
'background-origin': false,
'background-clip': false
}
* Updates to remainder of tests based on refined compact style mutations
* Apply suggestions from code review by: Justin Halsall <Juice10@users.noreply.github.com>
---------
Authored-by: eoghanmurray <eoghan@getthere.ie>
* Export correct mirror in player
Was using DeprecatedMirror in its types, that shouldn't be used anymore.
* Add playRange to types
* Create smooth-poems-bake.md
* Apply formatting changes
* Add $set to player type
* Update smooth-poems-bake.md
* Apply formatting changes
* Last two arguments of playRange are optional
* Guard against presence of likely older third party libraries which (re)define Date.now, e.g. https://github.com/datejs/Datejs/issues/92
* Apply formatting changes
* (remove nowTimestamp import where Date.now() is not used)
* Add a PURE marker so an empty `ìf` statement doesn't show up in the rrweb-replay output
* Update packages/rrweb/src/utils.ts
Fix typing issue with regex against `Date.now()`
Co-authored-by: Justin Halsall <Juice10@users.noreply.github.com>
* Create little-radios-thank.md
* Apply formatting changes
* Update .changeset/little-radios-thank.md
* Apply formatting changes
---------
Co-authored-by: eoghanmurray <eoghanmurray@users.noreply.github.com>
Co-authored-by: Justin Halsall <Juice10@users.noreply.github.com>
* As per @Yun Feng: everyone has npm installed globally but maybe not yarn
* Add command to enable test result updating
* Default to running tests HEADLESS on rrweb
* Add command to build:all in a low memory environment
* Add a 'retest' command for when the code hasn't changed, but you are working on the test cases
* Add commands to reformat according to prettier. Named 'reformat' to indicate that we are doing a `--write`
* Update package.json
Co-authored-by: Yun Feng <yun.feng0817@gmail.com>
* Apply suggestions from code review
Co-authored-by: Yun Feng <yun.feng0817@gmail.com>
* Create few-turkeys-reflect.md
* Apply formatting changes
---------
Co-authored-by: Justin Halsall <Juice10@users.noreply.github.com>
Co-authored-by: Yun Feng <yun.feng0817@gmail.com>
* fix: rrdom bug
1. fix one bug of the diff algorithm
2. omit srcdoc attribute of iframe
* use linked list to iterate children
* fix the bug that the children of shadowRoot don't get diffed
* add test cases
* add change log
* Scale sponsors
Gold sponsors where a bit too big. I've scaled down all sponsors to match their donation level (calculation below). Also makes the low res image of our gold sponsor less apparent.
Example:
Bronze Sponsors Calculation:
50 pixels per donation $
100$ = 5000 pixels
√5000 = +/-70
Resolution: 70*70 = +/-5000 pixels
* Create fresh-cars-impress.md
* refactor rrvideo: use playwright rather than puppeteer
* add a progress bar for the tool
* add tests for cli.ts
* fix build error
* add change log
* update readme file
* Apply a scaling method to improve the resolution of the output video
* Reduce verbosity/redundancy of output of new pointerType attribute by confining it only to clicks (and to a MouseDown/MouseUp from a PointerTypes.Pen, as these don't yet have a dedicated PendDown/PenUp)
* Update how the changeset will read for the next release based on the trimming in this PR
* Prefer triple equals
* The assignment to the outer `pointerType` variable in an anonymous function was somehow missed by the `typings` check
* Apply formatting changes
* Update packages/rrweb/src/record/observer.ts
* Update packages/rrweb/src/record/observer.ts
---------
Co-authored-by: Yun Feng <yun.feng0817@gmail.com>
* Reset the finished flag in goto
If the player finishes a replaying a video the `finished` boolean is set to true. This allows the video to be restarted at the beginning if the controller is toggled again. If a user clicks on the progress bar the `finished` boolean is reset so if the `toggle` API is called it starts at the right place. If a user programatically calls `goto` which is the underlying API that handling the progress click calls the next invocation of `toggle` will start the video at the beginning instead of the proper location.
* Create controller-finish-flag.md
* Update controller-finish-flag.md
* fix: Fix input.type check
Actually I noticed that `el.type` returns `text` when type is not explicitly set, so this is slightly incorrect.
* fix linting
* Apply formatting changes