accessibility

package
v0.0.0-...-fd310a9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 1, 2017 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package accessibility provides the Chrome Debugging Protocol commands, types, and events for the Accessibility domain.

Generated by the chromedp-gen command.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AXNode

type AXNode struct {
	NodeID           AXNodeID          `json:"nodeId"`                     // Unique identifier for this node.
	Ignored          bool              `json:"ignored"`                    // Whether this node is ignored for accessibility
	IgnoredReasons   []*AXProperty     `json:"ignoredReasons,omitempty"`   // Collection of reasons why this node is hidden.
	Role             *AXValue          `json:"role,omitempty"`             // This Node's role, whether explicit or implicit.
	Name             *AXValue          `json:"name,omitempty"`             // The accessible name for this Node.
	Description      *AXValue          `json:"description,omitempty"`      // The accessible description for this Node.
	Value            *AXValue          `json:"value,omitempty"`            // The value for this Node.
	Properties       []*AXProperty     `json:"properties,omitempty"`       // All other properties
	ChildIds         []AXNodeID        `json:"childIds,omitempty"`         // IDs for each of this node's child nodes.
	BackendDOMNodeID cdp.BackendNodeID `json:"backendDOMNodeId,omitempty"` // The backend ID for the associated DOM node, if any.
}

AXNode a node in the accessibility tree.

func (AXNode) MarshalEasyJSON

func (v AXNode) MarshalEasyJSON(w *jwriter.Writer)

MarshalEasyJSON supports easyjson.Marshaler interface

func (AXNode) MarshalJSON

func (v AXNode) MarshalJSON() ([]byte, error)

MarshalJSON supports json.Marshaler interface

func (*AXNode) UnmarshalEasyJSON

func (v *AXNode) UnmarshalEasyJSON(l *jlexer.Lexer)

UnmarshalEasyJSON supports easyjson.Unmarshaler interface

func (*AXNode) UnmarshalJSON

func (v *AXNode) UnmarshalJSON(data []byte) error

UnmarshalJSON supports json.Unmarshaler interface

type AXNodeID

type AXNodeID string

AXNodeID unique accessibility node identifier.

func (AXNodeID) String

func (t AXNodeID) String() string

String returns the AXNodeID as string value.

type AXProperty

type AXProperty struct {
	Name  AXPropertyName `json:"name"`  // The name of this property.
	Value *AXValue       `json:"value"` // The value of this property.
}

AXProperty [no description].

func (AXProperty) MarshalEasyJSON

func (v AXProperty) MarshalEasyJSON(w *jwriter.Writer)

MarshalEasyJSON supports easyjson.Marshaler interface

func (AXProperty) MarshalJSON

func (v AXProperty) MarshalJSON() ([]byte, error)

MarshalJSON supports json.Marshaler interface

func (*AXProperty) UnmarshalEasyJSON

func (v *AXProperty) UnmarshalEasyJSON(l *jlexer.Lexer)

UnmarshalEasyJSON supports easyjson.Unmarshaler interface

func (*AXProperty) UnmarshalJSON

func (v *AXProperty) UnmarshalJSON(data []byte) error

UnmarshalJSON supports json.Unmarshaler interface

type AXPropertyName

type AXPropertyName string

AXPropertyName values of AXProperty name: from 'busy' to 'roledescription' - states which apply to every AX node, from 'live' to 'root' - attributes which apply to nodes in live regions, from 'autocomplete' to 'valuetext' - attributes which apply to widgets, from 'checked' to 'selected' - states which apply to widgets, from 'activedescendant' to 'owns' - relationships between elements other than parent/child/sibling.

const (
	AXPropertyNameBusy             AXPropertyName = "busy"
	AXPropertyNameDisabled         AXPropertyName = "disabled"
	AXPropertyNameHidden           AXPropertyName = "hidden"
	AXPropertyNameHiddenRoot       AXPropertyName = "hiddenRoot"
	AXPropertyNameInvalid          AXPropertyName = "invalid"
	AXPropertyNameKeyshortcuts     AXPropertyName = "keyshortcuts"
	AXPropertyNameRoledescription  AXPropertyName = "roledescription"
	AXPropertyNameLive             AXPropertyName = "live"
	AXPropertyNameAtomic           AXPropertyName = "atomic"
	AXPropertyNameRelevant         AXPropertyName = "relevant"
	AXPropertyNameRoot             AXPropertyName = "root"
	AXPropertyNameAutocomplete     AXPropertyName = "autocomplete"
	AXPropertyNameHaspopup         AXPropertyName = "haspopup"
	AXPropertyNameLevel            AXPropertyName = "level"
	AXPropertyNameMultiselectable  AXPropertyName = "multiselectable"
	AXPropertyNameOrientation      AXPropertyName = "orientation"
	AXPropertyNameMultiline        AXPropertyName = "multiline"
	AXPropertyNameReadonly         AXPropertyName = "readonly"
	AXPropertyNameRequired         AXPropertyName = "required"
	AXPropertyNameValuemin         AXPropertyName = "valuemin"
	AXPropertyNameValuemax         AXPropertyName = "valuemax"
	AXPropertyNameValuetext        AXPropertyName = "valuetext"
	AXPropertyNameChecked          AXPropertyName = "checked"
	AXPropertyNameExpanded         AXPropertyName = "expanded"
	AXPropertyNameModal            AXPropertyName = "modal"
	AXPropertyNamePressed          AXPropertyName = "pressed"
	AXPropertyNameSelected         AXPropertyName = "selected"
	AXPropertyNameActivedescendant AXPropertyName = "activedescendant"
	AXPropertyNameControls         AXPropertyName = "controls"
	AXPropertyNameDescribedby      AXPropertyName = "describedby"
	AXPropertyNameDetails          AXPropertyName = "details"
	AXPropertyNameErrormessage     AXPropertyName = "errormessage"
	AXPropertyNameFlowto           AXPropertyName = "flowto"
	AXPropertyNameLabelledby       AXPropertyName = "labelledby"
	AXPropertyNameOwns             AXPropertyName = "owns"
)

AXPropertyName values.

func (AXPropertyName) MarshalEasyJSON

func (t AXPropertyName) MarshalEasyJSON(out *jwriter.Writer)

MarshalEasyJSON satisfies easyjson.Marshaler.

func (AXPropertyName) MarshalJSON

func (t AXPropertyName) MarshalJSON() ([]byte, error)

MarshalJSON satisfies json.Marshaler.

func (AXPropertyName) String

func (t AXPropertyName) String() string

String returns the AXPropertyName as string value.

func (*AXPropertyName) UnmarshalEasyJSON

func (t *AXPropertyName) UnmarshalEasyJSON(in *jlexer.Lexer)

UnmarshalEasyJSON satisfies easyjson.Unmarshaler.

func (*AXPropertyName) UnmarshalJSON

func (t *AXPropertyName) UnmarshalJSON(buf []byte) error

UnmarshalJSON satisfies json.Unmarshaler.

type AXRelatedNode

type AXRelatedNode struct {
	BackendDOMNodeID cdp.BackendNodeID `json:"backendDOMNodeId"` // The BackendNodeId of the related DOM node.
	Idref            string            `json:"idref,omitempty"`  // The IDRef value provided, if any.
	Text             string            `json:"text,omitempty"`   // The text alternative of this node in the current context.
}

AXRelatedNode [no description].

func (AXRelatedNode) MarshalEasyJSON

func (v AXRelatedNode) MarshalEasyJSON(w *jwriter.Writer)

MarshalEasyJSON supports easyjson.Marshaler interface

func (AXRelatedNode) MarshalJSON

func (v AXRelatedNode) MarshalJSON() ([]byte, error)

MarshalJSON supports json.Marshaler interface

func (*AXRelatedNode) UnmarshalEasyJSON

func (v *AXRelatedNode) UnmarshalEasyJSON(l *jlexer.Lexer)

UnmarshalEasyJSON supports easyjson.Unmarshaler interface

func (*AXRelatedNode) UnmarshalJSON

func (v *AXRelatedNode) UnmarshalJSON(data []byte) error

UnmarshalJSON supports json.Unmarshaler interface

type AXValue

type AXValue struct {
	Type         AXValueType         `json:"type"`                   // The type of this value.
	Value        easyjson.RawMessage `json:"value,omitempty"`        // The computed value of this property.
	RelatedNodes []*AXRelatedNode    `json:"relatedNodes,omitempty"` // One or more related nodes, if applicable.
	Sources      []*AXValueSource    `json:"sources,omitempty"`      // The sources which contributed to the computation of this property.
}

AXValue a single computed AX property.

func (AXValue) MarshalEasyJSON

func (v AXValue) MarshalEasyJSON(w *jwriter.Writer)

MarshalEasyJSON supports easyjson.Marshaler interface

func (AXValue) MarshalJSON

func (v AXValue) MarshalJSON() ([]byte, error)

MarshalJSON supports json.Marshaler interface

func (*AXValue) UnmarshalEasyJSON

func (v *AXValue) UnmarshalEasyJSON(l *jlexer.Lexer)

UnmarshalEasyJSON supports easyjson.Unmarshaler interface

func (*AXValue) UnmarshalJSON

func (v *AXValue) UnmarshalJSON(data []byte) error

UnmarshalJSON supports json.Unmarshaler interface

type AXValueNativeSourceType

type AXValueNativeSourceType string

AXValueNativeSourceType enum of possible native property sources (as a subtype of a particular AXValueSourceType).

const (
	AXValueNativeSourceTypeFigcaption   AXValueNativeSourceType = "figcaption"
	AXValueNativeSourceTypeLabel        AXValueNativeSourceType = "label"
	AXValueNativeSourceTypeLabelfor     AXValueNativeSourceType = "labelfor"
	AXValueNativeSourceTypeLabelwrapped AXValueNativeSourceType = "labelwrapped"
	AXValueNativeSourceTypeLegend       AXValueNativeSourceType = "legend"
	AXValueNativeSourceTypeTablecaption AXValueNativeSourceType = "tablecaption"
	AXValueNativeSourceTypeTitle        AXValueNativeSourceType = "title"
	AXValueNativeSourceTypeOther        AXValueNativeSourceType = "other"
)

AXValueNativeSourceType values.

func (AXValueNativeSourceType) MarshalEasyJSON

func (t AXValueNativeSourceType) MarshalEasyJSON(out *jwriter.Writer)

MarshalEasyJSON satisfies easyjson.Marshaler.

func (AXValueNativeSourceType) MarshalJSON

func (t AXValueNativeSourceType) MarshalJSON() ([]byte, error)

MarshalJSON satisfies json.Marshaler.

func (AXValueNativeSourceType) String

func (t AXValueNativeSourceType) String() string

String returns the AXValueNativeSourceType as string value.

func (*AXValueNativeSourceType) UnmarshalEasyJSON

func (t *AXValueNativeSourceType) UnmarshalEasyJSON(in *jlexer.Lexer)

UnmarshalEasyJSON satisfies easyjson.Unmarshaler.

func (*AXValueNativeSourceType) UnmarshalJSON

func (t *AXValueNativeSourceType) UnmarshalJSON(buf []byte) error

UnmarshalJSON satisfies json.Unmarshaler.

type AXValueSource

type AXValueSource struct {
	Type              AXValueSourceType       `json:"type"`                        // What type of source this is.
	Value             *AXValue                `json:"value,omitempty"`             // The value of this property source.
	Attribute         string                  `json:"attribute,omitempty"`         // The name of the relevant attribute, if any.
	AttributeValue    *AXValue                `json:"attributeValue,omitempty"`    // The value of the relevant attribute, if any.
	Superseded        bool                    `json:"superseded,omitempty"`        // Whether this source is superseded by a higher priority source.
	NativeSource      AXValueNativeSourceType `json:"nativeSource,omitempty"`      // The native markup source for this value, e.g. a <label> element.
	NativeSourceValue *AXValue                `json:"nativeSourceValue,omitempty"` // The value, such as a node or node list, of the native source.
	Invalid           bool                    `json:"invalid,omitempty"`           // Whether the value for this property is invalid.
	InvalidReason     string                  `json:"invalidReason,omitempty"`     // Reason for the value being invalid, if it is.
}

AXValueSource a single source for a computed AX property.

func (AXValueSource) MarshalEasyJSON

func (v AXValueSource) MarshalEasyJSON(w *jwriter.Writer)

MarshalEasyJSON supports easyjson.Marshaler interface

func (AXValueSource) MarshalJSON

func (v AXValueSource) MarshalJSON() ([]byte, error)

MarshalJSON supports json.Marshaler interface

func (*AXValueSource) UnmarshalEasyJSON

func (v *AXValueSource) UnmarshalEasyJSON(l *jlexer.Lexer)

UnmarshalEasyJSON supports easyjson.Unmarshaler interface

func (*AXValueSource) UnmarshalJSON

func (v *AXValueSource) UnmarshalJSON(data []byte) error

UnmarshalJSON supports json.Unmarshaler interface

type AXValueSourceType

type AXValueSourceType string

AXValueSourceType enum of possible property sources.

const (
	AXValueSourceTypeAttribute      AXValueSourceType = "attribute"
	AXValueSourceTypeImplicit       AXValueSourceType = "implicit"
	AXValueSourceTypeStyle          AXValueSourceType = "style"
	AXValueSourceTypeContents       AXValueSourceType = "contents"
	AXValueSourceTypePlaceholder    AXValueSourceType = "placeholder"
	AXValueSourceTypeRelatedElement AXValueSourceType = "relatedElement"
)

AXValueSourceType values.

func (AXValueSourceType) MarshalEasyJSON

func (t AXValueSourceType) MarshalEasyJSON(out *jwriter.Writer)

MarshalEasyJSON satisfies easyjson.Marshaler.

func (AXValueSourceType) MarshalJSON

func (t AXValueSourceType) MarshalJSON() ([]byte, error)

MarshalJSON satisfies json.Marshaler.

func (AXValueSourceType) String

func (t AXValueSourceType) String() string

String returns the AXValueSourceType as string value.

func (*AXValueSourceType) UnmarshalEasyJSON

func (t *AXValueSourceType) UnmarshalEasyJSON(in *jlexer.Lexer)

UnmarshalEasyJSON satisfies easyjson.Unmarshaler.

func (*AXValueSourceType) UnmarshalJSON

func (t *AXValueSourceType) UnmarshalJSON(buf []byte) error

UnmarshalJSON satisfies json.Unmarshaler.

type AXValueType

type AXValueType string

AXValueType enum of possible property types.

const (
	AXValueTypeBoolean            AXValueType = "boolean"
	AXValueTypeTristate           AXValueType = "tristate"
	AXValueTypeBooleanOrUndefined AXValueType = "booleanOrUndefined"
	AXValueTypeIdref              AXValueType = "idref"
	AXValueTypeIdrefList          AXValueType = "idrefList"
	AXValueTypeInteger            AXValueType = "integer"
	AXValueTypeNode               AXValueType = "node"
	AXValueTypeNodeList           AXValueType = "nodeList"
	AXValueTypeNumber             AXValueType = "number"
	AXValueTypeString             AXValueType = "string"
	AXValueTypeComputedString     AXValueType = "computedString"
	AXValueTypeToken              AXValueType = "token"
	AXValueTypeTokenList          AXValueType = "tokenList"
	AXValueTypeDomRelation        AXValueType = "domRelation"
	AXValueTypeRole               AXValueType = "role"
	AXValueTypeInternalRole       AXValueType = "internalRole"
	AXValueTypeValueUndefined     AXValueType = "valueUndefined"
)

AXValueType values.

func (AXValueType) MarshalEasyJSON

func (t AXValueType) MarshalEasyJSON(out *jwriter.Writer)

MarshalEasyJSON satisfies easyjson.Marshaler.

func (AXValueType) MarshalJSON

func (t AXValueType) MarshalJSON() ([]byte, error)

MarshalJSON satisfies json.Marshaler.

func (AXValueType) String

func (t AXValueType) String() string

String returns the AXValueType as string value.

func (*AXValueType) UnmarshalEasyJSON

func (t *AXValueType) UnmarshalEasyJSON(in *jlexer.Lexer)

UnmarshalEasyJSON satisfies easyjson.Unmarshaler.

func (*AXValueType) UnmarshalJSON

func (t *AXValueType) UnmarshalJSON(buf []byte) error

UnmarshalJSON satisfies json.Unmarshaler.

type GetPartialAXTreeParams

type GetPartialAXTreeParams struct {
	NodeID         cdp.NodeID `json:"nodeId"`                   // ID of node to get the partial accessibility tree for.
	FetchRelatives bool       `json:"fetchRelatives,omitempty"` // Whether to fetch this nodes ancestors, siblings and children. Defaults to true.
}

GetPartialAXTreeParams fetches the accessibility node and partial accessibility tree for this DOM node, if it exists.

func GetPartialAXTree

func GetPartialAXTree(nodeID cdp.NodeID) *GetPartialAXTreeParams

GetPartialAXTree fetches the accessibility node and partial accessibility tree for this DOM node, if it exists.

parameters:

nodeID - ID of node to get the partial accessibility tree for.

func (*GetPartialAXTreeParams) Do

func (p *GetPartialAXTreeParams) Do(ctxt context.Context, h cdp.Handler) (nodes []*AXNode, err error)

Do executes Accessibility.getPartialAXTree against the provided context and target handler.

returns:

nodes - The Accessibility.AXNode for this DOM node, if it exists, plus its ancestors, siblings and children, if requested.

func (GetPartialAXTreeParams) MarshalEasyJSON

func (v GetPartialAXTreeParams) MarshalEasyJSON(w *jwriter.Writer)

MarshalEasyJSON supports easyjson.Marshaler interface

func (GetPartialAXTreeParams) MarshalJSON

func (v GetPartialAXTreeParams) MarshalJSON() ([]byte, error)

MarshalJSON supports json.Marshaler interface

func (*GetPartialAXTreeParams) UnmarshalEasyJSON

func (v *GetPartialAXTreeParams) UnmarshalEasyJSON(l *jlexer.Lexer)

UnmarshalEasyJSON supports easyjson.Unmarshaler interface

func (*GetPartialAXTreeParams) UnmarshalJSON

func (v *GetPartialAXTreeParams) UnmarshalJSON(data []byte) error

UnmarshalJSON supports json.Unmarshaler interface

func (GetPartialAXTreeParams) WithFetchRelatives

func (p GetPartialAXTreeParams) WithFetchRelatives(fetchRelatives bool) *GetPartialAXTreeParams

WithFetchRelatives whether to fetch this nodes ancestors, siblings and children. Defaults to true.

type GetPartialAXTreeReturns

type GetPartialAXTreeReturns struct {
	Nodes []*AXNode `json:"nodes,omitempty"` // The Accessibility.AXNode for this DOM node, if it exists, plus its ancestors, siblings and children, if requested.
}

GetPartialAXTreeReturns return values.

func (GetPartialAXTreeReturns) MarshalEasyJSON

func (v GetPartialAXTreeReturns) MarshalEasyJSON(w *jwriter.Writer)

MarshalEasyJSON supports easyjson.Marshaler interface

func (GetPartialAXTreeReturns) MarshalJSON

func (v GetPartialAXTreeReturns) MarshalJSON() ([]byte, error)

MarshalJSON supports json.Marshaler interface

func (*GetPartialAXTreeReturns) UnmarshalEasyJSON

func (v *GetPartialAXTreeReturns) UnmarshalEasyJSON(l *jlexer.Lexer)

UnmarshalEasyJSON supports easyjson.Unmarshaler interface

func (*GetPartialAXTreeReturns) UnmarshalJSON

func (v *GetPartialAXTreeReturns) UnmarshalJSON(data []byte) error

UnmarshalJSON supports json.Unmarshaler interface

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL