ComputedStyle <Native_Element_Type>
Hierarchy
- Question<Promise<string>>
- ComputedStyle
Implements
- MetaQuestion<PageElement<Native_Element_Type>, Question<Promise<string>>>
Index
Methods
staticcalled
Instantiates a Question that uses the actor’s ability to BrowseTheWeb to retrieve the value of the specified computed style property of a given PageElement.
Type parameters
- NET = any
Parameters
name: Answerable<string>
The name of the computed style property to retrieve
Returns ComputedStyle<NET>
as
Maps this question to one of a different type.
Question.about('number returned as string', actor => '42') // returns: QuestionAdapter<string>
.as(Number) // returns: QuestionAdapter<number>Type parameters
- O
Parameters
mapping: (answer: string) => O | Promise<O>
Returns QuestionAdapter<O>
ofPseudoElement
Instantiates a Question that uses the actor’s ability to BrowseTheWeb to retrieve the value of the specified computed style property of the specified pseudo-element of a given PageElement.
Parameters
pseudoElement: Answerable<string>
The pseudo-element to retrieve the computed style property from, such as
::before
or::after
Returns MetaQuestionAdapter<PageElement<Native_Element_Type>, string>
of
Parameters
pageElement: PageElement<Native_Element_Type> | QuestionAdapter<PageElement<Native_Element_Type>>
Returns MetaQuestionAdapter<PageElement<Native_Element_Type>, string>
answeredBy
Parameters
actor: AnswersQuestions & UsesAbilities
Returns Promise<string>
describedAs
Parameters
subject: string
Returns ComputedStyle<Native_Element_Type>
toString
Returns string
Uses the actor’s ability to BrowseTheWeb to retrieve the value of the specified computed style property of a given PageElement.
Example widget
Retrieve a computed style property of a given PageElement
Using
ComputedStyle
as QuestionAdapterUsing as filter in Page Element Query Language
Learn more