{/* Badge with checkout count - color based on urgency */}
getUrgencyColor(mostUrgentLevel).bg,
),
border: computed(
() => `2px solid ${getUrgencyColor(mostUrgentLevel).border}`,
),
color: computed(() => getUrgencyColor(mostUrgentLevel).text),
display: "flex",
alignItems: "center",
justifyContent: "center",
fontWeight: "bold",
fontSize: "16px",
}}
>
{checkedOutCount}
{/* Label and summary */}
Library Books
(overdueCount > 0 ? "inline" : "none")),
}}
>
{overdueCount} overdue
overdueCount > 0 && dueTomorrowCount > 0 ? "inline" : "none"
),
}}
>
{" ยท "}
dueTomorrowCount > 0 ? "inline" : "none"
),
}}
>
{dueTomorrowCount} due tomorrow
holdsReadyCount > 0 ? "inline" : "none"
),
}}
>
{" ยท "}
{holdsReadyCount} holds ready
{/* Loading/progress indicator */}
);
return {
[NAME]: "Berkeley Library",
trackedItems,
holdsReady,
overdueCount,
checkedOutCount,
holdsReadyCount,
previewUI,
// Omnibot actions - bind handlers with current state
markAsReturned: markAsReturnedHandler({
manuallyReturned,
rawAnalyses: rawAnalyses as Array<
{ analysis?: { result?: LibraryEmailAnalysis } }
>,
}),
dismissHold: dismissHoldHandler({
dismissedHolds,
rawAnalyses: rawAnalyses as Array<
{ analysis?: { result?: LibraryEmailAnalysis } }
>,
}),
[UI]: (