Skip to content

Commit 744d749

Browse files
committed
revert(home): bring back the pre-wrapped layout after an upload
The analysis bar that replaced the upload hero reads "another file to analyze it." on its button — the fileAnother string is the tail of a sentence, not a label — and pushes the results down behind a band of empty space. Restore what the page did before: the hero and the drop zone stay put, and dropping in another export replaces the analysis. The persisted analysis is untouched; it survives navigation and the payment redirect exactly as before. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_018yuhjKpZrmUyqx4qUideLM
1 parent 97d87f8 commit 744d749

2 files changed

Lines changed: 8 additions & 48 deletions

File tree

pages/index.vue

Lines changed: 1 addition & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
</v-alert>
1212
</v-container>
1313

14-
<div v-show="!isShowingChats" ref="aboveTheFold" class="top-color">
14+
<div ref="aboveTheFold" class="top-color">
1515
<v-container>
1616
<v-alert
1717
prominent
@@ -143,30 +143,6 @@
143143
/>
144144
</v-container>
145145

146-
<div v-if="isShowingChats" class="active-chat-bar py-3">
147-
<v-container
148-
class="d-flex align-center justify-space-between flex-wrap gap-2"
149-
>
150-
<div class="d-flex align-center">
151-
<v-icon color="#21a68d" class="mr-2">mdi-check-decagram</v-icon>
152-
<span class="font-weight-bold text-subtitle-1">
153-
{{ activeChatSummary }}
154-
</span>
155-
</div>
156-
<v-btn
157-
variant="outlined"
158-
color="#21a68d"
159-
size="small"
160-
class="font-weight-bold"
161-
style="text-transform: none"
162-
@click="resetChat"
163-
>
164-
<v-icon size="16" class="mr-1">mdi-swap-horizontal</v-icon>
165-
{{ $t("fileAnother") || "Analyze Another Chat" }}
166-
</v-btn>
167-
</v-container>
168-
</div>
169-
170146
<v-container v-if="isShowingChats" id="results" class="py-4">
171147
<ChartsResults
172148
ref="results"
@@ -239,13 +215,6 @@ export default {
239215
// tab was closed, or it was too large to keep in sessionStorage).
240216
return Boolean(this.oneTimePurchase) && !this.isShowingChats;
241217
},
242-
activeChatSummary() {
243-
if (!this.chat) return "WhatsApp Chat Analysis";
244-
const count = this.chat.filterdChatObject
245-
? this.chat.filterdChatObject.length
246-
: 0;
247-
return `Complete Analysis (${count.toLocaleString()} messages)`;
248-
},
249218
},
250219
created() {
251220
// eslint-disable-next-line no-undef
@@ -376,14 +345,6 @@ export default {
376345
this.$refs.aboveTheFold.scrollTop = window.scrollY;
377346
}
378347
},
379-
resetChat() {
380-
this.isShowingChats = false;
381-
this.chat = undefined;
382-
this.attachments = undefined;
383-
const sharedChat = useSharedChat();
384-
sharedChat.value = null;
385-
clearChatSession();
386-
},
387348
},
388349
};
389350
</script>

tests/e2e/tools-and-footer.spec.js

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -84,14 +84,13 @@ test.describe("Footer Links & Tools Suite", () => {
8484
// Verify navigation to main page with results
8585
await page.waitForURL(/.*#results/);
8686
await expect(page.locator("#results")).toBeVisible({ timeout: 15_000 });
87-
await expect(page.locator(".active-chat-bar")).toBeVisible();
88-
await expect(page.locator(".active-chat-bar")).toContainText(
89-
"Complete Analysis"
90-
);
91-
92-
// Verify the upload hero is hidden
93-
const aboveTheFold = page.locator(".top-color");
94-
await expect(aboveTheFold).toBeHidden();
87+
await expect(page.getByText("Chat Timeline", { exact: true })).toBeVisible({
88+
timeout: 15_000,
89+
});
90+
91+
// The upload hero stays on the page, so another chat can be dropped in
92+
// without leaving the results.
93+
await expect(page.locator(".top-color")).toBeVisible();
9594
});
9695

9796
test("tools header button shows dropdown on hover and navigates to tools or specific tool", async ({

0 commit comments

Comments
 (0)