parsek-cdp 0.1.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- parsek_cdp/__init__.py +55 -0
- parsek_cdp/_logging.py +49 -0
- parsek_cdp/cdp/__init__.py +247 -0
- parsek_cdp/cdp/accessibility/__init__.py +15 -0
- parsek_cdp/cdp/accessibility/events.py +35 -0
- parsek_cdp/cdp/accessibility/functions.py +202 -0
- parsek_cdp/cdp/accessibility/types.py +235 -0
- parsek_cdp/cdp/animation/__init__.py +15 -0
- parsek_cdp/cdp/animation/events.py +52 -0
- parsek_cdp/cdp/animation/functions.py +140 -0
- parsek_cdp/cdp/animation/types.py +113 -0
- parsek_cdp/cdp/audits/__init__.py +15 -0
- parsek_cdp/cdp/audits/events.py +21 -0
- parsek_cdp/cdp/audits/functions.py +95 -0
- parsek_cdp/cdp/audits/types.py +1051 -0
- parsek_cdp/cdp/autofill/__init__.py +15 -0
- parsek_cdp/cdp/autofill/events.py +27 -0
- parsek_cdp/cdp/autofill/functions.py +64 -0
- parsek_cdp/cdp/autofill/types.py +108 -0
- parsek_cdp/cdp/backgroundservice/__init__.py +15 -0
- parsek_cdp/cdp/backgroundservice/events.py +40 -0
- parsek_cdp/cdp/backgroundservice/functions.py +59 -0
- parsek_cdp/cdp/backgroundservice/types.py +63 -0
- parsek_cdp/cdp/bluetoothemulation/__init__.py +15 -0
- parsek_cdp/cdp/bluetoothemulation/events.py +70 -0
- parsek_cdp/cdp/bluetoothemulation/functions.py +247 -0
- parsek_cdp/cdp/bluetoothemulation/types.py +120 -0
- parsek_cdp/cdp/browser/__init__.py +15 -0
- parsek_cdp/cdp/browser/events.py +46 -0
- parsek_cdp/cdp/browser/functions.py +350 -0
- parsek_cdp/cdp/browser/types.py +158 -0
- parsek_cdp/cdp/cachestorage/__init__.py +15 -0
- parsek_cdp/cdp/cachestorage/events.py +13 -0
- parsek_cdp/cdp/cachestorage/functions.py +126 -0
- parsek_cdp/cdp/cachestorage/types.py +89 -0
- parsek_cdp/cdp/cast/__init__.py +15 -0
- parsek_cdp/cdp/cast/events.py +38 -0
- parsek_cdp/cdp/cast/functions.py +77 -0
- parsek_cdp/cdp/cast/types.py +23 -0
- parsek_cdp/cdp/console/__init__.py +15 -0
- parsek_cdp/cdp/console/events.py +22 -0
- parsek_cdp/cdp/console/functions.py +36 -0
- parsek_cdp/cdp/console/types.py +30 -0
- parsek_cdp/cdp/css/__init__.py +15 -0
- parsek_cdp/cdp/css/events.py +79 -0
- parsek_cdp/cdp/css/functions.py +788 -0
- parsek_cdp/cdp/css/types.py +742 -0
- parsek_cdp/cdp/debugger/__init__.py +15 -0
- parsek_cdp/cdp/debugger/events.py +164 -0
- parsek_cdp/cdp/debugger/functions.py +663 -0
- parsek_cdp/cdp/debugger/types.py +171 -0
- parsek_cdp/cdp/deviceaccess/__init__.py +15 -0
- parsek_cdp/cdp/deviceaccess/events.py +30 -0
- parsek_cdp/cdp/deviceaccess/functions.py +54 -0
- parsek_cdp/cdp/deviceaccess/types.py +28 -0
- parsek_cdp/cdp/deviceorientation/__init__.py +15 -0
- parsek_cdp/cdp/deviceorientation/events.py +13 -0
- parsek_cdp/cdp/deviceorientation/functions.py +35 -0
- parsek_cdp/cdp/deviceorientation/types.py +10 -0
- parsek_cdp/cdp/dom/__init__.py +15 -0
- parsek_cdp/cdp/dom/events.py +228 -0
- parsek_cdp/cdp/dom/functions.py +1033 -0
- parsek_cdp/cdp/dom/types.py +293 -0
- parsek_cdp/cdp/domdebugger/__init__.py +15 -0
- parsek_cdp/cdp/domdebugger/events.py +13 -0
- parsek_cdp/cdp/domdebugger/functions.py +155 -0
- parsek_cdp/cdp/domdebugger/types.py +57 -0
- parsek_cdp/cdp/domsnapshot/__init__.py +15 -0
- parsek_cdp/cdp/domsnapshot/events.py +13 -0
- parsek_cdp/cdp/domsnapshot/functions.py +111 -0
- parsek_cdp/cdp/domsnapshot/types.py +312 -0
- parsek_cdp/cdp/domstorage/__init__.py +15 -0
- parsek_cdp/cdp/domstorage/events.py +60 -0
- parsek_cdp/cdp/domstorage/functions.py +79 -0
- parsek_cdp/cdp/domstorage/types.py +30 -0
- parsek_cdp/cdp/emulation/__init__.py +15 -0
- parsek_cdp/cdp/emulation/events.py +17 -0
- parsek_cdp/cdp/emulation/functions.py +688 -0
- parsek_cdp/cdp/emulation/types.py +305 -0
- parsek_cdp/cdp/eventbreakpoints/__init__.py +15 -0
- parsek_cdp/cdp/eventbreakpoints/events.py +13 -0
- parsek_cdp/cdp/eventbreakpoints/functions.py +41 -0
- parsek_cdp/cdp/eventbreakpoints/types.py +10 -0
- parsek_cdp/cdp/extensions/__init__.py +15 -0
- parsek_cdp/cdp/extensions/events.py +13 -0
- parsek_cdp/cdp/extensions/functions.py +118 -0
- parsek_cdp/cdp/extensions/types.py +19 -0
- parsek_cdp/cdp/fedcm/__init__.py +15 -0
- parsek_cdp/cdp/fedcm/events.py +45 -0
- parsek_cdp/cdp/fedcm/functions.py +93 -0
- parsek_cdp/cdp/fedcm/types.py +72 -0
- parsek_cdp/cdp/fetch/__init__.py +15 -0
- parsek_cdp/cdp/fetch/events.py +82 -0
- parsek_cdp/cdp/fetch/functions.py +215 -0
- parsek_cdp/cdp/fetch/types.py +81 -0
- parsek_cdp/cdp/filesystem/__init__.py +15 -0
- parsek_cdp/cdp/filesystem/events.py +13 -0
- parsek_cdp/cdp/filesystem/functions.py +36 -0
- parsek_cdp/cdp/filesystem/types.py +54 -0
- parsek_cdp/cdp/headlessexperimental/__init__.py +15 -0
- parsek_cdp/cdp/headlessexperimental/events.py +13 -0
- parsek_cdp/cdp/headlessexperimental/functions.py +77 -0
- parsek_cdp/cdp/headlessexperimental/types.py +24 -0
- parsek_cdp/cdp/heapprofiler/__init__.py +15 -0
- parsek_cdp/cdp/heapprofiler/events.py +65 -0
- parsek_cdp/cdp/heapprofiler/functions.py +193 -0
- parsek_cdp/cdp/heapprofiler/types.py +57 -0
- parsek_cdp/cdp/indexeddb/__init__.py +15 -0
- parsek_cdp/cdp/indexeddb/events.py +13 -0
- parsek_cdp/cdp/indexeddb/functions.py +232 -0
- parsek_cdp/cdp/indexeddb/types.py +120 -0
- parsek_cdp/cdp/input/__init__.py +15 -0
- parsek_cdp/cdp/input/events.py +25 -0
- parsek_cdp/cdp/input/functions.py +361 -0
- parsek_cdp/cdp/input/types.py +87 -0
- parsek_cdp/cdp/inspector/__init__.py +15 -0
- parsek_cdp/cdp/inspector/events.py +41 -0
- parsek_cdp/cdp/inspector/functions.py +27 -0
- parsek_cdp/cdp/inspector/types.py +10 -0
- parsek_cdp/cdp/io/__init__.py +15 -0
- parsek_cdp/cdp/io/events.py +13 -0
- parsek_cdp/cdp/io/functions.py +77 -0
- parsek_cdp/cdp/io/types.py +13 -0
- parsek_cdp/cdp/layertree/__init__.py +15 -0
- parsek_cdp/cdp/layertree/events.py +36 -0
- parsek_cdp/cdp/layertree/functions.py +178 -0
- parsek_cdp/cdp/layertree/types.py +104 -0
- parsek_cdp/cdp/log/__init__.py +15 -0
- parsek_cdp/cdp/log/events.py +22 -0
- parsek_cdp/cdp/log/functions.py +54 -0
- parsek_cdp/cdp/log/types.py +57 -0
- parsek_cdp/cdp/media/__init__.py +15 -0
- parsek_cdp/cdp/media/events.py +87 -0
- parsek_cdp/cdp/media/functions.py +27 -0
- parsek_cdp/cdp/media/types.py +101 -0
- parsek_cdp/cdp/memory/__init__.py +15 -0
- parsek_cdp/cdp/memory/events.py +13 -0
- parsek_cdp/cdp/memory/functions.py +164 -0
- parsek_cdp/cdp/memory/types.py +71 -0
- parsek_cdp/cdp/mixins/__init__.py +21 -0
- parsek_cdp/cdp/mixins/datatype.py +123 -0
- parsek_cdp/cdp/mixins/event.py +78 -0
- parsek_cdp/cdp/mixins/namespace.py +31 -0
- parsek_cdp/cdp/network/__init__.py +15 -0
- parsek_cdp/cdp/network/events.py +726 -0
- parsek_cdp/cdp/network/functions.py +734 -0
- parsek_cdp/cdp/network/types.py +1247 -0
- parsek_cdp/cdp/overlay/__init__.py +15 -0
- parsek_cdp/cdp/overlay/events.py +54 -0
- parsek_cdp/cdp/overlay/functions.py +407 -0
- parsek_cdp/cdp/overlay/types.py +328 -0
- parsek_cdp/cdp/page/__init__.py +15 -0
- parsek_cdp/cdp/page/events.py +416 -0
- parsek_cdp/cdp/page/functions.py +1081 -0
- parsek_cdp/cdp/page/types.py +1088 -0
- parsek_cdp/cdp/performance/__init__.py +15 -0
- parsek_cdp/cdp/performance/events.py +24 -0
- parsek_cdp/cdp/performance/functions.py +63 -0
- parsek_cdp/cdp/performance/types.py +22 -0
- parsek_cdp/cdp/performancetimeline/__init__.py +15 -0
- parsek_cdp/cdp/performancetimeline/events.py +22 -0
- parsek_cdp/cdp/performancetimeline/functions.py +30 -0
- parsek_cdp/cdp/performancetimeline/types.py +85 -0
- parsek_cdp/cdp/preload/__init__.py +15 -0
- parsek_cdp/cdp/preload/events.py +116 -0
- parsek_cdp/cdp/preload/functions.py +25 -0
- parsek_cdp/cdp/preload/types.py +267 -0
- parsek_cdp/cdp/profiler/__init__.py +15 -0
- parsek_cdp/cdp/profiler/events.py +64 -0
- parsek_cdp/cdp/profiler/functions.py +134 -0
- parsek_cdp/cdp/profiler/types.py +105 -0
- parsek_cdp/cdp/pwa/__init__.py +15 -0
- parsek_cdp/cdp/pwa/events.py +13 -0
- parsek_cdp/cdp/pwa/functions.py +196 -0
- parsek_cdp/cdp/pwa/types.py +45 -0
- parsek_cdp/cdp/runtime/__init__.py +15 -0
- parsek_cdp/cdp/runtime/events.py +123 -0
- parsek_cdp/cdp/runtime/functions.py +552 -0
- parsek_cdp/cdp/runtime/types.py +319 -0
- parsek_cdp/cdp/schema/__init__.py +15 -0
- parsek_cdp/cdp/schema/events.py +13 -0
- parsek_cdp/cdp/schema/functions.py +32 -0
- parsek_cdp/cdp/schema/types.py +22 -0
- parsek_cdp/cdp/security/__init__.py +15 -0
- parsek_cdp/cdp/security/events.py +64 -0
- parsek_cdp/cdp/security/functions.py +66 -0
- parsek_cdp/cdp/security/types.py +168 -0
- parsek_cdp/cdp/serviceworker/__init__.py +15 -0
- parsek_cdp/cdp/serviceworker/events.py +43 -0
- parsek_cdp/cdp/serviceworker/functions.py +115 -0
- parsek_cdp/cdp/serviceworker/types.py +95 -0
- parsek_cdp/cdp/storage/__init__.py +15 -0
- parsek_cdp/cdp/storage/events.py +288 -0
- parsek_cdp/cdp/storage/functions.py +571 -0
- parsek_cdp/cdp/storage/types.py +656 -0
- parsek_cdp/cdp/systeminfo/__init__.py +15 -0
- parsek_cdp/cdp/systeminfo/events.py +13 -0
- parsek_cdp/cdp/systeminfo/functions.py +75 -0
- parsek_cdp/cdp/systeminfo/types.py +132 -0
- parsek_cdp/cdp/target/__init__.py +15 -0
- parsek_cdp/cdp/target/events.py +109 -0
- parsek_cdp/cdp/target/functions.py +424 -0
- parsek_cdp/cdp/target/types.py +83 -0
- parsek_cdp/cdp/tethering/__init__.py +15 -0
- parsek_cdp/cdp/tethering/events.py +22 -0
- parsek_cdp/cdp/tethering/functions.py +35 -0
- parsek_cdp/cdp/tethering/types.py +10 -0
- parsek_cdp/cdp/tracing/__init__.py +15 -0
- parsek_cdp/cdp/tracing/events.py +61 -0
- parsek_cdp/cdp/tracing/functions.py +119 -0
- parsek_cdp/cdp/tracing/types.py +81 -0
- parsek_cdp/cdp/webaudio/__init__.py +15 -0
- parsek_cdp/cdp/webaudio/events.py +184 -0
- parsek_cdp/cdp/webaudio/functions.py +51 -0
- parsek_cdp/cdp/webaudio/types.py +155 -0
- parsek_cdp/cdp/webauthn/__init__.py +15 -0
- parsek_cdp/cdp/webauthn/events.py +69 -0
- parsek_cdp/cdp/webauthn/functions.py +214 -0
- parsek_cdp/cdp/webauthn/types.py +96 -0
- parsek_cdp/core/__init__.py +18 -0
- parsek_cdp/core/browser.py +240 -0
- parsek_cdp/core/browser_context.py +58 -0
- parsek_cdp/core/element.py +405 -0
- parsek_cdp/core/feature.py +376 -0
- parsek_cdp/core/frame.py +351 -0
- parsek_cdp/core/pagable.py +175 -0
- parsek_cdp/core/page.py +163 -0
- parsek_cdp/core/target.py +490 -0
- parsek_cdp/features/__init__.py +14 -0
- parsek_cdp/features/request_listener/__init__.py +256 -0
- parsek_cdp/features/request_listener/events.py +48 -0
- parsek_cdp/features/request_listener/types.py +235 -0
- parsek_cdp/generate.py +642 -0
- parsek_cdp/parsek/__init__.py +18 -0
- parsek_cdp/parsek/events.py +38 -0
- parsek_cdp/parsek/types.py +36 -0
- parsek_cdp/py.typed +0 -0
- parsek_cdp-0.1.0.dist-info/METADATA +277 -0
- parsek_cdp-0.1.0.dist-info/RECORD +242 -0
- parsek_cdp-0.1.0.dist-info/WHEEL +5 -0
- parsek_cdp-0.1.0.dist-info/licenses/LICENSE +201 -0
- parsek_cdp-0.1.0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,742 @@
|
|
|
1
|
+
"""Custom types and enums for the CSS domain (generated)."""
|
|
2
|
+
from __future__ import annotations
|
|
3
|
+
|
|
4
|
+
from dataclasses import dataclass
|
|
5
|
+
from enum import Enum
|
|
6
|
+
from typing import TYPE_CHECKING, Any, ClassVar, Dict, List, Literal, Optional
|
|
7
|
+
|
|
8
|
+
from ..mixins.datatype import DataType, FieldMeta, register
|
|
9
|
+
|
|
10
|
+
if TYPE_CHECKING:
|
|
11
|
+
from ..dom.types import BackendNodeId as DOM_BackendNodeId
|
|
12
|
+
from ..dom.types import LogicalAxes as DOM_LogicalAxes
|
|
13
|
+
from ..dom.types import PhysicalAxes as DOM_PhysicalAxes
|
|
14
|
+
from ..dom.types import PseudoType as DOM_PseudoType
|
|
15
|
+
from ..dom.types import StyleSheetId as DOM_StyleSheetId
|
|
16
|
+
from ..page.types import FrameId as Page_FrameId
|
|
17
|
+
|
|
18
|
+
@register("CSS.StyleSheetOrigin")
|
|
19
|
+
class StyleSheetOrigin(str, Enum):
|
|
20
|
+
"""
|
|
21
|
+
Stylesheet type: "injected" for stylesheets injected via extension, "user-agent" for user-agent
|
|
22
|
+
stylesheets, "inspector" for stylesheets created by the inspector (i.e. those holding the "via
|
|
23
|
+
inspector" rules), "regular" for regular stylesheets.
|
|
24
|
+
"""
|
|
25
|
+
INJECTED = 'injected'
|
|
26
|
+
USER_AGENT = 'user-agent'
|
|
27
|
+
INSPECTOR = 'inspector'
|
|
28
|
+
REGULAR = 'regular'
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
@register("CSS.PseudoElementMatches")
|
|
32
|
+
@dataclass
|
|
33
|
+
class PseudoElementMatches(DataType):
|
|
34
|
+
"""CSS rule collection for a single pseudo style."""
|
|
35
|
+
pseudo_type: DOM_PseudoType
|
|
36
|
+
matches: List[RuleMatch]
|
|
37
|
+
pseudo_identifier: Optional[str] = None
|
|
38
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
39
|
+
FieldMeta('pseudo_type', 'pseudoType', False, 'enum', ref='DOM.PseudoType'),
|
|
40
|
+
FieldMeta('matches', 'matches', False, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.RuleMatch')),
|
|
41
|
+
FieldMeta('pseudo_identifier', 'pseudoIdentifier', True, 'primitive'),
|
|
42
|
+
)
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
@register("CSS.CSSAnimationStyle")
|
|
46
|
+
@dataclass
|
|
47
|
+
class CSSAnimationStyle(DataType):
|
|
48
|
+
"""CSS style coming from animations with the name of the animation."""
|
|
49
|
+
style: CSSStyle
|
|
50
|
+
name: Optional[str] = None
|
|
51
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
52
|
+
FieldMeta('style', 'style', False, 'object', ref='CSS.CSSStyle'),
|
|
53
|
+
FieldMeta('name', 'name', True, 'primitive'),
|
|
54
|
+
)
|
|
55
|
+
|
|
56
|
+
|
|
57
|
+
@register("CSS.InheritedStyleEntry")
|
|
58
|
+
@dataclass
|
|
59
|
+
class InheritedStyleEntry(DataType):
|
|
60
|
+
"""Inherited CSS rule collection from ancestor node."""
|
|
61
|
+
matched_css_rules: List[RuleMatch]
|
|
62
|
+
inline_style: Optional[CSSStyle] = None
|
|
63
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
64
|
+
FieldMeta('matched_css_rules', 'matchedCSSRules', False, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.RuleMatch')),
|
|
65
|
+
FieldMeta('inline_style', 'inlineStyle', True, 'object', ref='CSS.CSSStyle'),
|
|
66
|
+
)
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
@register("CSS.InheritedAnimatedStyleEntry")
|
|
70
|
+
@dataclass
|
|
71
|
+
class InheritedAnimatedStyleEntry(DataType):
|
|
72
|
+
"""Inherited CSS style collection for animated styles from ancestor node."""
|
|
73
|
+
animation_styles: Optional[List[CSSAnimationStyle]] = None
|
|
74
|
+
transitions_style: Optional[CSSStyle] = None
|
|
75
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
76
|
+
FieldMeta('animation_styles', 'animationStyles', True, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.CSSAnimationStyle')),
|
|
77
|
+
FieldMeta('transitions_style', 'transitionsStyle', True, 'object', ref='CSS.CSSStyle'),
|
|
78
|
+
)
|
|
79
|
+
|
|
80
|
+
|
|
81
|
+
@register("CSS.InheritedPseudoElementMatches")
|
|
82
|
+
@dataclass
|
|
83
|
+
class InheritedPseudoElementMatches(DataType):
|
|
84
|
+
"""Inherited pseudo element matches from pseudos of an ancestor node."""
|
|
85
|
+
pseudo_elements: List[PseudoElementMatches]
|
|
86
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
87
|
+
FieldMeta('pseudo_elements', 'pseudoElements', False, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.PseudoElementMatches')),
|
|
88
|
+
)
|
|
89
|
+
|
|
90
|
+
|
|
91
|
+
@register("CSS.RuleMatch")
|
|
92
|
+
@dataclass
|
|
93
|
+
class RuleMatch(DataType):
|
|
94
|
+
"""Match data for a CSS rule."""
|
|
95
|
+
rule: CSSRule
|
|
96
|
+
matching_selectors: List[int]
|
|
97
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
98
|
+
FieldMeta('rule', 'rule', False, 'object', ref='CSS.CSSRule'),
|
|
99
|
+
FieldMeta('matching_selectors', 'matchingSelectors', False, 'array', inner=FieldMeta('', '', False, 'primitive')),
|
|
100
|
+
)
|
|
101
|
+
|
|
102
|
+
|
|
103
|
+
@register("CSS.Value")
|
|
104
|
+
@dataclass
|
|
105
|
+
class Value(DataType):
|
|
106
|
+
"""Data for a simple selector (these are delimited by commas in a selector list)."""
|
|
107
|
+
text: str
|
|
108
|
+
range: Optional[SourceRange] = None
|
|
109
|
+
specificity: Optional[Specificity] = None
|
|
110
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
111
|
+
FieldMeta('text', 'text', False, 'primitive'),
|
|
112
|
+
FieldMeta('range', 'range', True, 'object', ref='CSS.SourceRange'),
|
|
113
|
+
FieldMeta('specificity', 'specificity', True, 'object', ref='CSS.Specificity'),
|
|
114
|
+
)
|
|
115
|
+
|
|
116
|
+
|
|
117
|
+
@register("CSS.Specificity")
|
|
118
|
+
@dataclass
|
|
119
|
+
class Specificity(DataType):
|
|
120
|
+
"""
|
|
121
|
+
Specificity:
|
|
122
|
+
https://drafts.csswg.org/selectors/#specificity-rules
|
|
123
|
+
"""
|
|
124
|
+
a: int
|
|
125
|
+
b: int
|
|
126
|
+
c: int
|
|
127
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
128
|
+
FieldMeta('a', 'a', False, 'primitive'),
|
|
129
|
+
FieldMeta('b', 'b', False, 'primitive'),
|
|
130
|
+
FieldMeta('c', 'c', False, 'primitive'),
|
|
131
|
+
)
|
|
132
|
+
|
|
133
|
+
|
|
134
|
+
@register("CSS.SelectorList")
|
|
135
|
+
@dataclass
|
|
136
|
+
class SelectorList(DataType):
|
|
137
|
+
"""Selector list data."""
|
|
138
|
+
selectors: List[Value]
|
|
139
|
+
text: str
|
|
140
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
141
|
+
FieldMeta('selectors', 'selectors', False, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.Value')),
|
|
142
|
+
FieldMeta('text', 'text', False, 'primitive'),
|
|
143
|
+
)
|
|
144
|
+
|
|
145
|
+
|
|
146
|
+
@register("CSS.CSSStyleSheetHeader")
|
|
147
|
+
@dataclass
|
|
148
|
+
class CSSStyleSheetHeader(DataType):
|
|
149
|
+
"""CSS stylesheet metainformation."""
|
|
150
|
+
style_sheet_id: DOM_StyleSheetId
|
|
151
|
+
frame_id: Page_FrameId
|
|
152
|
+
source_url: str
|
|
153
|
+
origin: StyleSheetOrigin
|
|
154
|
+
title: str
|
|
155
|
+
disabled: bool
|
|
156
|
+
is_inline: bool
|
|
157
|
+
is_mutable: bool
|
|
158
|
+
is_constructed: bool
|
|
159
|
+
start_line: float
|
|
160
|
+
start_column: float
|
|
161
|
+
length: float
|
|
162
|
+
end_line: float
|
|
163
|
+
end_column: float
|
|
164
|
+
source_map_url: Optional[str] = None
|
|
165
|
+
owner_node: Optional[DOM_BackendNodeId] = None
|
|
166
|
+
has_source_url: Optional[bool] = None
|
|
167
|
+
loading_failed: Optional[bool] = None
|
|
168
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
169
|
+
FieldMeta('style_sheet_id', 'styleSheetId', False, 'primitive'),
|
|
170
|
+
FieldMeta('frame_id', 'frameId', False, 'primitive'),
|
|
171
|
+
FieldMeta('source_url', 'sourceURL', False, 'primitive'),
|
|
172
|
+
FieldMeta('origin', 'origin', False, 'enum', ref='CSS.StyleSheetOrigin'),
|
|
173
|
+
FieldMeta('title', 'title', False, 'primitive'),
|
|
174
|
+
FieldMeta('disabled', 'disabled', False, 'primitive'),
|
|
175
|
+
FieldMeta('is_inline', 'isInline', False, 'primitive'),
|
|
176
|
+
FieldMeta('is_mutable', 'isMutable', False, 'primitive'),
|
|
177
|
+
FieldMeta('is_constructed', 'isConstructed', False, 'primitive'),
|
|
178
|
+
FieldMeta('start_line', 'startLine', False, 'primitive'),
|
|
179
|
+
FieldMeta('start_column', 'startColumn', False, 'primitive'),
|
|
180
|
+
FieldMeta('length', 'length', False, 'primitive'),
|
|
181
|
+
FieldMeta('end_line', 'endLine', False, 'primitive'),
|
|
182
|
+
FieldMeta('end_column', 'endColumn', False, 'primitive'),
|
|
183
|
+
FieldMeta('source_map_url', 'sourceMapURL', True, 'primitive'),
|
|
184
|
+
FieldMeta('owner_node', 'ownerNode', True, 'primitive'),
|
|
185
|
+
FieldMeta('has_source_url', 'hasSourceURL', True, 'primitive'),
|
|
186
|
+
FieldMeta('loading_failed', 'loadingFailed', True, 'primitive'),
|
|
187
|
+
)
|
|
188
|
+
|
|
189
|
+
|
|
190
|
+
@register("CSS.CSSRule")
|
|
191
|
+
@dataclass
|
|
192
|
+
class CSSRule(DataType):
|
|
193
|
+
"""CSS rule representation."""
|
|
194
|
+
selector_list: SelectorList
|
|
195
|
+
origin: StyleSheetOrigin
|
|
196
|
+
style: CSSStyle
|
|
197
|
+
style_sheet_id: Optional[DOM_StyleSheetId] = None
|
|
198
|
+
nesting_selectors: Optional[List[str]] = None
|
|
199
|
+
origin_tree_scope_node_id: Optional[DOM_BackendNodeId] = None
|
|
200
|
+
media: Optional[List[CSSMedia]] = None
|
|
201
|
+
container_queries: Optional[List[CSSContainerQuery]] = None
|
|
202
|
+
supports: Optional[List[CSSSupports]] = None
|
|
203
|
+
layers: Optional[List[CSSLayer]] = None
|
|
204
|
+
scopes: Optional[List[CSSScope]] = None
|
|
205
|
+
rule_types: Optional[List[CSSRuleType]] = None
|
|
206
|
+
starting_styles: Optional[List[CSSStartingStyle]] = None
|
|
207
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
208
|
+
FieldMeta('selector_list', 'selectorList', False, 'object', ref='CSS.SelectorList'),
|
|
209
|
+
FieldMeta('origin', 'origin', False, 'enum', ref='CSS.StyleSheetOrigin'),
|
|
210
|
+
FieldMeta('style', 'style', False, 'object', ref='CSS.CSSStyle'),
|
|
211
|
+
FieldMeta('style_sheet_id', 'styleSheetId', True, 'primitive'),
|
|
212
|
+
FieldMeta('nesting_selectors', 'nestingSelectors', True, 'array', inner=FieldMeta('', '', False, 'primitive')),
|
|
213
|
+
FieldMeta('origin_tree_scope_node_id', 'originTreeScopeNodeId', True, 'primitive'),
|
|
214
|
+
FieldMeta('media', 'media', True, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.CSSMedia')),
|
|
215
|
+
FieldMeta('container_queries', 'containerQueries', True, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.CSSContainerQuery')),
|
|
216
|
+
FieldMeta('supports', 'supports', True, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.CSSSupports')),
|
|
217
|
+
FieldMeta('layers', 'layers', True, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.CSSLayer')),
|
|
218
|
+
FieldMeta('scopes', 'scopes', True, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.CSSScope')),
|
|
219
|
+
FieldMeta('rule_types', 'ruleTypes', True, 'array', inner=FieldMeta('', '', False, 'enum', ref='CSS.CSSRuleType')),
|
|
220
|
+
FieldMeta('starting_styles', 'startingStyles', True, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.CSSStartingStyle')),
|
|
221
|
+
)
|
|
222
|
+
|
|
223
|
+
|
|
224
|
+
@register("CSS.CSSRuleType")
|
|
225
|
+
class CSSRuleType(str, Enum):
|
|
226
|
+
"""
|
|
227
|
+
Enum indicating the type of a CSS rule, used to represent the order of a style rule's ancestors.
|
|
228
|
+
This list only contains rule types that are collected during the ancestor rule collection.
|
|
229
|
+
"""
|
|
230
|
+
MEDIARULE = 'MediaRule'
|
|
231
|
+
SUPPORTSRULE = 'SupportsRule'
|
|
232
|
+
CONTAINERRULE = 'ContainerRule'
|
|
233
|
+
LAYERRULE = 'LayerRule'
|
|
234
|
+
SCOPERULE = 'ScopeRule'
|
|
235
|
+
STYLERULE = 'StyleRule'
|
|
236
|
+
STARTINGSTYLERULE = 'StartingStyleRule'
|
|
237
|
+
|
|
238
|
+
|
|
239
|
+
@register("CSS.RuleUsage")
|
|
240
|
+
@dataclass
|
|
241
|
+
class RuleUsage(DataType):
|
|
242
|
+
"""CSS coverage information."""
|
|
243
|
+
style_sheet_id: DOM_StyleSheetId
|
|
244
|
+
start_offset: float
|
|
245
|
+
end_offset: float
|
|
246
|
+
used: bool
|
|
247
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
248
|
+
FieldMeta('style_sheet_id', 'styleSheetId', False, 'primitive'),
|
|
249
|
+
FieldMeta('start_offset', 'startOffset', False, 'primitive'),
|
|
250
|
+
FieldMeta('end_offset', 'endOffset', False, 'primitive'),
|
|
251
|
+
FieldMeta('used', 'used', False, 'primitive'),
|
|
252
|
+
)
|
|
253
|
+
|
|
254
|
+
|
|
255
|
+
@register("CSS.SourceRange")
|
|
256
|
+
@dataclass
|
|
257
|
+
class SourceRange(DataType):
|
|
258
|
+
"""Text range within a resource. All numbers are zero-based."""
|
|
259
|
+
start_line: int
|
|
260
|
+
start_column: int
|
|
261
|
+
end_line: int
|
|
262
|
+
end_column: int
|
|
263
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
264
|
+
FieldMeta('start_line', 'startLine', False, 'primitive'),
|
|
265
|
+
FieldMeta('start_column', 'startColumn', False, 'primitive'),
|
|
266
|
+
FieldMeta('end_line', 'endLine', False, 'primitive'),
|
|
267
|
+
FieldMeta('end_column', 'endColumn', False, 'primitive'),
|
|
268
|
+
)
|
|
269
|
+
|
|
270
|
+
|
|
271
|
+
@register("CSS.ShorthandEntry")
|
|
272
|
+
@dataclass
|
|
273
|
+
class ShorthandEntry(DataType):
|
|
274
|
+
name: str
|
|
275
|
+
value: str
|
|
276
|
+
important: Optional[bool] = None
|
|
277
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
278
|
+
FieldMeta('name', 'name', False, 'primitive'),
|
|
279
|
+
FieldMeta('value', 'value', False, 'primitive'),
|
|
280
|
+
FieldMeta('important', 'important', True, 'primitive'),
|
|
281
|
+
)
|
|
282
|
+
|
|
283
|
+
|
|
284
|
+
@register("CSS.CSSComputedStyleProperty")
|
|
285
|
+
@dataclass
|
|
286
|
+
class CSSComputedStyleProperty(DataType):
|
|
287
|
+
name: str
|
|
288
|
+
value: str
|
|
289
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
290
|
+
FieldMeta('name', 'name', False, 'primitive'),
|
|
291
|
+
FieldMeta('value', 'value', False, 'primitive'),
|
|
292
|
+
)
|
|
293
|
+
|
|
294
|
+
|
|
295
|
+
@register("CSS.ComputedStyleExtraFields")
|
|
296
|
+
@dataclass
|
|
297
|
+
class ComputedStyleExtraFields(DataType):
|
|
298
|
+
is_appearance_base: bool
|
|
299
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
300
|
+
FieldMeta('is_appearance_base', 'isAppearanceBase', False, 'primitive'),
|
|
301
|
+
)
|
|
302
|
+
|
|
303
|
+
|
|
304
|
+
@register("CSS.CSSStyle")
|
|
305
|
+
@dataclass
|
|
306
|
+
class CSSStyle(DataType):
|
|
307
|
+
"""CSS style representation."""
|
|
308
|
+
css_properties: List[CSSProperty]
|
|
309
|
+
shorthand_entries: List[ShorthandEntry]
|
|
310
|
+
style_sheet_id: Optional[DOM_StyleSheetId] = None
|
|
311
|
+
css_text: Optional[str] = None
|
|
312
|
+
range: Optional[SourceRange] = None
|
|
313
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
314
|
+
FieldMeta('css_properties', 'cssProperties', False, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.CSSProperty')),
|
|
315
|
+
FieldMeta('shorthand_entries', 'shorthandEntries', False, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.ShorthandEntry')),
|
|
316
|
+
FieldMeta('style_sheet_id', 'styleSheetId', True, 'primitive'),
|
|
317
|
+
FieldMeta('css_text', 'cssText', True, 'primitive'),
|
|
318
|
+
FieldMeta('range', 'range', True, 'object', ref='CSS.SourceRange'),
|
|
319
|
+
)
|
|
320
|
+
|
|
321
|
+
|
|
322
|
+
@register("CSS.CSSProperty")
|
|
323
|
+
@dataclass
|
|
324
|
+
class CSSProperty(DataType):
|
|
325
|
+
"""CSS property declaration data."""
|
|
326
|
+
name: str
|
|
327
|
+
value: str
|
|
328
|
+
important: Optional[bool] = None
|
|
329
|
+
implicit: Optional[bool] = None
|
|
330
|
+
text: Optional[str] = None
|
|
331
|
+
parsed_ok: Optional[bool] = None
|
|
332
|
+
disabled: Optional[bool] = None
|
|
333
|
+
range: Optional[SourceRange] = None
|
|
334
|
+
longhand_properties: Optional[List[CSSProperty]] = None
|
|
335
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
336
|
+
FieldMeta('name', 'name', False, 'primitive'),
|
|
337
|
+
FieldMeta('value', 'value', False, 'primitive'),
|
|
338
|
+
FieldMeta('important', 'important', True, 'primitive'),
|
|
339
|
+
FieldMeta('implicit', 'implicit', True, 'primitive'),
|
|
340
|
+
FieldMeta('text', 'text', True, 'primitive'),
|
|
341
|
+
FieldMeta('parsed_ok', 'parsedOk', True, 'primitive'),
|
|
342
|
+
FieldMeta('disabled', 'disabled', True, 'primitive'),
|
|
343
|
+
FieldMeta('range', 'range', True, 'object', ref='CSS.SourceRange'),
|
|
344
|
+
FieldMeta('longhand_properties', 'longhandProperties', True, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.CSSProperty')),
|
|
345
|
+
)
|
|
346
|
+
|
|
347
|
+
|
|
348
|
+
@register("CSS.CSSMedia")
|
|
349
|
+
@dataclass
|
|
350
|
+
class CSSMedia(DataType):
|
|
351
|
+
"""CSS media rule descriptor."""
|
|
352
|
+
text: str
|
|
353
|
+
source: Literal['mediaRule', 'importRule', 'linkedSheet', 'inlineSheet']
|
|
354
|
+
source_url: Optional[str] = None
|
|
355
|
+
range: Optional[SourceRange] = None
|
|
356
|
+
style_sheet_id: Optional[DOM_StyleSheetId] = None
|
|
357
|
+
media_list: Optional[List[MediaQuery]] = None
|
|
358
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
359
|
+
FieldMeta('text', 'text', False, 'primitive'),
|
|
360
|
+
FieldMeta('source', 'source', False, 'primitive'),
|
|
361
|
+
FieldMeta('source_url', 'sourceURL', True, 'primitive'),
|
|
362
|
+
FieldMeta('range', 'range', True, 'object', ref='CSS.SourceRange'),
|
|
363
|
+
FieldMeta('style_sheet_id', 'styleSheetId', True, 'primitive'),
|
|
364
|
+
FieldMeta('media_list', 'mediaList', True, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.MediaQuery')),
|
|
365
|
+
)
|
|
366
|
+
|
|
367
|
+
|
|
368
|
+
@register("CSS.MediaQuery")
|
|
369
|
+
@dataclass
|
|
370
|
+
class MediaQuery(DataType):
|
|
371
|
+
"""Media query descriptor."""
|
|
372
|
+
expressions: List[MediaQueryExpression]
|
|
373
|
+
active: bool
|
|
374
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
375
|
+
FieldMeta('expressions', 'expressions', False, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.MediaQueryExpression')),
|
|
376
|
+
FieldMeta('active', 'active', False, 'primitive'),
|
|
377
|
+
)
|
|
378
|
+
|
|
379
|
+
|
|
380
|
+
@register("CSS.MediaQueryExpression")
|
|
381
|
+
@dataclass
|
|
382
|
+
class MediaQueryExpression(DataType):
|
|
383
|
+
"""Media query expression descriptor."""
|
|
384
|
+
value: float
|
|
385
|
+
unit: str
|
|
386
|
+
feature: str
|
|
387
|
+
value_range: Optional[SourceRange] = None
|
|
388
|
+
computed_length: Optional[float] = None
|
|
389
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
390
|
+
FieldMeta('value', 'value', False, 'primitive'),
|
|
391
|
+
FieldMeta('unit', 'unit', False, 'primitive'),
|
|
392
|
+
FieldMeta('feature', 'feature', False, 'primitive'),
|
|
393
|
+
FieldMeta('value_range', 'valueRange', True, 'object', ref='CSS.SourceRange'),
|
|
394
|
+
FieldMeta('computed_length', 'computedLength', True, 'primitive'),
|
|
395
|
+
)
|
|
396
|
+
|
|
397
|
+
|
|
398
|
+
@register("CSS.CSSContainerQuery")
|
|
399
|
+
@dataclass
|
|
400
|
+
class CSSContainerQuery(DataType):
|
|
401
|
+
"""CSS container query rule descriptor."""
|
|
402
|
+
text: str
|
|
403
|
+
range: Optional[SourceRange] = None
|
|
404
|
+
style_sheet_id: Optional[DOM_StyleSheetId] = None
|
|
405
|
+
name: Optional[str] = None
|
|
406
|
+
physical_axes: Optional[DOM_PhysicalAxes] = None
|
|
407
|
+
logical_axes: Optional[DOM_LogicalAxes] = None
|
|
408
|
+
queries_scroll_state: Optional[bool] = None
|
|
409
|
+
queries_anchored: Optional[bool] = None
|
|
410
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
411
|
+
FieldMeta('text', 'text', False, 'primitive'),
|
|
412
|
+
FieldMeta('range', 'range', True, 'object', ref='CSS.SourceRange'),
|
|
413
|
+
FieldMeta('style_sheet_id', 'styleSheetId', True, 'primitive'),
|
|
414
|
+
FieldMeta('name', 'name', True, 'primitive'),
|
|
415
|
+
FieldMeta('physical_axes', 'physicalAxes', True, 'enum', ref='DOM.PhysicalAxes'),
|
|
416
|
+
FieldMeta('logical_axes', 'logicalAxes', True, 'enum', ref='DOM.LogicalAxes'),
|
|
417
|
+
FieldMeta('queries_scroll_state', 'queriesScrollState', True, 'primitive'),
|
|
418
|
+
FieldMeta('queries_anchored', 'queriesAnchored', True, 'primitive'),
|
|
419
|
+
)
|
|
420
|
+
|
|
421
|
+
|
|
422
|
+
@register("CSS.CSSSupports")
|
|
423
|
+
@dataclass
|
|
424
|
+
class CSSSupports(DataType):
|
|
425
|
+
"""CSS Supports at-rule descriptor."""
|
|
426
|
+
text: str
|
|
427
|
+
active: bool
|
|
428
|
+
range: Optional[SourceRange] = None
|
|
429
|
+
style_sheet_id: Optional[DOM_StyleSheetId] = None
|
|
430
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
431
|
+
FieldMeta('text', 'text', False, 'primitive'),
|
|
432
|
+
FieldMeta('active', 'active', False, 'primitive'),
|
|
433
|
+
FieldMeta('range', 'range', True, 'object', ref='CSS.SourceRange'),
|
|
434
|
+
FieldMeta('style_sheet_id', 'styleSheetId', True, 'primitive'),
|
|
435
|
+
)
|
|
436
|
+
|
|
437
|
+
|
|
438
|
+
@register("CSS.CSSScope")
|
|
439
|
+
@dataclass
|
|
440
|
+
class CSSScope(DataType):
|
|
441
|
+
"""CSS Scope at-rule descriptor."""
|
|
442
|
+
text: str
|
|
443
|
+
range: Optional[SourceRange] = None
|
|
444
|
+
style_sheet_id: Optional[DOM_StyleSheetId] = None
|
|
445
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
446
|
+
FieldMeta('text', 'text', False, 'primitive'),
|
|
447
|
+
FieldMeta('range', 'range', True, 'object', ref='CSS.SourceRange'),
|
|
448
|
+
FieldMeta('style_sheet_id', 'styleSheetId', True, 'primitive'),
|
|
449
|
+
)
|
|
450
|
+
|
|
451
|
+
|
|
452
|
+
@register("CSS.CSSLayer")
|
|
453
|
+
@dataclass
|
|
454
|
+
class CSSLayer(DataType):
|
|
455
|
+
"""CSS Layer at-rule descriptor."""
|
|
456
|
+
text: str
|
|
457
|
+
range: Optional[SourceRange] = None
|
|
458
|
+
style_sheet_id: Optional[DOM_StyleSheetId] = None
|
|
459
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
460
|
+
FieldMeta('text', 'text', False, 'primitive'),
|
|
461
|
+
FieldMeta('range', 'range', True, 'object', ref='CSS.SourceRange'),
|
|
462
|
+
FieldMeta('style_sheet_id', 'styleSheetId', True, 'primitive'),
|
|
463
|
+
)
|
|
464
|
+
|
|
465
|
+
|
|
466
|
+
@register("CSS.CSSStartingStyle")
|
|
467
|
+
@dataclass
|
|
468
|
+
class CSSStartingStyle(DataType):
|
|
469
|
+
"""CSS Starting Style at-rule descriptor."""
|
|
470
|
+
range: Optional[SourceRange] = None
|
|
471
|
+
style_sheet_id: Optional[DOM_StyleSheetId] = None
|
|
472
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
473
|
+
FieldMeta('range', 'range', True, 'object', ref='CSS.SourceRange'),
|
|
474
|
+
FieldMeta('style_sheet_id', 'styleSheetId', True, 'primitive'),
|
|
475
|
+
)
|
|
476
|
+
|
|
477
|
+
|
|
478
|
+
@register("CSS.CSSLayerData")
|
|
479
|
+
@dataclass
|
|
480
|
+
class CSSLayerData(DataType):
|
|
481
|
+
"""CSS Layer data."""
|
|
482
|
+
name: str
|
|
483
|
+
order: float
|
|
484
|
+
sub_layers: Optional[List[CSSLayerData]] = None
|
|
485
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
486
|
+
FieldMeta('name', 'name', False, 'primitive'),
|
|
487
|
+
FieldMeta('order', 'order', False, 'primitive'),
|
|
488
|
+
FieldMeta('sub_layers', 'subLayers', True, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.CSSLayerData')),
|
|
489
|
+
)
|
|
490
|
+
|
|
491
|
+
|
|
492
|
+
@register("CSS.PlatformFontUsage")
|
|
493
|
+
@dataclass
|
|
494
|
+
class PlatformFontUsage(DataType):
|
|
495
|
+
"""Information about amount of glyphs that were rendered with given font."""
|
|
496
|
+
family_name: str
|
|
497
|
+
post_script_name: str
|
|
498
|
+
is_custom_font: bool
|
|
499
|
+
glyph_count: float
|
|
500
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
501
|
+
FieldMeta('family_name', 'familyName', False, 'primitive'),
|
|
502
|
+
FieldMeta('post_script_name', 'postScriptName', False, 'primitive'),
|
|
503
|
+
FieldMeta('is_custom_font', 'isCustomFont', False, 'primitive'),
|
|
504
|
+
FieldMeta('glyph_count', 'glyphCount', False, 'primitive'),
|
|
505
|
+
)
|
|
506
|
+
|
|
507
|
+
|
|
508
|
+
@register("CSS.FontVariationAxis")
|
|
509
|
+
@dataclass
|
|
510
|
+
class FontVariationAxis(DataType):
|
|
511
|
+
"""Information about font variation axes for variable fonts"""
|
|
512
|
+
tag: str
|
|
513
|
+
name: str
|
|
514
|
+
min_value: float
|
|
515
|
+
max_value: float
|
|
516
|
+
default_value: float
|
|
517
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
518
|
+
FieldMeta('tag', 'tag', False, 'primitive'),
|
|
519
|
+
FieldMeta('name', 'name', False, 'primitive'),
|
|
520
|
+
FieldMeta('min_value', 'minValue', False, 'primitive'),
|
|
521
|
+
FieldMeta('max_value', 'maxValue', False, 'primitive'),
|
|
522
|
+
FieldMeta('default_value', 'defaultValue', False, 'primitive'),
|
|
523
|
+
)
|
|
524
|
+
|
|
525
|
+
|
|
526
|
+
@register("CSS.FontFace")
|
|
527
|
+
@dataclass
|
|
528
|
+
class FontFace(DataType):
|
|
529
|
+
"""
|
|
530
|
+
Properties of a web font: https://www.w3.org/TR/2008/REC-CSS2-20080411/fonts.html#font-descriptions
|
|
531
|
+
and additional information such as platformFontFamily and fontVariationAxes.
|
|
532
|
+
"""
|
|
533
|
+
font_family: str
|
|
534
|
+
font_style: str
|
|
535
|
+
font_variant: str
|
|
536
|
+
font_weight: str
|
|
537
|
+
font_stretch: str
|
|
538
|
+
font_display: str
|
|
539
|
+
unicode_range: str
|
|
540
|
+
src: str
|
|
541
|
+
platform_font_family: str
|
|
542
|
+
font_variation_axes: Optional[List[FontVariationAxis]] = None
|
|
543
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
544
|
+
FieldMeta('font_family', 'fontFamily', False, 'primitive'),
|
|
545
|
+
FieldMeta('font_style', 'fontStyle', False, 'primitive'),
|
|
546
|
+
FieldMeta('font_variant', 'fontVariant', False, 'primitive'),
|
|
547
|
+
FieldMeta('font_weight', 'fontWeight', False, 'primitive'),
|
|
548
|
+
FieldMeta('font_stretch', 'fontStretch', False, 'primitive'),
|
|
549
|
+
FieldMeta('font_display', 'fontDisplay', False, 'primitive'),
|
|
550
|
+
FieldMeta('unicode_range', 'unicodeRange', False, 'primitive'),
|
|
551
|
+
FieldMeta('src', 'src', False, 'primitive'),
|
|
552
|
+
FieldMeta('platform_font_family', 'platformFontFamily', False, 'primitive'),
|
|
553
|
+
FieldMeta('font_variation_axes', 'fontVariationAxes', True, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.FontVariationAxis')),
|
|
554
|
+
)
|
|
555
|
+
|
|
556
|
+
|
|
557
|
+
@register("CSS.CSSTryRule")
|
|
558
|
+
@dataclass
|
|
559
|
+
class CSSTryRule(DataType):
|
|
560
|
+
"""CSS try rule representation."""
|
|
561
|
+
origin: StyleSheetOrigin
|
|
562
|
+
style: CSSStyle
|
|
563
|
+
style_sheet_id: Optional[DOM_StyleSheetId] = None
|
|
564
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
565
|
+
FieldMeta('origin', 'origin', False, 'enum', ref='CSS.StyleSheetOrigin'),
|
|
566
|
+
FieldMeta('style', 'style', False, 'object', ref='CSS.CSSStyle'),
|
|
567
|
+
FieldMeta('style_sheet_id', 'styleSheetId', True, 'primitive'),
|
|
568
|
+
)
|
|
569
|
+
|
|
570
|
+
|
|
571
|
+
@register("CSS.CSSPositionTryRule")
|
|
572
|
+
@dataclass
|
|
573
|
+
class CSSPositionTryRule(DataType):
|
|
574
|
+
"""CSS @position-try rule representation."""
|
|
575
|
+
name: Value
|
|
576
|
+
origin: StyleSheetOrigin
|
|
577
|
+
style: CSSStyle
|
|
578
|
+
active: bool
|
|
579
|
+
style_sheet_id: Optional[DOM_StyleSheetId] = None
|
|
580
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
581
|
+
FieldMeta('name', 'name', False, 'object', ref='CSS.Value'),
|
|
582
|
+
FieldMeta('origin', 'origin', False, 'enum', ref='CSS.StyleSheetOrigin'),
|
|
583
|
+
FieldMeta('style', 'style', False, 'object', ref='CSS.CSSStyle'),
|
|
584
|
+
FieldMeta('active', 'active', False, 'primitive'),
|
|
585
|
+
FieldMeta('style_sheet_id', 'styleSheetId', True, 'primitive'),
|
|
586
|
+
)
|
|
587
|
+
|
|
588
|
+
|
|
589
|
+
@register("CSS.CSSKeyframesRule")
|
|
590
|
+
@dataclass
|
|
591
|
+
class CSSKeyframesRule(DataType):
|
|
592
|
+
"""CSS keyframes rule representation."""
|
|
593
|
+
animation_name: Value
|
|
594
|
+
keyframes: List[CSSKeyframeRule]
|
|
595
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
596
|
+
FieldMeta('animation_name', 'animationName', False, 'object', ref='CSS.Value'),
|
|
597
|
+
FieldMeta('keyframes', 'keyframes', False, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.CSSKeyframeRule')),
|
|
598
|
+
)
|
|
599
|
+
|
|
600
|
+
|
|
601
|
+
@register("CSS.CSSPropertyRegistration")
|
|
602
|
+
@dataclass
|
|
603
|
+
class CSSPropertyRegistration(DataType):
|
|
604
|
+
"""Representation of a custom property registration through CSS.registerProperty"""
|
|
605
|
+
property_name: str
|
|
606
|
+
inherits: bool
|
|
607
|
+
syntax: str
|
|
608
|
+
initial_value: Optional[Value] = None
|
|
609
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
610
|
+
FieldMeta('property_name', 'propertyName', False, 'primitive'),
|
|
611
|
+
FieldMeta('inherits', 'inherits', False, 'primitive'),
|
|
612
|
+
FieldMeta('syntax', 'syntax', False, 'primitive'),
|
|
613
|
+
FieldMeta('initial_value', 'initialValue', True, 'object', ref='CSS.Value'),
|
|
614
|
+
)
|
|
615
|
+
|
|
616
|
+
|
|
617
|
+
@register("CSS.CSSAtRule")
|
|
618
|
+
@dataclass
|
|
619
|
+
class CSSAtRule(DataType):
|
|
620
|
+
"""CSS generic @rule representation."""
|
|
621
|
+
type_: Literal['font-face', 'font-feature-values', 'font-palette-values']
|
|
622
|
+
origin: StyleSheetOrigin
|
|
623
|
+
style: CSSStyle
|
|
624
|
+
subsection: Optional[Literal['swash', 'annotation', 'ornaments', 'stylistic', 'styleset', 'character-variant']] = None
|
|
625
|
+
name: Optional[Value] = None
|
|
626
|
+
style_sheet_id: Optional[DOM_StyleSheetId] = None
|
|
627
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
628
|
+
FieldMeta('type_', 'type', False, 'primitive'),
|
|
629
|
+
FieldMeta('origin', 'origin', False, 'enum', ref='CSS.StyleSheetOrigin'),
|
|
630
|
+
FieldMeta('style', 'style', False, 'object', ref='CSS.CSSStyle'),
|
|
631
|
+
FieldMeta('subsection', 'subsection', True, 'primitive'),
|
|
632
|
+
FieldMeta('name', 'name', True, 'object', ref='CSS.Value'),
|
|
633
|
+
FieldMeta('style_sheet_id', 'styleSheetId', True, 'primitive'),
|
|
634
|
+
)
|
|
635
|
+
|
|
636
|
+
|
|
637
|
+
@register("CSS.CSSPropertyRule")
|
|
638
|
+
@dataclass
|
|
639
|
+
class CSSPropertyRule(DataType):
|
|
640
|
+
"""CSS property at-rule representation."""
|
|
641
|
+
origin: StyleSheetOrigin
|
|
642
|
+
property_name: Value
|
|
643
|
+
style: CSSStyle
|
|
644
|
+
style_sheet_id: Optional[DOM_StyleSheetId] = None
|
|
645
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
646
|
+
FieldMeta('origin', 'origin', False, 'enum', ref='CSS.StyleSheetOrigin'),
|
|
647
|
+
FieldMeta('property_name', 'propertyName', False, 'object', ref='CSS.Value'),
|
|
648
|
+
FieldMeta('style', 'style', False, 'object', ref='CSS.CSSStyle'),
|
|
649
|
+
FieldMeta('style_sheet_id', 'styleSheetId', True, 'primitive'),
|
|
650
|
+
)
|
|
651
|
+
|
|
652
|
+
|
|
653
|
+
@register("CSS.CSSFunctionParameter")
|
|
654
|
+
@dataclass
|
|
655
|
+
class CSSFunctionParameter(DataType):
|
|
656
|
+
"""CSS function argument representation."""
|
|
657
|
+
name: str
|
|
658
|
+
type_: str
|
|
659
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
660
|
+
FieldMeta('name', 'name', False, 'primitive'),
|
|
661
|
+
FieldMeta('type_', 'type', False, 'primitive'),
|
|
662
|
+
)
|
|
663
|
+
|
|
664
|
+
|
|
665
|
+
@register("CSS.CSSFunctionConditionNode")
|
|
666
|
+
@dataclass
|
|
667
|
+
class CSSFunctionConditionNode(DataType):
|
|
668
|
+
"""CSS function conditional block representation."""
|
|
669
|
+
children: List[CSSFunctionNode]
|
|
670
|
+
condition_text: str
|
|
671
|
+
media: Optional[CSSMedia] = None
|
|
672
|
+
container_queries: Optional[CSSContainerQuery] = None
|
|
673
|
+
supports: Optional[CSSSupports] = None
|
|
674
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
675
|
+
FieldMeta('children', 'children', False, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.CSSFunctionNode')),
|
|
676
|
+
FieldMeta('condition_text', 'conditionText', False, 'primitive'),
|
|
677
|
+
FieldMeta('media', 'media', True, 'object', ref='CSS.CSSMedia'),
|
|
678
|
+
FieldMeta('container_queries', 'containerQueries', True, 'object', ref='CSS.CSSContainerQuery'),
|
|
679
|
+
FieldMeta('supports', 'supports', True, 'object', ref='CSS.CSSSupports'),
|
|
680
|
+
)
|
|
681
|
+
|
|
682
|
+
|
|
683
|
+
@register("CSS.CSSFunctionNode")
|
|
684
|
+
@dataclass
|
|
685
|
+
class CSSFunctionNode(DataType):
|
|
686
|
+
"""Section of the body of a CSS function rule."""
|
|
687
|
+
condition: Optional[CSSFunctionConditionNode] = None
|
|
688
|
+
style: Optional[CSSStyle] = None
|
|
689
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
690
|
+
FieldMeta('condition', 'condition', True, 'object', ref='CSS.CSSFunctionConditionNode'),
|
|
691
|
+
FieldMeta('style', 'style', True, 'object', ref='CSS.CSSStyle'),
|
|
692
|
+
)
|
|
693
|
+
|
|
694
|
+
|
|
695
|
+
@register("CSS.CSSFunctionRule")
|
|
696
|
+
@dataclass
|
|
697
|
+
class CSSFunctionRule(DataType):
|
|
698
|
+
"""CSS function at-rule representation."""
|
|
699
|
+
name: Value
|
|
700
|
+
origin: StyleSheetOrigin
|
|
701
|
+
parameters: List[CSSFunctionParameter]
|
|
702
|
+
children: List[CSSFunctionNode]
|
|
703
|
+
style_sheet_id: Optional[DOM_StyleSheetId] = None
|
|
704
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
705
|
+
FieldMeta('name', 'name', False, 'object', ref='CSS.Value'),
|
|
706
|
+
FieldMeta('origin', 'origin', False, 'enum', ref='CSS.StyleSheetOrigin'),
|
|
707
|
+
FieldMeta('parameters', 'parameters', False, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.CSSFunctionParameter')),
|
|
708
|
+
FieldMeta('children', 'children', False, 'array', inner=FieldMeta('', '', False, 'object', ref='CSS.CSSFunctionNode')),
|
|
709
|
+
FieldMeta('style_sheet_id', 'styleSheetId', True, 'primitive'),
|
|
710
|
+
)
|
|
711
|
+
|
|
712
|
+
|
|
713
|
+
@register("CSS.CSSKeyframeRule")
|
|
714
|
+
@dataclass
|
|
715
|
+
class CSSKeyframeRule(DataType):
|
|
716
|
+
"""CSS keyframe rule representation."""
|
|
717
|
+
origin: StyleSheetOrigin
|
|
718
|
+
key_text: Value
|
|
719
|
+
style: CSSStyle
|
|
720
|
+
style_sheet_id: Optional[DOM_StyleSheetId] = None
|
|
721
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
722
|
+
FieldMeta('origin', 'origin', False, 'enum', ref='CSS.StyleSheetOrigin'),
|
|
723
|
+
FieldMeta('key_text', 'keyText', False, 'object', ref='CSS.Value'),
|
|
724
|
+
FieldMeta('style', 'style', False, 'object', ref='CSS.CSSStyle'),
|
|
725
|
+
FieldMeta('style_sheet_id', 'styleSheetId', True, 'primitive'),
|
|
726
|
+
)
|
|
727
|
+
|
|
728
|
+
|
|
729
|
+
@register("CSS.StyleDeclarationEdit")
|
|
730
|
+
@dataclass
|
|
731
|
+
class StyleDeclarationEdit(DataType):
|
|
732
|
+
"""A descriptor of operation to mutate style declaration text."""
|
|
733
|
+
style_sheet_id: DOM_StyleSheetId
|
|
734
|
+
range: SourceRange
|
|
735
|
+
text: str
|
|
736
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
737
|
+
FieldMeta('style_sheet_id', 'styleSheetId', False, 'primitive'),
|
|
738
|
+
FieldMeta('range', 'range', False, 'object', ref='CSS.SourceRange'),
|
|
739
|
+
FieldMeta('text', 'text', False, 'primitive'),
|
|
740
|
+
)
|
|
741
|
+
|
|
742
|
+
__all__ = ["CSSAnimationStyle", "CSSAtRule", "CSSComputedStyleProperty", "CSSContainerQuery", "CSSFunctionConditionNode", "CSSFunctionNode", "CSSFunctionParameter", "CSSFunctionRule", "CSSKeyframeRule", "CSSKeyframesRule", "CSSLayer", "CSSLayerData", "CSSMedia", "CSSPositionTryRule", "CSSProperty", "CSSPropertyRegistration", "CSSPropertyRule", "CSSRule", "CSSRuleType", "CSSScope", "CSSStartingStyle", "CSSStyle", "CSSStyleSheetHeader", "CSSSupports", "CSSTryRule", "ComputedStyleExtraFields", "FontFace", "FontVariationAxis", "InheritedAnimatedStyleEntry", "InheritedPseudoElementMatches", "InheritedStyleEntry", "MediaQuery", "MediaQueryExpression", "PlatformFontUsage", "PseudoElementMatches", "RuleMatch", "RuleUsage", "SelectorList", "ShorthandEntry", "SourceRange", "Specificity", "StyleDeclarationEdit", "StyleSheetOrigin", "Value"]
|