填寫這份《一分鐘調查》,幫我們(開發組)做得更好!去填寫Home

MockAnimationDriver

      
      class MockAnimationDriver implements AnimationDriver {
  static log: AnimationPlayer[]
  validateStyleProperty(prop: string): boolean
  matchesElement(element: any, selector: string): boolean
  containsElement(elm1: any, elm2: any): boolean
  query(element: any, selector: string, multi: boolean): any[]
  computeStyle(element: any, prop: string, defaultValue?: string): string
  animate(element: any, keyframes: { [key: string]: string | number; }[], duration: number, delay: number, easing: string, previousPlayers: any[] = []): MockAnimationPlayer
}
    

靜態屬性

屬性說明
static log: AnimationPlayer[]

方法

      
      validateStyleProperty(prop: string): boolean
    
引數
prop string
返回值

boolean

      
      matchesElement(element: any, selector: string): boolean
    
引數
element any
selector string
返回值

boolean

      
      containsElement(elm1: any, elm2: any): boolean
    
引數
elm1 any
elm2 any
返回值

boolean

      
      query(element: any, selector: string, multi: boolean): any[]
    
引數
element any
selector string
multi boolean
返回值

any[]

      
      computeStyle(element: any, prop: string, defaultValue?: string): string
    
引數
element any
prop string
defaultValue string
可選. 預設值是 `undefined`.
返回值

string

      
      animate(element: any, keyframes: { [key: string]: string | number; }[], duration: number, delay: number, easing: string, previousPlayers: any[] = []): MockAnimationPlayer
    
引數
element any
keyframes { [key: string]: string | number; }[]
duration number
delay number
easing string
previousPlayers any[]
可選. 預設值是 `[]`.
返回值

MockAnimationPlayer