Web UI on Ant Design, scrollable factory columns, fix empty page after deleting the open chat
Buttons, fields, drop-downs, check boxes, tabs, dialogs and notices are Ant Design components; their tokens come from the theme variables (web/src/ui). Every factory board column has its own vertical scrollbar. ChatView rendered fewer hooks once its chat was deleted. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
90b9ab6670
commit
6b1a1742b2
79 files changed
+2628
-1393
No files matched your search
@@ -1,3 +1,4 @@
|
||||
import { Button, Checkbox, Input } from "antd";
|
||||
import { useState } from "react";
|
||||
import { del, post, put } from "../../api";
|
||||
import { useFetch } from "../../hooks";
|
||||
@@ -45,17 +46,16 @@ export function Folders() {
|
||||
<h3>
|
||||
📁 <code>{f.path.slice(ws.length) || "/"}</code>
|
||||
<span className="spacer" />
|
||||
<button className="small danger" onClick={() => void confirmDialog({ message: t("folders.removeConfirm"), danger: true, confirmLabel: t("folders.remove") }).then((ok): unknown => ok && run(() => del(`/folders/${f.id}`)))}>
|
||||
<Button danger size="small" onClick={() => void confirmDialog({ message: t("folders.removeConfirm"), danger: true, confirmLabel: t("folders.remove") }).then((ok): unknown => ok && run(() => del(`/folders/${f.id}`)))}>
|
||||
{t("folders.remove")}
|
||||
</button>
|
||||
</Button>
|
||||
</h3>
|
||||
<div className="check-list">
|
||||
{users.length === 0 && <div style={{ color: "var(--muted)" }}>{t("folders.noUsers")}</div>}
|
||||
{users.map((u) => (
|
||||
<label key={u.id}>
|
||||
<input type="checkbox" checked={f.users.includes(u.id)} onChange={() => toggle(f, u.id)} />
|
||||
<Checkbox key={u.id} checked={f.users.includes(u.id)} onChange={() => toggle(f, u.id)}>
|
||||
{u.display_name || u.username} <span style={{ color: "var(--muted)" }}>@{u.username}</span>
|
||||
</label>
|
||||
</Checkbox>
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
@@ -64,10 +64,10 @@ export function Folders() {
|
||||
<h3>{t("folders.add")}</h3>
|
||||
<div className="row">
|
||||
<code>{ws}/</code>
|
||||
<input value={path} onChange={(e) => setPath(e.target.value)} placeholder="team/project" style={{ flex: 1, minWidth: 160 }} />
|
||||
<button className="primary" disabled={!path.trim()} onClick={() => run(async () => (await post("/folders", { path }), setPath("")))}>
|
||||
<Input value={path} onChange={(e) => setPath(e.target.value)} placeholder="team/project" style={{ flex: 1, minWidth: 160 }} />
|
||||
<Button type="primary" disabled={!path.trim()} onClick={() => run(async () => (await post("/folders", { path }), setPath("")))}>
|
||||
+ {t("common.add")}
|
||||
</button>
|
||||
</Button>
|
||||
</div>
|
||||
<div style={{ fontSize: 12, color: "var(--muted)", marginTop: 6 }}>{t("folders.addHint")}</div>
|
||||
</div>
|
||||
|
||||
Reference in new issue
Block a user