added few more fixes

This commit is contained in:
Mahesh Sanikommmu 2025-08-27 21:59:35 -07:00
parent e97d642217
commit 2be9d04fdc
9 changed files with 10 additions and 26 deletions

View file

@ -15,14 +15,6 @@ import type {
MemoryPayload,
} from "../utils/types"
interface SearchResponse {
results: Array<{
chunks: Array<{
content: string
}>
}>
}
export default defineBackground(() => {
let twitterImporter: TwitterImporter | null = null
@ -134,8 +126,10 @@ export default defineBackground(() => {
): Promise<{ success: boolean; data?: unknown; error?: string }> => {
try {
const responseData = await searchMemories(data)
const content = (responseData as SearchResponse).results[0].chunks[0]
.content
const response = responseData as {
results?: Array<{ chunks?: Array<{ content?: string }> }>
}
const content = response.results?.[0]?.chunks?.[0]?.content
console.log("Content:", content)
return { success: true, data: content }
} catch (error) {

View file

@ -56,7 +56,7 @@
align-items: center;
justify-content: space-between;
gap: 12px;
padding: 16px;
padding: 10px;
border-bottom: 1px solid #e5e7eb;
position: relative;
}

View file

@ -151,8 +151,8 @@ function App() {
<img
alt="supermemory"
className="logo"
src="/logo-trademark.svg"
style={{ width: "80%", height: "32px" }}
src="https://assets.supermemory.ai/brand/wordmark/dark-transparent.svg"
style={{ width: "80%", height: "45px" }}
/>
{userSignedIn && (
<button

View file

@ -7,7 +7,7 @@ function Welcome() {
<img
alt="supermemory"
className="welcome-logo"
src="/logo-trademark.svg"
src="https://assets.supermemory.ai/brand/wordmark/dark-transparent.svg"
/>
<p className="welcome-subtitle">
Your AI-powered second brain for saving and organizing everything

Binary file not shown.

Before

Width:  |  Height:  |  Size: 100 KiB

After

Width:  |  Height:  |  Size: 224 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 100 KiB

After

Width:  |  Height:  |  Size: 33 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 100 KiB

After

Width:  |  Height:  |  Size: 108 KiB

View file

@ -303,14 +303,7 @@ export function createSaveTweetElement(onClick: () => void): HTMLElement {
z-index: 1000;
`
// Check body background color to determine which icon to use
const bodyStyle = window.getComputedStyle(document.body)
const backgroundColor = bodyStyle.backgroundColor
const isLightMode = backgroundColor === "rgb(255, 255, 255)"
const iconFileName = isLightMode
? "/light-mode-icon.png"
: "/dark-mode-icon.png"
const iconFileName = "/icon-16.png"
const iconUrl = browser.runtime.getURL(iconFileName)
iconButton.innerHTML = `
<img src="${iconUrl}" width="20" height="20" alt="Save to Memory" style="border-radius: 4px;" />
@ -352,8 +345,7 @@ export function createChatGPTInputBarElement(onClick: () => void): HTMLElement {
`
// Use appropriate icon based on theme
const isDark = DOMUtils.isDarkMode()
const iconFileName = isDark ? "/dark-mode-icon.png" : "/light-mode-icon.png"
const iconFileName = "/icon-16.png"
const iconUrl = browser.runtime.getURL(iconFileName)
iconButton.innerHTML = `
<img src="${iconUrl}" width="20" height="20" alt="Save to Memory" style="border-radius: 50%;" />

View file

@ -26,8 +26,6 @@ export default defineConfig({
{
resources: [
"icon-16.png",
"light-mode-icon.png",
"dark-mode-icon.png",
"fonts/*.ttf",
],
matches: ["<all_urls>"],