{# @description Sends a ripple along a line, each letter rising and settling a moment after the one before it. #} {# @prop text:text | required | description:"The line to set moving. Plain words: it is split into its letters." #} {# @prop height:number | default:"0.2" | description:"How far a letter rises, as a share of its own height" #} {# @prop speed:number | default:"1" | description:"How quickly the ripple travels, as a multiple: 2 is twice as fast, 0.5 half, and 0 holds the line still" #} {# @prop repeat:number | description:"How many times each letter rises before it stops. Left out, it never stops." #} {# @prop class:text | description:"Extra classes on the span" #} {% comment %} A line can break between any two inline boxes, so each word is wrapped to keep it whole. A letter takes its turn from its word and its place in it (docs/adr/0005-text-effects-are-spans-moved-by-css.md). {% endcomment %} {% load text_effects %} {% with line=text|plain pace=speed|floatformat:'-3u'|default:'1' %} {{ line|escape }} {# djlint:off #} {# djlint:on #} {% endwith %}