Menu

Pulse

Makes an element pulse.

Example

Add yoi-action="Pulse:#id;" to make an element pulse. By default, it pulses two times:

<!-- example -->
<button class="button button--large" yoi-action="Pulse:#example-1;">Pulse</button>
<div id="example-1" class="box p-4 m-t-4 fs-2">This will pulse two times.</div>

Parent and Self Use the keyword parent to target the parent (=sourrounding) element. Use the keyword self to target the element itself.

Parameters

on Optional – a valid event (learn more). The default event is click.
trigger Optional – the trigger element to listen to (learn more).
times Oprional - the number of times the animation will play. The default value is 2.

Times

Add the parameter times to define how many times the pulse animation plays:

<!-- example -->
<button class="button button--large" yoi-action="Pulse:#example-2; times:4;">Pulse Four Times</button>
<div id="example-2" class="box p-4 m-t-4 fs-2">This will pulse four times.</div>

Events

This action does not fire any event.

Source Files

actions/pulse.js