Back to Amphtml

Hide/Show/Toggle Examples in AMP

examples/standard-actions.amp.html

latest721 B
Original Source

AMP.navigateTo()

google.comgoogle.com (_top)google.com (_blank, noopener)google.com (_blank, with opener)google.comyahoo.combing.com

AMP.print()

Print

AMP.scrollTo(el)

Scroll to Element (Global)Scroll to Element Bottom (Global)Jump to elem 2Jump to elem 3

AMP.optoutOfCid()

Opt out CID

amp-img:

ShowHideToggle Visibility

Normal element:

ShowHideToggle VisibilityToggle ClassToggle Class (force = true)Toggle Class (force = false)Toggle Checked StateToggle Checked State (force = true)Toggle Checked State (force = false)ScrollToScrollTo BottomScrollTo CenterScrollTo SlowlyFocusScrollTo and Focus

I was initially hidden.

I toggles between black and red.

You have to scroll to see me.