feat: re add group column

This commit is contained in:
2024-04-09 14:05:50 +07:00
parent 420be77b5c
commit 5e6692cd6d
10 changed files with 200 additions and 78 deletions

View File

@@ -19,7 +19,6 @@ enum NSTORE_KEYS {
settings = "lume_user_settings",
interests = "lume_user_interests",
columns = "lume_user_columns",
group = "lume_group_",
}
export class Ark {
@@ -654,11 +653,36 @@ export class Ark {
content: JSON.stringify(interests),
});
return cmd;
} catch (e) {
throw new Error(String(e));
}
}
public async get_nstore(key: string) {
try {
const cmd: string = await invoke("get_nstore", {
key,
});
const parse: string | string[] = cmd ? JSON.parse(cmd) : null;
if (!parse.length) return null;
return parse;
} catch {
return null;
}
}
public async set_nstore(key: string, content: string) {
try {
const cmd: string = await invoke("set_nstore", {
key,
content,
});
return cmd;
} catch (e) {
throw new Error(String(e));
}
}
public open_thread(id: string) {
try {
const window = new WebviewWindow(`event-${id}`, {

View File

@@ -1,22 +1,17 @@
import { SVGProps } from 'react';
import { SVGProps } from "react";
export function ExpandIcon(props: JSX.IntrinsicAttributes & SVGProps<SVGSVGElement>) {
export function ExpandIcon(
props: JSX.IntrinsicAttributes & SVGProps<SVGSVGElement>,
) {
return (
<svg
xmlns="http://www.w3.org/2000/svg"
width="24"
height="24"
fill="none"
viewBox="0 0 24 24"
{...props}
>
<svg width="24" height="24" fill="none" viewBox="0 0 24 24" {...props}>
<path
stroke="currentColor"
strokeLinecap="round"
strokeLinejoin="round"
strokeWidth="1.5"
d="M13.75 3.75h5.75a.75.75 0 01.75.75v5.75m-16.5 3.5v5.75c0 .414.336.75.75.75h5.75M19.5 4.5L14 10m-4 4l-5.5 5.5"
></path>
d="M5.75 12.75v3.5a2 2 0 0 0 2 2h3.5m1.5-12.5h3.5a2 2 0 0 1 2 2v3.5"
/>
</svg>
);
}

View File

@@ -1,4 +1,4 @@
import { CancelIcon, RefreshIcon } from "@lume/icons";
import { CancelIcon, ExpandIcon, RefreshIcon } from "@lume/icons";
import { cn } from "@lume/utils";
import { getCurrent } from "@tauri-apps/api/window";
import { ReactNode } from "react";