• Sets visibility of the target element. Some elements can have custom handling, others are hidden by setting display to none.

    Parameters

    • element: HTMLElement
    • visible: boolean

      Whether the element should be visible.

    • Optional params: {
          animate?: boolean;
          layoutchange?: boolean;
          onComplete?: (() => void);
      }
      • Optional animate?: boolean

        Whether to force animation

        Default

        false
        
      • Optional layoutchange?: boolean

        Whether to call layoutchange event

        Default

        true
        
      • Optional onComplete?: (() => void)

        calls function after animation with source element as first parameter

          • (): void
          • Returns void

    Returns HTMLElement

    Source element.