mirror of
https://github.com/direct-img/vibegif.direct-img.link.git
synced 2026-10-29 11:44:51 +00:00
Add 150 UI and page state stickers in three pending sections
404s, loaders, success, errors, empty states, confirmation, under construction, offline and more: 50 monochrome (ui), 50 colored (uicolor) and 50 with an anime girl (uianime), on /test until approved. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
// rounded progress bar: the striped fill eases out to full while its stripes slide, then slips off the end and wraps round to start again
|
||||
const{min,max}=Math
|
||||
export const frames=24,delay=70
|
||||
const io=u=>(u=min(1,max(0,u)),u<.5?2*u*u:1-2*(1-u)**2)
|
||||
export default(c,t)=>{
|
||||
const X=32,W=192,b=X+W*io(t/.7),a=X+W*io((t-.72)/.26)
|
||||
c.beginPath();c.roundRect(18,92,220,72,36);c.fill();c.stroke()
|
||||
if(b-a<1)return
|
||||
c.save();c.beginPath();c.roundRect(32,106,192,44,22);c.clip()
|
||||
c.beginPath();c.roundRect(a,106,b-a,44,22);c.clip()
|
||||
c.fillStyle='#111';c.fillRect(0,0,256,256)
|
||||
c.fillStyle='#888';const o=t*72%24
|
||||
for(let x=-48+o;x<256;x+=24)c.beginPath(),c.moveTo(x,150),c.lineTo(x+12,150),c.lineTo(x+34,106),c.lineTo(x+22,106),c.fill()
|
||||
c.restore()
|
||||
}
|
||||
Reference in New Issue
Block a user