feat(mini-user): configurable WeChat mini share scenes in system settings

Add HQ group for default and per-page share title/desc/image; expose via client-config and wire all mini-user share entry points.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-08-06 15:45:57 +08:00
parent a2abbb6169
commit 83b1b0e5f6
12 changed files with 526 additions and 106 deletions
+7 -11
View File
@@ -36,9 +36,9 @@ import {
setStoresListCache,
} from '../../lib/stores-session';
import {
DEFAULT_SHARE_DESC,
DEFAULT_SHARE_TITLE,
buildSceneSharePayload,
toWeappShareMessage,
toWeappShareTimeline,
} from '../../lib/wechat-share';
type Store = {
@@ -350,19 +350,15 @@ export default function StoresPage() {
}
const sharePayload = useMemo(
() => ({
title: '杜康好客门店',
desc: DEFAULT_SHARE_DESC,
path: '/pages/stores/index',
}),
() =>
buildSceneSharePayload('stores', {
path: '/pages/stores/index',
}),
[],
);
useShareAppMessage(() => toWeappShareMessage(sharePayload));
useShareTimeline(() => ({
title: sharePayload.title || DEFAULT_SHARE_TITLE,
query: '',
}));
useShareTimeline(() => toWeappShareTimeline(sharePayload));
return (
<PageShell variant="tab" className="store-page no-tab-header">