fix(tracker): fix message prop

This commit is contained in:
sylenien 2022-09-12 12:18:55 +02:00
parent 4e41fdfcf3
commit d77374c1e3
26 changed files with 305 additions and 276 deletions

View file

@ -2,7 +2,7 @@
package messages package messages
func IsReplayerType(id int) bool { func IsReplayerType(id int) bool {
return 0 == id || 4 == id || 5 == id || 6 == id || 7 == id || 8 == id || 9 == id || 10 == id || 11 == id || 12 == id || 13 == id || 14 == id || 15 == id || 16 == id || 18 == id || 19 == id || 20 == id || 22 == id || 37 == id || 38 == id || 39 == id || 40 == id || 41 == id || 44 == id || 45 == id || 46 == id || 47 == id || 48 == id || 49 == id || 54 == id || 55 == id || 59 == id || 60 == id || 61 == id || 67 == id || 69 == id || 70 == id || 71 == id || 72 == id || 73 == id || 74 == id || 75 == id || 76 == id || 77 == id || 79 == id || 83 == id || 90 == id || 93 == id || 96 == id || 100 == id || 102 == id || 103 == id || 105 == id return 0 == id || 4 == id || 5 == id || 6 == id || 7 == id || 8 == id || 9 == id || 10 == id || 11 == id || 12 == id || 13 == id || 14 == id || 15 == id || 16 == id || 18 == id || 19 == id || 20 == id || 22 == id || 37 == id || 38 == id || 39 == id || 40 == id || 41 == id || 44 == id || 45 == id || 46 == id || 47 == id || 48 == id || 49 == id || 54 == id || 55 == id || 59 == id || 60 == id || 61 == id || 67 == id || 69 == id || 70 == id || 71 == id || 72 == id || 73 == id || 74 == id || 75 == id || 76 == id || 77 == id || 79 == id || 83 == id || 90 == id || 93 == id || 96 == id || 100 == id || 102 == id || 103 == id || 105 == id
} }
func IsIOSType(id int) bool { func IsIOSType(id int) bool {

View file

@ -3068,21 +3068,29 @@ func (msg *Zustand) EncodeWithIndex() []byte {
return data return data
} }
func (msg *Zustand) Decode() Message {
return msg
}
func (msg *Zustand) TypeID() int {
return 79
}
type ReplaceVCSS struct { type ReplaceVCSS struct {
message message
ID uint64 ID uint64
Styles string Styles string
SheetID string SheetID uint64
BaseURL string BaseURL string
} }
func (msg *ReplaceVCSS) Encode() []byte { func (msg *ReplaceVCSS) Encode() []byte {
buf := make([]byte, 41+len(msg.Styles)+len(msg.SheetID)+len(msg.BaseURL)) buf := make([]byte, 41+len(msg.Styles)+len(msg.BaseURL))
buf[0] = 83 buf[0] = 83
p := 1 p := 1
p = WriteUint(msg.ID, buf, p) p = WriteUint(msg.ID, buf, p)
p = WriteString(msg.Styles, buf, p) p = WriteString(msg.Styles, buf, p)
p = WriteString(msg.SheetID, buf, p) p = WriteUint(msg.SheetID, buf, p)
p = WriteString(msg.BaseURL, buf, p) p = WriteString(msg.BaseURL, buf, p)
return buf[:p] return buf[:p]
} }
@ -3098,14 +3106,6 @@ func (msg *ReplaceVCSS) EncodeWithIndex() []byte {
return data return data
} }
func (msg *Zustand) Decode() Message {
return msg
}
func (msg *Zustand) TypeID() int {
return 79
}
func (msg *ReplaceVCSS) Decode() Message { func (msg *ReplaceVCSS) Decode() Message {
return msg return msg
} }

View file

@ -1327,7 +1327,7 @@ func DecodeReplaceVCSS(reader io.Reader) (Message, error) {
if msg.Styles, err = ReadString(reader); err != nil { if msg.Styles, err = ReadString(reader); err != nil {
return nil, err return nil, err
} }
if msg.SheetID, err = ReadString(reader); err != nil { if msg.SheetID, err = ReadUint(reader); err != nil {
return nil, err return nil, err
} }
if msg.BaseURL, err = ReadString(reader); err != nil { if msg.BaseURL, err = ReadString(reader); err != nil {

View file

@ -99,7 +99,7 @@ class CreateDocument(Message):
__id__ = 7 __id__ = 7
def __init__(self, ): def __init__(self, ):
class CreateElementNode(Message): class CreateElementNode(Message):
@ -970,3 +970,5 @@ class IOSIssueEvent(Message):
self.context_string = context_string self.context_string = context_string
self.context = context self.context = context
self.payload = payload self.payload = payload

View file

@ -149,7 +149,7 @@ class MessageCodec(Codec):
if message_id == 7: if message_id == 7:
return CreateDocument( return CreateDocument(
) )
if message_id == 8: if message_id == 8:
@ -672,7 +672,7 @@ class MessageCodec(Codec):
return ReplaceVCSS( return ReplaceVCSS(
id=self.read_uint(reader), id=self.read_uint(reader),
styles=self.read_string(reader), styles=self.read_string(reader),
sheet_id=self.read_string(reader), sheet_id=self.read_uint(reader),
base_url=self.read_string(reader) base_url=self.read_string(reader)
) )
@ -847,3 +847,4 @@ class MessageCodec(Codec):
context=self.read_string(reader), context=self.read_string(reader),
payload=self.read_string(reader) payload=self.read_string(reader)
) )

View file

@ -50,7 +50,7 @@ export default class DOMManager extends ListWalker<Message> {
private vElements: Map<number, VElement> = new Map() private vElements: Map<number, VElement> = new Map()
private vRoots: Map<number, VShadowRoot | VDocument> = new Map() private vRoots: Map<number, VShadowRoot | VDocument> = new Map()
private styleSheets: Map<number, CSSStyleSheet> = new Map() private styleSheets: Map<number, CSSStyleSheet> = new Map()
private upperBodyId: number = -1; private upperBodyId: number = -1;
private nodeScrollManagers: Map<number, ListWalker<SetNodeScroll>> = new Map() private nodeScrollManagers: Map<number, ListWalker<SetNodeScroll>> = new Map()
@ -81,7 +81,7 @@ export default class DOMManager extends ListWalker<Message> {
if(m.tag === "BODY" && this.upperBodyId === -1) { if(m.tag === "BODY" && this.upperBodyId === -1) {
this.upperBodyId = m.id this.upperBodyId = m.id
} }
} else if (m.tp === "set_node_attribute" && } else if (m.tp === "set_node_attribute" &&
(IGNORED_ATTRS.includes(m.name) || !ATTR_NAME_REGEXP.test(m.name))) { (IGNORED_ATTRS.includes(m.name) || !ATTR_NAME_REGEXP.test(m.name))) {
logger.log("Ignorring message: ", m) logger.log("Ignorring message: ", m)
return; // Ignoring return; // Ignoring
@ -95,7 +95,7 @@ export default class DOMManager extends ListWalker<Message> {
} }
} }
// May be make it as a message on message add? // May be make it as a message on message add?
private removeAutocomplete(node: Element): boolean { private removeAutocomplete(node: Element): boolean {
const tag = node.tagName const tag = node.tagName
if ([ "FORM", "TEXTAREA", "SELECT" ].includes(tag)) { if ([ "FORM", "TEXTAREA", "SELECT" ].includes(tag)) {
@ -123,7 +123,7 @@ export default class DOMManager extends ListWalker<Message> {
const pNode = parent.node const pNode = parent.node
if ((pNode instanceof HTMLStyleElement) && // TODO: correct ordering OR filter in tracker if ((pNode instanceof HTMLStyleElement) && // TODO: correct ordering OR filter in tracker
pNode.sheet && pNode.sheet &&
pNode.sheet.cssRules && pNode.sheet.cssRules &&
pNode.sheet.cssRules.length > 0 && pNode.sheet.cssRules.length > 0 &&
pNode.innerText && pNode.innerText &&
@ -160,7 +160,7 @@ export default class DOMManager extends ListWalker<Message> {
vDoc.insertChildAt(vn, 0) vDoc.insertChildAt(vn, 0)
this.vRoots = new Map([[0, vDoc]]) // watchout: id==0 for both Document and documentElement this.vRoots = new Map([[0, vDoc]]) // watchout: id==0 for both Document and documentElement
// this is done for the AdoptedCSS logic // this is done for the AdoptedCSS logic
// todo: start from 0 (sync logic with tracker) // todo: start from 0 (sync logic with tracker)
this.stylesManager.reset() this.stylesManager.reset()
return return
case "create_text_node": case "create_text_node":
@ -326,6 +326,18 @@ export default class DOMManager extends ListWalker<Message> {
} }
deleteRule(styleSheet, msg) deleteRule(styleSheet, msg)
return return
case "replace_vcss":
styleSheet = this.styleSheets.get(msg.id)
if (!styleSheet) {
logger.warn("No stylesheet was created for ", msg)
return
}
const toRemove = styleSheet.cssRules.length
for (let i = 0; i < toRemove; i++) {
styleSheet.deleteRule(i)
}
styleSheet.insertRule(msg.styles)
return
case "adopted_ss_replace": case "adopted_ss_replace":
styleSheet = this.styleSheets.get(msg.sheetID) styleSheet = this.styleSheets.get(msg.sheetID)
if (!styleSheet) { if (!styleSheet) {
@ -364,11 +376,11 @@ export default class DOMManager extends ListWalker<Message> {
//@ts-ignore //@ts-ignore
vn.node.adoptedStyleSheets = [...vn.node.adoptedStyleSheets].filter(s => s !== styleSheet) vn.node.adoptedStyleSheets = [...vn.node.adoptedStyleSheets].filter(s => s !== styleSheet)
return return
} }
} }
moveReady(t: number): Promise<void> { moveReady(t: number): Promise<void> {
// MBTODO (back jump optimisation): // MBTODO (back jump optimisation):
// - store intemediate virtual dom state // - store intemediate virtual dom state
// - cancel previous moveReady tasks (is it possible?) if new timestamp is less // - cancel previous moveReady tasks (is it possible?) if new timestamp is less
this.moveApply(t, this.applyMessage) // This function autoresets pointer if necessary (better name?) this.moveApply(t, this.applyMessage) // This function autoresets pointer if necessary (better name?)
@ -391,4 +403,4 @@ export default class DOMManager extends ListWalker<Message> {
}) })
}) })
} }
} }

View file

@ -1,9 +1,8 @@
import type StatedScreen from '../../StatedScreen'; import type StatedScreen from '../../StatedScreen';
import type { CssInsertRule, CssDeleteRule } from '../../messages'; import type { CssInsertRule, CssDeleteRule, ReplaceVcss } from '../../messages';
type CSSRuleMessage = CssInsertRule | CssDeleteRule; type CSSRuleMessage = CssInsertRule | CssDeleteRule | ReplaceVcss;
import logger from 'App/logger';
import ListWalker from '../ListWalker'; import ListWalker from '../ListWalker';
@ -72,7 +71,7 @@ export default class StylesManager extends ListWalker<CSSRuleMessage> {
private manageRule = (msg: CSSRuleMessage):void => { private manageRule = (msg: CSSRuleMessage):void => {
// if (msg.tp === "css_insert_rule") { // if (msg.tp === "css_insert_rule") {
// let styleSheet = this.#screen.document.styleSheets[ msg.stylesheetID ]; // let styleSheet = this.#screen.document.styleSheets[ msg.stylesheetID ];
// if (!styleSheet) { // if (!styleSheet) {
// logger.log("No stylesheet with corresponding ID found: ", msg) // logger.log("No stylesheet with corresponding ID found: ", msg)
// styleSheet = this.#screen.document.styleSheets[0]; // styleSheet = this.#screen.document.styleSheets[0];
// if (!styleSheet) { // if (!styleSheet) {
@ -91,9 +90,9 @@ export default class StylesManager extends ListWalker<CSSRuleMessage> {
// if (msg.tp === "css_delete_rule") { // if (msg.tp === "css_delete_rule") {
// // console.warn('Warning: STYLESHEET_DELETE_RULE msg') // // console.warn('Warning: STYLESHEET_DELETE_RULE msg')
// const styleSheet = this.#screen.document.styleSheets[msg.stylesheetID]; // const styleSheet = this.#screen.document.styleSheets[msg.stylesheetID];
// if (!styleSheet) { // if (!styleSheet) {
// logger.log("No stylesheet with corresponding ID found: ", msg) // logger.log("No stylesheet with corresponding ID found: ", msg)
// return; // return;
// } // }
// styleSheet.deleteRule(msg.index); // styleSheet.deleteRule(msg.index);
// } // }
@ -103,4 +102,4 @@ export default class StylesManager extends ListWalker<CSSRuleMessage> {
return Promise.all(this.linkLoadPromises) return Promise.all(this.linkLoadPromises)
.then(() => this.moveApply(t, this.manageRule)); .then(() => this.moveApply(t, this.manageRule));
} }
} }

View file

@ -1,4 +1,5 @@
// Auto-generated, do not edit // Auto-generated, do not edit
/* eslint-disable */
import PrimitiveReader from './PrimitiveReader' import PrimitiveReader from './PrimitiveReader'
import type { RawMessage } from './raw' import type { RawMessage } from './raw'
@ -16,7 +17,7 @@ export default class RawMessageReader extends PrimitiveReader {
if (tp === null) { return resetPointer() } if (tp === null) { return resetPointer() }
switch (tp) { switch (tp) {
case 0: { case 0: {
const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() } const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() }
return { return {
@ -24,7 +25,7 @@ export default class RawMessageReader extends PrimitiveReader {
timestamp, timestamp,
}; };
} }
case 4: { case 4: {
const url = this.readString(); if (url === null) { return resetPointer() } const url = this.readString(); if (url === null) { return resetPointer() }
const referrer = this.readString(); if (referrer === null) { return resetPointer() } const referrer = this.readString(); if (referrer === null) { return resetPointer() }
@ -36,7 +37,7 @@ export default class RawMessageReader extends PrimitiveReader {
navigationStart, navigationStart,
}; };
} }
case 5: { case 5: {
const width = this.readUint(); if (width === null) { return resetPointer() } const width = this.readUint(); if (width === null) { return resetPointer() }
const height = this.readUint(); if (height === null) { return resetPointer() } const height = this.readUint(); if (height === null) { return resetPointer() }
@ -46,7 +47,7 @@ export default class RawMessageReader extends PrimitiveReader {
height, height,
}; };
} }
case 6: { case 6: {
const x = this.readInt(); if (x === null) { return resetPointer() } const x = this.readInt(); if (x === null) { return resetPointer() }
const y = this.readInt(); if (y === null) { return resetPointer() } const y = this.readInt(); if (y === null) { return resetPointer() }
@ -56,7 +57,7 @@ export default class RawMessageReader extends PrimitiveReader {
y, y,
}; };
} }
case 7: { case 7: {
return { return {
@ -64,7 +65,7 @@ export default class RawMessageReader extends PrimitiveReader {
}; };
} }
case 8: { case 8: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const parentID = this.readUint(); if (parentID === null) { return resetPointer() } const parentID = this.readUint(); if (parentID === null) { return resetPointer() }
@ -80,7 +81,7 @@ export default class RawMessageReader extends PrimitiveReader {
svg, svg,
}; };
} }
case 9: { case 9: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const parentID = this.readUint(); if (parentID === null) { return resetPointer() } const parentID = this.readUint(); if (parentID === null) { return resetPointer() }
@ -92,7 +93,7 @@ export default class RawMessageReader extends PrimitiveReader {
index, index,
}; };
} }
case 10: { case 10: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const parentID = this.readUint(); if (parentID === null) { return resetPointer() } const parentID = this.readUint(); if (parentID === null) { return resetPointer() }
@ -104,7 +105,7 @@ export default class RawMessageReader extends PrimitiveReader {
index, index,
}; };
} }
case 11: { case 11: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
return { return {
@ -112,7 +113,7 @@ export default class RawMessageReader extends PrimitiveReader {
id, id,
}; };
} }
case 12: { case 12: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const name = this.readString(); if (name === null) { return resetPointer() } const name = this.readString(); if (name === null) { return resetPointer() }
@ -124,7 +125,7 @@ export default class RawMessageReader extends PrimitiveReader {
value, value,
}; };
} }
case 13: { case 13: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const name = this.readString(); if (name === null) { return resetPointer() } const name = this.readString(); if (name === null) { return resetPointer() }
@ -134,7 +135,7 @@ export default class RawMessageReader extends PrimitiveReader {
name, name,
}; };
} }
case 14: { case 14: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const data = this.readString(); if (data === null) { return resetPointer() } const data = this.readString(); if (data === null) { return resetPointer() }
@ -144,7 +145,7 @@ export default class RawMessageReader extends PrimitiveReader {
data, data,
}; };
} }
case 15: { case 15: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const data = this.readString(); if (data === null) { return resetPointer() } const data = this.readString(); if (data === null) { return resetPointer() }
@ -154,7 +155,7 @@ export default class RawMessageReader extends PrimitiveReader {
data, data,
}; };
} }
case 16: { case 16: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const x = this.readInt(); if (x === null) { return resetPointer() } const x = this.readInt(); if (x === null) { return resetPointer() }
@ -166,7 +167,7 @@ export default class RawMessageReader extends PrimitiveReader {
y, y,
}; };
} }
case 18: { case 18: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const value = this.readString(); if (value === null) { return resetPointer() } const value = this.readString(); if (value === null) { return resetPointer() }
@ -178,7 +179,7 @@ export default class RawMessageReader extends PrimitiveReader {
mask, mask,
}; };
} }
case 19: { case 19: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const checked = this.readBoolean(); if (checked === null) { return resetPointer() } const checked = this.readBoolean(); if (checked === null) { return resetPointer() }
@ -188,7 +189,7 @@ export default class RawMessageReader extends PrimitiveReader {
checked, checked,
}; };
} }
case 20: { case 20: {
const x = this.readUint(); if (x === null) { return resetPointer() } const x = this.readUint(); if (x === null) { return resetPointer() }
const y = this.readUint(); if (y === null) { return resetPointer() } const y = this.readUint(); if (y === null) { return resetPointer() }
@ -198,7 +199,7 @@ export default class RawMessageReader extends PrimitiveReader {
y, y,
}; };
} }
case 22: { case 22: {
const level = this.readString(); if (level === null) { return resetPointer() } const level = this.readString(); if (level === null) { return resetPointer() }
const value = this.readString(); if (value === null) { return resetPointer() } const value = this.readString(); if (value === null) { return resetPointer() }
@ -208,7 +209,7 @@ export default class RawMessageReader extends PrimitiveReader {
value, value,
}; };
} }
case 37: { case 37: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const rule = this.readString(); if (rule === null) { return resetPointer() } const rule = this.readString(); if (rule === null) { return resetPointer() }
@ -220,7 +221,7 @@ export default class RawMessageReader extends PrimitiveReader {
index, index,
}; };
} }
case 38: { case 38: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const index = this.readUint(); if (index === null) { return resetPointer() } const index = this.readUint(); if (index === null) { return resetPointer() }
@ -230,7 +231,7 @@ export default class RawMessageReader extends PrimitiveReader {
index, index,
}; };
} }
case 39: { case 39: {
const method = this.readString(); if (method === null) { return resetPointer() } const method = this.readString(); if (method === null) { return resetPointer() }
const url = this.readString(); if (url === null) { return resetPointer() } const url = this.readString(); if (url === null) { return resetPointer() }
@ -250,7 +251,7 @@ export default class RawMessageReader extends PrimitiveReader {
duration, duration,
}; };
} }
case 40: { case 40: {
const name = this.readString(); if (name === null) { return resetPointer() } const name = this.readString(); if (name === null) { return resetPointer() }
const duration = this.readUint(); if (duration === null) { return resetPointer() } const duration = this.readUint(); if (duration === null) { return resetPointer() }
@ -264,7 +265,7 @@ export default class RawMessageReader extends PrimitiveReader {
result, result,
}; };
} }
case 41: { case 41: {
const key = this.readString(); if (key === null) { return resetPointer() } const key = this.readString(); if (key === null) { return resetPointer() }
const value = this.readString(); if (value === null) { return resetPointer() } const value = this.readString(); if (value === null) { return resetPointer() }
@ -274,7 +275,7 @@ export default class RawMessageReader extends PrimitiveReader {
value, value,
}; };
} }
case 44: { case 44: {
const action = this.readString(); if (action === null) { return resetPointer() } const action = this.readString(); if (action === null) { return resetPointer() }
const state = this.readString(); if (state === null) { return resetPointer() } const state = this.readString(); if (state === null) { return resetPointer() }
@ -286,7 +287,7 @@ export default class RawMessageReader extends PrimitiveReader {
duration, duration,
}; };
} }
case 45: { case 45: {
const mutation = this.readString(); if (mutation === null) { return resetPointer() } const mutation = this.readString(); if (mutation === null) { return resetPointer() }
const state = this.readString(); if (state === null) { return resetPointer() } const state = this.readString(); if (state === null) { return resetPointer() }
@ -296,7 +297,7 @@ export default class RawMessageReader extends PrimitiveReader {
state, state,
}; };
} }
case 46: { case 46: {
const type = this.readString(); if (type === null) { return resetPointer() } const type = this.readString(); if (type === null) { return resetPointer() }
const payload = this.readString(); if (payload === null) { return resetPointer() } const payload = this.readString(); if (payload === null) { return resetPointer() }
@ -306,7 +307,7 @@ export default class RawMessageReader extends PrimitiveReader {
payload, payload,
}; };
} }
case 47: { case 47: {
const action = this.readString(); if (action === null) { return resetPointer() } const action = this.readString(); if (action === null) { return resetPointer() }
const state = this.readString(); if (state === null) { return resetPointer() } const state = this.readString(); if (state === null) { return resetPointer() }
@ -318,7 +319,7 @@ export default class RawMessageReader extends PrimitiveReader {
duration, duration,
}; };
} }
case 48: { case 48: {
const operationKind = this.readString(); if (operationKind === null) { return resetPointer() } const operationKind = this.readString(); if (operationKind === null) { return resetPointer() }
const operationName = this.readString(); if (operationName === null) { return resetPointer() } const operationName = this.readString(); if (operationName === null) { return resetPointer() }
@ -332,7 +333,7 @@ export default class RawMessageReader extends PrimitiveReader {
response, response,
}; };
} }
case 49: { case 49: {
const frames = this.readInt(); if (frames === null) { return resetPointer() } const frames = this.readInt(); if (frames === null) { return resetPointer() }
const ticks = this.readInt(); if (ticks === null) { return resetPointer() } const ticks = this.readInt(); if (ticks === null) { return resetPointer() }
@ -346,7 +347,7 @@ export default class RawMessageReader extends PrimitiveReader {
usedJSHeapSize, usedJSHeapSize,
}; };
} }
case 54: { case 54: {
const downlink = this.readUint(); if (downlink === null) { return resetPointer() } const downlink = this.readUint(); if (downlink === null) { return resetPointer() }
const type = this.readString(); if (type === null) { return resetPointer() } const type = this.readString(); if (type === null) { return resetPointer() }
@ -356,7 +357,7 @@ export default class RawMessageReader extends PrimitiveReader {
type, type,
}; };
} }
case 55: { case 55: {
const hidden = this.readBoolean(); if (hidden === null) { return resetPointer() } const hidden = this.readBoolean(); if (hidden === null) { return resetPointer() }
return { return {
@ -364,7 +365,7 @@ export default class RawMessageReader extends PrimitiveReader {
hidden, hidden,
}; };
} }
case 59: { case 59: {
const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() } const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() }
const duration = this.readUint(); if (duration === null) { return resetPointer() } const duration = this.readUint(); if (duration === null) { return resetPointer() }
@ -384,7 +385,7 @@ export default class RawMessageReader extends PrimitiveReader {
containerName, containerName,
}; };
} }
case 60: { case 60: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const name = this.readString(); if (name === null) { return resetPointer() } const name = this.readString(); if (name === null) { return resetPointer() }
@ -398,7 +399,7 @@ export default class RawMessageReader extends PrimitiveReader {
baseURL, baseURL,
}; };
} }
case 61: { case 61: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const data = this.readString(); if (data === null) { return resetPointer() } const data = this.readString(); if (data === null) { return resetPointer() }
@ -410,7 +411,7 @@ export default class RawMessageReader extends PrimitiveReader {
baseURL, baseURL,
}; };
} }
case 67: { case 67: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const rule = this.readString(); if (rule === null) { return resetPointer() } const rule = this.readString(); if (rule === null) { return resetPointer() }
@ -424,7 +425,7 @@ export default class RawMessageReader extends PrimitiveReader {
baseURL, baseURL,
}; };
} }
case 69: { case 69: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const hesitationTime = this.readUint(); if (hesitationTime === null) { return resetPointer() } const hesitationTime = this.readUint(); if (hesitationTime === null) { return resetPointer() }
@ -438,7 +439,7 @@ export default class RawMessageReader extends PrimitiveReader {
selector, selector,
}; };
} }
case 70: { case 70: {
const frameID = this.readUint(); if (frameID === null) { return resetPointer() } const frameID = this.readUint(); if (frameID === null) { return resetPointer() }
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
@ -448,7 +449,7 @@ export default class RawMessageReader extends PrimitiveReader {
id, id,
}; };
} }
case 71: { case 71: {
const sheetID = this.readUint(); if (sheetID === null) { return resetPointer() } const sheetID = this.readUint(); if (sheetID === null) { return resetPointer() }
const text = this.readString(); if (text === null) { return resetPointer() } const text = this.readString(); if (text === null) { return resetPointer() }
@ -460,7 +461,7 @@ export default class RawMessageReader extends PrimitiveReader {
baseURL, baseURL,
}; };
} }
case 72: { case 72: {
const sheetID = this.readUint(); if (sheetID === null) { return resetPointer() } const sheetID = this.readUint(); if (sheetID === null) { return resetPointer() }
const text = this.readString(); if (text === null) { return resetPointer() } const text = this.readString(); if (text === null) { return resetPointer() }
@ -470,7 +471,7 @@ export default class RawMessageReader extends PrimitiveReader {
text, text,
}; };
} }
case 73: { case 73: {
const sheetID = this.readUint(); if (sheetID === null) { return resetPointer() } const sheetID = this.readUint(); if (sheetID === null) { return resetPointer() }
const rule = this.readString(); if (rule === null) { return resetPointer() } const rule = this.readString(); if (rule === null) { return resetPointer() }
@ -484,7 +485,7 @@ export default class RawMessageReader extends PrimitiveReader {
baseURL, baseURL,
}; };
} }
case 74: { case 74: {
const sheetID = this.readUint(); if (sheetID === null) { return resetPointer() } const sheetID = this.readUint(); if (sheetID === null) { return resetPointer() }
const rule = this.readString(); if (rule === null) { return resetPointer() } const rule = this.readString(); if (rule === null) { return resetPointer() }
@ -496,7 +497,7 @@ export default class RawMessageReader extends PrimitiveReader {
index, index,
}; };
} }
case 75: { case 75: {
const sheetID = this.readUint(); if (sheetID === null) { return resetPointer() } const sheetID = this.readUint(); if (sheetID === null) { return resetPointer() }
const index = this.readUint(); if (index === null) { return resetPointer() } const index = this.readUint(); if (index === null) { return resetPointer() }
@ -506,7 +507,7 @@ export default class RawMessageReader extends PrimitiveReader {
index, index,
}; };
} }
case 76: { case 76: {
const sheetID = this.readUint(); if (sheetID === null) { return resetPointer() } const sheetID = this.readUint(); if (sheetID === null) { return resetPointer() }
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
@ -516,7 +517,7 @@ export default class RawMessageReader extends PrimitiveReader {
id, id,
}; };
} }
case 77: { case 77: {
const sheetID = this.readUint(); if (sheetID === null) { return resetPointer() } const sheetID = this.readUint(); if (sheetID === null) { return resetPointer() }
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
@ -526,7 +527,7 @@ export default class RawMessageReader extends PrimitiveReader {
id, id,
}; };
} }
case 79: { case 79: {
const mutation = this.readString(); if (mutation === null) { return resetPointer() } const mutation = this.readString(); if (mutation === null) { return resetPointer() }
const state = this.readString(); if (state === null) { return resetPointer() } const state = this.readString(); if (state === null) { return resetPointer() }
@ -536,11 +537,11 @@ export default class RawMessageReader extends PrimitiveReader {
state, state,
}; };
} }
case 83: { case 83: {
const id = this.readUint(); if (id === null) { return resetPointer() } const id = this.readUint(); if (id === null) { return resetPointer() }
const styles = this.readString(); if (styles === null) { return resetPointer() } const styles = this.readString(); if (styles === null) { return resetPointer() }
const sheetID = this.readString(); if (sheetID === null) { return resetPointer() } const sheetID = this.readUint(); if (sheetID === null) { return resetPointer() }
const baseURL = this.readString(); if (baseURL === null) { return resetPointer() } const baseURL = this.readString(); if (baseURL === null) { return resetPointer() }
return { return {
tp: "replace_vcss", tp: "replace_vcss",
@ -550,7 +551,7 @@ export default class RawMessageReader extends PrimitiveReader {
baseURL, baseURL,
}; };
} }
case 90: { case 90: {
const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() } const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() }
const projectID = this.readUint(); if (projectID === null) { return resetPointer() } const projectID = this.readUint(); if (projectID === null) { return resetPointer() }
@ -576,7 +577,7 @@ export default class RawMessageReader extends PrimitiveReader {
userCountry, userCountry,
}; };
} }
case 93: { case 93: {
const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() } const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() }
const length = this.readUint(); if (length === null) { return resetPointer() } const length = this.readUint(); if (length === null) { return resetPointer() }
@ -590,7 +591,7 @@ export default class RawMessageReader extends PrimitiveReader {
payload, payload,
}; };
} }
case 96: { case 96: {
const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() } const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() }
const length = this.readUint(); if (length === null) { return resetPointer() } const length = this.readUint(); if (length === null) { return resetPointer() }
@ -608,7 +609,7 @@ export default class RawMessageReader extends PrimitiveReader {
height, height,
}; };
} }
case 100: { case 100: {
const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() } const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() }
const length = this.readUint(); if (length === null) { return resetPointer() } const length = this.readUint(); if (length === null) { return resetPointer() }
@ -624,7 +625,7 @@ export default class RawMessageReader extends PrimitiveReader {
y, y,
}; };
} }
case 102: { case 102: {
const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() } const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() }
const length = this.readUint(); if (length === null) { return resetPointer() } const length = this.readUint(); if (length === null) { return resetPointer() }
@ -638,7 +639,7 @@ export default class RawMessageReader extends PrimitiveReader {
value, value,
}; };
} }
case 103: { case 103: {
const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() } const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() }
const length = this.readUint(); if (length === null) { return resetPointer() } const length = this.readUint(); if (length === null) { return resetPointer() }
@ -652,7 +653,7 @@ export default class RawMessageReader extends PrimitiveReader {
content, content,
}; };
} }
case 105: { case 105: {
const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() } const timestamp = this.readUint(); if (timestamp === null) { return resetPointer() }
const length = this.readUint(); if (length === null) { return resetPointer() } const length = this.readUint(); if (length === null) { return resetPointer() }
@ -676,7 +677,7 @@ export default class RawMessageReader extends PrimitiveReader {
status, status,
}; };
} }
default: default:
throw new Error(`Unrecognizable message type: ${ tp }; Pointer at the position ${this.p} of ${this.buf.length}`) throw new Error(`Unrecognizable message type: ${ tp }; Pointer at the position ${this.p} of ${this.buf.length}`)
return null; return null;

View file

@ -1,4 +1,5 @@
// Auto-generated, do not edit // Auto-generated, do not edit
/* eslint-disable */
import type { Timed } from './timed' import type { Timed } from './timed'
import type { RawMessage } from './raw' import type { RawMessage } from './raw'
@ -166,3 +167,4 @@ export type IosPerformanceEvent = RawIosPerformanceEvent & Timed
export type IosLog = RawIosLog & Timed export type IosLog = RawIosLog & Timed
export type IosNetworkCall = RawIosNetworkCall & Timed export type IosNetworkCall = RawIosNetworkCall & Timed

View file

@ -1,4 +1,5 @@
// Auto-generated, do not edit // Auto-generated, do not edit
/* eslint-disable */
export interface RawTimestamp { export interface RawTimestamp {
@ -310,7 +311,7 @@ export interface RawReplaceVcss {
tp: "replace_vcss", tp: "replace_vcss",
id: number, id: number,
styles: string, styles: string,
sheetID: string, sheetID: number,
baseURL: string, baseURL: string,
} }

View file

@ -1,4 +1,5 @@
// @ts-nocheck // @ts-nocheck
/* eslint-disable */
// Auto-generated, do not edit // Auto-generated, do not edit
export const TP_MAP = { export const TP_MAP = {

View file

@ -1,4 +1,5 @@
// Auto-generated, do not edit // Auto-generated, do not edit
/* eslint-disable */
import type { RawMessage } from './raw' import type { RawMessage } from './raw'
@ -44,7 +45,7 @@ type TrSetViewportScroll = [
type TrCreateDocument = [ type TrCreateDocument = [
type: 7, type: 7,
] ]
type TrCreateElementNode = [ type TrCreateElementNode = [
@ -392,22 +393,23 @@ type TrReplaceVCSS = [
type: 83, type: 83,
id: number, id: number,
styles: string, styles: string,
sheetID: string, sheetID: number,
baseURL: string, baseURL: string,
] ]
export type TrackerMessage = TrBatchMetadata | TrPartitionedMessage | TrTimestamp | TrSetPageLocation | TrSetViewportSize | TrSetViewportScroll | TrCreateDocument | TrCreateElementNode | TrCreateTextNode | TrMoveNode | TrRemoveNode | TrSetNodeAttribute | TrRemoveNodeAttribute | TrSetNodeData | TrSetNodeScroll | TrSetInputTarget | TrSetInputValue | TrSetInputChecked | TrMouseMove | TrConsoleLog | TrPageLoadTiming | TrPageRenderTiming | TrJSException | TrRawCustomEvent | TrUserID | TrUserAnonymousID | TrMetadata | TrCSSInsertRule | TrCSSDeleteRule | TrFetch | TrProfiler | TrOTable | TrStateAction | TrRedux | TrVuex | TrMobX | TrNgRx | TrGraphQL | TrPerformanceTrack | TrResourceTiming | TrConnectionInformation | TrSetPageVisibility | TrLongTask | TrSetNodeAttributeURLBased | TrSetCSSDataURLBased | TrTechnicalInfo | TrCustomIssue | TrCSSInsertRuleURLBased | TrMouseClick | TrCreateIFrameDocument | TrAdoptedSSReplaceURLBased | TrAdoptedSSInsertRuleURLBased | TrAdoptedSSDeleteRule | TrAdoptedSSAddOwner | TrAdoptedSSRemoveOwner | TrZustand | TrReplaceVCSS export type TrackerMessage = TrBatchMetadata | TrPartitionedMessage | TrTimestamp | TrSetPageLocation | TrSetViewportSize | TrSetViewportScroll | TrCreateDocument | TrCreateElementNode | TrCreateTextNode | TrMoveNode | TrRemoveNode | TrSetNodeAttribute | TrRemoveNodeAttribute | TrSetNodeData | TrSetNodeScroll | TrSetInputTarget | TrSetInputValue | TrSetInputChecked | TrMouseMove | TrConsoleLog | TrPageLoadTiming | TrPageRenderTiming | TrJSException | TrRawCustomEvent | TrUserID | TrUserAnonymousID | TrMetadata | TrCSSInsertRule | TrCSSDeleteRule | TrFetch | TrProfiler | TrOTable | TrStateAction | TrRedux | TrVuex | TrMobX | TrNgRx | TrGraphQL | TrPerformanceTrack | TrResourceTiming | TrConnectionInformation | TrSetPageVisibility | TrLongTask | TrSetNodeAttributeURLBased | TrSetCSSDataURLBased | TrTechnicalInfo | TrCustomIssue | TrCSSInsertRuleURLBased | TrMouseClick | TrCreateIFrameDocument | TrAdoptedSSReplaceURLBased | TrAdoptedSSInsertRuleURLBased | TrAdoptedSSDeleteRule | TrAdoptedSSAddOwner | TrAdoptedSSRemoveOwner | TrZustand | TrReplaceVCSS
export default function translate(tMsg: TrackerMessage): RawMessage | null { export default function translate(tMsg: TrackerMessage): RawMessage | null {
switch(tMsg[0]) { switch(tMsg[0]) {
case 0: { case 0: {
return { return {
tp: "timestamp", tp: "timestamp",
timestamp: tMsg[1], timestamp: tMsg[1],
} }
} }
case 4: { case 4: {
return { return {
tp: "set_page_location", tp: "set_page_location",
@ -416,7 +418,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
navigationStart: tMsg[3], navigationStart: tMsg[3],
} }
} }
case 5: { case 5: {
return { return {
tp: "set_viewport_size", tp: "set_viewport_size",
@ -424,7 +426,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
height: tMsg[2], height: tMsg[2],
} }
} }
case 6: { case 6: {
return { return {
tp: "set_viewport_scroll", tp: "set_viewport_scroll",
@ -432,14 +434,14 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
y: tMsg[2], y: tMsg[2],
} }
} }
case 7: { case 7: {
return { return {
tp: "create_document", tp: "create_document",
} }
} }
case 8: { case 8: {
return { return {
tp: "create_element_node", tp: "create_element_node",
@ -450,7 +452,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
svg: tMsg[5], svg: tMsg[5],
} }
} }
case 9: { case 9: {
return { return {
tp: "create_text_node", tp: "create_text_node",
@ -459,7 +461,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
index: tMsg[3], index: tMsg[3],
} }
} }
case 10: { case 10: {
return { return {
tp: "move_node", tp: "move_node",
@ -468,14 +470,14 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
index: tMsg[3], index: tMsg[3],
} }
} }
case 11: { case 11: {
return { return {
tp: "remove_node", tp: "remove_node",
id: tMsg[1], id: tMsg[1],
} }
} }
case 12: { case 12: {
return { return {
tp: "set_node_attribute", tp: "set_node_attribute",
@ -484,7 +486,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
value: tMsg[3], value: tMsg[3],
} }
} }
case 13: { case 13: {
return { return {
tp: "remove_node_attribute", tp: "remove_node_attribute",
@ -492,7 +494,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
name: tMsg[2], name: tMsg[2],
} }
} }
case 14: { case 14: {
return { return {
tp: "set_node_data", tp: "set_node_data",
@ -500,7 +502,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
data: tMsg[2], data: tMsg[2],
} }
} }
case 16: { case 16: {
return { return {
tp: "set_node_scroll", tp: "set_node_scroll",
@ -509,7 +511,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
y: tMsg[3], y: tMsg[3],
} }
} }
case 18: { case 18: {
return { return {
tp: "set_input_value", tp: "set_input_value",
@ -518,7 +520,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
mask: tMsg[3], mask: tMsg[3],
} }
} }
case 19: { case 19: {
return { return {
tp: "set_input_checked", tp: "set_input_checked",
@ -526,7 +528,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
checked: tMsg[2], checked: tMsg[2],
} }
} }
case 20: { case 20: {
return { return {
tp: "mouse_move", tp: "mouse_move",
@ -534,7 +536,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
y: tMsg[2], y: tMsg[2],
} }
} }
case 22: { case 22: {
return { return {
tp: "console_log", tp: "console_log",
@ -542,7 +544,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
value: tMsg[2], value: tMsg[2],
} }
} }
case 37: { case 37: {
return { return {
tp: "css_insert_rule", tp: "css_insert_rule",
@ -551,7 +553,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
index: tMsg[3], index: tMsg[3],
} }
} }
case 38: { case 38: {
return { return {
tp: "css_delete_rule", tp: "css_delete_rule",
@ -559,7 +561,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
index: tMsg[2], index: tMsg[2],
} }
} }
case 39: { case 39: {
return { return {
tp: "fetch", tp: "fetch",
@ -572,7 +574,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
duration: tMsg[7], duration: tMsg[7],
} }
} }
case 40: { case 40: {
return { return {
tp: "profiler", tp: "profiler",
@ -582,7 +584,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
result: tMsg[4], result: tMsg[4],
} }
} }
case 41: { case 41: {
return { return {
tp: "o_table", tp: "o_table",
@ -590,7 +592,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
value: tMsg[2], value: tMsg[2],
} }
} }
case 44: { case 44: {
return { return {
tp: "redux", tp: "redux",
@ -599,7 +601,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
duration: tMsg[3], duration: tMsg[3],
} }
} }
case 45: { case 45: {
return { return {
tp: "vuex", tp: "vuex",
@ -607,7 +609,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
state: tMsg[2], state: tMsg[2],
} }
} }
case 46: { case 46: {
return { return {
tp: "mob_x", tp: "mob_x",
@ -615,7 +617,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
payload: tMsg[2], payload: tMsg[2],
} }
} }
case 47: { case 47: {
return { return {
tp: "ng_rx", tp: "ng_rx",
@ -624,7 +626,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
duration: tMsg[3], duration: tMsg[3],
} }
} }
case 48: { case 48: {
return { return {
tp: "graph_ql", tp: "graph_ql",
@ -634,7 +636,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
response: tMsg[4], response: tMsg[4],
} }
} }
case 49: { case 49: {
return { return {
tp: "performance_track", tp: "performance_track",
@ -644,7 +646,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
usedJSHeapSize: tMsg[4], usedJSHeapSize: tMsg[4],
} }
} }
case 54: { case 54: {
return { return {
tp: "connection_information", tp: "connection_information",
@ -652,14 +654,14 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
type: tMsg[2], type: tMsg[2],
} }
} }
case 55: { case 55: {
return { return {
tp: "set_page_visibility", tp: "set_page_visibility",
hidden: tMsg[1], hidden: tMsg[1],
} }
} }
case 59: { case 59: {
return { return {
tp: "long_task", tp: "long_task",
@ -672,7 +674,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
containerName: tMsg[7], containerName: tMsg[7],
} }
} }
case 60: { case 60: {
return { return {
tp: "set_node_attribute_url_based", tp: "set_node_attribute_url_based",
@ -682,7 +684,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
baseURL: tMsg[4], baseURL: tMsg[4],
} }
} }
case 61: { case 61: {
return { return {
tp: "set_css_data_url_based", tp: "set_css_data_url_based",
@ -691,7 +693,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
baseURL: tMsg[3], baseURL: tMsg[3],
} }
} }
case 67: { case 67: {
return { return {
tp: "css_insert_rule_url_based", tp: "css_insert_rule_url_based",
@ -701,7 +703,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
baseURL: tMsg[4], baseURL: tMsg[4],
} }
} }
case 69: { case 69: {
return { return {
tp: "mouse_click", tp: "mouse_click",
@ -711,7 +713,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
selector: tMsg[4], selector: tMsg[4],
} }
} }
case 70: { case 70: {
return { return {
tp: "create_i_frame_document", tp: "create_i_frame_document",
@ -719,7 +721,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
id: tMsg[2], id: tMsg[2],
} }
} }
case 71: { case 71: {
return { return {
tp: "adopted_ss_replace_url_based", tp: "adopted_ss_replace_url_based",
@ -728,7 +730,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
baseURL: tMsg[3], baseURL: tMsg[3],
} }
} }
case 73: { case 73: {
return { return {
tp: "adopted_ss_insert_rule_url_based", tp: "adopted_ss_insert_rule_url_based",
@ -738,7 +740,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
baseURL: tMsg[4], baseURL: tMsg[4],
} }
} }
case 75: { case 75: {
return { return {
tp: "adopted_ss_delete_rule", tp: "adopted_ss_delete_rule",
@ -746,7 +748,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
index: tMsg[2], index: tMsg[2],
} }
} }
case 76: { case 76: {
return { return {
tp: "adopted_ss_add_owner", tp: "adopted_ss_add_owner",
@ -754,7 +756,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
id: tMsg[2], id: tMsg[2],
} }
} }
case 77: { case 77: {
return { return {
tp: "adopted_ss_remove_owner", tp: "adopted_ss_remove_owner",
@ -762,7 +764,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
id: tMsg[2], id: tMsg[2],
} }
} }
case 79: { case 79: {
return { return {
tp: "zustand", tp: "zustand",
@ -770,7 +772,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
state: tMsg[2], state: tMsg[2],
} }
} }
case 83: { case 83: {
return { return {
tp: "replace_vcss", tp: "replace_vcss",
@ -780,7 +782,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
baseURL: tMsg[4], baseURL: tMsg[4],
} }
} }
default: default:
return null return null
} }

View file

@ -464,6 +464,6 @@ end
message 83, 'ReplaceVCSS' do message 83, 'ReplaceVCSS' do
uint 'ID' uint 'ID'
string 'Styles' string 'Styles'
string 'SheetID' uint 'SheetID'
string 'BaseURL' string 'BaseURL'
end end

View file

@ -1,4 +1,5 @@
// Auto-generated, do not edit // Auto-generated, do not edit
/* eslint-disable */
import PrimitiveReader from './PrimitiveReader' import PrimitiveReader from './PrimitiveReader'
import type { RawMessage } from './raw' import type { RawMessage } from './raw'
@ -18,12 +19,12 @@ export default class RawMessageReader extends PrimitiveReader {
switch (tp) { switch (tp) {
<% $messages.select { |msg| msg.replayer }.each do |msg| %> <% $messages.select { |msg| msg.replayer }.each do |msg| %>
case <%= msg.id %>: { case <%= msg.id %>: {
<%= msg.attributes.map { |attr| <%= msg.attributes.map { |attr|
" const #{attr.name.camel_case} = this.read#{attr.type.to_s.pascal_case}(); if (#{attr.name.camel_case} === null) { return resetPointer() }" }.join "\n" %> " const #{attr.name.camel_case} = this.read#{attr.type.to_s.pascal_case}(); if (#{attr.name.camel_case} === null) { return resetPointer() }" }.join "\n" %>
return { return {
tp: "<%= msg.name.snake_case %>", tp: "<%= msg.name.snake_case %>",
<%= msg.attributes.map { |attr| <%= msg.attributes.map { |attr|
" #{attr.name.camel_case}," }.join "\n" %> " #{attr.name.camel_case}," }.join "\n" %>
}; };
} }
<% end %> <% end %>

View file

@ -1,8 +1,9 @@
// Auto-generated, do not edit // Auto-generated, do not edit
/* eslint-disable */
import type { Timed } from './timed' import type { Timed } from './timed'
import type { RawMessage } from './raw' import type { RawMessage } from './raw'
import type { import type {
<%= $messages.select { |msg| msg.replayer }.map { |msg| " Raw#{msg.name.snake_case.pascal_case}," }.join "\n" %> <%= $messages.select { |msg| msg.replayer }.map { |msg| " Raw#{msg.name.snake_case.pascal_case}," }.join "\n" %>
} from './raw' } from './raw'
@ -10,4 +11,4 @@ export type Message = RawMessage & Timed
<% $messages.select { |msg| msg.replayer }.each do |msg| %> <% $messages.select { |msg| msg.replayer }.each do |msg| %>
export type <%= msg.name.snake_case.pascal_case %> = Raw<%= msg.name.snake_case.pascal_case %> & Timed export type <%= msg.name.snake_case.pascal_case %> = Raw<%= msg.name.snake_case.pascal_case %> & Timed
<% end %> <% end %>

View file

@ -1,4 +1,5 @@
// Auto-generated, do not edit // Auto-generated, do not edit
/* eslint-disable */
<% $messages.select { |msg| msg.replayer }.each do |msg| %> <% $messages.select { |msg| msg.replayer }.each do |msg| %>
export interface Raw<%= msg.name.snake_case.pascal_case %> { export interface Raw<%= msg.name.snake_case.pascal_case %> {

View file

@ -1,8 +1,7 @@
// @ts-nocheck // @ts-nocheck
/* eslint-disable */
// Auto-generated, do not edit // Auto-generated, do not edit
export const TP_MAP = { export const TP_MAP = {
<%= $messages.select { |msg| msg.tracker || msg.replayer }.map { |msg| " #{msg.id}: \"#{msg.name.snake_case}\"," }.join "\n" %> <%= $messages.select { |msg| msg.tracker || msg.replayer }.map { |msg| " #{msg.id}: \"#{msg.name.snake_case}\"," }.join "\n" %>
} as const } as const

View file

@ -1,6 +1,7 @@
// Auto-generated, do not edit // Auto-generated, do not edit
/* eslint-disable */
import type { RawMessage } from './raw' import type { RawMessage } from './raw'
<% $messages.select { |msg| msg.tracker }.each do |msg| %> <% $messages.select { |msg| msg.tracker }.each do |msg| %>
type Tr<%= msg.name %> = [ type Tr<%= msg.name %> = [
@ -16,7 +17,7 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
<% $messages.select { |msg| msg.replayer & msg.tracker }.each do |msg| %> <% $messages.select { |msg| msg.replayer & msg.tracker }.each do |msg| %>
case <%= msg.id %>: { case <%= msg.id %>: {
return { return {
tp: "<%= msg.name.snake_case %>", tp: "<%= msg.name.snake_case %>",
<%= msg.attributes.map.with_index { |attr, i| "#{attr.name.camel_case}: tMsg[#{i+1}]," }.join "\n " %> <%= msg.attributes.map.with_index { |attr, i| "#{attr.name.camel_case}: tMsg[#{i+1}]," }.join "\n " %>
} }
} }
@ -25,4 +26,4 @@ export default function translate(tMsg: TrackerMessage): RawMessage | null {
return null return null
} }
} }

View file

@ -1,4 +1,5 @@
// Auto-generated, do not edit // Auto-generated, do not edit
/* eslint-disable */
export declare const enum Type { export declare const enum Type {
<%= $messages.select { |msg| msg.tracker }.map { |msg| "#{ msg.name } = #{ msg.id }," }.join "\n " %> <%= $messages.select { |msg| msg.tracker }.map { |msg| "#{ msg.name } = #{ msg.id }," }.join "\n " %>

View file

@ -1,4 +1,5 @@
// Auto-generated, do not edit // Auto-generated, do not edit
/* eslint-disable */
import * as Messages from '../../common/messages.gen.js' import * as Messages from '../../common/messages.gen.js'
export { default } from '../../common/messages.gen.js' export { default } from '../../common/messages.gen.js'
@ -7,7 +8,7 @@ export { default } from '../../common/messages.gen.js'
export function <%= msg.name %>( export function <%= msg.name %>(
<%= msg.attributes.map { |attr| "#{attr.name.camel_case}: #{attr.type_js}," }.join "\n " %> <%= msg.attributes.map { |attr| "#{attr.name.camel_case}: #{attr.type_js}," }.join "\n " %>
): Messages.<%= msg.name %> { ): Messages.<%= msg.name %> {
return [ return [
Messages.Type.<%= msg.name %>, Messages.Type.<%= msg.name %>,
<%= msg.attributes.map { |attr| "#{attr.name.camel_case}," }.join "\n " %> <%= msg.attributes.map { |attr| "#{attr.name.camel_case}," }.join "\n " %>
] ]

View file

@ -1,4 +1,5 @@
// Auto-generated, do not edit // Auto-generated, do not edit
/* eslint-disable */
import * as Messages from '../common/messages.gen.js' import * as Messages from '../common/messages.gen.js'
import Message from '../common/messages.gen.js' import Message from '../common/messages.gen.js'
@ -15,6 +16,5 @@ export default class MessageEncoder extends PrimitiveEncoder {
<% end %> <% end %>
} }
} }
}
}

View file

@ -34,7 +34,7 @@ module.exports = {
'@typescript-eslint/no-unsafe-member-access': 'off', '@typescript-eslint/no-unsafe-member-access': 'off',
'@typescript-eslint/no-unsafe-call': 'off', '@typescript-eslint/no-unsafe-call': 'off',
'@typescript-eslint/restrict-plus-operands': 'warn', '@typescript-eslint/restrict-plus-operands': 'warn',
'@typescript-eslint/no-unsafe-return': 'warn', '@typescript-eslint/no-unsafe-return': 'off',
'no-useless-escape': 'warn', 'no-useless-escape': 'warn',
'no-control-regex': 'warn', 'no-control-regex': 'warn',
'@typescript-eslint/restrict-template-expressions': 'warn', '@typescript-eslint/restrict-template-expressions': 'warn',

View file

@ -1,4 +1,5 @@
// Auto-generated, do not edit // Auto-generated, do not edit
/* eslint-disable */
export declare const enum Type { export declare const enum Type {
BatchMetadata = 81, BatchMetadata = 81,
@ -102,7 +103,7 @@ export type SetViewportScroll = [
export type CreateDocument = [ export type CreateDocument = [
/*type:*/ Type.CreateDocument, /*type:*/ Type.CreateDocument,
] ]
export type CreateElementNode = [ export type CreateElementNode = [
@ -450,11 +451,10 @@ export type ReplaceVCSS = [
/*type:*/ Type.ReplaceVCSS, /*type:*/ Type.ReplaceVCSS,
/*id:*/ number, /*id:*/ number,
/*styles:*/ string, /*styles:*/ string,
/*sheetID:*/ string, /*sheetID:*/ number,
/*baseURL:*/ string, /*baseURL:*/ string,
] ]
type Message = BatchMetadata | PartitionedMessage | Timestamp | SetPageLocation | SetViewportSize | SetViewportScroll | CreateDocument | CreateElementNode | CreateTextNode | MoveNode | RemoveNode | SetNodeAttribute | RemoveNodeAttribute | SetNodeData | SetNodeScroll | SetInputTarget | SetInputValue | SetInputChecked | MouseMove | ConsoleLog | PageLoadTiming | PageRenderTiming | JSException | RawCustomEvent | UserID | UserAnonymousID | Metadata | CSSInsertRule | CSSDeleteRule | Fetch | Profiler | OTable | StateAction | Redux | Vuex | MobX | NgRx | GraphQL | PerformanceTrack | ResourceTiming | ConnectionInformation | SetPageVisibility | LongTask | SetNodeAttributeURLBased | SetCSSDataURLBased | TechnicalInfo | CustomIssue | CSSInsertRuleURLBased | MouseClick | CreateIFrameDocument | AdoptedSSReplaceURLBased | AdoptedSSInsertRuleURLBased | AdoptedSSDeleteRule | AdoptedSSAddOwner | AdoptedSSRemoveOwner | Zustand | ReplaceVCSS type Message = BatchMetadata | PartitionedMessage | Timestamp | SetPageLocation | SetViewportSize | SetViewportScroll | CreateDocument | CreateElementNode | CreateTextNode | MoveNode | RemoveNode | SetNodeAttribute | RemoveNodeAttribute | SetNodeData | SetNodeScroll | SetInputTarget | SetInputValue | SetInputChecked | MouseMove | ConsoleLog | PageLoadTiming | PageRenderTiming | JSException | RawCustomEvent | UserID | UserAnonymousID | Metadata | CSSInsertRule | CSSDeleteRule | Fetch | Profiler | OTable | StateAction | Redux | Vuex | MobX | NgRx | GraphQL | PerformanceTrack | ResourceTiming | ConnectionInformation | SetPageVisibility | LongTask | SetNodeAttributeURLBased | SetCSSDataURLBased | TechnicalInfo | CustomIssue | CSSInsertRuleURLBased | MouseClick | CreateIFrameDocument | AdoptedSSReplaceURLBased | AdoptedSSInsertRuleURLBased | AdoptedSSDeleteRule | AdoptedSSAddOwner | AdoptedSSRemoveOwner | Zustand | ReplaceVCSS
export default Message export default Message

View file

@ -1,4 +1,5 @@
// Auto-generated, do not edit // Auto-generated, do not edit
/* eslint-disable */
import * as Messages from '../../common/messages.gen.js' import * as Messages from '../../common/messages.gen.js'
export { default } from '../../common/messages.gen.js' export { default } from '../../common/messages.gen.js'
@ -77,11 +78,11 @@ export function SetViewportScroll(
} }
export function CreateDocument( export function CreateDocument(
): Messages.CreateDocument { ): Messages.CreateDocument {
return [ return [
Messages.Type.CreateDocument, Messages.Type.CreateDocument,
] ]
} }
@ -721,7 +722,7 @@ export function Zustand(
export function ReplaceVCSS( export function ReplaceVCSS(
id: number, id: number,
styles: string, styles: string,
sheetID: string, sheetID: number,
baseURL: string, baseURL: string,
): Messages.ReplaceVCSS { ): Messages.ReplaceVCSS {
return [ return [
@ -732,3 +733,4 @@ export function ReplaceVCSS(
baseURL, baseURL,
] ]
} }

View file

@ -50,7 +50,7 @@ export default function (app: App | null) {
} }
} }
if (parentNodeID && id >= 0) { if (parentNodeID && id >= 0) {
app.send(ReplaceVCSS(parentNodeID, entireStyle, id.toString(), app.getBaseHref())) app.send(ReplaceVCSS(parentNodeID, entireStyle, id, app.getBaseHref()))
} }
} else { } else {
app.debug.error('Owner Node not found') app.debug.error('Owner Node not found')

View file

@ -1,4 +1,5 @@
// Auto-generated, do not edit // Auto-generated, do not edit
/* eslint-disable */
import * as Messages from '../common/messages.gen.js' import * as Messages from '../common/messages.gen.js'
import Message from '../common/messages.gen.js' import Message from '../common/messages.gen.js'
@ -8,235 +9,235 @@ import PrimitiveEncoder from './PrimitiveEncoder.js'
export default class MessageEncoder extends PrimitiveEncoder { export default class MessageEncoder extends PrimitiveEncoder {
encode(msg: Message): boolean { encode(msg: Message): boolean {
switch(msg[0]) { switch(msg[0]) {
case Messages.Type.BatchMetadata: case Messages.Type.BatchMetadata:
return this.uint(msg[1]) && this.uint(msg[2]) && this.uint(msg[3]) && this.int(msg[4]) && this.string(msg[5]) return this.uint(msg[1]) && this.uint(msg[2]) && this.uint(msg[3]) && this.int(msg[4]) && this.string(msg[5])
break break
case Messages.Type.PartitionedMessage: case Messages.Type.PartitionedMessage:
return this.uint(msg[1]) && this.uint(msg[2]) return this.uint(msg[1]) && this.uint(msg[2])
break break
case Messages.Type.Timestamp: case Messages.Type.Timestamp:
return this.uint(msg[1]) return this.uint(msg[1])
break break
case Messages.Type.SetPageLocation: case Messages.Type.SetPageLocation:
return this.string(msg[1]) && this.string(msg[2]) && this.uint(msg[3]) return this.string(msg[1]) && this.string(msg[2]) && this.uint(msg[3])
break break
case Messages.Type.SetViewportSize: case Messages.Type.SetViewportSize:
return this.uint(msg[1]) && this.uint(msg[2]) return this.uint(msg[1]) && this.uint(msg[2])
break break
case Messages.Type.SetViewportScroll: case Messages.Type.SetViewportScroll:
return this.int(msg[1]) && this.int(msg[2]) return this.int(msg[1]) && this.int(msg[2])
break break
case Messages.Type.CreateDocument: case Messages.Type.CreateDocument:
return true return true
break break
case Messages.Type.CreateElementNode: case Messages.Type.CreateElementNode:
return this.uint(msg[1]) && this.uint(msg[2]) && this.uint(msg[3]) && this.string(msg[4]) && this.boolean(msg[5]) return this.uint(msg[1]) && this.uint(msg[2]) && this.uint(msg[3]) && this.string(msg[4]) && this.boolean(msg[5])
break break
case Messages.Type.CreateTextNode: case Messages.Type.CreateTextNode:
return this.uint(msg[1]) && this.uint(msg[2]) && this.uint(msg[3]) return this.uint(msg[1]) && this.uint(msg[2]) && this.uint(msg[3])
break break
case Messages.Type.MoveNode: case Messages.Type.MoveNode:
return this.uint(msg[1]) && this.uint(msg[2]) && this.uint(msg[3]) return this.uint(msg[1]) && this.uint(msg[2]) && this.uint(msg[3])
break break
case Messages.Type.RemoveNode: case Messages.Type.RemoveNode:
return this.uint(msg[1]) return this.uint(msg[1])
break break
case Messages.Type.SetNodeAttribute: case Messages.Type.SetNodeAttribute:
return this.uint(msg[1]) && this.string(msg[2]) && this.string(msg[3]) return this.uint(msg[1]) && this.string(msg[2]) && this.string(msg[3])
break break
case Messages.Type.RemoveNodeAttribute: case Messages.Type.RemoveNodeAttribute:
return this.uint(msg[1]) && this.string(msg[2]) return this.uint(msg[1]) && this.string(msg[2])
break break
case Messages.Type.SetNodeData: case Messages.Type.SetNodeData:
return this.uint(msg[1]) && this.string(msg[2]) return this.uint(msg[1]) && this.string(msg[2])
break break
case Messages.Type.SetNodeScroll: case Messages.Type.SetNodeScroll:
return this.uint(msg[1]) && this.int(msg[2]) && this.int(msg[3]) return this.uint(msg[1]) && this.int(msg[2]) && this.int(msg[3])
break break
case Messages.Type.SetInputTarget: case Messages.Type.SetInputTarget:
return this.uint(msg[1]) && this.string(msg[2]) return this.uint(msg[1]) && this.string(msg[2])
break break
case Messages.Type.SetInputValue: case Messages.Type.SetInputValue:
return this.uint(msg[1]) && this.string(msg[2]) && this.int(msg[3]) return this.uint(msg[1]) && this.string(msg[2]) && this.int(msg[3])
break break
case Messages.Type.SetInputChecked: case Messages.Type.SetInputChecked:
return this.uint(msg[1]) && this.boolean(msg[2]) return this.uint(msg[1]) && this.boolean(msg[2])
break break
case Messages.Type.MouseMove: case Messages.Type.MouseMove:
return this.uint(msg[1]) && this.uint(msg[2]) return this.uint(msg[1]) && this.uint(msg[2])
break break
case Messages.Type.ConsoleLog: case Messages.Type.ConsoleLog:
return this.string(msg[1]) && this.string(msg[2]) return this.string(msg[1]) && this.string(msg[2])
break break
case Messages.Type.PageLoadTiming: case Messages.Type.PageLoadTiming:
return this.uint(msg[1]) && this.uint(msg[2]) && this.uint(msg[3]) && this.uint(msg[4]) && this.uint(msg[5]) && this.uint(msg[6]) && this.uint(msg[7]) && this.uint(msg[8]) && this.uint(msg[9]) return this.uint(msg[1]) && this.uint(msg[2]) && this.uint(msg[3]) && this.uint(msg[4]) && this.uint(msg[5]) && this.uint(msg[6]) && this.uint(msg[7]) && this.uint(msg[8]) && this.uint(msg[9])
break break
case Messages.Type.PageRenderTiming: case Messages.Type.PageRenderTiming:
return this.uint(msg[1]) && this.uint(msg[2]) && this.uint(msg[3]) return this.uint(msg[1]) && this.uint(msg[2]) && this.uint(msg[3])
break break
case Messages.Type.JSException: case Messages.Type.JSException:
return this.string(msg[1]) && this.string(msg[2]) && this.string(msg[3]) return this.string(msg[1]) && this.string(msg[2]) && this.string(msg[3])
break break
case Messages.Type.RawCustomEvent: case Messages.Type.RawCustomEvent:
return this.string(msg[1]) && this.string(msg[2]) return this.string(msg[1]) && this.string(msg[2])
break break
case Messages.Type.UserID: case Messages.Type.UserID:
return this.string(msg[1]) return this.string(msg[1])
break break
case Messages.Type.UserAnonymousID: case Messages.Type.UserAnonymousID:
return this.string(msg[1]) return this.string(msg[1])
break break
case Messages.Type.Metadata: case Messages.Type.Metadata:
return this.string(msg[1]) && this.string(msg[2]) return this.string(msg[1]) && this.string(msg[2])
break break
case Messages.Type.CSSInsertRule: case Messages.Type.CSSInsertRule:
return this.uint(msg[1]) && this.string(msg[2]) && this.uint(msg[3]) return this.uint(msg[1]) && this.string(msg[2]) && this.uint(msg[3])
break break
case Messages.Type.CSSDeleteRule: case Messages.Type.CSSDeleteRule:
return this.uint(msg[1]) && this.uint(msg[2]) return this.uint(msg[1]) && this.uint(msg[2])
break break
case Messages.Type.Fetch: case Messages.Type.Fetch:
return this.string(msg[1]) && this.string(msg[2]) && this.string(msg[3]) && this.string(msg[4]) && this.uint(msg[5]) && this.uint(msg[6]) && this.uint(msg[7]) return this.string(msg[1]) && this.string(msg[2]) && this.string(msg[3]) && this.string(msg[4]) && this.uint(msg[5]) && this.uint(msg[6]) && this.uint(msg[7])
break break
case Messages.Type.Profiler: case Messages.Type.Profiler:
return this.string(msg[1]) && this.uint(msg[2]) && this.string(msg[3]) && this.string(msg[4]) return this.string(msg[1]) && this.uint(msg[2]) && this.string(msg[3]) && this.string(msg[4])
break break
case Messages.Type.OTable: case Messages.Type.OTable:
return this.string(msg[1]) && this.string(msg[2]) return this.string(msg[1]) && this.string(msg[2])
break break
case Messages.Type.StateAction: case Messages.Type.StateAction:
return this.string(msg[1]) return this.string(msg[1])
break break
case Messages.Type.Redux: case Messages.Type.Redux:
return this.string(msg[1]) && this.string(msg[2]) && this.uint(msg[3]) return this.string(msg[1]) && this.string(msg[2]) && this.uint(msg[3])
break break
case Messages.Type.Vuex: case Messages.Type.Vuex:
return this.string(msg[1]) && this.string(msg[2]) return this.string(msg[1]) && this.string(msg[2])
break break
case Messages.Type.MobX: case Messages.Type.MobX:
return this.string(msg[1]) && this.string(msg[2]) return this.string(msg[1]) && this.string(msg[2])
break break
case Messages.Type.NgRx: case Messages.Type.NgRx:
return this.string(msg[1]) && this.string(msg[2]) && this.uint(msg[3]) return this.string(msg[1]) && this.string(msg[2]) && this.uint(msg[3])
break break
case Messages.Type.GraphQL: case Messages.Type.GraphQL:
return this.string(msg[1]) && this.string(msg[2]) && this.string(msg[3]) && this.string(msg[4]) return this.string(msg[1]) && this.string(msg[2]) && this.string(msg[3]) && this.string(msg[4])
break break
case Messages.Type.PerformanceTrack: case Messages.Type.PerformanceTrack:
return this.int(msg[1]) && this.int(msg[2]) && this.uint(msg[3]) && this.uint(msg[4]) return this.int(msg[1]) && this.int(msg[2]) && this.uint(msg[3]) && this.uint(msg[4])
break break
case Messages.Type.ResourceTiming: case Messages.Type.ResourceTiming:
return this.uint(msg[1]) && this.uint(msg[2]) && this.uint(msg[3]) && this.uint(msg[4]) && this.uint(msg[5]) && this.uint(msg[6]) && this.string(msg[7]) && this.string(msg[8]) return this.uint(msg[1]) && this.uint(msg[2]) && this.uint(msg[3]) && this.uint(msg[4]) && this.uint(msg[5]) && this.uint(msg[6]) && this.string(msg[7]) && this.string(msg[8])
break break
case Messages.Type.ConnectionInformation: case Messages.Type.ConnectionInformation:
return this.uint(msg[1]) && this.string(msg[2]) return this.uint(msg[1]) && this.string(msg[2])
break break
case Messages.Type.SetPageVisibility: case Messages.Type.SetPageVisibility:
return this.boolean(msg[1]) return this.boolean(msg[1])
break break
case Messages.Type.LongTask: case Messages.Type.LongTask:
return this.uint(msg[1]) && this.uint(msg[2]) && this.uint(msg[3]) && this.uint(msg[4]) && this.string(msg[5]) && this.string(msg[6]) && this.string(msg[7]) return this.uint(msg[1]) && this.uint(msg[2]) && this.uint(msg[3]) && this.uint(msg[4]) && this.string(msg[5]) && this.string(msg[6]) && this.string(msg[7])
break break
case Messages.Type.SetNodeAttributeURLBased: case Messages.Type.SetNodeAttributeURLBased:
return this.uint(msg[1]) && this.string(msg[2]) && this.string(msg[3]) && this.string(msg[4]) return this.uint(msg[1]) && this.string(msg[2]) && this.string(msg[3]) && this.string(msg[4])
break break
case Messages.Type.SetCSSDataURLBased: case Messages.Type.SetCSSDataURLBased:
return this.uint(msg[1]) && this.string(msg[2]) && this.string(msg[3]) return this.uint(msg[1]) && this.string(msg[2]) && this.string(msg[3])
break break
case Messages.Type.TechnicalInfo: case Messages.Type.TechnicalInfo:
return this.string(msg[1]) && this.string(msg[2]) return this.string(msg[1]) && this.string(msg[2])
break break
case Messages.Type.CustomIssue: case Messages.Type.CustomIssue:
return this.string(msg[1]) && this.string(msg[2]) return this.string(msg[1]) && this.string(msg[2])
break break
case Messages.Type.CSSInsertRuleURLBased: case Messages.Type.CSSInsertRuleURLBased:
return this.uint(msg[1]) && this.string(msg[2]) && this.uint(msg[3]) && this.string(msg[4]) return this.uint(msg[1]) && this.string(msg[2]) && this.uint(msg[3]) && this.string(msg[4])
break break
case Messages.Type.MouseClick: case Messages.Type.MouseClick:
return this.uint(msg[1]) && this.uint(msg[2]) && this.string(msg[3]) && this.string(msg[4]) return this.uint(msg[1]) && this.uint(msg[2]) && this.string(msg[3]) && this.string(msg[4])
break break
case Messages.Type.CreateIFrameDocument: case Messages.Type.CreateIFrameDocument:
return this.uint(msg[1]) && this.uint(msg[2]) return this.uint(msg[1]) && this.uint(msg[2])
break break
case Messages.Type.AdoptedSSReplaceURLBased: case Messages.Type.AdoptedSSReplaceURLBased:
return this.uint(msg[1]) && this.string(msg[2]) && this.string(msg[3]) return this.uint(msg[1]) && this.string(msg[2]) && this.string(msg[3])
break break
case Messages.Type.AdoptedSSInsertRuleURLBased: case Messages.Type.AdoptedSSInsertRuleURLBased:
return this.uint(msg[1]) && this.string(msg[2]) && this.uint(msg[3]) && this.string(msg[4]) return this.uint(msg[1]) && this.string(msg[2]) && this.uint(msg[3]) && this.string(msg[4])
break break
case Messages.Type.AdoptedSSDeleteRule: case Messages.Type.AdoptedSSDeleteRule:
return this.uint(msg[1]) && this.uint(msg[2]) return this.uint(msg[1]) && this.uint(msg[2])
break break
case Messages.Type.AdoptedSSAddOwner: case Messages.Type.AdoptedSSAddOwner:
return this.uint(msg[1]) && this.uint(msg[2]) return this.uint(msg[1]) && this.uint(msg[2])
break break
case Messages.Type.AdoptedSSRemoveOwner: case Messages.Type.AdoptedSSRemoveOwner:
return this.uint(msg[1]) && this.uint(msg[2]) return this.uint(msg[1]) && this.uint(msg[2])
break break
case Messages.Type.Zustand: case Messages.Type.Zustand:
return this.string(msg[1]) && this.string(msg[2]) return this.string(msg[1]) && this.string(msg[2])
break
case Messages.Type.ReplaceVCSS:
return this.uint(msg[1]) && this.string(msg[2]) && this.string(msg[3]) && this.string(msg[4])
break break
case Messages.Type.ReplaceVCSS:
return this.uint(msg[1]) && this.string(msg[2]) && this.uint(msg[3]) && this.string(msg[4])
break
} }
} }