2
guide.md
2
guide.md
@@ -296,7 +296,7 @@ replayer.destroy();
|
|||||||
The replayer accepts options as its constructor's second parameter, and it has the following options:
|
The replayer accepts options as its constructor's second parameter, and it has the following options:
|
||||||
|
|
||||||
| key | default | description |
|
| key | default | description |
|
||||||
| ------------------- | ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
| ----------------------- | ------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
||||||
| speed | 1 | replay speed ratio |
|
| speed | 1 | replay speed ratio |
|
||||||
| root | document.body | the root element of replayer |
|
| root | document.body | the root element of replayer |
|
||||||
| loadTimeout | 0 | timeout of loading remote style sheet |
|
| loadTimeout | 0 | timeout of loading remote style sheet |
|
||||||
|
|||||||
@@ -167,7 +167,10 @@ function isUserInteraction(event: eventWithTime): boolean {
|
|||||||
* @param inactivePeriodThreshold - threshold of inactive time in milliseconds
|
* @param inactivePeriodThreshold - threshold of inactive time in milliseconds
|
||||||
* @returns periods of time consist with [start time, end time]
|
* @returns periods of time consist with [start time, end time]
|
||||||
*/
|
*/
|
||||||
export function getInactivePeriods(events: eventWithTime[], inactivePeriodThreshold: number) {
|
export function getInactivePeriods(
|
||||||
|
events: eventWithTime[],
|
||||||
|
inactivePeriodThreshold: number,
|
||||||
|
) {
|
||||||
const inactivePeriods: [number, number][] = [];
|
const inactivePeriods: [number, number][] = [];
|
||||||
let lastActiveTime = events[0].timestamp;
|
let lastActiveTime = events[0].timestamp;
|
||||||
for (const event of events) {
|
for (const event of events) {
|
||||||
|
|||||||
Reference in New Issue
Block a user