import { MetaQuestion , Question } from '@serenity-js/core' ; import { ElementArrayFinder , ElementFinder } from 'protractor' ; import { TextOfMultipleElements } from './TextOfMultipleElements' ; import { TextOfSingleElement } from './TextOfSingleElement' ; desc Resolves to the visible (i.e. not hidden by CSS) `innerText` of:
 *  - a given  WebElement , represented by  ElementFinder or `Question<ElementFinder>`,
 *  - a group of  WebElement s, represented by  ElementArrayFinder or `Question<ElementArrayFinder>`.
 *
 *  The result includes the visible text of any sub-elements, without any leading or trailing whitespace.
 *
 *  public extends serenity-js implements serenity-js export class Text { desc Retrieves text of a single  WebElement ,
     *  represented by  ElementFinder *  or `Question<ElementFinder>`.
     *
     *  param { Question < ElementFinder > | ElementFinder } target returns { Question < Promise < string > > & MetaQuestion < Question < ElementFinder > | ElementFinder , Promise < string > > } see {@link @serenity-js/core/lib/screenplay/questions~MetaQuestion} static of ( target ) { return new TextOfSingleElement ( target ) ; } desc Retrieves text of a group of  WebElement s,
     *  represented by  ElementArrayFinder *  or `Question<ElementArrayFinder>`
     *
     *  param { Question < ElementArrayFinder > | ElementArrayFinder } target returns { Question < Promise < string [ ] > > & MetaQuestion < Question < ElementFinder > | ElementFinder , Promise < string [ ] > > } see {@link @serenity-js/core/lib/screenplay/questions~MetaQuestion} static ofAll ( target ) { return new TextOfMultipleElements ( target ) ; } }