選項
全部
  • 公開
  • 公開/受保護
  • 全部
選單

階層

索引

屬性

方法

屬性

唯讀 ATTRIBUTE_NODE

ATTRIBUTE_NODE: number

唯讀 CDATA_SECTION_NODE

CDATA_SECTION_NODE: number

節點為 CDATASection 節點。

唯讀 COMMENT_NODE

COMMENT_NODE: number

節點為 Comment 節點。

唯讀 DOCUMENT_FRAGMENT_NODE

DOCUMENT_FRAGMENT_NODE: number

節點為 DocumentFragment 節點。

唯讀 DOCUMENT_NODE

DOCUMENT_NODE: number

節點為文件。

唯讀 DOCUMENT_POSITION_CONTAINED_BY

DOCUMENT_POSITION_CONTAINED_BY: number

當其他節點為此節點的後代時設定。

唯讀 DOCUMENT_POSITION_CONTAINS

DOCUMENT_POSITION_CONTAINS: number

當其他節點為此節點的祖先時設定。

唯讀 DOCUMENT_POSITION_DISCONNECTED

DOCUMENT_POSITION_DISCONNECTED: number

當節點和其他節點不在同一樹狀結構時設定。

唯讀 DOCUMENT_POSITION_FOLLOWING

DOCUMENT_POSITION_FOLLOWING: number

當其他節點在節點之後時設定。

唯讀 DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC

DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: number

唯讀 DOCUMENT_POSITION_PRECEDING

DOCUMENT_POSITION_PRECEDING: number

當其他節點在節點之前時設定。

唯讀 DOCUMENT_TYPE_NODE

DOCUMENT_TYPE_NODE: number

節點為 doctype。

唯讀 ELEMENT_NODE

ELEMENT_NODE: number

節點為元素。

唯讀 ENTITY_NODE

ENTITY_NODE: number

唯讀 ENTITY_REFERENCE_NODE

ENTITY_REFERENCE_NODE: number

唯讀 NOTATION_NODE

NOTATION_NODE: number

唯讀 PROCESSING_INSTRUCTION_NODE

PROCESSING_INSTRUCTION_NODE: number

節點為 ProcessingInstruction 節點。

唯讀 TEXT_NODE

TEXT_NODE: number

節點為 Text 節點。

accessKey

accessKey: string

唯讀 accessKeyLabel

accessKeyLabel: string

唯讀 assignedSlot

assignedSlot: null | HTMLSlotElement

唯讀 attributes

attributes: NamedNodeMap

autocapitalize

autocapitalize: string

autofocus

autofocus: boolean

唯讀 baseURI

baseURI: string

返回節點的文件之文件基本 URL。

唯讀 childElementCount

childElementCount: number

唯讀 childNodes

childNodes: NodeListOf<ChildNode>

回傳子節點。

唯讀 children

children: HTMLCollection

回傳子元素。

唯讀 classList

classList: DOMTokenList

允許透過 DOMTokenList 物件,將元素的 class 屬性內容視為以空白分隔的符記集合來操作。

className

className: string

回傳元素的 class 屬性的值。可以設定以更改之。

唯讀 clientHeight

clientHeight: number

唯讀 clientLeft

clientLeft: number

唯讀 clientTop

clientTop: number

唯讀 clientWidth

clientWidth: number

contentEditable

contentEditable: string

唯讀 dataset

dataset: DOMStringMap

dir

dir: string

draggable

draggable: boolean

enterKeyHint

enterKeyHint: string

eventsPrefix

eventsPrefix: string

唯讀 firstChild

firstChild: null | ChildNode

回傳第一個子節點。

唯讀 firstElementChild

firstElementChild: null | Element

回傳第一個子元素,否則回傳 null。

hidden

hidden: boolean

id

id: string

回傳元素的 id 屬性的值。可以設定以更改之。

injectStyles

injectStyles: string[]

injectStylesUrls

injectStylesUrls: string[]

innerHTML

innerHTML: string

innerText

innerText: string

inputMode

inputMode: string

唯讀 isConnected

isConnected: boolean

如果節點已連接則回傳 true,否則回傳 false。

唯讀 isContentEditable

isContentEditable: boolean

lang

lang: string

唯讀 lastChild

lastChild: null | ChildNode

回傳最後一個子節點。

唯讀 lastElementChild

lastElementChild: null | Element

回傳最後一個子元素,否則回傳 null。

唯讀 localName

localName: string

回傳本地名稱。

唯讀 namespaceURI

namespaceURI: null | string

回傳命名空間。

唯讀 nextElementSibling

nextElementSibling: null | Element

回傳第一個後續的兄弟元素,否則回傳 null。

唯讀 nextSibling

nextSibling: null | ChildNode

回傳下一個兄弟節點。

唯讀 nodeName

nodeName: string

回傳適合節點類型的字串。

唯讀 nodeType

nodeType: number

回傳節點的類型。

nodeValue

nodeValue: null | string

可選 nonce

nonce: string

唯讀 offsetHeight

offsetHeight: number

唯讀 offsetLeft

offsetLeft: number

唯讀 offsetParent

offsetParent: null | Element

唯讀 offsetTop

offsetTop: number

唯讀 offsetWidth

offsetWidth: number

onabort

onabort: null | ((ev: UIEvent) => any)

當使用者中止下載時觸發。

param

事件。

onanimationcancel

onanimationcancel: null | ((ev: AnimationEvent) => any)

onanimationend

onanimationend: null | ((ev: AnimationEvent) => any)

onanimationiteration

onanimationiteration: null | ((ev: AnimationEvent) => any)

onanimationstart

onanimationstart: null | ((ev: AnimationEvent) => any)

onauxclick

onauxclick: null | ((ev: MouseEvent) => any)

onblur

onblur: null | ((ev: FocusEvent) => any)

當物件失去輸入焦點時觸發。

param

焦點事件。

oncancel

oncancel: null | ((ev: Event) => any)

oncanplay

oncanplay: null | ((ev: Event) => any)

當可以播放但需要進一步緩衝時觸發。

param

事件。

oncanplaythrough

oncanplaythrough: null | ((ev: Event) => any)

onchange

onchange: null | ((ev: Event) => any)

當物件內容或選取範圍變更時觸發。

param

事件。

onclick

onclick: null | ((ev: MouseEvent) => any)

當使用者在物件上點擊滑鼠左鍵時觸發

param

滑鼠事件。

onclose

onclose: null | ((ev: Event) => any)

oncontextmenu

oncontextmenu: null | ((ev: MouseEvent) => any)

當使用者在客戶端區域點擊滑鼠右鍵,開啟上下文選單時觸發。

param

滑鼠事件。

oncopy

oncopy: null | ((ev: ClipboardEvent) => any)

oncuechange

oncuechange: null | ((ev: Event) => any)

oncut

oncut: null | ((ev: ClipboardEvent) => any)

ondblclick

ondblclick: null | ((ev: MouseEvent) => any)

當使用者雙擊物件時觸發。

param

滑鼠事件。

ondrag

ondrag: null | ((ev: DragEvent) => any)

在拖曳操作期間,於來源物件上持續觸發。

param

事件。

ondragend

ondragend: null | ((ev: DragEvent) => any)

當使用者在拖曳操作結束時釋放滑鼠時,於來源物件上觸發。

param

事件。

ondragenter

ondragenter: null | ((ev: DragEvent) => any)

當使用者將物件拖曳至有效的放置目標時,於目標元素上觸發。

param

拖曳事件。

ondragexit

ondragexit: null | ((ev: Event) => any)

ondragleave

ondragleave: null | ((ev: DragEvent) => any)

當使用者在拖曳操作期間將滑鼠移出有效的放置目標時,於目標物件上觸發。

param

拖曳事件。

ondragover

ondragover: null | ((ev: DragEvent) => any)

當使用者將物件拖曳至有效的放置目標上方時,於目標元素上持續觸發。

param

事件。

ondragstart

ondragstart: null | ((ev: DragEvent) => any)

當使用者開始拖曳文字選取範圍或選取的物件時,於來源物件上觸發。

param

事件。

ondrop

ondrop: null | ((ev: DragEvent) => any)

ondurationchange

ondurationchange: null | ((ev: Event) => any)

當 duration 屬性更新時觸發。

param

事件。

onemptied

onemptied: null | ((ev: Event) => any)

當媒體元素重設為其初始狀態時觸發。

param

事件。

onended

onended: null | ((ev: Event) => any)

當播放結束時觸發。

param

事件

onerror

onerror: OnErrorEventHandler

當物件載入期間發生錯誤時觸發。

param

事件。

onfocus

onfocus: null | ((ev: FocusEvent) => any)

當物件獲得焦點時觸發。

param

事件。

onfullscreenchange

onfullscreenchange: null | ((ev: Event) => any)

onfullscreenerror

onfullscreenerror: null | ((ev: Event) => any)

ongotpointercapture

ongotpointercapture: null | ((ev: PointerEvent) => any)

oninput

oninput: null | ((ev: Event) => any)

oninvalid

oninvalid: null | ((ev: Event) => any)

onkeydown

onkeydown: null | ((ev: KeyboardEvent) => any)

當使用者按下按鍵時觸發。

param

鍵盤事件

onkeypress

onkeypress: null | ((ev: KeyboardEvent) => any)

當使用者按下字母數字鍵時觸發。

param

事件。

onkeyup

onkeyup: null | ((ev: KeyboardEvent) => any)

當使用者釋放按鍵時觸發。

param

鍵盤事件

onload

onload: null | ((ev: Event) => any)

在瀏覽器載入物件後立即觸發。

param

事件。

onloadeddata

onloadeddata: null | ((ev: Event) => any)

當媒體資料在目前播放位置載入時發生。

param

事件。

onloadedmetadata

onloadedmetadata: null | ((ev: Event) => any)

當媒體的持續時間和尺寸已確定時發生。

param

事件。

onloadstart

onloadstart: null | ((ev: Event) => any)

當 Internet Explorer 開始尋找媒體資料時發生。

param

事件。

onlostpointercapture

onlostpointercapture: null | ((ev: PointerEvent) => any)

onmousedown

onmousedown: null | ((ev: MouseEvent) => any)

當使用者使用任一滑鼠按鈕點擊物件時觸發。

param

滑鼠事件。

onmouseenter

onmouseenter: null | ((ev: MouseEvent) => any)

onmouseleave

onmouseleave: null | ((ev: MouseEvent) => any)

onmousemove

onmousemove: null | ((ev: MouseEvent) => any)

當使用者將滑鼠移到物件上方時觸發。

param

滑鼠事件。

onmouseout

onmouseout: null | ((ev: MouseEvent) => any)

當使用者將滑鼠指標移出物件邊界時觸發。

param

滑鼠事件。

onmouseover

onmouseover: null | ((ev: MouseEvent) => any)

當使用者將滑鼠指標移入物件時觸發。

param

滑鼠事件。

onmouseup

onmouseup: null | ((ev: MouseEvent) => any)

當使用者將滑鼠停留在物件上方並釋放滑鼠按鈕時觸發。

param

滑鼠事件。

onpaste

onpaste: null | ((ev: ClipboardEvent) => any)

onpause

onpause: null | ((ev: Event) => any)

當播放暫停時發生。

param

事件。

onplay

onplay: null | ((ev: Event) => any)

當請求播放方法時發生。

param

事件。

onplaying

onplaying: null | ((ev: Event) => any)

當音訊或視訊開始播放時發生。

param

事件。

onpointercancel

onpointercancel: null | ((ev: PointerEvent) => any)

onpointerdown

onpointerdown: null | ((ev: PointerEvent) => any)

onpointerenter

onpointerenter: null | ((ev: PointerEvent) => any)

onpointerleave

onpointerleave: null | ((ev: PointerEvent) => any)

onpointermove

onpointermove: null | ((ev: PointerEvent) => any)

onpointerout

onpointerout: null | ((ev: PointerEvent) => any)

onpointerover

onpointerover: null | ((ev: PointerEvent) => any)

onpointerup

onpointerup: null | ((ev: PointerEvent) => any)

onprogress

onprogress: null | ((ev: ProgressEvent<EventTarget>) => any)

在下載媒體資料時,指示進度的事件。

param

事件。

onratechange

onratechange: null | ((ev: Event) => any)

當播放速率增加或減少時觸發。

param

事件。

onreset

onreset: null | ((ev: Event) => any)

當使用者重設表單時觸發。

param

事件。

onresize

onresize: null | ((ev: UIEvent) => any)

onscroll

onscroll: null | ((ev: Event) => any)

當使用者在物件的捲軸中重新定位捲軸方塊時觸發。

param

事件。

onsecuritypolicyviolation

onsecuritypolicyviolation: null | ((ev: SecurityPolicyViolationEvent) => any)

onseeked

onseeked: null | ((ev: Event) => any)

當搜尋操作結束時觸發。

param

事件。

onseeking

onseeking: null | ((ev: Event) => any)

當目前的播放位置被移動時觸發。

param

事件。

onselect

onselect: null | ((ev: Event) => any)

當目前的選取範圍變更時觸發。

param

事件。

onselectionchange

onselectionchange: null | ((ev: Event) => any)

onselectstart

onselectstart: null | ((ev: Event) => any)

onstalled

onstalled: null | ((ev: Event) => any)

當下載已停止時觸發。

param

事件。

onsubmit

onsubmit: null | ((ev: Event) => any)

onsuspend

onsuspend: null | ((ev: Event) => any)

如果載入操作被刻意停止時觸發。

param

事件。

ontimeupdate

ontimeupdate: null | ((ev: Event) => any)

指示目前的播放位置時觸發。

param

事件。

ontoggle

ontoggle: null | ((ev: Event) => any)

可選 ontouchcancel

ontouchcancel: null | ((ev: TouchEvent) => any)

可選 ontouchend

ontouchend: null | ((ev: TouchEvent) => any)

可選 ontouchmove

ontouchmove: null | ((ev: TouchEvent) => any)

可選 ontouchstart

ontouchstart: null | ((ev: TouchEvent) => any)

ontransitioncancel

ontransitioncancel: null | ((ev: TransitionEvent) => any)

ontransitionend

ontransitionend: null | ((ev: TransitionEvent) => any)

ontransitionrun

ontransitionrun: null | ((ev: TransitionEvent) => any)

ontransitionstart

ontransitionstart: null | ((ev: TransitionEvent) => any)

onvolumechange

onvolumechange: null | ((ev: Event) => any)

當音量改變,或播放被靜音或取消靜音時觸發。

param

事件。

onwaiting

onwaiting: null | ((ev: Event) => any)

當播放停止,因為影片資源的下一幀無法取得時觸發。

param

事件。

onwheel

onwheel: null | ((ev: WheelEvent) => any)

outerHTML

outerHTML: string

唯讀 ownerDocument

ownerDocument: Document

唯讀 parentElement

parentElement: null | HTMLElement

返回父元素。

唯讀 parentNode

parentNode: null | (Node & ParentNode)

返回父節點。

唯讀 prefix

prefix: null | string

返回命名空間前綴。

唯讀 previousElementSibling

previousElementSibling: null | Element

返回第一個在前的元素同層級元素,若無則返回 null。

唯讀 previousSibling

previousSibling: null | ChildNode

返回前一個同層級節點。

唯讀 scrollHeight

scrollHeight: number

scrollLeft

scrollLeft: number

scrollTop

scrollTop: number

唯讀 scrollWidth

scrollWidth: number

唯讀 shadowRoot

shadowRoot: null | ShadowRoot

返回元素的陰影根(如果有),並且陰影根的模式為 "open",否則返回 null。

slot

slot: string

返回元素 slot 內容屬性的值。可以設定來更改它。

spellcheck

spellcheck: boolean

唯讀 style

style: CSSStyleDeclaration

swiper

swiper: any

tabIndex

tabIndex: number

唯讀 tagName

tagName: string

返回 HTML 大寫限定名稱。

textContent

textContent: null | string

title

title: string

translate

translate: boolean

方法

addEventListener

  • addEventListener<K>(type: K, listener: (ev: SwiperContainerEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void
  • addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void
  • 型別參數

    • K: keyof SwiperContainerEventMap

    參數

    • type: K
    • listener: (ev: SwiperContainerEventMap[K]) => any
        • (ev: SwiperContainerEventMap[K]): any
        • 參數

          • ev: SwiperContainerEventMap[K]

          返回 any

    • 可選 options: boolean | AddEventListenerOptions

    返回 void

  • 參數

    • type: string
    • listener: EventListenerOrEventListenerObject
    • 可選 options: boolean | AddEventListenerOptions

    返回 void

after

  • after(...nodes: (string | Node)[]): void
  • 在節點之後插入節點,同時將 nodes 中的字串替換為等效的 Text 節點。

    如果違反節點樹的約束,則會拋出 "HierarchyRequestError" DOMException。

    參數

    • 其餘參數 ...nodes: (string | Node)[]

    返回 void

animate

  • animate(keyframes: null | Keyframe[] | PropertyIndexedKeyframes, options?: number | KeyframeAnimationOptions): Animation
  • 參數

    • keyframes: null | Keyframe[] | PropertyIndexedKeyframes
    • 可選 options: number | KeyframeAnimationOptions

    回傳 Animation

append

  • append(...nodes: (string | Node)[]): void
  • 在節點的最後一個子節點之後插入節點,同時將節點中的字串替換為等效的文字節點。

    如果違反節點樹的約束,則會拋出 "HierarchyRequestError" DOMException。

    參數

    • 其餘參數 ...nodes: (string | Node)[]

    返回 void

appendChild

  • appendChild<T>(newChild: T): T
  • 型別參數

    • T: Node

    參數

    • newChild: T

    回傳 T

attachShadow

  • attachShadow(init: ShadowRootInit): ShadowRoot
  • 為元素建立陰影根並傳回它。

    參數

    • init: ShadowRootInit

    回傳 ShadowRoot

before

  • before(...nodes: (string | Node)[]): void
  • 在節點之前插入節點,同時將節點中的字串替換為等效的文字節點。

    如果違反節點樹的約束,則會拋出 "HierarchyRequestError" DOMException。

    參數

    • 其餘參數 ...nodes: (string | Node)[]

    返回 void

blur

  • blur(): void
  • 返回 void

click

  • click(): void
  • 返回 void

cloneNode

  • cloneNode(deep?: boolean): Node
  • 回傳節點的副本。如果 deep 為 true,則副本還包括節點的後代。

    參數

    • 可選 deep: boolean

    回傳 Node

closest

  • closest<K>(selector: K): null | HTMLElementTagNameMap[K]
  • closest<K>(selector: K): null | SVGElementTagNameMap[K]
  • closest<E>(selector: string): null | E
  • 回傳第一個 (從元素開始) 符合選擇器的祖先 (包含元素本身),否則回傳 null。

    型別參數

    • K: keyof HTMLElementTagNameMap

    參數

    • selector: K

    回傳 null | HTMLElementTagNameMap[K]

  • 型別參數

    • K: keyof SVGElementTagNameMap

    參數

    • selector: K

    回傳 null | SVGElementTagNameMap[K]

  • 型別參數

    • E: Element = Element

    參數

    • selector: string

    回傳 null | E

compareDocumentPosition

  • compareDocumentPosition(other: Node): number
  • 回傳一個位元遮罩,指示 other 相對於 node 的位置。

    參數

    • other: Node

    回傳 number

contains

  • contains(other: null | Node): boolean
  • 如果 other 是 node 的後代 (包含自身),則回傳 true,否則回傳 false。

    參數

    • other: null | Node

    回傳 boolean

dispatchEvent

  • dispatchEvent(event: Event): boolean
  • 將合成事件 event 分派到目標,如果事件的 cancelable 屬性值為 false,或者未呼叫其 preventDefault() 方法,則回傳 true,否則回傳 false。

    參數

    • event: Event

    回傳 boolean

focus

  • focus(options?: FocusOptions): void
  • 參數

    • 可選 options: FocusOptions

    返回 void

getAnimations

  • getAnimations(): Animation[]
  • 回傳 Animation[]

getAttribute

  • getAttribute(qualifiedName: string): null | string
  • 回傳元素的 qualifiedName 屬性的第一個值,如果沒有此屬性則回傳 null。

    參數

    • qualifiedName: string

    回傳 null | string

getAttributeNS

  • getAttributeNS(namespace: null | string, localName: string): null | string
  • 回傳命名空間為 namespace 且本機名稱為 localName 的元素屬性,如果沒有此屬性則回傳 null。

    參數

    • namespace: null | string
    • localName: string

    回傳 null | string

getAttributeNames

  • getAttributeNames(): string[]
  • 回傳元素所有屬性的 qualified name。可以包含重複項。

    回傳 string[]

getAttributeNode

  • getAttributeNode(qualifiedName: string): null | Attr
  • 參數

    • qualifiedName: string

    回傳 null | Attr

getAttributeNodeNS

  • getAttributeNodeNS(namespace: null | string, localName: string): null | Attr
  • 參數

    • namespace: null | string
    • localName: string

    回傳 null | Attr

getBoundingClientRect

  • getBoundingClientRect(): DOMRect
  • 回傳 DOMRect

getClientRects

  • getClientRects(): DOMRectList
  • 回傳 DOMRectList

getElementsByClassName

  • getElementsByClassName(classNames: string): HTMLCollectionOf<Element>
  • 回傳一個 HTMLCollection,其中包含方法調用物件 (文件或元素) 中,具有 classNames 給定的所有類別的元素。classNames 引數會被視為以空格分隔的類別列表。

    參數

    • classNames: string

    回傳 HTMLCollectionOf<Element>

getElementsByTagName

  • getElementsByTagName<K>(qualifiedName: K): HTMLCollectionOf<HTMLElementTagNameMap[K]>
  • getElementsByTagName<K>(qualifiedName: K): HTMLCollectionOf<SVGElementTagNameMap[K]>
  • getElementsByTagName(qualifiedName: string): HTMLCollectionOf<Element>
  • 型別參數

    • K: keyof HTMLElementTagNameMap

    參數

    • qualifiedName: K

    返回 HTMLCollectionOf<HTMLElementTagNameMap[K]>

  • 型別參數

    • K: keyof SVGElementTagNameMap

    參數

    • qualifiedName: K

    返回 HTMLCollectionOf<SVGElementTagNameMap[K]>

  • 參數

    • qualifiedName: string

    回傳 HTMLCollectionOf<Element>

getElementsByTagNameNS

  • getElementsByTagNameNS(namespaceURI: "http://www.w3.org/1999/xhtml", localName: string): HTMLCollectionOf<HTMLElement>
  • getElementsByTagNameNS(namespaceURI: "http://www.w3.org/2000/svg", localName: string): HTMLCollectionOf<SVGElement>
  • getElementsByTagNameNS(namespaceURI: string, localName: string): HTMLCollectionOf<Element>
  • 參數

    • namespaceURI: "http://www.w3.org/1999/xhtml"
    • localName: string

    返回 HTMLCollectionOf<HTMLElement>

  • 參數

    • namespaceURI: "http://www.w3.org/2000/svg"
    • localName: string

    返回 HTMLCollectionOf<SVGElement>

  • 參數

    • namespaceURI: string
    • localName: string

    回傳 HTMLCollectionOf<Element>

getRootNode

  • getRootNode(options?: GetRootNodeOptions): Node
  • 返回節點的根。

    參數

    • 可選 options: GetRootNodeOptions

    回傳 Node

hasAttribute

  • hasAttribute(qualifiedName: string): boolean
  • 如果元素具有 qualifiedName 的屬性,則返回 true,否則返回 false。

    參數

    • qualifiedName: string

    回傳 boolean

hasAttributeNS

  • hasAttributeNS(namespace: null | string, localName: string): boolean
  • 如果元素具有命名空間為 namespace 且本地名稱為 localName 的屬性,則返回 true。

    參數

    • namespace: null | string
    • localName: string

    回傳 boolean

hasAttributes

  • hasAttributes(): boolean
  • 如果元素具有屬性,則返回 true,否則返回 false。

    回傳 boolean

hasChildNodes

  • hasChildNodes(): boolean
  • 返回節點是否有子節點。

    回傳 boolean

hasPointerCapture

  • hasPointerCapture(pointerId: number): boolean
  • 參數

    • pointerId: number

    回傳 boolean

initialize

  • initialize(): void
  • 返回 void

insertAdjacentElement

  • insertAdjacentElement(position: InsertPosition, insertedElement: Element): null | Element
  • 參數

    • position: InsertPosition
    • insertedElement: Element

    返回 null | Element

insertAdjacentHTML

  • insertAdjacentHTML(where: InsertPosition, html: string): void
  • 參數

    • where: InsertPosition
    • html: string

    返回 void

insertAdjacentText

  • insertAdjacentText(where: InsertPosition, text: string): void
  • 參數

    • where: InsertPosition
    • text: string

    返回 void

insertBefore

  • insertBefore<T>(newChild: T, refChild: null | Node): T
  • 型別參數

    • T: Node

    參數

    • newChild: T
    • refChild: null | Node

    回傳 T

isDefaultNamespace

  • isDefaultNamespace(namespace: null | string): boolean
  • 參數

    • namespace: null | string

    回傳 boolean

isEqualNode

  • isEqualNode(otherNode: null | Node): boolean
  • 返回節點和 otherNode 是否具有相同的屬性。

    參數

    • otherNode: null | Node

    回傳 boolean

isSameNode

  • isSameNode(otherNode: null | Node): boolean
  • 參數

    • otherNode: null | Node

    回傳 boolean

lookupNamespaceURI

  • lookupNamespaceURI(prefix: null | string): null | string
  • 參數

    • prefix: null | string

    回傳 null | string

lookupPrefix

  • lookupPrefix(namespace: null | string): null | string
  • 參數

    • namespace: null | string

    回傳 null | string

matches

  • matches(selectors: string): boolean
  • 如果將 selectors 與元素的根進行匹配會產生元素,則返回 true,否則返回 false。

    參數

    • selectors: string

    回傳 boolean

msGetRegionContent

  • msGetRegionContent(): any
  • 返回 any

normalize

  • normalize(): void
  • 移除空的 exclusive Text 節點,並將剩餘連續 exclusive Text 節點的資料連接到它們的第一個節點。

    返回 void

prepend

  • prepend(...nodes: (string | Node)[]): void
  • 在節點的第一個子節點之前插入節點,同時用等效的 Text 節點替換節點中的字串。

    如果違反節點樹的約束,則會拋出 "HierarchyRequestError" DOMException。

    參數

    • 其餘參數 ...nodes: (string | Node)[]

    返回 void

querySelector

  • querySelector<K>(selectors: K): null | HTMLElementTagNameMap[K]
  • querySelector<K>(selectors: K): null | SVGElementTagNameMap[K]
  • querySelector<E>(selectors: string): null | E
  • 返回與 selectors 相符的節點的第一個子元素。

    型別參數

    • K: keyof HTMLElementTagNameMap

    參數

    • selectors: K

    回傳 null | HTMLElementTagNameMap[K]

  • 型別參數

    • K: keyof SVGElementTagNameMap

    參數

    • selectors: K

    回傳 null | SVGElementTagNameMap[K]

  • 型別參數

    • E: Element = Element

    參數

    • selectors: string

    回傳 null | E

querySelectorAll

  • querySelectorAll<K>(selectors: K): NodeListOf<HTMLElementTagNameMap[K]>
  • querySelectorAll<K>(selectors: K): NodeListOf<SVGElementTagNameMap[K]>
  • querySelectorAll<E>(selectors: string): NodeListOf<E>
  • 返回與 selectors 相符的節點的所有子元素。

    型別參數

    • K: keyof HTMLElementTagNameMap

    參數

    • selectors: K

    返回 NodeListOf<HTMLElementTagNameMap[K]>

  • 型別參數

    • K: keyof SVGElementTagNameMap

    參數

    • selectors: K

    返回 NodeListOf<SVGElementTagNameMap[K]>

  • 型別參數

    • E: Element = Element

    參數

    • selectors: string

    返回 NodeListOf<E>

releasePointerCapture

  • releasePointerCapture(pointerId: number): void
  • 參數

    • pointerId: number

    返回 void

remove

  • remove(): void
  • 移除節點。

    返回 void

removeAttribute

  • removeAttribute(qualifiedName: string): void
  • 移除元素第一個符合 qualifiedName 限定名稱的屬性。

    參數

    • qualifiedName: string

    返回 void

removeAttributeNS

  • removeAttributeNS(namespace: null | string, localName: string): void
  • 移除元素命名空間為 namespace 且本地名稱為 localName 的屬性。

    參數

    • namespace: null | string
    • localName: string

    返回 void

removeAttributeNode

  • removeAttributeNode(attr: Attr): Attr
  • 參數

    • attr: Attr

    返回 Attr

removeChild

  • removeChild<T>(oldChild: T): T
  • 型別參數

    • T: Node

    參數

    • oldChild: T

    回傳 T

removeEventListener

  • removeEventListener<K>(type: K, listener: (ev: SwiperContainerEventMap[K]) => any, options?: boolean | EventListenerOptions): void
  • removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void
  • 型別參數

    • K: keyof SwiperContainerEventMap

    參數

    • type: K
    • listener: (ev: SwiperContainerEventMap[K]) => any
        • (ev: SwiperContainerEventMap[K]): any
        • 參數

          • ev: SwiperContainerEventMap[K]

          返回 any

    • 可選 options: boolean | EventListenerOptions

    返回 void

  • 參數

    • type: string
    • listener: EventListenerOrEventListenerObject
    • 可選 options: boolean | EventListenerOptions

    返回 void

replaceChild

  • replaceChild<T>(newChild: Node, oldChild: T): T
  • 型別參數

    • T: Node

    參數

    • newChild: Node
    • oldChild: T

    回傳 T

replaceWith

  • replaceWith(...nodes: (string | Node)[]): void
  • 將節點替換為 nodes,同時將 nodes 中的字串替換為等效的文字節點。

    如果違反節點樹的約束,則會拋出 "HierarchyRequestError" DOMException。

    參數

    • 其餘參數 ...nodes: (string | Node)[]

    返回 void

requestFullscreen

  • requestFullscreen(options?: FullscreenOptions): Promise<void>
  • 將元素顯示為全螢幕,並在完成時解析 Promise。

    當提供 options 時,其 navigationUI 成員表示是否偏好在全螢幕模式下顯示導覽 UI。如果設定為 "show",則導覽簡潔度優先於螢幕空間,如果設定為 "hide",則更多螢幕空間優先。使用者代理程式始終可以自由地優先考慮使用者的偏好,而不是應用程式的偏好。預設值 "auto" 表示沒有應用程式偏好。

    參數

    • 可選 options: FullscreenOptions

    返回 Promise<void>

requestPointerLock

  • requestPointerLock(): void
  • 返回 void

scroll

  • scroll(options?: ScrollToOptions): void
  • scroll(x: number, y: number): void
  • 參數

    • 可選 options: ScrollToOptions

    返回 void

  • 參數

    • x: number
    • y: number

    返回 void

scrollBy

  • scrollBy(options?: ScrollToOptions): void
  • scrollBy(x: number, y: number): void
  • 參數

    • 可選 options: ScrollToOptions

    返回 void

  • 參數

    • x: number
    • y: number

    返回 void

scrollIntoView

  • scrollIntoView(arg?: boolean | ScrollIntoViewOptions): void
  • 參數

    • 可選 arg: boolean | ScrollIntoViewOptions

    返回 void

scrollTo

  • scrollTo(options?: ScrollToOptions): void
  • scrollTo(x: number, y: number): void
  • 參數

    • 可選 options: ScrollToOptions

    返回 void

  • 參數

    • x: number
    • y: number

    返回 void

setAttribute

  • setAttribute(qualifiedName: string, value: string): void
  • 將元素第一個符合 qualifiedName 限定名稱的屬性的值設定為 value。

    參數

    • qualifiedName: string
    • value: string

    返回 void

setAttributeNS

  • setAttributeNS(namespace: null | string, qualifiedName: string, value: string): void
  • 將元素命名空間為 namespace 且本地名稱為 localName 的屬性的值設定為 value。

    參數

    • namespace: null | string
    • qualifiedName: string
    • value: string

    返回 void

setAttributeNode

  • setAttributeNode(attr: Attr): null | Attr
  • 參數

    • attr: Attr

    回傳 null | Attr

setAttributeNodeNS

  • setAttributeNodeNS(attr: Attr): null | Attr
  • 參數

    • attr: Attr

    回傳 null | Attr

setPointerCapture

  • setPointerCapture(pointerId: number): void
  • 參數

    • pointerId: number

    返回 void

toggleAttribute

  • toggleAttribute(qualifiedName: string, force?: boolean): boolean
  • 如果未提供 force,則「切換」qualifiedName,如果存在則移除,如果不存在則新增。如果 force 為 true,則新增 qualifiedName。如果 force 為 false,則移除 qualifiedName。

    如果 qualifiedName 現在存在,則返回 true,否則返回 false。

    參數

    • qualifiedName: string
    • 可選 force: boolean

    回傳 boolean

webkitMatchesSelector

  • webkitMatchesSelector(selectors: string): boolean
  • 參數

    • selectors: string

    回傳 boolean

使用 TypeDoc 生成