diff --git a/apps/desktop/layer/main/src/updater/configs.ts b/apps/desktop/layer/main/src/updater/configs.ts index 795286101..616b68203 100644 --- a/apps/desktop/layer/main/src/updater/configs.ts +++ b/apps/desktop/layer/main/src/updater/configs.ts @@ -9,7 +9,7 @@ export const appUpdaterConfig = { // Disable app update will also disable renderer hot update and core update enableAppUpdate: true, - enableDistributionStoreUpdate: true, + enableDistributionStoreUpdate: isStoreDistribution, app: { autoCheckUpdate: true, diff --git a/apps/desktop/layer/main/src/updater/index.ts b/apps/desktop/layer/main/src/updater/index.ts index d21b03b68..37a771b3c 100644 --- a/apps/desktop/layer/main/src/updater/index.ts +++ b/apps/desktop/layer/main/src/updater/index.ts @@ -116,25 +116,8 @@ class FollowUpdater { } const payload = await getUpdateInfo(options.refresh ? { refresh: true } : {}) - const { decision } = payload - if (!decision || decision.type === "none") { - logger.info("Update decision: none") - return { hasUpdate: false } - } - - if (decision.type === "renderer") { - logger.info("Update decision: renderer") - return await this.handleRendererDecision(payload) - } - - if (decision.type === "app") { - logger.info("Update decision: app") - return await this.handleAppDecision(payload) - } - - logger.warn("Unknown update decision type", { type: decision.type }) - return { hasUpdate: false } + return this.handleDirectAppDecision(payload) } catch (error) { logger.error("Failed to check for updates", error) return { hasUpdate: false, error: error instanceof Error ? error.message : "Unknown error" } @@ -143,6 +126,28 @@ class FollowUpdater { } } + async handleDirectAppDecision(payload: LatestReleasePayload): Promise { + const { decision } = payload + + if (!decision || decision.type === "none") { + logger.info("Update decision: none") + return { hasUpdate: false } + } + + if (decision.type === "renderer") { + logger.info("Update decision: renderer") + return await this.handleRendererDecision(payload) + } + + if (decision.type === "app") { + logger.info("Update decision: app") + return await this.handleAppDecision(payload) + } + + logger.warn("Unknown update decision type", { type: decision.type }) + return { hasUpdate: false } + } + async downloadAppUpdate(): Promise { if (this.disabled || this.downloadingUpdate) { return @@ -266,8 +271,11 @@ class FollowUpdater { const info = await getDistributionUpdateInfo() if (!info) { - logger.info("Distribution update info unavailable for current build") - return { hasUpdate: false } + logger.info( + "Distribution update info unavailable for current build, falling back to direct app decision", + ) + const payload = await getUpdateInfo() + return this.handleDirectAppDecision(payload) } const rendererResult = await this.tryDistributionRendererUpdate(info.rendererUpdate) diff --git a/apps/desktop/layer/renderer/src/modules/ai-chat/components/layouts/AISmartSidebar.css b/apps/desktop/layer/renderer/src/modules/ai-chat/components/layouts/AISmartSidebar.css index 30701fb75..63fc7d972 100644 --- a/apps/desktop/layer/renderer/src/modules/ai-chat/components/layouts/AISmartSidebar.css +++ b/apps/desktop/layer/renderer/src/modules/ai-chat/components/layouts/AISmartSidebar.css @@ -4,7 +4,7 @@ .ai-glass-layer-1, .ai-glass-layer-2, .ai-glass-layer-3 { - transform-origin: right center; + transform-origin: right bottom; transition: width 0.5s cubic-bezier(0.23, 1, 0.32, 1), opacity 0.5s cubic-bezier(0.23, 1, 0.32, 1), diff --git a/apps/desktop/layer/renderer/src/modules/ai-chat/components/layouts/AISmartSidebar.tsx b/apps/desktop/layer/renderer/src/modules/ai-chat/components/layouts/AISmartSidebar.tsx index 4dbc6e937..2d42aa5d9 100644 --- a/apps/desktop/layer/renderer/src/modules/ai-chat/components/layouts/AISmartSidebar.tsx +++ b/apps/desktop/layer/renderer/src/modules/ai-chat/components/layouts/AISmartSidebar.tsx @@ -45,7 +45,8 @@ const AIAmbientSidebar: React.FC<{ onExpand: () => void }> = ({ onExpand }) => { const alpha = value <= 0.4 ? 0 : (value - 0.4) * 0.12 return `radial-gradient(ellipse at center, rgba(255, 92, 0, ${alpha}) 0%, transparent 70%)` }) - const glowX = useTransform(intensity, (value) => value * -20) + const glowX = useTransform(intensity, (value) => value * -12) + const glowY = useTransform(intensity, (value) => value * -24) const canShowPrompt = useGlobalFocusableScopeSelector(FocusablePresets.isNotFloatingLayerScope) useEffect(() => { @@ -58,13 +59,15 @@ const AIAmbientSidebar: React.FC<{ onExpand: () => void }> = ({ onExpand }) => { return } - const maxDistance = 500 - const threshold = 80 - const showedThreshold = 300 - const topBoundary = 100 + const effectWidth = 220 + const effectHeight = 220 + const activationWidth = 50 + const activationHeight = 50 + const releaseWidth = 90 + const releaseHeight = 90 const frameRef = { current: null as number | null } - const hidePrompt = () => { + const resetState = () => { intensity.set(0) if (isShowPromptRef.current) { isShowPromptRef.current = false @@ -82,27 +85,31 @@ const AIAmbientSidebar: React.FC<{ onExpand: () => void }> = ({ onExpand }) => { frameRef.current = null const rightEdgeDistance = window.innerWidth - clientX + const bottomEdgeDistance = window.innerHeight - clientY + const withinEffectZone = + rightEdgeDistance <= effectWidth && bottomEdgeDistance <= effectHeight - if (clientY <= topBoundary) { - hidePrompt() + if (!withinEffectZone) { + resetState() return } - if (rightEdgeDistance <= maxDistance) { - const newIntensity = Math.max(0, (maxDistance - rightEdgeDistance) / maxDistance) - intensity.set(newIntensity) + const normalizedX = 1 - Math.min(1, rightEdgeDistance / effectWidth) + const normalizedY = 1 - Math.min(1, bottomEdgeDistance / effectHeight) + const newIntensity = Math.max(normalizedX, normalizedY) + intensity.set(newIntensity) - if (isShowPromptRef.current && rightEdgeDistance <= showedThreshold) { - return - } + const withinActivation = + rightEdgeDistance <= activationWidth && bottomEdgeDistance <= activationHeight + const withinRelease = + rightEdgeDistance <= releaseWidth && bottomEdgeDistance <= releaseHeight - const shouldShow = rightEdgeDistance <= threshold - if (shouldShow !== isShowPromptRef.current) { - isShowPromptRef.current = shouldShow - setShowPrompt(shouldShow) - } - } else { - hidePrompt() + if (withinActivation && !isShowPromptRef.current) { + isShowPromptRef.current = true + setShowPrompt(true) + } else if (isShowPromptRef.current && !withinRelease) { + isShowPromptRef.current = false + setShowPrompt(false) } }) } @@ -112,7 +119,7 @@ const AIAmbientSidebar: React.FC<{ onExpand: () => void }> = ({ onExpand }) => { cancelAnimationFrame(frameRef.current) frameRef.current = null } - hidePrompt() + resetState() } window.addEventListener("pointermove", handlePointerMove, { passive: true }) @@ -133,10 +140,10 @@ const AIAmbientSidebar: React.FC<{ onExpand: () => void }> = ({ onExpand }) => { return ( <> {/* Multi-layer glass edge with depth */} -
+
{/* Background layer - deepest */} void }> = ({ onExpand }) => { {/* Middle layer */} void }> = ({ onExpand }) => { {/* Front layer - most prominent */} void }> = ({ onExpand }) => { {/* Subtle ambient glow */}
@@ -187,7 +195,7 @@ const AIAmbientSidebar: React.FC<{ onExpand: () => void }> = ({ onExpand }) => { animate={{ opacity: 1, x: 0, scale: 1 }} exit={{ opacity: 0, x: 30, scale: 0.95 }} transition={Spring.presets.smooth} - className="fixed bottom-12 right-6 z-50 flex flex-col items-end gap-3" + className="fixed bottom-6 right-6 z-50 flex flex-col items-end gap-3" > {/* Unified glass card with integrated button */} { markAllByRoute(getRouteParams(), filter) .then(() => setStatus("done")) diff --git a/apps/desktop/layer/renderer/src/modules/entry-column/grid.tsx b/apps/desktop/layer/renderer/src/modules/entry-column/grid.tsx index 664d8d117..90818ae7e 100644 --- a/apps/desktop/layer/renderer/src/modules/entry-column/grid.tsx +++ b/apps/desktop/layer/renderer/src/modules/entry-column/grid.tsx @@ -115,7 +115,8 @@ const VirtualGridImpl: FC< return Array.from({ length: columnCount }).fill(width / columnCount) as number[] }, [containerWidth]) - const isImageOnly = useUISettingKey("pictureViewImageOnly") + const pictureViewImageOnly = useUISettingKey("pictureViewImageOnly") + const isImageOnly = view === FeedViewType.Pictures && pictureViewImageOnly // Calculate rows based on entries const rows = useMemo(() => { diff --git a/apps/desktop/layer/renderer/src/modules/entry-column/layouts/EntryItemWrapper.tsx b/apps/desktop/layer/renderer/src/modules/entry-column/layouts/EntryItemWrapper.tsx index 79dd0bc83..37a7ce529 100644 --- a/apps/desktop/layer/renderer/src/modules/entry-column/layouts/EntryItemWrapper.tsx +++ b/apps/desktop/layer/renderer/src/modules/entry-column/layouts/EntryItemWrapper.tsx @@ -153,7 +153,7 @@ export const EntryItemWrapper: FC< to={navigationPath} className={cn( "relative block cursor-button overflow-visible duration-200 hover:bg-theme-item-hover", - isWide ? "rounded-none @[650px]:rounded-md" : "", + !isWide ? "rounded-none @[650px]:rounded-md" : "rounded-md", isAll && "!rounded-none", (isActive || isContextMenuOpen) && "!bg-theme-item-active", itemClassName, diff --git a/apps/desktop/layer/renderer/src/modules/entry-column/templates/grid-item-template.tsx b/apps/desktop/layer/renderer/src/modules/entry-column/templates/grid-item-template.tsx index 47973286e..ef154f787 100644 --- a/apps/desktop/layer/renderer/src/modules/entry-column/templates/grid-item-template.tsx +++ b/apps/desktop/layer/renderer/src/modules/entry-column/templates/grid-item-template.tsx @@ -1,4 +1,5 @@ import { TitleMarquee } from "@follow/components/ui/marquee/index.jsx" +import { FeedViewType } from "@follow/constants" import { useIsEntryStarred } from "@follow/store/collection/hooks" import { useEntry, useHasEntry } from "@follow/store/entry/hooks" import { useFeedById } from "@follow/store/feed/hooks" @@ -9,6 +10,7 @@ import { useTranslation } from "react-i18next" import { useUISettingKey } from "~/atoms/settings/ui" import { useEntryIsRead } from "~/hooks/biz/useAsRead" +import { useRouteParamsSelector } from "~/hooks/biz/useRouteParams" import { EntryTranslation } from "~/modules/entry-column/translation" import type { FeedIconEntry } from "~/modules/feed/feed-icon" import { FeedIcon } from "~/modules/feed/feed-icon" @@ -80,7 +82,9 @@ export const GridItemFooter = ({ const { t } = useTranslation("common") const isImageOnly = useUISettingKey("pictureViewImageOnly") - if (isImageOnly) return null + const view = useRouteParamsSelector(({ view }) => view) + const shouldHideFooter = view === FeedViewType.Pictures && isImageOnly + if (shouldHideFooter) return null if (!entry) return null return ( diff --git a/apps/desktop/package.json b/apps/desktop/package.json index 662545d11..8d7ce8323 100644 --- a/apps/desktop/package.json +++ b/apps/desktop/package.json @@ -1,7 +1,7 @@ { "name": "Folo", "type": "module", - "version": "1.1.1", + "version": "1.1.2", "private": true, "description": "Follow everything in one place", "author": "Folo Team", diff --git a/locales/errors/en.json b/locales/errors/en.json index 740c195b3..f64b47248 100644 --- a/locales/errors/en.json +++ b/locales/errors/en.json @@ -60,7 +60,7 @@ "13001": "You are not the owner of this RSSHub instance", "13002": "RSSHub is in use", "13003": "RSSHub not found", - "13004": "RSSHub user limit exceeded", + "13004": "RSSHub subscription limit exceeded", "13005": "RSSHub purchase not found", "13006": "RSSHub config invalid", "13007": "This RSSHub instance is unavailable currently", diff --git a/locales/errors/ja.json b/locales/errors/ja.json index fe43e23df..3f6b37662 100644 --- a/locales/errors/ja.json +++ b/locales/errors/ja.json @@ -60,7 +60,7 @@ "13001": "このRSSHubインスタンスの所有者ではありません", "13002": "RSSHubが使用中です", "13003": "RSSHubが見つかりません", - "13004": "RSSHubのユーザー制限を超えました", + "13004": "RSSHubのサブスクリプション数制限を超えました", "13005": "RSSHubの購入が見つかりません", "13006": "RSSHubの設定が無効です", "13007": "このRSSHubインスタンスは現在利用できません", diff --git a/locales/errors/zh-CN.json b/locales/errors/zh-CN.json index 26a8aa7f1..3678eaa85 100644 --- a/locales/errors/zh-CN.json +++ b/locales/errors/zh-CN.json @@ -60,7 +60,7 @@ "13001": "您不是此 RSSHub 实例的所有者", "13002": "RSSHub 正在使用中", "13003": "未找到 RSSHub", - "13004": "RSSHub 用户限制已超出", + "13004": "RSSHub 订阅源数量限制已超出", "13005": "未找到 RSSHub 购买记录", "13006": "RSSHub 配置无效", "13007": "此 RSSHub 实例当前不可用", diff --git a/locales/errors/zh-TW.json b/locales/errors/zh-TW.json index 36d02dac5..7437c8387 100644 --- a/locales/errors/zh-TW.json +++ b/locales/errors/zh-TW.json @@ -60,7 +60,7 @@ "13001": "您不是此 RSSHub 實例的擁有者", "13002": "RSSHub 正在使用中", "13003": "未找到 RSSHub", - "13004": "RSSHub 用戶限制已超過", + "13004": "RSSHub 訂閱源數量限制已超過", "13005": "未找到 RSSHub 購買記錄", "13006": "RSSHub 配置無效", "13007": "此 RSSHub 實例目前不可用",