-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
91 lines (88 loc) · 3.31 KB
/
index.html
File metadata and controls
91 lines (88 loc) · 3.31 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta
name="viewport"
content="width=device-width, initial-scale=1.0, maximum-scale=1.0, viewport-fit=cover"
/>
<link rel="icon" href="/favicon.ico" />
<meta
name="description"
content="Web site created using create-tsrouter-app"
/>
<link rel="apple-touch-icon" href="/logo192.png" />
<link rel="manifest" href="/manifest.json" />
<link
rel="preload"
href="/fonts/PretendardVariable.woff2"
as="font"
type="font/woff2"
crossorigin
/>
<title>나답</title>
<!-- amplitude -->
<script src="https://cdn.amplitude.com/libs/analytics-browser-2.11.1-min.js.gz"></script>
<script src="https://cdn.amplitude.com/libs/plugin-session-replay-browser-1.25.0-min.js.gz"></script>
<script>
window.amplitude.add(window.sessionReplay.plugin({ sampleRate: 1 }));
window.amplitude.init("948fc3da22f1528a4062be1e06fd30b", {
autocapture: { elementInteractions: true },
});
</script>
<!-- kakao login -->
<script
src="https://t1.kakaocdn.net/kakao_js_sdk/2.8.1/kakao.min.js"
integrity="sha384-OL+ylM/iuPLtW5U3XcvLSGhE8JzReKDank5InqlHGWPhb4140/yrBw0bg0y7+C9J"
crossorigin="anonymous"
></script>
<!-- lagacy CSS -->
<script>
(function () {
var MIN_CHROME = 100; // 이 버전 미만일 때만 구형으로 간주
var ua = navigator.userAgent;
var isLegacy = false;
// 1. 크롬 버전 정확히 추출 (가짜 Safari 버전에 속지 않음)
var chromeMatch = ua.match(/Chrome\/([0-9]+)/);
if (chromeMatch) {
var chromeVersion = parseInt(chromeMatch[1], 10);
if (chromeVersion < MIN_CHROME) {
isLegacy = true;
}
}
// 크롬이 아닌 경우 (예: 진짜 구형 아이폰) 처리가 필요하다면
// 아이폰 전용 정규식을 따로 써야 하지만, 안드로이드 타겟이라면 생략 가능합니다.
// 2. 구형 기기일 때만 Fallback CSS 주입 및 기존 CSS 제거
if (isLegacy) {
// 레거시 CSS 찔러넣기
var link = document.createElement("link");
link.rel = "stylesheet";
// ⚠️ 주의: 빌드 환경에 따라 경로가 다를 수 있습니다. (예: '/assets/tailwind-v3-legacy.css')
link.href = "/assets/tailwind-v3-legacy.css";
document.head.appendChild(link);
// DOM 로드 완료 후 기존 v4 CSS와 Style 태그 모조리 삭제
document.addEventListener("DOMContentLoaded", function () {
document
.querySelectorAll('link[rel="stylesheet"]')
.forEach(function (el) {
// 방금 추가한 레거시 CSS는 지우지 않음
if (el.href.indexOf("tailwind-v3-legacy") === -1) {
el.remove();
}
});
document.querySelectorAll("style").forEach(function (el) {
el.remove();
});
});
}
})();
</script>
</head>
<body>
<div id="push-root"></div>
<div style="height: 100%" id="app"></div>
<div id="modal-root"></div>
<div id="toast-root"></div>
<script type="module" src="/src/main.tsx"></script>
</body>
</html>