chore: test deploy snapshot
This commit is contained in:
@@ -1199,10 +1199,6 @@ function buildAbsoluteShareUrl(path?: string | null) {
|
||||
}
|
||||
|
||||
function createChatShareManifestHref(pathname: string, title?: string | null) {
|
||||
if (isAppleMobileDevice()) {
|
||||
return '/chat-share.webmanifest';
|
||||
}
|
||||
|
||||
const normalizedTitle = title?.trim();
|
||||
return createInstallManifestObjectUrl({
|
||||
startPath: pathname,
|
||||
|
||||
@@ -154,14 +154,13 @@ export function swapInstallDocumentMetadata(options: SwapInstallDocumentMetadata
|
||||
|
||||
|
||||
type BootstrapInstallMetadataResult = {
|
||||
manifestHref: string;
|
||||
manifestObjectUrl: string;
|
||||
title: string;
|
||||
themeColor: string;
|
||||
} | null;
|
||||
|
||||
type BootstrapInstallMetadataDefinition = {
|
||||
description: string;
|
||||
manifestPath?: string;
|
||||
scope?: string;
|
||||
shortName?: string;
|
||||
themeColor: string;
|
||||
@@ -235,7 +234,6 @@ function resolveBootstrapInstallMetadataDefinition(pathname: string, search: str
|
||||
shortName: '공유채팅',
|
||||
description: '리소스 공유 채팅방을 홈 화면 앱으로 바로 엽니다.',
|
||||
themeColor: '#165dff',
|
||||
manifestPath: '/chat-share.webmanifest',
|
||||
scope: pathname,
|
||||
};
|
||||
}
|
||||
@@ -256,7 +254,7 @@ export function applyBootstrapInstallMetadataForCurrentRoute(): BootstrapInstall
|
||||
}
|
||||
|
||||
return {
|
||||
manifestHref: metadata.manifestPath ?? createCurrentRouteInstallManifestObjectUrl(metadata),
|
||||
manifestObjectUrl: createCurrentRouteInstallManifestObjectUrl(metadata),
|
||||
title: metadata.title,
|
||||
themeColor: metadata.themeColor,
|
||||
};
|
||||
|
||||
@@ -19,9 +19,9 @@ async function bootstrap() {
|
||||
if (typeof window !== 'undefined') {
|
||||
const bootstrapInstallMetadata = applyBootstrapInstallMetadataForCurrentRoute();
|
||||
|
||||
if (bootstrapInstallMetadata?.manifestHref) {
|
||||
if (bootstrapInstallMetadata?.manifestObjectUrl) {
|
||||
restoreBootstrapInstallMetadata = swapInstallDocumentMetadata({
|
||||
manifestHref: bootstrapInstallMetadata.manifestHref,
|
||||
manifestHref: bootstrapInstallMetadata.manifestObjectUrl,
|
||||
title: bootstrapInstallMetadata.title,
|
||||
themeColor: bootstrapInstallMetadata.themeColor,
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user