mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-10-31 22:24:16 +01:00
Address sidebar sort event type review
Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
1 parent
e689b3dc44
commit
975b991181
4 files changed
+4
-12
No files matched your search
@@ -24,6 +24,7 @@ import {
|
||||
AGENT_SORT_MODE_UPDATED_EVENT,
|
||||
getAgentSortModeStorageKey,
|
||||
readAgentSortMode,
|
||||
type AgentSortModeUpdatedDetail,
|
||||
type AgentSidebarSortMode,
|
||||
writeAgentSortMode,
|
||||
} from "../lib/agent-order";
|
||||
@@ -46,11 +47,6 @@ const AGENT_SORT_CHOICES: SidebarSectionRadioChoice[] = [
|
||||
{ value: "recent", label: "Recent" },
|
||||
];
|
||||
|
||||
type AgentSortModeUpdatedDetail = {
|
||||
storageKey: string;
|
||||
sortMode: AgentSidebarSortMode;
|
||||
};
|
||||
|
||||
function agentTimestamp(agent: Agent, field: "lastHeartbeatAt" | "updatedAt" | "createdAt"): number {
|
||||
const raw = agent[field];
|
||||
if (!raw) return 0;
|
||||
|
||||
@@ -28,6 +28,7 @@ import {
|
||||
getProjectSortModeStorageKey,
|
||||
PROJECT_SORT_MODE_UPDATED_EVENT,
|
||||
readProjectSortMode,
|
||||
type ProjectSortModeUpdatedDetail,
|
||||
type ProjectSidebarSortMode,
|
||||
writeProjectSortMode,
|
||||
} from "../lib/project-order";
|
||||
@@ -41,11 +42,6 @@ const PROJECT_SORT_CHOICES: SidebarSectionRadioChoice[] = [
|
||||
{ value: "recent", label: "Recent" },
|
||||
];
|
||||
|
||||
type ProjectSortModeUpdatedDetail = {
|
||||
storageKey: string;
|
||||
sortMode: ProjectSidebarSortMode;
|
||||
};
|
||||
|
||||
type ProjectItemProps = {
|
||||
activeProjectRef: string | null;
|
||||
companyId: string | null;
|
||||
|
||||
@@ -13,7 +13,7 @@ type AgentOrderUpdatedDetail = {
|
||||
orderedIds: string[];
|
||||
};
|
||||
|
||||
type AgentSortModeUpdatedDetail = {
|
||||
export type AgentSortModeUpdatedDetail = {
|
||||
storageKey: string;
|
||||
sortMode: AgentSidebarSortMode;
|
||||
};
|
||||
|
||||
@@ -13,7 +13,7 @@ type ProjectOrderUpdatedDetail = {
|
||||
orderedIds: string[];
|
||||
};
|
||||
|
||||
type ProjectSortModeUpdatedDetail = {
|
||||
export type ProjectSortModeUpdatedDetail = {
|
||||
storageKey: string;
|
||||
sortMode: ProjectSidebarSortMode;
|
||||
};
|
||||
|
||||
Reference in new issue
Block a user