File tree Expand file tree Collapse file tree 1 file changed +14
-2
lines changed Expand file tree Collapse file tree 1 file changed +14
-2
lines changed Original file line number Diff line number Diff line change 42
42
* @method array location() Determine an element's location on the page.
43
43
* @method array location_in_view() Determine an element's location on the screen once it has been scrolled into view.
44
44
* @method array size() Determine an element's size in pixels.
45
- * @method string css($propertyName) Query the value of an element's computed CSS property.
46
45
*/
47
46
final class Element extends Container
48
47
{
@@ -66,7 +65,6 @@ protected function methods()
66
65
'location ' => array ('GET ' ),
67
66
'location_in_view ' => array ('GET ' ),
68
67
'size ' => array ('GET ' ),
69
- 'css ' => array ('GET ' ),
70
68
);
71
69
}
72
70
@@ -114,6 +112,20 @@ public function getID()
114
112
return $ this ->id ;
115
113
}
116
114
115
+ /**
116
+ * Query the value of an element’s computed CSS property: /session/:sessionId/element/:id/css/:propertyName
117
+ *
118
+ * @param string $propertyName
119
+ *
120
+ * @return mixed
121
+ */
122
+ public function css ($ propertyName )
123
+ {
124
+ $ result = $ this ->curl ('GET ' , "/css/ $ propertyName " );
125
+
126
+ return $ result ['value ' ];
127
+ }
128
+
117
129
/**
118
130
* {@inheritdoc}
119
131
*/
You can’t perform that action at this time.
0 commit comments