ongoing UI work; fixes; TV callback loop problems again/still

This commit is contained in:
Tim
2024-03-09 19:17:06 -04:00
parent 1743a7462d
commit 4362d12f0f
14 changed files with 416 additions and 307 deletions

View File

@@ -1,6 +1,7 @@
import {FixedNumber} from "ethers";
import {usePrefStore, useStore} from "@/store/store.js";
import {token} from "@/blockchain/token.js";
import Color from "color";
export class SingletonCoroutine {
constructor(f, delay=10, retry=true) {
@@ -137,4 +138,12 @@ export function builderDefaults(builder, defaults) {
export function uuid() {
return crypto.randomUUID();
}
}
export function lightenColor(color, lightness=85) {
return new Color(color).hsl().lightness(lightness).string()
}
export function lightenColor2(color) {
return lightenColor(color,98)
}