pagwin
pagwin
TTCTheo's Typesafe Cult
Created by pagwin on 7/24/2023 in #questions
Different timings for animating to different states
I have a button, when I hover over it, it changes color over some amount of time, when I click/activate it it changes to a different color and I want that change to happen over a different amount of time than the hover change. How can I do that? className: "ease-in-out duration-500 hover:bg-red-800 ease-in-out duration-100 active:bg-red-900 outline-none text-white bg-red-600 font-bold text-lg border-4 border-black rounded-full bg-contain m-3 p-1" I'm aware putting 2 durations means that one simply overrides the other(and that 2 ease-in-outs is also redundant), I have them both here anyways to provide a better idea of what I'm hoping for
3 replies
TTCTheo's Typesafe Cult
Created by pagwin on 7/18/2023 in #questions
Implementing next auth adapter with a cache
so I've implemented an adapter for next auth which would try to cache certain things in memory via the code below and I was wondering if I made any notable or obvious mistakes with my code (if you don't notice any issues or think I did okay you can just react with 👍 if you don't want to send a message)
5 replies
TTCTheo's Typesafe Cult
Created by pagwin on 7/7/2023 in #questions
Setting up vanilla trpc client
So I have a button and when that button is clicked I want it to do some trpc mutation. After doing some searching and seeing this response in a different post here https://discord.com/channels/966627436387266600/1126264396285481151/1126264611008696320 I concluded that the best way to do this was to setup a vanilla trpc client following the linked guide(https://trpc.io/docs/client/vanilla/setup) But after following that guide I get a typescript error when I build and when I try to click the button in the dev environment I get a runtime error. So what am I doing wrong? repo(dev branch is where stuff is): [linked repo that isn't in the state it was when I asked this] probably relevant files: src/pages/wip.tsx, src/server/api/routers/itemlist.ts and src/server/api/root.ts
20 replies