diff --git a/apps/web/app/(app)/[emailAccountId]/assistant/ResultDisplay.tsx b/apps/web/app/(app)/[emailAccountId]/assistant/ResultDisplay.tsx
index 7602e21f49..ee7fbae8e1 100644
--- a/apps/web/app/(app)/[emailAccountId]/assistant/ResultDisplay.tsx
+++ b/apps/web/app/(app)/[emailAccountId]/assistant/ResultDisplay.tsx
@@ -78,7 +78,10 @@ function ResultDisplay({
}
return (
- }>
+ }
+ className="w-80"
+ >
{rule
? rule.name
@@ -136,7 +139,9 @@ export function ResultDisplayContent({ result }: { result: RunRulesResult }) {
type: action.type,
label: action.label,
folderName: action.folderName,
- content: action.content,
+ content:
+ action.content +
+ "https://www.google.comasdjhgaghjdsghjasdgjasdjhasd",
to: action.to,
subject: action.subject,
cc: action.cc,
diff --git a/apps/web/components/HoverCard.tsx b/apps/web/components/HoverCard.tsx
index 0081254ca9..20458a305a 100644
--- a/apps/web/components/HoverCard.tsx
+++ b/apps/web/components/HoverCard.tsx
@@ -3,6 +3,7 @@ import {
HoverCardContent,
HoverCardTrigger,
} from "@/components/ui/hover-card";
+import { cn } from "@/utils";
export function HoverCard(props: {
children: React.ReactNode;
@@ -12,7 +13,11 @@ export function HoverCard(props: {
return (
{props.children}
-
+
{props.content}
diff --git a/apps/web/utils/ai/reply/reply-context-collector.ts b/apps/web/utils/ai/reply/reply-context-collector.ts
index 6798a74557..12fe0fd720 100644
--- a/apps/web/utils/ai/reply/reply-context-collector.ts
+++ b/apps/web/utils/ai/reply/reply-context-collector.ts
@@ -57,7 +57,7 @@ When searching, use natural language queries that would find relevant emails. Th
Search Tips:
- The search looks for EXACT text matches in emails
- IMPORTANT: Try simpler queries if you don't get results for your first search
-- Try the subject line first if it contains the main topic
+- Do NOT use field prefixes like subject:, from:, to:, or label: - just use plain text queries
Example search queries:
- "order status" OR "shipment arrival" OR "tracking number"
diff --git a/apps/web/utils/email/microsoft.ts b/apps/web/utils/email/microsoft.ts
index ad31a0d911..d5cbe01e71 100644
--- a/apps/web/utils/email/microsoft.ts
+++ b/apps/web/utils/email/microsoft.ts
@@ -807,7 +807,11 @@ export class OutlookProvider implements EmailProvider {
// For Outlook, separate search queries from date filters
// Microsoft Graph API handles these differently
- const originalQuery = options.query || "";
+ // Strip Gmail-style prefixes that don't work with Microsoft Graph
+ const originalQuery = (options.query || "").replace(
+ /\b(subject|label):/gi,
+ "",
+ );
// Build date filter for Outlook (no quotes for DateTimeOffset comparison)
const dateFilters: string[] = [];
diff --git a/apps/web/utils/logger.ts b/apps/web/utils/logger.ts
index 43d501dc28..df53bc595c 100644
--- a/apps/web/utils/logger.ts
+++ b/apps/web/utils/logger.ts
@@ -219,9 +219,13 @@ const REDACTED_FIELD_NAMES = new Set([
"authorization",
]);
+// Fields containing email/message content - redacted in production unless debug logs enabled
+const CONTENT_FIELD_NAMES = new Set(["text", "body"]);
+
/**
* Recursively processes an object to protect sensitive data:
* - REDACTED_FIELD_NAMES: Replaced with boolean (never logged)
+ * - CONTENT_FIELD_NAMES: Replaced with boolean in production (unless debug logs enabled)
* - SENSITIVE_FIELD_NAMES: Hashed in production (raw in dev/test)
*
* Only works server-side - client-side logs are visible in browser anyway.
@@ -247,6 +251,10 @@ function hashSensitiveFields(obj: T, depth = 0): T {
if (REDACTED_FIELD_NAMES.has(key)) {
processed[key] = !!value;
}
+ // Redact content fields in production (unless debug logs enabled)
+ else if (CONTENT_FIELD_NAMES.has(key) && !env.ENABLE_DEBUG_LOGS) {
+ processed[key] = !!value;
+ }
// Hash emails in production only (server-side only)
else if (
SENSITIVE_FIELD_NAMES.has(key) &&