recognize reactions

This commit is contained in:
Jon Staab
2024-08-23 14:42:50 -07:00
parent f12e7ef77c
commit 6722bd8493
8 changed files with 73 additions and 20 deletions
+2 -2
View File
@@ -36,7 +36,7 @@
on:click
class={cx(
$$props.class,
"flex items-center gap-3 transition-all hover:bg-base-100 hover:text-base-content",
"flex items-center gap-3 transition-all hover:bg-base-100 hover:text-base-content text-left",
)}
class:text-base-content={active}
class:bg-base-100={active}>
@@ -48,7 +48,7 @@
on:click
class={cx(
$$props.class,
"flex w-full items-center gap-3 transition-all hover:bg-base-100 hover:text-base-content",
"flex w-full items-center gap-3 transition-all hover:bg-base-100 hover:text-base-content text-left",
)}
class:text-base-content={active}
class:bg-base-100={active}>
+9
View File
@@ -33,6 +33,7 @@ export const synced = <T>(key: string, defaultValue: T, delay = 300) => {
}
export type SearchOptions<V, T> = {
getValue: (item: T) => V
fuseOptions?: IFuseOptions<T>
sortFn?: (items: FuseResult<T>) => any
@@ -95,3 +96,11 @@ export const formatTimestampAsDate = (ts: number) => {
return formatter.format(secondsToDate(ts))
}
export const formatTimestampAsTime = (ts: number) => {
const formatter = new Intl.DateTimeFormat(getLocale(), {
timeStyle: "short",
})
return formatter.format(secondsToDate(ts))
}