
The elastic button
Buttons, Hover, Text
The task search of Pondwise, an invented project app, on white, in the premium style of Dribbble shots: under the field a strip of twelve weeks shows how many matching tasks there are in each week. As you type the bars grow and shrink on a spring; over the bars a glass window with two grips narrows from either side and slides whole, the weeks inside turn tangerine, the rows below leave and arrive on a spring while those that stay glide into place, and the count and the dates roll.
A folder that runs on its own: index.html, style.css, script.js and the libraries from a CDN. The React and Vue tabs hold the same demo as a ready component, which switches its animations off when it leaves the page.
<!doctype html>
<!--
"Task search with weeks" from Animorio · https://animorio.com
License: free on your own sites and your clients’ sites, paid work included.
Not for resale, redistribution, templates or code collections · https://animorio.com/en/license/
-->
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>The task search with a week range to narrow under the field</title>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fontsource-variable/mona-sans@5.3.0/wdth.css">
<link rel="stylesheet" href="style.css">
</head>
<body>
<main class="stage">
<!-- the task search of Pondwise, a project app: under the field a strip of twelve weeks shows how many tasks match
in each week. Typing reshapes the bars on springs; the window over the bars is dragged by its grips or by its
middle to narrow the weeks, the rows below leave and arrive on a spring and the count rolls -->
<div class="wrap" data-wrap>
<section class="card" data-card role="search" aria-label="Search the project tasks">
<i class="card__grain" aria-hidden="true"></i>
<i class="card__sheen" aria-hidden="true"></i>
<div class="field" data-field>
<svg class="field__lens" data-lens viewBox="0 0 20 20" aria-hidden="true"><circle cx="8.6" cy="8.6" r="5.4"/><path d="M12.6 12.6l4.2 4.2"/></svg>
<span class="field__type">
<label class="sr" for="task-q">Search tasks</label>
<input class="field__input" id="task-q" type="text" autocomplete="off" spellcheck="false" placeholder="Search tasks in Pondwise" data-input aria-controls="task-list">
<span class="field__caret" data-caret aria-hidden="true"></span>
<span class="field__measure" data-measure aria-hidden="true"></span>
</span>
<button class="field__clear" type="button" data-clear aria-label="Clear the search">
<svg viewBox="0 0 20 20" aria-hidden="true"><path d="M6.5 6.5l7 7M13.5 6.5l-7 7"/></svg>
</button>
</div>
<div class="weeks" data-weeks>
<div class="weeks__top">
<span class="weeks__label">Updated</span>
<span class="weeks__range" data-range aria-live="polite"><span class="weeks__range-in" data-range-in>Aug 17 – Nov 8</span></span>
</div>
<div class="strip" data-strip>
<div class="bars" data-bars aria-hidden="true"></div>
<div class="brush" data-brush>
<i class="brush__glass" aria-hidden="true"></i>
<i class="brush__glint" data-glint aria-hidden="true"></i>
<button class="grip grip--lo" type="button" data-grip="lo" role="slider" aria-label="First week" aria-valuemin="0" aria-valuemax="11" aria-valuenow="0"><i></i></button>
<button class="grip grip--hi" type="button" data-grip="hi" role="slider" aria-label="Last week" aria-valuemin="0" aria-valuemax="11" aria-valuenow="11"><i></i></button>
</div>
<div class="tip" data-tip aria-hidden="true"><span data-tip-w></span><b data-tip-n></b></div>
</div>
<div class="months" data-months aria-hidden="true"></div>
</div>
<div class="sum" aria-hidden="true">
<span class="sum__count"><span class="roll" data-roll><span class="roll__n" data-roll-n>0</span></span> <span data-sum-word>tasks</span></span>
<span class="sum__in" data-sum-in>in 12 weeks</span>
</div>
<div class="list" id="task-list" data-list role="list" aria-label="Tasks">
<div class="rows" data-rows></div>
<p class="empty" data-empty>
<svg viewBox="0 0 24 24" aria-hidden="true"><rect x="4" y="4" width="16" height="16" rx="4"/><path d="M8.5 12h7"/></svg>
<span data-empty-t>No tasks in these weeks</span>
</p>
</div>
</section>
</div>
<p class="sr" aria-live="polite" data-live></p>
</main>
<script src="https://cdn.jsdelivr.net/npm/gsap@3.15.0/dist/gsap.min.js"></script>
<script src="script.js"></script>
</body>
</html>Change values, colours and text with the controls and watch the animation respond live. Or write in the code yourself. Then download the folder with your changes.
27 values to change
With the Animorio connector, Claude Code, ChatGPT, Cursor or VS Code take it from here, guide included, and fit it into your project. Paste this request:
Take “Task search with weeks” from Animorio and fit it into my siteThe tasks are a list of objects with key, title, week and day. A regex looks for the word at the start of a word in the title; the matches are counted per week in an array of twelve, and the list keeps only those between the first and the last week of the window, newest first.
Each bar is a fill with its height in pixels, worked out from the strip height measured on resize and divided by the fullest week. GSAP takes it to the new height with a damped spring written as an ease, with a small delay spreading from the middle of the window.
The window is one element with x and width in pixels (start week times column width). With the pointer captured the two ends move in decimal weeks, with a minimum width; on release GSAP takes them to whole weeks on a soft spring and a glint crosses the glass.
Before the list changes, every row is measured. Those leaving go absolute where they were and fade away; new ones come up from below, staggered; those staying start from the difference between the old and the new place and go back to zero on the spring. While typing, the list waits for a fifth of a second pause, the bars do not.
The loop on its own is a GSAP timeline of calls using the same functions as the pointer (type, drag a grip, settle the window). A tap, a key or the wheel from the person stops the pilot.
| Name | File | Default | What it changes |
|---|---|---|---|
QUERY_A | script.js | invoice | The first word the field types by itself. |
QUERY_B | script.js | onboarding | The second word the field types by itself. |
TYPING | script.js | 11 | How many letters per second the field types by itself. |
SPRING | script.js | 1 | How springy bars, rows and window are: 0.5 calm, 2 very bouncy. |
BARS | script.js | 0.7 | How many seconds a bar takes to reach its height. |
ROWS | script.js | 0.6 | How many seconds a row takes to arrive or glide into place. |
DRAG | script.js | 0.95 | How many seconds the pilot takes to drag a grip. |
MIN_WEEKS | script.js | 2 | How many weeks wide the window is at the least. |
AUTO | script.js | true | Types, narrows and slides by itself until someone touches the card. |
For the search of a back office, a project or ticket app, an archive of orders, invoices or messages: wherever the results have a date and it helps to see at a glance when they happened, and to narrow the period by dragging instead of opening a calendar.
The same animation with adapted sizes: the card is almost as wide as the screen and at most as tall as the window, the strip and the rows get shorter with the height, the row date hides below 420 pixels. With a finger drag the grips and the window, and tap a week to bring the window there.
Nothing moves: the bars take their height at once, the window jumps to the chosen weeks, the rows fade in and out, the count and the dates change in place and the glint does not run.
GSAP 3.15.0, Mona Sans (font variabile) 5.3.0.
Compressed with gzip, the three demo files weigh 13 KB; the libraries: GSAP 28 KB.
Tested on 7 November 2026
Use it in your own projects and in your clients’ projects. Do not resell it or redistribute it as is. GSAP stays under its own Standard license. Full license.
Support Animorio
Animorio stays free thanks to the people who support it. If you like, buy us a coffee: it helps us make the next animations.
You asked for
We made it for you: it’s in the library, with the preview, the Playground and the code to copy.
An animation you can’t find, or a site to take apart in the journal: tell us which. We pick the next ones from here.
With your account’s email and password.
or with your email
You’re signed in as .
With your account, you can download the zip of every animation and every pack, for free.