@hot-updater/console 1.2.0-rc.24 → 1.2.0-rc.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.output/nitro.json +1 -1
- package/.output/public/assets/{EventDetails-Dcpdu7re.js → EventDetails-DZsRlDHk.js} +1 -1
- package/.output/public/assets/{InsightsPageHeader-CSas9gM0.js → InsightsPageHeader-2bTrjXln.js} +1 -1
- package/.output/public/assets/{RelativeTime-CiZ7yXNJ.js → RelativeTime-TCmpOVPg.js} +1 -1
- package/.output/public/assets/{RolloutPercentageBadge-D-tZKnX7.js → RolloutPercentageBadge-G6qt8rVb.js} +1 -1
- package/.output/public/assets/StoreSubmission-CqSg880n.js +1 -0
- package/.output/public/assets/{TargetDisplay-CoYY8Fs4.js → TargetDisplay-DwOaMOiI.js} +1 -1
- package/.output/public/assets/{api-keys-3IL4dIHe.js → api-keys-uFY8FsN9.js} +1 -1
- package/.output/public/assets/{badge-laIuYW1U.js → badge-D0NFvUY5.js} +1 -1
- package/.output/public/assets/{index-BKB82n6Y.js → index-CJclLsbG.js} +3 -3
- package/.output/public/assets/{insights-_6iMn8GR.js → insights-B75txQ_F.js} +1 -1
- package/.output/public/assets/{insights-DDRfERph.js → insights-C17Z0whn.js} +2 -2
- package/.output/public/assets/{insights_.distribution-BGAqgPi0.js → insights_.distribution-_dZi1_ay.js} +1 -1
- package/.output/public/assets/{insights_.distribution-CjYkDRA4.js → insights_.distribution-gDqNqI5E.js} +2 -2
- package/.output/public/assets/{installations-CSZfo1rG.js → installations-D0g3xvw8.js} +2 -2
- package/.output/public/assets/{installations-CwQYwQ6K.js → installations-Y_7QW_p8.js} +1 -1
- package/.output/public/assets/{native-builds-B4pD_O7E.js → native-builds-Ba6cEZfm.js} +2 -2
- package/.output/public/assets/native-builds-C3_-21we.js +1 -0
- package/.output/public/assets/native-builds_._buildId-BnP31v32.js +1 -0
- package/.output/public/assets/{native-builds_._buildId-D5tnmyu7.js → native-builds_._buildId-Cp9LJiMP.js} +2 -2
- package/.output/public/assets/{remote-config-Dwdc-sij.js → remote-config-BRdy8QFR.js} +1 -1
- package/.output/public/assets/{remote-config-ZJ_IRSKE.js → remote-config-C9p5Pcdj.js} +3 -3
- package/.output/public/assets/{routes-BUWLcUqW.js → routes-BLTF7nwe.js} +1 -1
- package/.output/public/assets/{routes-Rtz-KcQO.js → routes-gQXSzO_n.js} +2 -2
- package/.output/public/assets/styles-BdlrKlVs.css +2 -0
- package/.output/server/{__23tanstack-start-server-fn-resolver-CcDHdMzp.mjs → __23tanstack-start-server-fn-resolver-z8rr63xV.mjs} +49 -49
- package/.output/server/_libs/@tanstack/react-router-ssr-query+[...].mjs +1 -1
- package/.output/server/_libs/_.mjs +1 -1
- package/.output/server/_ssr/{-native-builds-search-Cl8EZ0Ud.mjs → -native-builds-search-M6t7EIt4.mjs} +1 -1
- package/.output/server/_ssr/{BundleIdDisplay-BOFw0I4S.mjs → BundleIdDisplay-DRnAzJse.mjs} +2 -2
- package/.output/server/_ssr/{ConsoleFeatureUnavailable-CLb3FQ37.mjs → ConsoleFeatureUnavailable-BEU7r4aH.mjs} +6 -6
- package/.output/server/_ssr/{EventDetails-DCcm4h8I.mjs → EventDetails-CjT6o2sJ.mjs} +6 -6
- package/.output/server/_ssr/{HashValueDisplay-Bo7HtMVb.mjs → HashValueDisplay-Bkim8r3-.mjs} +2 -2
- package/.output/server/_ssr/{InsightsPageHeader-D0CFqoqK.mjs → InsightsPageHeader-Ctw4N3SZ.mjs} +6 -6
- package/.output/server/_ssr/{NotFoundPage-CrM2mNho.mjs → NotFoundPage-Bh3gFsR6.mjs} +2 -2
- package/.output/server/_ssr/{PlatformIcon-Cuhy0CIO.mjs → PlatformIcon-CMLs3Wez.mjs} +1 -1
- package/.output/server/_ssr/{RelativeTime-pdNaQt7K.mjs → RelativeTime-DjdCU0J7.mjs} +3 -3
- package/.output/server/_ssr/{RolloutPercentageBadge-D2fgomoj.mjs → RolloutPercentageBadge-BiIHw-V2.mjs} +3 -3
- package/.output/server/_ssr/{StoreSubmission-tbaU5Jxl.mjs → StoreSubmission-Cv59joPo.mjs} +29 -7
- package/.output/server/_ssr/{TargetDisplay-c4AmIqUa.mjs → TargetDisplay-D1PKOupt.mjs} +4 -4
- package/.output/server/_ssr/{alert-dialog-Bl_9bN7q.mjs → alert-dialog-BOKQTpmP.mjs} +1 -1
- package/.output/server/_ssr/{api-bPCSYWmk.mjs → api-CDvGGB1B.mjs} +4 -4
- package/.output/server/_ssr/{api-keys-DCdpQxvq.mjs → api-keys-DvbSgd9L.mjs} +2 -2
- package/.output/server/_ssr/{api-keys-CWc-kMoo.mjs → api-keys-NYJ0VaDB.mjs} +9 -9
- package/.output/server/_ssr/{api-keys-rpc-r2mnoc7r.mjs → api-keys-rpc-B0MrcD15.mjs} +3 -3
- package/.output/server/_ssr/{api-rpc--JDsqZkl.mjs → api-rpc-CIB9gcI7.mjs} +10 -10
- package/.output/server/_ssr/{auth-rpc-c6zZj3k7.mjs → auth-rpc-DsIffEXe.mjs} +4 -4
- package/.output/server/_ssr/{auth.server-D1lLWwx9.mjs → auth.server-Dt9XHLs_.mjs} +42 -15
- package/.output/server/_ssr/{badge-Cf4fbU_q.mjs → badge-KS3YftV5.mjs} +2 -1
- package/.output/server/_ssr/{card-Bx_12-o-.mjs → card-CG5GqIoA.mjs} +1 -1
- package/.output/server/_ssr/{config.server-DBFnQIeD.mjs → config.server-CJs-9Zd_.mjs} +4 -4
- package/.output/server/_ssr/{console-access-Dah0AEYy.mjs → console-access-ClmTMpo_.mjs} +2 -2
- package/.output/server/_ssr/{console-features-CgdQJQlX.mjs → console-features-CRP-pfov.mjs} +1 -1
- package/.output/server/_ssr/{console-features-api-CP8VgLf_.mjs → console-features-api-CpMYF0Pb.mjs} +5 -5
- package/.output/server/_ssr/{console-features-rpc-BWc5qG3c.mjs → console-features-rpc-D-dr-WF8.mjs} +3 -3
- package/.output/server/_ssr/{dialog-B5-o4y_0.mjs → dialog-DvHMJkq7.mjs} +1 -1
- package/.output/server/_ssr/{empty-sGLINpS3.mjs → empty-Bx8DnyWN.mjs} +2 -2
- package/.output/server/_ssr/{field-CYSNwGK0.mjs → field-BVI4lxoz.mjs} +2 -2
- package/.output/server/_ssr/{input-group-LpWc50V4.mjs → input-group-CpJwooTk.mjs} +1 -1
- package/.output/server/_ssr/{insights-CRjccjYz.mjs → insights-B-VtObqr.mjs} +5 -5
- package/.output/server/_ssr/{insights-CjQ9FDjt.mjs → insights-DxlHHXPK.mjs} +21 -21
- package/.output/server/_ssr/{insights-api-ChTevZmg.mjs → insights-api-8PWQ7PiR.mjs} +3 -3
- package/.output/server/_ssr/{insights-C3eT73Ut.mjs → insights-b1hq1O0p.mjs} +2 -2
- package/.output/server/_ssr/{insights-failures-rpc-C2SBL0t-.mjs → insights-failures-rpc-pY2KV9HI.mjs} +7 -7
- package/.output/server/_ssr/{insights-recovery-rpc-fBmK_XwY.mjs → insights-recovery-rpc-CejmWL_y.mjs} +4 -4
- package/.output/server/_ssr/{insights-rpc-CoIPmXt3.mjs → insights-rpc-D_7d_AAJ.mjs} +3 -3
- package/.output/server/_ssr/{insights-search-DqI-4UF6.mjs → insights-search-CoMkZvRt.mjs} +2 -2
- package/.output/server/_ssr/{insights-usage-rpc-DpI7VDWn.mjs → insights-usage-rpc-B1XSuara.mjs} +3 -3
- package/.output/server/_ssr/{insights-usage-rpc-37TTUAr6.mjs → insights-usage-rpc-CrGZDHzO.mjs} +4 -4
- package/.output/server/_ssr/{insights_.distribution-W4fpzgsj.mjs → insights_.distribution-B9sPDvG4.mjs} +5 -5
- package/.output/server/_ssr/{insights_.distribution-RwlJNvF6.mjs → insights_.distribution-CpqnDZNG.mjs} +15 -15
- package/.output/server/_ssr/{insights_.distribution-pdBXAM-9.mjs → insights_.distribution-EOOOOTb6.mjs} +2 -2
- package/.output/server/_ssr/{installations-DKKAVTSE.mjs → installations-BOI_y7Ma.mjs} +11 -11
- package/.output/server/_ssr/{installations-BmIh7M2B.mjs → installations-D0_0hzdi.mjs} +4 -4
- package/.output/server/_ssr/{installations-PHNRkSUb.mjs → installations-dWlOOS7Y.mjs} +2 -2
- package/.output/server/_ssr/{native-builds-CymG4aTV.mjs → native-builds-Bx_az6YZ.mjs} +3 -3
- package/.output/server/_ssr/{native-builds-q-yQUcmQ.mjs → native-builds-C721Rw23.mjs} +25 -21
- package/.output/server/_ssr/{native-builds-CWA9Y__P.mjs → native-builds-OUdRtp6m.mjs} +2 -2
- package/.output/server/_ssr/{native-builds_._buildId-CzJKPxiV.mjs → native-builds_._buildId-YItxv8j9.mjs} +3 -3
- package/.output/server/_ssr/{native-builds_._buildId-bLt4WRQ0.mjs → native-builds_._buildId-ubi48Sfs.mjs} +118 -85
- package/.output/server/_ssr/{nativeBuildDevice-Dn16gNmZ.mjs → nativeBuildDevice-DJUAzAIj.mjs} +26 -46
- package/.output/server/_ssr/{nativeBuildDownloadLink-mzzxooek.mjs → nativeBuildDownloadLink-C0I8eLpS.mjs} +2 -2
- package/.output/server/_ssr/{nativeBuildInstall-C52_rFTA.mjs → nativeBuildInstall-CxG8K8TL.mjs} +5 -6
- package/.output/server/_ssr/{nativeBuilds-D84Qo6jn.mjs → nativeBuilds-CRLmvFaO.mjs} +2 -2
- package/.output/server/_ssr/{native-artifact-H1MDP0Jz.mjs → publicConsoleBase-DvHYxDaG.mjs} +26 -17
- package/.output/server/_ssr/{release-adoption-rpc-CiQeg2XC.mjs → release-adoption-rpc-DcZAYRWJ.mjs} +7 -7
- package/.output/server/_ssr/{releaseAdoption-LLYlRnUB.mjs → releaseAdoption-D6ScSu-W.mjs} +1 -1
- package/.output/server/_ssr/{remote-config-D6_98aiF.mjs → remote-config-BZ_vGV97.mjs} +19 -19
- package/.output/server/_ssr/{remote-config-CHXk0t0Y.mjs → remote-config-DOcSXzxG.mjs} +2 -2
- package/.output/server/_ssr/{remote-config-DFcP3X_W.mjs → remote-config-gKqDKMxk.mjs} +2 -2
- package/.output/server/_ssr/{remote-config-rpc-CmjtaLZo.mjs → remote-config-rpc-CVPd3V69.mjs} +3 -3
- package/.output/server/_ssr/{router-DlRo8qJe.mjs → router-Bcyej4cr.mjs} +60 -75
- package/.output/server/_ssr/{routes-BemtQYlj.mjs → routes-B10xsCh4.mjs} +22 -22
- package/.output/server/_ssr/{routes-DeokFLZU.mjs → routes-ddBRVSju.mjs} +10 -10
- package/.output/server/_ssr/{runtime.server-BsTTLV-B.mjs → runtime.server-wcHT2Cop.mjs} +2 -2
- package/.output/server/_ssr/{schema-migration-rpc-8sXxCyev.mjs → schema-migration-rpc-iWZzLv70.mjs} +3 -3
- package/.output/server/_ssr/{select-C-Xg3M0y.mjs → select-i4WT0c9r.mjs} +1 -1
- package/.output/server/_ssr/{server-BMeXGwaI.mjs → server-CMgMPrDx.mjs} +4 -4
- package/.output/server/_ssr/{sidebar-C-YtAmhJ.mjs → sidebar-mIQgB0iy.mjs} +2 -2
- package/.output/server/_ssr/ssr.mjs +1 -1
- package/.output/server/_ssr/{start-C0XSSCq4.mjs → start-By4wHYjG.mjs} +1 -1
- package/.output/server/_ssr/{switch-Bq_TE-f9.mjs → switch-DR8EAh5C.mjs} +2 -2
- package/.output/server/_ssr/{table-DvW7CEdk.mjs → table-DXmK6G7A.mjs} +1 -1
- package/.output/server/_ssr/{tabs-X3A6lDz5.mjs → tabs-DAfypcYe.mjs} +2 -2
- package/.output/server/_ssr/{updateFailures-DPYzv9bE.mjs → updateFailures-DNiv3S_y.mjs} +1 -1
- package/.output/server/{_tanstack-start-manifest_v-Df6g3sSt.mjs → _tanstack-start-manifest_v-8M7ggCuB.mjs} +36 -38
- package/.output/server/index.mjs +211 -211
- package/package.json +7 -7
- package/src/components/ThemeProvider.tsx +11 -2
- package/src/components/features/native-builds/InstallCard.tsx +20 -21
- package/src/components/features/native-builds/IosInstall.tsx +77 -47
- package/src/components/features/native-builds/NativeBuildsTable.tsx +14 -9
- package/src/components/features/native-builds/SandboxBadge.tsx +8 -2
- package/src/components/features/native-builds/StoreSubmission.tsx +7 -10
- package/src/components/features/native-builds/playTracks.ts +19 -0
- package/src/components/ui/badge.tsx +2 -0
- package/src/lib/server/nativeBuildDevice.ts +22 -43
- package/src/routeTree.gen.ts +0 -44
- package/src/styles.css +8 -0
- package/.output/public/assets/StoreSubmission-CGFw9Mjw.js +0 -1
- package/.output/public/assets/native-builds-CKSg6cCF.js +0 -1
- package/.output/public/assets/native-builds_._buildId-BuVvRbMp.js +0 -1
- package/.output/public/assets/styles-83XEjOMT.css +0 -2
- package/.output/server/_ssr/nativeBuildQr-P9qKcI7l.mjs +0 -115
- package/.output/server/_ssr/publicConsoleBase-3IHSHvqd.mjs +0 -27
- package/.output/server/_ssr/qr-code-pENFuyy9.mjs +0 -22
- package/src/lib/server/nativeBuildQr.ts +0 -163
- package/src/routes/[_]hot-updater/native-builds/preview-qr.ts +0 -14
- package/src/routes/[_]hot-updater/native-builds/qr.ts +0 -14
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hot-updater/console",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "1.2.0-rc.
|
|
4
|
+
"version": "1.2.0-rc.26",
|
|
5
5
|
"files": [
|
|
6
6
|
".output",
|
|
7
7
|
"lib",
|
|
@@ -59,10 +59,10 @@
|
|
|
59
59
|
"tw-animate-css": "^1.4.0",
|
|
60
60
|
"uqr": "^0.1.3",
|
|
61
61
|
"verkit": "0.4.0",
|
|
62
|
-
"@hot-updater/bsdiff": "1.2.0-rc.
|
|
63
|
-
"@hot-updater/plugin-core": "1.2.0-rc.
|
|
64
|
-
"@hot-updater/
|
|
65
|
-
"@hot-updater/
|
|
62
|
+
"@hot-updater/bsdiff": "1.2.0-rc.26",
|
|
63
|
+
"@hot-updater/plugin-core": "1.2.0-rc.26",
|
|
64
|
+
"@hot-updater/protocol": "1.2.0-rc.26",
|
|
65
|
+
"@hot-updater/server": "1.2.0-rc.26"
|
|
66
66
|
},
|
|
67
67
|
"devDependencies": {
|
|
68
68
|
"@tanstack/devtools-vite": "^0.6.0",
|
|
@@ -87,8 +87,8 @@
|
|
|
87
87
|
"vite-tsconfig-paths": "^6.1.1",
|
|
88
88
|
"vitest": "4.1.4",
|
|
89
89
|
"web-vitals": "^5.1.0",
|
|
90
|
-
"@hot-updater/cli-tools": "1.2.0-rc.
|
|
91
|
-
"@hot-updater/mock": "1.2.0-rc.
|
|
90
|
+
"@hot-updater/cli-tools": "1.2.0-rc.26",
|
|
91
|
+
"@hot-updater/mock": "1.2.0-rc.26"
|
|
92
92
|
},
|
|
93
93
|
"description": "React Native OTA solution for self-hosted",
|
|
94
94
|
"license": "SEE LICENSE IN LICENSE",
|
|
@@ -24,7 +24,12 @@ export function ThemeProvider({
|
|
|
24
24
|
const [theme, setTheme] = useState<Theme>(defaultTheme);
|
|
25
25
|
|
|
26
26
|
useEffect(() => {
|
|
27
|
-
|
|
27
|
+
let stored: Theme | null = null;
|
|
28
|
+
try {
|
|
29
|
+
stored = localStorage.getItem(storageKey) as Theme | null;
|
|
30
|
+
} catch {
|
|
31
|
+
// A browser that keeps nothing: the default theme stands.
|
|
32
|
+
}
|
|
28
33
|
if (stored) {
|
|
29
34
|
setTheme(stored);
|
|
30
35
|
}
|
|
@@ -97,7 +102,11 @@ export function ThemeProvider({
|
|
|
97
102
|
const value = {
|
|
98
103
|
theme,
|
|
99
104
|
setTheme: (newTheme: Theme) => {
|
|
100
|
-
|
|
105
|
+
try {
|
|
106
|
+
localStorage.setItem(storageKey, newTheme);
|
|
107
|
+
} catch {
|
|
108
|
+
// A browser that keeps nothing: the theme lasts this visit.
|
|
109
|
+
}
|
|
101
110
|
setTheme(newTheme);
|
|
102
111
|
},
|
|
103
112
|
};
|
|
@@ -21,6 +21,7 @@ import type { NativeBuildDownloadLinkResult } from "@/lib/server/nativeBuildDown
|
|
|
21
21
|
|
|
22
22
|
import { CopyableText } from "./CopyableText";
|
|
23
23
|
import { IosInstall, useIosDevice } from "./IosInstall";
|
|
24
|
+
import { PLAY_TRACKS } from "./playTracks";
|
|
24
25
|
import { isSubmitted, type Submitted } from "./StoreSubmission";
|
|
25
26
|
|
|
26
27
|
/**
|
|
@@ -152,27 +153,18 @@ function SubmittedVersion({ build }: { readonly build: NativeBuildRow }) {
|
|
|
152
153
|
);
|
|
153
154
|
}
|
|
154
155
|
|
|
155
|
-
/**
|
|
156
|
-
* Where a store's testers and its people get a build: a tester's own link needs
|
|
157
|
-
* the app's ID in the store, which only the pull request's comment has.
|
|
158
|
-
*/
|
|
159
|
-
const STORE_CONSOLES = {
|
|
160
|
-
testflight: {
|
|
161
|
-
name: "App Store Connect",
|
|
162
|
-
url: "https://appstoreconnect.apple.com/apps",
|
|
163
|
-
},
|
|
164
|
-
"play-internal": {
|
|
165
|
-
name: "Play Console",
|
|
166
|
-
url: "https://play.google.com/console",
|
|
167
|
-
},
|
|
168
|
-
} as const;
|
|
169
|
-
|
|
170
156
|
/**
|
|
171
157
|
* A build a store took installs from the store, so the card leads with it, and
|
|
172
158
|
* the file stays for keeping, with no QR code or signed link to ask for.
|
|
173
159
|
*/
|
|
174
160
|
function StoreInstallCard({ build }: { readonly build: Submitted }) {
|
|
175
|
-
const store =
|
|
161
|
+
const store =
|
|
162
|
+
build.submitted_to === "testflight"
|
|
163
|
+
? {
|
|
164
|
+
name: "App Store Connect",
|
|
165
|
+
url: "https://appstoreconnect.apple.com/apps",
|
|
166
|
+
}
|
|
167
|
+
: { name: "Play Console", url: "https://play.google.com/console" };
|
|
176
168
|
return (
|
|
177
169
|
<Card className="overflow-hidden shadow-sm">
|
|
178
170
|
<CardHeader className="border-b px-4 py-3">
|
|
@@ -265,10 +257,15 @@ function InstallSteps({ build }: { readonly build: NativeBuildRow }) {
|
|
|
265
257
|
case "aab":
|
|
266
258
|
return isSubmitted(build) ? (
|
|
267
259
|
<p className="text-xs text-muted-foreground">
|
|
268
|
-
Submitted to
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
260
|
+
Submitted to{" "}
|
|
261
|
+
{build.submitted_to === "play-internal"
|
|
262
|
+
? PLAY_TRACKS["play-internal"].name
|
|
263
|
+
: PLAY_TRACKS[build.submitted_to as keyof typeof PLAY_TRACKS]
|
|
264
|
+
.label}{" "}
|
|
265
|
+
as <SubmittedVersion build={build} />.{" "}
|
|
266
|
+
{build.submitted_to === "play-production" ? "Users" : "Testers"} get
|
|
267
|
+
it once its release is rolled out; on an app Play Console hasn't
|
|
268
|
+
published, the release is a draft you roll out in Play Console.
|
|
272
269
|
</p>
|
|
273
270
|
) : (
|
|
274
271
|
<div className="flex min-w-0 flex-col gap-2">
|
|
@@ -327,7 +324,9 @@ function SignedLink({
|
|
|
327
324
|
<CopyableText label="the download link" value={url} />
|
|
328
325
|
<p className="text-xs text-muted-foreground">
|
|
329
326
|
Anyone with this link can download this build until{" "}
|
|
330
|
-
|
|
327
|
+
<span className="whitespace-nowrap">
|
|
328
|
+
{dayjs(link.expiresAt).format("YYYY-MM-DD")}.
|
|
329
|
+
</span>
|
|
331
330
|
</p>
|
|
332
331
|
</div>
|
|
333
332
|
);
|
|
@@ -36,28 +36,66 @@ export const isIosBrowser = (
|
|
|
36
36
|
/iPhone|iPod|iPad/u.test(browser.userAgent) ||
|
|
37
37
|
(/Macintosh/u.test(browser.userAgent) && browser.maxTouchPoints > 1);
|
|
38
38
|
|
|
39
|
+
/** The UDID the profile's page passed in the fragment, if any. */
|
|
40
|
+
const fragmentUdid = () => {
|
|
41
|
+
if (typeof window === "undefined") return null;
|
|
42
|
+
const udid = new URLSearchParams(window.location.hash.slice(1)).get("udid");
|
|
43
|
+
return udid !== null && IOS_UDID_PATTERN.test(udid) ? udid : null;
|
|
44
|
+
};
|
|
45
|
+
|
|
39
46
|
/**
|
|
40
|
-
* Whether this page is open on an iPhone, and
|
|
41
|
-
*
|
|
42
|
-
* browser. Null until then.
|
|
47
|
+
* Whether this page is open on an iPhone, and its UDID: the one this phone
|
|
48
|
+
* kept, else the one the profile's page passed in the fragment. Read after the
|
|
49
|
+
* page mounts: the server renders it without a browser. Null until then.
|
|
43
50
|
*/
|
|
44
51
|
export const useIosDevice = () => {
|
|
45
52
|
const [device, setDevice] = useState<{
|
|
46
53
|
readonly ios: boolean;
|
|
47
54
|
readonly udid: string | null;
|
|
48
55
|
} | null>(null);
|
|
56
|
+
// Read at the first render, so an effect that runs again (React's
|
|
57
|
+
// development check) still has it after the fragment is gone.
|
|
58
|
+
const [passed] = useState(fragmentUdid);
|
|
49
59
|
useEffect(() => {
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
60
|
+
const valid = (udid: string | null | undefined) =>
|
|
61
|
+
udid != null && IOS_UDID_PATTERN.test(udid) ? udid : null;
|
|
62
|
+
// A browser that keeps nothing still has the ID from the fragment, in memory.
|
|
63
|
+
if (passed !== null && window.location.hash !== "") {
|
|
64
|
+
window.history.replaceState(
|
|
65
|
+
window.history.state,
|
|
66
|
+
"",
|
|
67
|
+
`${window.location.pathname}${window.location.search}`,
|
|
68
|
+
);
|
|
55
69
|
}
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
70
|
+
const read = () => {
|
|
71
|
+
let udid: string | null = null;
|
|
72
|
+
try {
|
|
73
|
+
udid = window.localStorage.getItem(IOS_UDID_STORAGE_KEY);
|
|
74
|
+
} catch {
|
|
75
|
+
// A browser that keeps nothing: the fragment's ID, if any, stands.
|
|
76
|
+
}
|
|
77
|
+
const kept = valid(udid) ?? passed;
|
|
78
|
+
setDevice((current) =>
|
|
79
|
+
current?.udid === kept && current !== null
|
|
80
|
+
? current
|
|
81
|
+
: { ios: isIosBrowser(navigator), udid: kept },
|
|
82
|
+
);
|
|
83
|
+
};
|
|
84
|
+
read();
|
|
85
|
+
// The profile's answer may land in another tab, which keeps the ID there:
|
|
86
|
+
// this tab reads it when that tab writes it, or when Safari shows it again.
|
|
87
|
+
const onStorage = (event: StorageEvent) => {
|
|
88
|
+
if (event.key === null || event.key === IOS_UDID_STORAGE_KEY) read();
|
|
89
|
+
};
|
|
90
|
+
window.addEventListener("storage", onStorage);
|
|
91
|
+
window.addEventListener("pageshow", read);
|
|
92
|
+
document.addEventListener("visibilitychange", read);
|
|
93
|
+
return () => {
|
|
94
|
+
window.removeEventListener("storage", onStorage);
|
|
95
|
+
window.removeEventListener("pageshow", read);
|
|
96
|
+
document.removeEventListener("visibilitychange", read);
|
|
97
|
+
};
|
|
98
|
+
}, [passed]);
|
|
61
99
|
return device;
|
|
62
100
|
};
|
|
63
101
|
|
|
@@ -116,21 +154,16 @@ function RenewInstallLink({
|
|
|
116
154
|
function InstallButton({
|
|
117
155
|
build,
|
|
118
156
|
token,
|
|
119
|
-
secondary = false,
|
|
120
157
|
}: {
|
|
121
158
|
readonly build: NativeBuildRow;
|
|
122
159
|
readonly token: string;
|
|
123
|
-
readonly secondary?: boolean;
|
|
124
160
|
}) {
|
|
125
161
|
return (
|
|
126
162
|
<a
|
|
127
|
-
className={buttonVariants({
|
|
128
|
-
className: ACTION_CLASS,
|
|
129
|
-
variant: secondary ? "outline" : "default",
|
|
130
|
-
})}
|
|
163
|
+
className={buttonVariants({ className: ACTION_CLASS })}
|
|
131
164
|
href={nativeBuildItmsUrl(window.location, build.id, token)}
|
|
132
165
|
>
|
|
133
|
-
|
|
166
|
+
Install
|
|
134
167
|
</a>
|
|
135
168
|
);
|
|
136
169
|
}
|
|
@@ -150,25 +183,27 @@ function InstallNotes() {
|
|
|
150
183
|
|
|
151
184
|
/**
|
|
152
185
|
* The link that hands this iPhone the profile that reads its UDID, under the
|
|
153
|
-
* console's path. A plain link, so iOS offers the profile.
|
|
186
|
+
* console's path. A plain link, so iOS offers the profile. Once it's installed,
|
|
187
|
+
* the phone comes back to this page, which then offers Install.
|
|
154
188
|
*/
|
|
155
|
-
function
|
|
189
|
+
function InstallProfile({
|
|
156
190
|
build,
|
|
157
|
-
|
|
191
|
+
again = false,
|
|
158
192
|
}: {
|
|
159
193
|
readonly build: NativeBuildRow;
|
|
160
|
-
|
|
194
|
+
/** Second to the command: for a phone whose kept ID isn't its own. */
|
|
195
|
+
readonly again?: boolean;
|
|
161
196
|
}) {
|
|
162
197
|
return (
|
|
163
198
|
<a
|
|
164
199
|
className={buttonVariants({
|
|
165
200
|
className: ACTION_CLASS,
|
|
166
|
-
variant:
|
|
201
|
+
variant: again ? "secondary" : "default",
|
|
167
202
|
})}
|
|
168
203
|
href={`${consolePathOf(window.location, build.id)}${nativeBuildDeviceProfilePath(build.id)}`}
|
|
169
204
|
>
|
|
170
205
|
<Smartphone data-icon="inline-start" />
|
|
171
|
-
|
|
206
|
+
{again ? "Install the profile again" : "Install profile"}
|
|
172
207
|
</a>
|
|
173
208
|
);
|
|
174
209
|
}
|
|
@@ -190,7 +225,8 @@ export function IosInstall({
|
|
|
190
225
|
const { refetch } = eligibility;
|
|
191
226
|
const expired = useInstallLinkExpired(
|
|
192
227
|
eligibility.dataUpdatedAt,
|
|
193
|
-
eligibility.data?.status === "installable"
|
|
228
|
+
eligibility.data?.status === "installable" &&
|
|
229
|
+
eligibility.data.device === "included",
|
|
194
230
|
);
|
|
195
231
|
useEffect(() => {
|
|
196
232
|
if (expired) void refetch();
|
|
@@ -241,20 +277,18 @@ export function IosInstall({
|
|
|
241
277
|
);
|
|
242
278
|
}
|
|
243
279
|
if (token === null) return null;
|
|
244
|
-
const install = ({ secondary = false } = {}) =>
|
|
245
|
-
expired ? (
|
|
246
|
-
<RenewInstallLink
|
|
247
|
-
fetching={eligibility.isFetching}
|
|
248
|
-
onRenew={() => void refetch()}
|
|
249
|
-
/>
|
|
250
|
-
) : (
|
|
251
|
-
<InstallButton build={build} secondary={secondary} token={token} />
|
|
252
|
-
);
|
|
253
280
|
if (result.device === "included") {
|
|
254
281
|
return (
|
|
255
282
|
<div className="flex min-w-0 flex-col gap-3">
|
|
256
283
|
<p className="text-sm font-medium">This iPhone is in this build.</p>
|
|
257
|
-
{
|
|
284
|
+
{expired ? (
|
|
285
|
+
<RenewInstallLink
|
|
286
|
+
fetching={eligibility.isFetching}
|
|
287
|
+
onRenew={() => void refetch()}
|
|
288
|
+
/>
|
|
289
|
+
) : (
|
|
290
|
+
<InstallButton build={build} token={token} />
|
|
291
|
+
)}
|
|
258
292
|
<InstallNotes />
|
|
259
293
|
</div>
|
|
260
294
|
);
|
|
@@ -275,26 +309,22 @@ export function IosInstall({
|
|
|
275
309
|
value={nativeBuildDeviceAddCommand(udid ?? "")}
|
|
276
310
|
wrap
|
|
277
311
|
/>
|
|
278
|
-
{
|
|
279
|
-
<InstallNotes />
|
|
312
|
+
<InstallProfile build={build} again />
|
|
280
313
|
</div>
|
|
281
314
|
);
|
|
282
315
|
}
|
|
283
316
|
return (
|
|
284
317
|
<div className="flex min-w-0 flex-col gap-3">
|
|
285
318
|
<div className="flex min-w-0 flex-col gap-1">
|
|
286
|
-
<p className="text-sm font-medium">
|
|
319
|
+
<p className="text-sm font-medium">Install the profile first</p>
|
|
287
320
|
<p className="text-xs text-muted-foreground">
|
|
288
|
-
iOS installs this IPA only on the devices it lists.
|
|
321
|
+
iOS installs this IPA only on the devices it lists. The profile reads
|
|
289
322
|
this iPhone's ID and nothing else: allow the download, then install it
|
|
290
|
-
|
|
323
|
+
in Settings, where iOS calls it not signed. Safari comes back here to
|
|
324
|
+
install the app, and nothing stays installed.
|
|
291
325
|
</p>
|
|
292
326
|
</div>
|
|
293
|
-
<
|
|
294
|
-
<CheckThisIphone build={build} />
|
|
295
|
-
{install({ secondary: true })}
|
|
296
|
-
</div>
|
|
297
|
-
<InstallNotes />
|
|
327
|
+
<InstallProfile build={build} />
|
|
298
328
|
</div>
|
|
299
329
|
);
|
|
300
330
|
}
|
|
@@ -177,20 +177,23 @@ function BuildLink({ build }: { readonly build: NativeBuildRow }) {
|
|
|
177
177
|
|
|
178
178
|
/**
|
|
179
179
|
* What the build is, its artifact kind and whether it is a sandbox build, kept
|
|
180
|
-
* together so the tag never wraps away from the kind it qualifies
|
|
181
|
-
*
|
|
182
|
-
*
|
|
180
|
+
* together so the tag never wraps away from the kind it qualifies. In a table
|
|
181
|
+
* cell the tag sits beside the kind, so a sandbox row is as tall as any other,
|
|
182
|
+
* and the cell is capped at its widest short kind ("AAB Sandbox"): only a
|
|
183
|
+
* longer kind, such as a sandbox "Simulator app", puts its tag under it rather
|
|
184
|
+
* than widen the table past its frame. On a card the tag sits beside the kind,
|
|
185
|
+
* under it only when a narrow card has no room.
|
|
183
186
|
*/
|
|
184
187
|
function BuildIdentity({
|
|
185
188
|
build,
|
|
186
|
-
|
|
189
|
+
inTable = false,
|
|
187
190
|
}: {
|
|
188
191
|
readonly build: NativeBuildRow;
|
|
189
|
-
readonly
|
|
192
|
+
readonly inTable?: boolean;
|
|
190
193
|
}) {
|
|
191
|
-
if (
|
|
194
|
+
if (inTable) {
|
|
192
195
|
return (
|
|
193
|
-
<span className="flex flex-
|
|
196
|
+
<span className="flex max-w-24 flex-wrap items-center gap-x-1.5 gap-y-1">
|
|
194
197
|
<BuildLink build={build} />
|
|
195
198
|
<SandboxBadge build={build} />
|
|
196
199
|
</span>
|
|
@@ -249,7 +252,9 @@ function StoreBadges({
|
|
|
249
252
|
<span className={className}>
|
|
250
253
|
<StoreSubmissionBadge build={build} />
|
|
251
254
|
{build.is_store_build ? (
|
|
252
|
-
<Badge variant="
|
|
255
|
+
<Badge className="px-1.5" variant="muted">
|
|
256
|
+
Store build
|
|
257
|
+
</Badge>
|
|
253
258
|
) : null}
|
|
254
259
|
</span>
|
|
255
260
|
);
|
|
@@ -307,7 +312,7 @@ function BuildRow({
|
|
|
307
312
|
}
|
|
308
313
|
>
|
|
309
314
|
<TableCell>
|
|
310
|
-
<BuildIdentity build={build}
|
|
315
|
+
<BuildIdentity build={build} inTable />
|
|
311
316
|
</TableCell>
|
|
312
317
|
<TableCell>
|
|
313
318
|
<ChannelFilterButton channel={channel} onChannel={onChannel} />
|
|
@@ -4,12 +4,18 @@ import { Badge } from "@/components/ui/badge";
|
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* "Sandbox" on a sandbox build, as the registry records it, whatever its
|
|
7
|
-
* channel; nothing on any other.
|
|
7
|
+
* channel; nothing on any other. A qualifier of the artifact kind beside it,
|
|
8
|
+
* so a quiet tag: tinted and muted like a neutral channel, the row's chip
|
|
9
|
+
* height, and narrow, as "Store build" is.
|
|
8
10
|
*/
|
|
9
11
|
export function SandboxBadge({
|
|
10
12
|
build,
|
|
11
13
|
}: {
|
|
12
14
|
readonly build: Pick<NativeBuildRow, "is_sandbox">;
|
|
13
15
|
}) {
|
|
14
|
-
return build.is_sandbox ?
|
|
16
|
+
return build.is_sandbox ? (
|
|
17
|
+
<Badge className="px-1.5" variant="muted">
|
|
18
|
+
Sandbox
|
|
19
|
+
</Badge>
|
|
20
|
+
) : null;
|
|
15
21
|
}
|
|
@@ -5,16 +5,17 @@ import { Send } from "lucide-react";
|
|
|
5
5
|
|
|
6
6
|
import { Badge } from "@/components/ui/badge";
|
|
7
7
|
|
|
8
|
+
import { PLAY_TRACKS } from "./playTracks";
|
|
9
|
+
|
|
8
10
|
dayjs.extend(relativeTime);
|
|
9
11
|
|
|
10
12
|
/** Each store track's name as the stores call it. */
|
|
11
13
|
export const storeTrackLabels = {
|
|
12
14
|
testflight: "TestFlight",
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
>;
|
|
15
|
+
...Object.fromEntries(
|
|
16
|
+
Object.entries(PLAY_TRACKS).map(([key, value]) => [key, value.label]),
|
|
17
|
+
),
|
|
18
|
+
} as Record<NonNullable<NativeBuildRow["submitted_to"]>, string>;
|
|
18
19
|
|
|
19
20
|
export type Submitted = NativeBuildRow & {
|
|
20
21
|
readonly submitted_to: NonNullable<NativeBuildRow["submitted_to"]>;
|
|
@@ -63,11 +64,7 @@ export function StoreSubmissionBadge({
|
|
|
63
64
|
if (!isSubmitted(build)) return null;
|
|
64
65
|
return (
|
|
65
66
|
<span className="inline-flex flex-wrap items-center gap-1.5">
|
|
66
|
-
<Badge
|
|
67
|
-
className="gap-1"
|
|
68
|
-
title={submittedTitle(build)}
|
|
69
|
-
variant="secondary"
|
|
70
|
-
>
|
|
67
|
+
<Badge className="gap-1" title={submittedTitle(build)} variant="muted">
|
|
71
68
|
<Send aria-hidden="true" className="size-3" />
|
|
72
69
|
{storeTrackLabels[build.submitted_to]}
|
|
73
70
|
{build.submitted_version ? (
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/** Google Play destination display labels. */
|
|
2
|
+
export const PLAY_TRACKS = {
|
|
3
|
+
"play-internal": {
|
|
4
|
+
label: "Play internal",
|
|
5
|
+
name: "Google Play internal testing",
|
|
6
|
+
},
|
|
7
|
+
"play-closed": {
|
|
8
|
+
label: "Play closed",
|
|
9
|
+
name: "Google Play closed testing",
|
|
10
|
+
},
|
|
11
|
+
"play-open": {
|
|
12
|
+
label: "Play open",
|
|
13
|
+
name: "Google Play open testing",
|
|
14
|
+
},
|
|
15
|
+
"play-production": {
|
|
16
|
+
label: "Play production",
|
|
17
|
+
name: "Google Play production",
|
|
18
|
+
},
|
|
19
|
+
} as const;
|
|
@@ -15,6 +15,8 @@ const badgeVariants = cva(
|
|
|
15
15
|
"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",
|
|
16
16
|
success: "border-success/20 bg-success/10 text-success",
|
|
17
17
|
warning: "border-warning/20 bg-warning/10 text-warning",
|
|
18
|
+
muted:
|
|
19
|
+
"border-badge-muted/20 bg-badge-muted/10 font-medium text-badge-muted",
|
|
18
20
|
destructive:
|
|
19
21
|
"border-transparent bg-destructive text-destructive-foreground shadow hover:bg-destructive/80",
|
|
20
22
|
outline: "text-foreground",
|
|
@@ -4,7 +4,6 @@ import { readProfileServiceUdid } from "@hot-updater/protocol/native-artifact";
|
|
|
4
4
|
import {
|
|
5
5
|
IOS_UDID_PATTERN,
|
|
6
6
|
IOS_UDID_STORAGE_KEY,
|
|
7
|
-
nativeBuildDeviceAddCommand,
|
|
8
7
|
nativeBuildDeviceProfilePath,
|
|
9
8
|
} from "../native-builds";
|
|
10
9
|
import { escapePlistText } from "./plistText";
|
|
@@ -74,11 +73,11 @@ export const serveDeviceProfile = (request: Request, id: string): Response => {
|
|
|
74
73
|
<key>PayloadOrganization</key>
|
|
75
74
|
<string>Hot Updater</string>
|
|
76
75
|
<key>PayloadDisplayName</key>
|
|
77
|
-
<string>
|
|
76
|
+
<string>Hot Updater Device Profile</string>
|
|
78
77
|
<key>PayloadDescription</key>
|
|
79
78
|
<string>Sends this iPhone's ID (UDID) to ${escapePlistText(host)}, to check whether a build can install on it. Nothing stays installed.</string>
|
|
80
79
|
<key>PayloadIdentifier</key>
|
|
81
|
-
<string>dev.hot-updater.
|
|
80
|
+
<string>dev.hot-updater.device-profile</string>
|
|
82
81
|
<key>PayloadUUID</key>
|
|
83
82
|
<string>6D3F4C0E-52C4-4C8B-9E0A-7B1E5A0C2F11</string>
|
|
84
83
|
<key>PayloadVersion</key>
|
|
@@ -161,13 +160,9 @@ const page = ({
|
|
|
161
160
|
readonly buildId: string;
|
|
162
161
|
readonly nonce: string;
|
|
163
162
|
}) => {
|
|
164
|
-
const [commandStart, commandEnd] =
|
|
165
|
-
nativeBuildDeviceAddCommand("UDID").split("UDID");
|
|
166
163
|
const script = JSON.stringify({
|
|
167
164
|
pattern: IOS_UDID_PATTERN.source,
|
|
168
165
|
key: IOS_UDID_STORAGE_KEY,
|
|
169
|
-
commandStart,
|
|
170
|
-
commandEnd,
|
|
171
166
|
}).replaceAll("<", "\\u003c");
|
|
172
167
|
return `<!doctype html>
|
|
173
168
|
<html lang="en">
|
|
@@ -176,38 +171,30 @@ const page = ({
|
|
|
176
171
|
<meta name="viewport" content="width=device-width, initial-scale=1, viewport-fit=cover">
|
|
177
172
|
<meta name="color-scheme" content="dark light">
|
|
178
173
|
<meta name="robots" content="noindex">
|
|
179
|
-
<title>
|
|
174
|
+
<title>Back to the build</title>
|
|
180
175
|
<style nonce="${nonce}">
|
|
181
|
-
:root { color-scheme: dark light; --bg: oklch(1 0 0); --fg: oklch(0.147 0.004 49.25); --muted: oklch(0.553 0.013 58.071); --line: oklch(0.923 0.003 48.717); --
|
|
182
|
-
@media (prefers-color-scheme: dark) { :root { --bg: oklch(0.147 0.004 49.25); --fg: oklch(0.985 0.001 106.423); --muted: oklch(0.709 0.01 56.259); --line: oklch(1 0 0 / 10%);
|
|
176
|
+
:root { color-scheme: dark light; --bg: oklch(1 0 0); --fg: oklch(0.147 0.004 49.25); --muted: oklch(0.553 0.013 58.071); --line: oklch(0.923 0.003 48.717); --radius: 0.45rem; }
|
|
177
|
+
@media (prefers-color-scheme: dark) { :root { --bg: oklch(0.147 0.004 49.25); --fg: oklch(0.985 0.001 106.423); --muted: oklch(0.709 0.01 56.259); --line: oklch(1 0 0 / 10%); } }
|
|
183
178
|
* { box-sizing: border-box; }
|
|
184
179
|
body { margin: 0; background: var(--bg); color: var(--fg); font: 16px/1.5 -apple-system, system-ui, sans-serif; }
|
|
185
180
|
main { display: flex; flex-direction: column; gap: 16px; max-width: 32rem; margin: 0 auto; padding: 32px 16px calc(32px + env(safe-area-inset-bottom)); }
|
|
186
181
|
h1 { margin: 0; font-size: 22px; line-height: 1.25; }
|
|
187
182
|
p { margin: 0; color: var(--muted); font-size: 15px; }
|
|
188
|
-
.
|
|
189
|
-
code { display: block; padding: 12px; overflow-wrap: anywhere; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); font: 14px/1.4 ui-monospace, Menlo, monospace; }
|
|
190
|
-
button, a.action { display: flex; align-items: center; justify-content: center; width: 100%; min-height: 44px; padding: 8px 16px; border-radius: var(--radius); font: inherit; font-weight: 600; text-decoration: none; }
|
|
191
|
-
button { border: 0; background: var(--primary); color: var(--on-primary); }
|
|
192
|
-
a.action { border: 1px solid var(--line); color: var(--fg); }
|
|
183
|
+
a.action { display: flex; align-items: center; justify-content: center; width: 100%; min-height: 44px; padding: 8px 16px; border-radius: var(--radius); font: inherit; font-weight: 600; text-decoration: none; border: 1px solid var(--line); color: var(--fg); }
|
|
193
184
|
[hidden] { display: none; }
|
|
194
185
|
</style>
|
|
195
186
|
</head>
|
|
196
187
|
<body>
|
|
197
188
|
<main>
|
|
198
|
-
<div id="
|
|
199
|
-
<h1>
|
|
189
|
+
<div id="returning" hidden>
|
|
190
|
+
<h1>Back to the build</h1>
|
|
191
|
+
<p>Opening the build's page to install it.</p>
|
|
200
192
|
</div>
|
|
201
193
|
<div id="missing" hidden>
|
|
202
194
|
<h1>No iPhone ID here</h1>
|
|
203
195
|
</div>
|
|
204
|
-
<
|
|
205
|
-
<
|
|
206
|
-
<p id="next" hidden>A maintainer runs this command to register the iPhone, then rebuilds. Open the build again afterwards to install it.</p>
|
|
207
|
-
<code id="command" hidden translate="no"></code>
|
|
208
|
-
<button id="copy" type="button" hidden>Copy command</button>
|
|
209
|
-
<p id="retry" hidden>Open the build's page in Safari and check this iPhone again. On a Mac, Finder shows an iPhone's ID, which a maintainer can register with native-build devices add.</p>
|
|
210
|
-
<a class="action" href="../../../native-builds/${encodeURIComponent(buildId)}">Back to the build</a>
|
|
196
|
+
<p id="retry" hidden>Open the build's page in Safari and install the profile again. On a Mac, Finder shows an iPhone's ID, which a maintainer can register with native-build devices add.</p>
|
|
197
|
+
<a class="action" id="back" href="../../../native-builds/${encodeURIComponent(buildId)}">Back to the build</a>
|
|
211
198
|
</main>
|
|
212
199
|
<script nonce="${nonce}">
|
|
213
200
|
(function () {
|
|
@@ -220,19 +207,11 @@ a.action { border: 1px solid var(--line); color: var(--fg); }
|
|
|
220
207
|
if (location.hash) history.replaceState(null, "", location.pathname);
|
|
221
208
|
if (!udid || !pattern.test(udid)) { show("missing"); show("retry"); return; }
|
|
222
209
|
try { localStorage.setItem(c.key, udid); } catch (e) {}
|
|
223
|
-
|
|
224
|
-
document.getElementById("
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
button.addEventListener("click", function () {
|
|
229
|
-
navigator.clipboard.writeText(command).then(function () {
|
|
230
|
-
button.textContent = "Copied";
|
|
231
|
-
}, function () {
|
|
232
|
-
getSelection().selectAllChildren(document.getElementById("command"));
|
|
233
|
-
button.textContent = "Select and copy above";
|
|
234
|
-
});
|
|
235
|
-
});
|
|
210
|
+
// The ID goes along in the fragment too, for a browser that keeps nothing.
|
|
211
|
+
var back = document.getElementById("back");
|
|
212
|
+
back.href = back.href.split("#")[0] + "#udid=" + encodeURIComponent(udid);
|
|
213
|
+
show("returning");
|
|
214
|
+
location.replace(back.href);
|
|
236
215
|
})();
|
|
237
216
|
</script>
|
|
238
217
|
</body>
|
|
@@ -241,12 +220,12 @@ a.action { border: 1px solid var(--line); color: var(--fg); }
|
|
|
241
220
|
};
|
|
242
221
|
|
|
243
222
|
/**
|
|
244
|
-
* The page the callback lands on
|
|
245
|
-
*
|
|
246
|
-
*
|
|
247
|
-
*
|
|
248
|
-
*
|
|
249
|
-
*
|
|
223
|
+
* The page the callback lands on. It keeps the UDID in the phone's
|
|
224
|
+
* `localStorage` and goes straight back to the build's page with the UDID in
|
|
225
|
+
* the fragment too, for a browser that keeps nothing. The build's page offers
|
|
226
|
+
* Install, or the command for a maintainer, which asks whose iPhone it is,
|
|
227
|
+
* since a crafted link can carry any ID. The UDID stays in the browser: a
|
|
228
|
+
* fragment never reaches a server. It takes no session.
|
|
250
229
|
*
|
|
251
230
|
* - 400: the ID isn't a UUIDv7;
|
|
252
231
|
* - 405: a method other than GET or HEAD.
|