@limrun/ui 0.9.0-rc.5 → 0.9.0-rc.6

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.
Files changed (64) hide show
  1. package/README.md +9 -0
  2. package/dist/components/device-install/device-install-dialog.d.ts +5 -0
  3. package/dist/components/device-install/index.d.ts +2 -0
  4. package/dist/core/device-install/apple/client.d.ts +17 -0
  5. package/dist/core/device-install/apple/crypto.d.ts +20 -0
  6. package/dist/core/device-install/apple/gsa-srp.d.ts +26 -0
  7. package/dist/core/device-install/apple/index.d.ts +5 -0
  8. package/dist/core/device-install/apple/provisioning.d.ts +161 -0
  9. package/dist/core/device-install/apple/relay.d.ts +29 -0
  10. package/dist/core/device-install/index.d.ts +4 -0
  11. package/dist/core/device-install/operations/index.d.ts +6 -0
  12. package/dist/core/device-install/operations/limbuild-client.d.ts +28 -0
  13. package/dist/core/device-install/operations/operations.d.ts +32 -0
  14. package/dist/core/device-install/operations/relay-client.d.ts +25 -0
  15. package/dist/core/device-install/operations/relay-protocol.d.ts +27 -0
  16. package/dist/core/device-install/operations/usbmux.d.ts +32 -0
  17. package/dist/core/device-install/operations/webusb.d.ts +21 -0
  18. package/dist/core/device-install/storage/browser-storage.d.ts +44 -0
  19. package/dist/core/device-install/storage/index.d.ts +1 -0
  20. package/dist/core/device-install/types.d.ts +48 -0
  21. package/dist/device-install/index.cjs +1 -0
  22. package/dist/device-install/index.d.ts +3 -0
  23. package/dist/device-install/index.js +78 -0
  24. package/dist/device-install/react.cjs +1 -0
  25. package/dist/device-install/react.d.ts +1 -0
  26. package/dist/device-install/react.js +4 -0
  27. package/dist/device-install-dialog-86RDdoK9.js +2 -0
  28. package/dist/device-install-dialog-CnyDWf0q.mjs +462 -0
  29. package/dist/device-install-dialog.css +1 -0
  30. package/dist/hooks/index.d.ts +1 -0
  31. package/dist/hooks/use-device-install.d.ts +73 -0
  32. package/dist/index.cjs +1 -1
  33. package/dist/index.d.ts +2 -0
  34. package/dist/index.js +495 -502
  35. package/dist/use-device-install-CbGVvwPp.js +31 -0
  36. package/dist/use-device-install-j1Gekpl4.mjs +13623 -0
  37. package/package.json +15 -2
  38. package/src/components/device-install/device-install-dialog.css +325 -0
  39. package/src/components/device-install/device-install-dialog.tsx +513 -0
  40. package/src/components/device-install/index.ts +2 -0
  41. package/src/core/device-install/apple/client.ts +152 -0
  42. package/src/core/device-install/apple/crypto.ts +202 -0
  43. package/src/core/device-install/apple/gsa-srp.ts +127 -0
  44. package/src/core/device-install/apple/index.ts +5 -0
  45. package/src/core/device-install/apple/provisioning.ts +298 -0
  46. package/src/core/device-install/apple/relay.ts +221 -0
  47. package/src/core/device-install/index.ts +4 -0
  48. package/src/core/device-install/operations/index.ts +6 -0
  49. package/src/core/device-install/operations/limbuild-client.ts +104 -0
  50. package/src/core/device-install/operations/operations.ts +217 -0
  51. package/src/core/device-install/operations/relay-client.ts +255 -0
  52. package/src/core/device-install/operations/relay-protocol.ts +71 -0
  53. package/src/core/device-install/operations/usbmux.ts +270 -0
  54. package/src/core/device-install/operations/webusb-dom.d.ts +54 -0
  55. package/src/core/device-install/operations/webusb.ts +105 -0
  56. package/src/core/device-install/storage/browser-storage.ts +263 -0
  57. package/src/core/device-install/storage/index.ts +1 -0
  58. package/src/core/device-install/types.ts +65 -0
  59. package/src/device-install/index.ts +3 -0
  60. package/src/device-install/react.ts +1 -0
  61. package/src/hooks/index.ts +1 -0
  62. package/src/hooks/use-device-install.ts +1210 -0
  63. package/src/index.ts +2 -0
  64. package/vite.config.ts +6 -2
@@ -0,0 +1,73 @@
1
+ import { AppleDeveloperPortalDevice, AppleDeveloperPortalAppID, AppleDeveloperPortalTeam, BuildLogLine, DeviceInstallBuildStatus, DeviceInstallBusyAction, DeviceInstallStep, DeviceInstallStepStatus } from '../core/device-install';
2
+ type DeviceInstallStepStatuses = Record<DeviceInstallStep, DeviceInstallStepStatus>;
3
+ export type UseDeviceInstallOptions = {
4
+ apiUrl?: string;
5
+ token?: string;
6
+ };
7
+ export type UseDeviceInstallResult = {
8
+ currentStep: DeviceInstallStep;
9
+ stepStatuses: DeviceInstallStepStatuses;
10
+ device?: DeviceInstallDevice;
11
+ hasPairRecord: boolean;
12
+ hasSigningAssets: boolean;
13
+ hasSigningInputs: boolean;
14
+ pairConfirmationRequired: boolean;
15
+ logs: string[];
16
+ buildLogs: BuildLogLine[];
17
+ buildStatus: DeviceInstallBuildStatus;
18
+ appleSigningStatus: DeviceInstallAppleSigningStatus;
19
+ appleTeams: AppleDeveloperPortalTeam[];
20
+ appleDevices: AppleDeveloperPortalDevice[];
21
+ appleAppIDs: AppleDeveloperPortalAppID[];
22
+ applePortalSummary?: ApplePortalSummary;
23
+ selectedAppleTeamID?: string;
24
+ selectedAppleDeviceIDs: string[];
25
+ connectedAppleDeviceRegistered: boolean;
26
+ connectedDeviceInProfile?: boolean;
27
+ hasReusableAppleCertificate: boolean;
28
+ appleBundleID: string;
29
+ buildLogPanelOpen: boolean;
30
+ busyAction?: DeviceInstallBusyAction;
31
+ error?: string;
32
+ canBuild: boolean;
33
+ canPrepareAppleSigningAssets: boolean;
34
+ canRequestUSBAccess: boolean;
35
+ canPairBrowser: boolean;
36
+ canInstall: boolean;
37
+ setSigningFiles: (files: DeviceInstallSigningFiles) => void;
38
+ setAppleBundleID: (bundleID: string) => void;
39
+ setSelectedAppleDeviceIDs: (deviceIDs: string[]) => void;
40
+ setBuildLogPanelOpen: (open: boolean) => void;
41
+ startAppleIDLogin: (input: DeviceInstallAppleIDLoginInput) => Promise<void>;
42
+ submitAppleTwoFactorCode: (code: string) => Promise<void>;
43
+ setSelectedAppleTeamID: (teamID: string | undefined) => void;
44
+ clearAppleIDLogin: () => void;
45
+ registerConnectedAppleDevice: () => Promise<void>;
46
+ prepareAppleSigningAssets: () => Promise<void>;
47
+ startDeviceBuild: () => Promise<void>;
48
+ requestUSBAccess: () => Promise<void>;
49
+ pairBrowser: () => Promise<void>;
50
+ startInstallation: () => Promise<void>;
51
+ stopRelay: () => void;
52
+ };
53
+ export type DeviceInstallAppleSigningStatus = 'idle' | 'authenticating' | 'two-factor-required' | 'authenticated' | 'preparing-assets' | 'assets-ready' | 'using-cached-profile' | 'error';
54
+ export type DeviceInstallDevice = {
55
+ serialNumber?: string;
56
+ productName?: string;
57
+ manufacturerName?: string;
58
+ };
59
+ export type DeviceInstallSigningFiles = {
60
+ certificateFile?: File;
61
+ provisioningProfileFile?: File;
62
+ certificatePassword?: string;
63
+ };
64
+ export type DeviceInstallAppleIDLoginInput = {
65
+ accountName: string;
66
+ password: string;
67
+ };
68
+ export type ApplePortalSummary = {
69
+ certificateCount: number;
70
+ profileCount: number;
71
+ };
72
+ export declare function useDeviceInstall({ apiUrl, token, }: UseDeviceInstallOptions): UseDeviceInstallResult;
73
+ export {};