176 web animation techniques, each a live demo with plain settings and a ready-made prompt for your AI assistant. No dependencies, no build step.
HTML ai-promptsanimationcss-animationsfrontendgithub-pagesjavascriptmicrointeractionsmotion-designno-dependenciesreferencescroll-animationui-animationweb-animationweb-developmentwebgl
feat: Not here? under the finder's cards opens a short GitHub form with the visitor's answers filled in, and the issue chooser offers the finder first
matin742dfdcea34b
diff --git a/.github/ISSUE_TEMPLATE/animation_not_here.yml b/.github/ISSUE_TEMPLATE/animation_not_here.ymlnew file mode 100644index 00000000..f02989d9--- /dev/null+++ b/.github/ISSUE_TEMPLATE/animation_not_here.yml@@ -0,0 +1,29 @@+name: "Can't find an animation"+description: "You saw an animation on a website, and the finder did not show it."+title: "[not here] "+labels: ["finder"]+body:+ - type: input+ id: answers+ attributes:+ label: "Your answers in the finder"+ description: "Filled in when you come from the finder's Not here? link."+ - type: input+ id: site+ attributes:+ label: "Where did you see it? A link, and where on the page"+ placeholder: "For example: https://example.com, the big picture at the top"+ validations:+ required: true+ - type: textarea+ id: what+ attributes:+ label: "What happened, in your own words"+ placeholder: "For example: as I scrolled, the picture broke into small pieces that floated away."+ validations:+ required: true+ - type: textarea+ id: recording+ attributes:+ label: "A screen recording or picture: drag it into this box"+ description: "Optional, but it helps us see exactly what you saw."diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.ymlindex 1973f30a..15341020 100644--- a/.github/ISSUE_TEMPLATE/config.yml+++ b/.github/ISSUE_TEMPLATE/config.yml@@ -1,5 +1,8 @@blank_issues_enabled: truecontact_links:+ - name: Find an animation by what you saw+ url: https://matinmonshizadeh.github.io/animation-handbook/?view=find+ about: "Saw an animation on a website and don't know its name? Answer three short questions and see the ones that match."- name: Browse the live handbookurl: https://matinmonshizadeh.github.io/animation-handbook/about: See all 166 techniques running before filing an issue.diff --git a/index.html b/index.htmlindex 6f060f63..ab9e471f 100644--- a/index.html+++ b/index.html@@ -373,6 +373,14 @@ button,input{font:inherit;color:inherit}.fd-how .fd-a{padding:8px 4px 10px;font-size:13px}.fd-go{flex-direction:column;align-self:stretch}}+/* Not here?, under the finder's cards whenever an answer is picked */+.fd-not{display:flex;flex-direction:column;align-items:center;gap:12px;margin-top:40px;padding:clamp(28px,4vw,44px) 24px;border-radius:20px;background:var(--surface);box-shadow:var(--shadow);text-align:center}+.fd-not-t{font-size:22px;font-weight:800}+.fd-not-s{max-width:560px;font-size:16px;color:var(--ink-2)}+.fd-not-acts{display:flex;flex-wrap:wrap;justify-content:center;gap:12px;margin-top:4px}+.fd-fine{font-size:14px;color:var(--muted)}+.fd-not .pillbtn{min-height:52px;padding:0 24px;font-size:16px;justify-content:center} /* Describe it in words, as Start over: as tall as the dark button beside it, its words in the middle when a phone stretches it */+@media(max-width:600px){.fd-not-acts{flex-direction:column;align-self:stretch}}/* ── preview library ── *//* The hint names the transform only: opacity in will-change flattens CSS 3D in Chrome (a cube draws as one flat face) */@@ -1683,6 +1691,12 @@ button,input{font:inherit;color:inherit}<p class="pop"><button type="button" data-q="fade in">fade in</button><button type="button" data-q="typing text">typing text</button><button type="button" data-q="loading spinner">loading spinner</button><button type="button" data-q="parallax">parallax</button><button type="button" data-q="confetti">confetti</button></p></div><div class="more" id="more"><button type="button" class="bigbtn" id="more-btn"><span id="more-label">Browse all 166 animations</span><svg class="i" viewBox="0 0 24 24" aria-hidden="true"><path d="M12 5v14M6 13l6 6 6-6"/></svg></button></div>+ <div class="fd-not" id="find-not" hidden>+ <h3 class="fd-not-t">Not here?</h3>+ <p class="fd-not-s" id="find-not-s">Tell us what you saw. We use it to add the animation or to fix the finder.</p>+ <p class="fd-not-acts"><a class="fd-btn" id="find-gh" href="https://github.com/matinmonshizadeh/animation-handbook/issues/new?template=animation_not_here.yml" target="_blank" rel="noopener">Tell us on GitHub</a><button type="button" class="pillbtn" id="find-words">Describe it in words</button></p>+ <p class="fd-fine">The form is on GitHub and needs a free account.</p>+ </div><noscript><p class="noscript">This page shows its animations with JavaScript. All 166 are still easy to reach: see the <a href="https://github.com/matinmonshizadeh/animation-handbook#categories">category list on GitHub</a> or the <a href="sitemap.xml">full sitemap</a>. Each demo is a page of its own under <code>/animations/<category>/<name>/</code>.</p></noscript></section>@@ -2890,6 +2904,7 @@ function render(answered){}titleEl.textContent=title;say(sub,finding&&answered);showFinder(finding,found);+ showNotHere(finding,found);syncBar();resultsEl.classList.toggle('no-tags',!tags);clearBtn.hidden=!filtered||finding;@@ -3055,6 +3070,17 @@ finderEl.addEventListener('change',e=>{});findSee.addEventListener('click',()=>{toResults();toTitle();});$('find-reset').addEventListener('click',()=>{go({view:'find'},false);scrollTo({top:0,behavior:reduce?'auto':'smooth'});findTitle.focus({preventScroll:true});});+// Not here?, under the cards whenever an answer is picked: its link opens the GitHub form with the answers filled in; when nothing+// fits, its line says so and suggests Not sure on one question. Describe it in words goes back to the start, search box focused.+const findNot=$('find-not'),findNotLine=$('find-not-s'),findGh=$('find-gh');+function showNotHere(finding,found){+ const answered=finding&&answeredAny();+ findNot.hidden=!answered;+ if(!answered)return;+ findNotLine.textContent=found.best.length+found.close.length?'Tell us what you saw. We use it to add the animation or to fix the finder.':'Nothing fits these answers yet. Try Not sure on one question, or tell us what you saw.';+ findGh.href=findIssueURL(state);+}+$('find-words').addEventListener('click',()=>{go({},true);scrollTo({top:0,behavior:reduce?'auto':'smooth'});q.focus({preventScroll:true});});const startCat=readURL();render();if(startCat){const g=$('cat-'+startCat);if(g)g.scrollIntoView();}diff --git a/tests/finder.test.js b/tests/finder.test.jsindex 2094ef9b..d0d95ba8 100644--- a/tests/finder.test.js+++ b/tests/finder.test.js@@ -255,6 +255,52 @@ test("a step that changes only the fragment (How it works, Back to top, the skipassert.deepEqual(calls, ['render'], 'the view is drawn again');});+// The fields of a GitHub issue form, in order: each item of its body that has an id, with its type, label and whether it is required.+const formFields = yml => yml.split(/\n - type: /).slice(1).map(item => ({+ type: item.split(/\r?\n/)[0].trim(),+ id: (item.match(/\n id: (\S+)/) || [])[1],+ label: ((item.match(/\n label: (.+)/) || [])[1] || '').trim().replace(/^"(.*)"$/, '$1'),+ required: /\n required: true/.test(item)+})).filter(field => field.id);+const FORM = path.join(ROOT, '.github', 'ISSUE_TEMPLATE', 'animation_not_here.yml');++test('Not here? sits under the cards with its words, its GitHub link in a new tab and Describe it in words', () => {+ const panel = between(HOME, '<div class="fd-not" id="find-not" hidden>', '</div>');+ assert.ok(panel, 'the Not here? panel, hidden until an answer is picked');+ for (const part of ['<h3 class="fd-not-t">Not here?</h3>',+ '<p class="fd-not-s" id="find-not-s">Tell us what you saw. We use it to add the animation or to fix the finder.</p>',+ '<a class="fd-btn" id="find-gh" href="https://github.com/matinmonshizadeh/animation-handbook/issues/new?template=animation_not_here.yml" target="_blank" rel="noopener">Tell us on GitHub</a>',+ '<button type="button" class="pillbtn" id="find-words">Describe it in words</button>',+ '<p class="fd-fine">The form is on GitHub and needs a free account.</p>']) assert.ok(panel.includes(part), part);+ assert.ok(at('id="find-not"') > at('id="more"') && at('id="find-not"') < at('id="how"'), 'under the cards, before How it works');+});++test('the GitHub form for Not here? has its name, title, label and four fields', () => {+ const form = read(FORM);+ assert.match(form, /^name: "Can't find an animation"\r?$/m);+ assert.match(form, /^description: "You saw an animation on a website, and the finder did not show it\."\r?$/m);+ assert.match(form, /^title: "\[not here\] "\r?$/m);+ assert.match(form, /^labels: \["finder"\]\r?$/m);+ assert.deepEqual(formFields(form).map(f => [f.type, f.id, f.label, f.required]), [+ ['input', 'answers', 'Your answers in the finder', false],+ ['input', 'site', 'Where did you see it? A link, and where on the page', true],+ ['textarea', 'what', 'What happened, in your own words', true],+ ['textarea', 'recording', 'A screen recording or picture: drag it into this box', false]+ ]);+});++test('the Not here? link names animation_not_here.yml and fills only fields the form has', () => {+ const fields = formFields(read(FORM)).map(f => f.id);+ const url = new URL(finder().findIssueURL({ what: 'card', when: 'scroll', how: 'pieces' }));+ assert.equal(url.searchParams.get('template'), path.basename(FORM));+ for (const name of url.searchParams.keys()) assert.ok(['template', 'title'].includes(name) || fields.includes(name), `${name} is a field of the form`);+});++test('the issue chooser offers the finder first', () => {+ const config = read(path.join(ROOT, '.github', 'ISSUE_TEMPLATE', 'config.yml'));+ assert.match(config.split(/\r?\n - name: /)[1] || '', /^Find an animation by what you saw\r?\n url: https:\/\/matinmonshizadeh\.github\.io\/animation-handbook\/\?view=find\r?\n/);+});+// ── Every card's answers and the test set ──// The reviewed answers: every answer given to some card, the rules every page of a kind shares, and the spec's 28 described effects.