From 17c8722246cec0a670ca5032de6d487c3c5e0555 Mon Sep 17 00:00:00 2001 From: Ann Date: Thu, 3 Apr 2025 22:03:40 +0300 Subject: [PATCH] Template v1 --- .gitignore | 3 + .vscode/extensions.json | 3 + Bridge-mock-APIs.d.ts | 1105 ++++++++++++++++++++++++++++++++++++ README.md | 6 +- index.html | 13 + package.json | 26 + pnpm-lock.yaml | 1016 +++++++++++++++++++++++++++++++++ public/mock/notice.txt | 9 + public/vite.svg | 1 + public/vue.svg | 1 + src/App.vue | 29 + src/components/AppIcon.vue | 43 ++ src/main.js | 13 + src/style.scss | 7 + vite.config.js | 15 + 15 files changed, 2288 insertions(+), 2 deletions(-) create mode 100644 .vscode/extensions.json create mode 100644 Bridge-mock-APIs.d.ts create mode 100644 index.html create mode 100644 package.json create mode 100644 pnpm-lock.yaml create mode 100644 public/mock/notice.txt create mode 100644 public/vite.svg create mode 100644 public/vue.svg create mode 100644 src/App.vue create mode 100644 src/components/AppIcon.vue create mode 100644 src/main.js create mode 100644 src/style.scss create mode 100644 vite.config.js diff --git a/.gitignore b/.gitignore index ceaea36..898ec66 100644 --- a/.gitignore +++ b/.gitignore @@ -130,3 +130,6 @@ dist .yarn/install-state.gz .pnp.* +# Mock hiding +public/mock/* +!public/mock/notice.txt diff --git a/.vscode/extensions.json b/.vscode/extensions.json new file mode 100644 index 0000000..a7cea0b --- /dev/null +++ b/.vscode/extensions.json @@ -0,0 +1,3 @@ +{ + "recommendations": ["Vue.volar"] +} diff --git a/Bridge-mock-APIs.d.ts b/Bridge-mock-APIs.d.ts new file mode 100644 index 0000000..6af0a92 --- /dev/null +++ b/Bridge-mock-APIs.d.ts @@ -0,0 +1,1105 @@ +// #region SERVER RESPONSES + +/** + * Describes the JSON object returned from the Bridge API apps endpoint. + * @see {@link JSToBridgeAPI.getAppsURL()} for the URL to `fetch()` from + */ +export interface BridgeGetAppsResponse +{ + apps: BridgeInstalledAppInfo[]; +} + +// export interface BridgeGetIconPacksResponse +// { +// iconPacks: BridgeIconPackInfo[]; +// } + +// export interface BridgeGetIconPacksWithItemsResponse +// { +// iconPacks: BridgeIconPackInfoWithItems[]; +// } + +// #endregion + + +// #region MODELS + +/** + * Describes the application info returned from Bridge APIs. + * @see {@link JSToBridgeAPI.getAppsURL()} + * @see {@link BridgeEventMap.appInstalled} + * @see {@link BridgeEventMap.appChanged} + */ +export interface BridgeInstalledAppInfo +{ + packageName: string; + label: string; +} + + +// TODO: draft - uncomment after icon pack support is implemented +// export interface BridgeIconPackInfo extends BridgeInstalledAppInfo +// { +// scaleFactor: number; +// iconBackImgs: string[]; +// iconMaskImg: string | null; +// iconUponImg: string | null; +// } + +// export interface BridgeIconPackInfoWithItems extends BridgeInstalledAppInfo +// { +// items: Partial>; +// } + + +/** + * Values for the Bridge button visibility setting. + * @see {@link JSToBridgeAPI.getBridgeButtonVisibility} + * @see {@link JSToBridgeAPI.requestSetBridgeButtonVisibility} + * @see {@link BridgeEventMap.bridgeButtonVisibilityChanged} +*/ +export type BridgeButtonVisibility = 'shown' | 'hidden'; + +/** + * Values for the "Draw overscroll effects" Bridge setting. + * @see {@link JSToBridgeAPI.getOverscrollEffects} + * @see {@link JSToBridgeAPI.requestSetOverscrollEffects} + * @see {@link BridgeEventMap.overscrollEffectsChanged} + */ +export type OverscrollEffects = 'default' | 'none'; + +/** + * Values for the Bridge theme setting. + * @see {@link JSToBridgeAPI.getBridgeTheme} + * @see {@link JSToBridgeAPI.requestSetBridgeTheme} + * @see {@link BridgeEventMap.bridgeThemeChanged} + */ +export type BridgeTheme = 'system' | 'dark' | 'light'; + +/** + * Values for the status/navigation bar appearance settings. + * @see {@link JSToBridgeAPI.getStatusBarAppearance} + * @see {@link JSToBridgeAPI.getNavigationBarAppearance} + * @see {@link JSToBridgeAPI.requestSetStatusBarAppearance} + * @see {@link JSToBridgeAPI.requestSetNavigationBarAppearance} + * @see {@link BridgeEventMap.statusBarAppearanceChanged} + * @see {@link BridgeEventMap.navigationBarAppearanceChanged} + */ +export type SystemBarAppearance = 'hide' | 'light-fg' | 'dark-fg'; + +/** + * Values for setting the system night mode. `custom` is only available from API level 30 (Android 11). + * @see {@link JSToBridgeAPI.requestSetSystemNightMode} + * @see [UiModeManager.setNightMode() | Android Developers](https://developer.android.com/reference/android/app/UiModeManager#setNightMode()) + * @see {@link SystemNightModeOrError} for possible return values. +*/ +export type SystemNightMode = 'no' | 'yes' | 'auto' | 'custom'; + +/** + * Values that can be returned when getting the system night mode. `custom` is only available from API level 30 (Android 11). + * + * **NOTE:** `unknown` should never be returned, but as `-1` (`error`) is already not described by a const I've decided to err on the side of caution and include `unknown` as a possible return string. You never know with Android. + * + * @see {@link SystemNightMode} + * @see {@link JSToBridgeAPI.getSystemNightMode} + * @see [UiModeManager.setNightMode() | Android Developers](https://developer.android.com/reference/android/app/UiModeManager#getNightMode()) + * @see {@link BridgeEventMap.systemNightModeChanged} for requestable values. +*/ +export type SystemNightModeOrError = SystemNightMode | 'error' | 'unknown'; + +/** + * {@link WindowInsets} serialized to a JSON string. + */ +export type WindowInsetsJson = string; + +/** + * Represents offsets from each edge of the screen in `dp` (should be equivalent to CSS `px`). + * @see [WindowInsets | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets) + */ +export interface WindowInsets +{ + left: number; + top: number; + right: number; + bottom: number; +} + +// #endregion + + +// #region JS TO BRIDGE + +/** + * Describes the object Bridge injects into the WebView to allow the project to use Android functionalities. + * Accessible via `window.Bridge` or simply `Bridge`. + * + * This interface can be implemented to mock the Bridge API for development purposes. + * @see [BridgeMock](https://github.com/bridgelauncher/api-mock) + * @example + * class BridgeMock implements JSToBridgeAPI { ... } + * if (!window.Bridge) window.Bridge = new BridgeMock(); + */ +export interface JSToBridgeAPI +{ + // system + + /** Returns the current Android API level (`Build.VERSION.SDK_INT`). + * @see [Build.VERSION.SDK_INT | Android Developers](https://developer.android.com/reference/android/os/Build.VERSION#SDK_INT) + */ + getAndroidAPILevel(): number; + + /** + * Returns the current Bridge Launcher version code. This increments with every release. + */ + getBridgeVersionCode(): number; + + /** + * Returns the current Bridge Launcher version name. Should only be used for display purposes. + */ + getBridgeVersionName(): string; + + /** + * Returns the last error message reported by one of the `request...()` API functions or `null` if no error happened yet. + */ + getLastErrorMessage(): string | null; + + + // fetch + + /** + * The full root URL that Bridge serves the project's startup file from. Using this is not necessary in most cases, as requests can just use paths (ex.: `/images/banner.jpg`). + */ + getProjectURL(): string; + + /** + * The URL to fetch a list of apps installed on the device. The response is a JSON object described by {@link BridgeGetAppsResponse}. + * This function is recommended over a static URL for compatability with future versions and for easily mocking the Bridge API. + * @example + * fetch(Bridge.getAppsURL()) + * .then(resp => resp.json()) + * .then((resp: BridgeGetAppsResponse) => { + * // process response + * }) + */ + getAppsURL(): string; + + + // icon packs + + /** + * Creates an URL to fetch a list of installed icon packs. The response is a JSON object described by {@link BridgeGetIconPacksResponse} or {@link BridgeGetIconPacksWithItemsResponse}. + * If {@param includeItems} is `true`, the response will include all items parsed from the icon pack's `appfilter.xml`. This will significantly increase the size of the response! + * + * This function is recommended over creating the URL yourself for compatability with future versions and for easily mocking the Bridge API. + * + * @example + * fetch(Bridge.getIconPacksURL()) + * .then(resp => resp.json()) + * .then((resp: GetIconPacksResponse) => { + * console.log(resp.iconPacks) + * }) + */ + // TODO: draft - uncomment after icon pack support is implemented + // getIconPacksURL(includeItems?: boolean): string; + + /** + * Creates an URL to fetch information about the icon pack with the given {@link packageName}. + * The server will respond with the default icon if the icon pack is not specified or if no icon for the given app's launch intent is found in the pack. + * + * This function is recommended over creating the URL yourself for compatability with future versions and for easily mocking the Bridge API. + * @example + * fetch(Bridge.getIconPackInfoURL(currentIconPack.packageName)) + * .then(resp => resp.json()) + * .then((resp: GetIconPackInfoResponse) => { + * console.log(resp.iconPacks) + * }) + */ + // TODO: draft - uncomment after icon pack support is implemented + // getIconPackInfoURL(packageName: string, includeItems?: boolean): string; + + /** + * Creates an URL to fetch the `appfilter.xml` for the icon pack with the given {@link packageName}. + * The server will respond with 404 NotFound if no icon for the given app's launch intent is found in the pack. + * + * This function is recommended over creating the URL yourself for compatability with future versions and for easily mocking the Bridge API. + * @example + * fetch(Bridge.getIconPackAppFilterXMLURL(currentIconPack.packageName)) + * .then(resp => resp.text()) + * .then(appFilterXML => { + * console.log(appFilterXML) + * }) + */ + // TODO: draft - uncomment after icon pack support is implemented + // getIconPackAppFilterXMLURL(packageName: string): string; + + + // icons + + /** + * Creates an URL to fetch the default icon for the app with the given {@link packageName}. + * - The server will respond with `404 NotFound` if the app is not found. + * + * This function is recommended over creating the URL yourself for compatability with future versions and for easily mocking the Bridge API. + * @example + * img.src = Bridge.getDefaultAppIconURL(app.packageName) + */ + getDefaultAppIconURL(packageName: string): string; + + /** + * Creates an URL to fetch an icon for the app with the given {@link appPackageName}, prioritizing the icon pack with the given {@link iconPackPackageName}. + * - The server will respond with `404 NotFound` if the app is not found. + * - The server will respond with the default icon if the icon pack is not specified, the pack is not found or if no icon for the given app's launch intent is found in the pack. + * + * This function is recommended over creating the URL yourself for compatability with future versions and for easily mocking the Bridge API. + * @example + * img.src = Bridge.getAppIconURL(app.packageName, currentIconPack?.packageName) + */ + // TODO: draft - uncomment after icon pack support is implemented + // getAppIconURL(appPackageName?: string, iconPackPackageName?: string): string; + + /** + * Creates an URL to fetch an icon for the app with the given {@link appPackageName} from the icon pack with the given {@link iconPackPackageName}. + * - The server will respond with `404 NotFound` if the pack is not found or if no icon for the given app's launch intent is found in the pack. + * + * This function is recommended over creating the URL yourself for compatability with future versions and for easily mocking the Bridge API. + * @example + * img.src = Bridge.getIconPackAppIconURL(currentIconPack.packageName, app.packageName) + */ + // TODO: draft - uncomment after icon pack support is implemented + // getIconPackAppIconURL(iconPackPackageName: string, appPackageName: string): string; + + /** + * Creates an URL to fetch the drawable for the item with the given {@link componentName} from the icon pack with the given {@link iconPackPackageName}. + * - The server will respond with `404 NotFound` if the pack is not found or if the item or drawable are not found in the pack. + * + * This function is recommended over creating the URL yourself for compatability with future versions and for easily mocking the Bridge API. + * @example + * img.src = Bridge.getIconPackAppIconURL(currentIconPack.packageName, app.packageName) + */ + // TODO: draft - uncomment after icon pack support is implemented + // getIconPackItemURL(iconPackPackageName: string, componentName: string): string; + + /** + * Creates an URL to fetch an arbitrary drawable from the icon pack with the given {@link iconPackPackageName}. + * - The server will respond with 404 NotFound if the pack is not found or if the drawable is not found in the pack. + * + * This function is recommended over creating the URL yourself for compatability with future versions and for easily mocking the Bridge API. + * @example + * img.src = Bridge.getIconPackAppIconURL(currentIconPack.packageName, app.packageName) + */ + // TODO: draft - uncomment after icon pack support is implemented + // getIconPackDrawableURL(iconPackPackageName: string, drawableName: string): string; + + + + // apps + + /** + * Requests the app with the given package name be uninistalled. + * This method will show a system prompt to the user asking for confirmation. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + */ + requestAppUninstall(packageName: string, showToastIfFailed?: boolean): boolean; + + /** + * Requests the app info settings page for the app with the given package name be opened. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + */ + requestOpenAppInfo(packageName: string, showToastIfFailed?: boolean): boolean; + + /** + * Requests the app with the given package name be launched. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + */ + requestLaunchApp(packageName: string, showToastIfFailed?: boolean): boolean; + + + // wallpaper + /** + * Calls `wallpaperManager.setWallpaperOffsetSteps()`. + * > "For applications that use multiple virtual screens showing a wallpaper, specify the step size between virtual screens. + * > For example, if the launcher has 3 virtual screens, it would specify an xStep of 0.5, + * > since the X offset for those screens are 0.0, 0.5 and 1.0" + * @see [WallpaperManager.setWallpaperOffsetSteps() | Android Developers](https://developer.android.com/reference/android/app/WallpaperManager#setWallpaperOffsetSteps(float,%20float)) + * @example + * const xPages = 3; + * const yPages = 2; + * const p2o = (p: number) => p > 1 ? 1 / (p - 1) : 0; + * Bridge.setWallpaperOffsetSteps(p2o(xPages), p2o(yPages)); + */ + setWallpaperOffsetSteps(x: number, y: number): void; + + /** + * Calls `wallpaperManager.setWallpaperOffsets()`. + * > "Set the display position of the current wallpaper within any larger space, when that wallpaper is visible behind the given window. + * > The X and Y offsets are floating point numbers ranging from 0 to 1, representing where the wallpaper should be positioned within the screen space. + * > These only make sense when the wallpaper is larger than the display." + * @see [WallpaperManager.setWallpaperOffsets() | Android Developers](https://developer.android.com/reference/android/app/WallpaperManager#setWallpaperOffsets(android.os.IBinder,%20float,%20float)) + * @example + * window.addEventListener('scroll', ev => { + * requestAnimationFrame(() => { + * const xMaxScroll = window.scrollWidth - window.innerWidth; + * const yMaxScroll = window.scrollHeight - window.innerHeight; + * const xScroll = window.scrollLeft; + * const yScroll = window.scrollTop; + * Bridge.setWallpaperOffsets( + * xMaxScroll === 0 ? 0 : xScroll / xMaxScroll, + * yMaxScroll === 0 ? 0 : yScroll / yMaxScroll + * ); + * }); + * }); + */ + setWallpaperOffsets(x: number, y: number): void; + + /** + * Calls `wallpaperManager.sendWallpaperCommand()` with the command `COMMAND_TAP`. + * @see [WallpaperManager.sendWallpaperCommand() | Android Developers](https://developer.android.com/reference/android/app/WallpaperManager#sendWallpaperCommand(android.os.IBinder,%20java.lang.String,%20int,%20int,%20int,%20android.os.Bundle)) + * @see [WallpaperManager.COMMAND_TAP() | Android Developers](https://developer.android.com/reference/android/app/WallpaperManager#COMMAND_TAP) + * @example + * window.addEventListener('click', ev => { + * Bridge.sendWallpaperTap(ev.clientX, ev.clientY); + * }); + */ + sendWallpaperTap(x: number, y: number, z?: number): void; + + /** + * Requests the user be prompted to select a system wallpaper. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + */ + requestChangeSystemWallpaper(showToastIfFailed?: boolean): boolean; + + + // bridge button + + /** + * Gets the current state of the Bridge button visibility setting. + */ + getBridgeButtonVisibility(): BridgeButtonVisibility; + + /** + * Requests the Bridge button visibility setting be set to the given value. + * @fires {@link BridgeEventMap.bridgeButtonVisibilityChanged} after the setting is successfully set. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + */ + requestSetBridgeButtonVisibility(newVisibility: BridgeButtonVisibility, showToastIfFailed?: boolean): boolean; + + + // draw system wallpaper behind webview + + /** + * Gets the current state of the "Draw system wallpaper behind web view" Bridge setting. + */ + getDrawSystemWallpaperBehindWebViewEnabled(): boolean; + + /** + * Requests the "Draw system wallpaper behind web view" Bridge setting be set to the given value. + * @fires {@link BridgeEventMap.drawSystemWallpaperBehindWebViewChanged} after the setting is successfully set. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + */ + requestSetDrawSystemWallpaperBehindWebViewEnabled(newEnabled: boolean, showToastIfFailed?: boolean): boolean; + + + /** + * Gets the current state of the "Draw overscroll effects" Bridge setting. + */ + getOverscrollEffects(): OverscrollEffects; + + /** + * Requests the "Draw overscroll effects" Bridge setting be set to the given value. + * @fires {@link BridgeEventMap.drawSystemWallpaperBehindWebViewChanged} after the setting is successfully set. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + */ + requestSetOverscrollEffects(effects: OverscrollEffects, showToastIfFailed?: boolean): boolean; + + // system theme + + /** + * Gets the current system night mode. + * If you are looking for a way to change your project's theme automatically, consider using the media query `prefers-color-scheme: dark` in your CSS. + * @see {@link BridgeEventMap.systemNightModeChanged} to react to system night mode changes. + */ + getSystemNightMode(): SystemNightModeOrError; + + /** + * Resolves whether the system is in dark theme or not to a simple boolean value. + * If you are looking for a way to change your project's theme automatically, consider using the media query `prefers-color-scheme: dark` in your CSS. + */ + resolveIsSystemInDarkTheme(): boolean; + + /** + * Checks whether Bridge has the permissions necessary to set the system night mode. + * @see {@link requestSetSystemNightMode()} + * @see {@link BridgeEventMap.systemNightModeChanged} to react to system night mode changes. + */ + getCanRequestSystemNightMode(): boolean; + + /** + * Requests the system's night theme be set to the given value. + * The value `custom` requires API level 30 (Android 11). + * + * **WARNING!** For this to work, Bridge must be granted either `android.permission.WRITE_SECURE_SETTINGS` or `android.permission.MODIFY_DAY_NIGHT_MODE`. + * The former can be granted via adb, by running `adb shell pm grant com.tored.bridgelauncher android.permission.WRITE_SECURE_SETTINGS`, + * the latter can't be granted without serious effort at the time of writing this message. + * + * @fires {@link BridgeEventMap.systemNightModeChanged} after the mode is successfully changed. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + * @see {@link getCanRequestSystemNightMode()} to check whether Bridge has the permissions necessary to change the system night mode. + * @see {@link BridgeEventMap.canRequestSystemNightModeChanged} to react to permission state changes. + * @see {@link BridgeEventMap.systemNightModeChanged} to react to system night mode changes. + */ + requestSetSystemNightMode(mode: SystemNightMode, showToastIfFailed?: boolean): boolean; + + + // Bridge theme + + /** + * Gets the current state of the Bridge theme setting. + */ + getBridgeTheme(): BridgeTheme; + + /** + * Requests the Bridge theme setting be set to the given value. + * @fires {@link BridgeEventMap.bridgeThemeChanged} after the setting is successfully set. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + */ + requestSetBridgeTheme(theme: BridgeTheme, showToastIfFailed?: boolean): boolean; + + + // status bar + + /** + * Gets the current state of the "Status bar appearance" Bridge setting. + */ + getStatusBarAppearance(): SystemBarAppearance; + + /** + * Requests the "Status bar appearance" Bridge setting be set to the given value. + * Window insets may change and the appropriate events be fired if the status bar goes from being shown to hidden or vice versa. + * @fires {@link BridgeEventMap.statusBarAppearanceChanged} after the setting is successfully set. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + */ + requestSetStatusBarAppearance(appearance: SystemBarAppearance, showToastIfFailed?: boolean): boolean; + + + // navigation bar + + /** + * Gets the current state of the "Navigation bar appearance" Bridge setting. + */ + getNavigationBarAppearance(): SystemBarAppearance; + + /** + * Requests the "Navigation bar appearance" Bridge setting be set to the given value. + * Window insets may change and the appropriate events be fired if the navigation bar goes from being shown to hidden or vice versa. + * @fires {@link BridgeEventMap.navigationBarAppearanceChanged} after the setting is successfully set. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + */ + requestSetNavigationBarAppearance(appearance: SystemBarAppearance, showToastIfFailed?: boolean): boolean; + + + // screen locking + + /** + * Checks if the project can lock screen. + * + * Before API level 28 (Android 9) screen locking requries Bridge to be a device admin. + * **WARNING!** After Bridge calls `DevicePolicyManager.lockNow()`, you won't be able to fingerprint unlock the device until you enter your PIN/password/pattern etc. + * This is an unfortunate inherent limitation of this method of locking the screen. + * + * From API level 28 (Android 9) onwards, it instead requires the Bridge Accessiblity Service be enabled. + * + * Regardless of API level, the user must also allow projects to lock the screen in Bridge settings. + * + * @see [DevicePolicyManager.lockNow() | Android Developers](https://developer.android.com/reference/android/app/admin/DevicePolicyManager#lockNow()) + * @see [AccessibilityService.GLOBAL_ACTION_LOCK_SCREEN | Android Developers](https://developer.android.com/reference/android/accessibilityservice/AccessibilityService#GLOBAL_ACTION_LOCK_SCREEN) + */ + getCanLockScreen(): boolean; + + /** + * Requests the screen be locked. + * + * Before API level 28 (Android 9) screen locking requries Bridge to be a device admin. + * **WARNING!** After Bridge calls `DevicePolicyManager.lockNow()`, you won't be able to fingerprint unlock the device until you enter your PIN/password/pattern etc. + * This is an unfortunate inherent limitation of this method of locking the screen. + * + * From API level 28 (Android 9) onwards, it instead requires the Bridge Accessiblity Service be enabled. + * + * Regardless of API level, the user must also allow projects to lock the screen in Bridge settings. + * + * Use {@link getCanLockScreen()} to check whether the requirements are fulfilled or not. + * + * @fires {@link BridgeEventMap.navigationBarAppearanceChanged} after the setting is successfully set. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + * + * @see [DevicePolicyManager.lockNow() | Android Developers](https://developer.android.com/reference/android/app/admin/DevicePolicyManager#lockNow()) + * @see [AccessibilityService.GLOBAL_ACTION_LOCK_SCREEN | Android Developers](https://developer.android.com/reference/android/accessibilityservice/AccessibilityService#GLOBAL_ACTION_LOCK_SCREEN) + */ + requestLockScreen(showToastIfFailed?: boolean): boolean; + + + // misc requests + + /** + * Requests the Bridge settings be opened. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + */ + requestOpenBridgeSettings(showToastIfFailed?: boolean): boolean; + + /** + * Requests the Bridge app drawer be opened. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + */ + requestOpenBridgeAppDrawer(showToastIfFailed?: boolean): boolean; + + /** + * Requests the developer console be opened. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + */ + requestOpenDeveloperConsole(showToastIfFailed?: boolean): boolean; + + /** + * Requests the notification shade to be expanded. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + */ + requestExpandNotificationShade(showToastIfFailed?: boolean): boolean; + + /** + * Requests Android settings be opened. + * @param showToastIfFailed Set to `false` to prevent a default error toast from appearing, for example when you have implemented custom error handling. Defaults to `true`. + * @returns `true` if the request succedeed, `false` if there was an error. You can obtain the error message by calling {@link getLastErrorMessage()}. + */ + requestOpenAndroidSettings(showToastIfFailed?: boolean): boolean; + + + // toast + + /** + * Shows a toast containing the given message. + * @param long If `true`, passes `Toast.LENGTH_LONG` as the duration. Otherwise, passes `Toast.LENGTH_SHORT`. Defaults to `false`. + * @see [Toasts overview | Android Developers](https://developer.android.com/guide/topics/ui/notifiers/toasts) + */ + showToast(message: string, long?: boolean): void; + + + // window insets and cutouts + + /** + * Gets the latest value of `WindowInsets.statusBars` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.statusBarsWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.statusBars | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).statusBars()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getStatusBarsWindowInsets()) + */ + getStatusBarsWindowInsets(): WindowInsetsJson; + + /** + * Gets the latest value of `WindowInsets.statusBarsIgnoringVisibility` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.statusBarsIgnoringVisibilityWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.statusBarsIgnoringVisibility | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).statusBarsIgnoringVisibility()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getStatusBarsIgnoringVisibilityWindowInsets()) + */ + getStatusBarsIgnoringVisibilityWindowInsets(): WindowInsetsJson; + + /** + * Gets the latest value of `WindowInsets.navigationBars` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.navigationBarsWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.navigationBars | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).navigationBars()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getNavigationBarsWindowInsets()) + */ + getNavigationBarsWindowInsets(): WindowInsetsJson; + + /** + * Gets the latest value of `WindowInsets.navigationBarsIgnoringVisibility` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.navigationBarsIgnoringVisibilityWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.navigationBarsIgnoringVisibility | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).navigationBarsIgnoringVisibility()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getNavigationBarsIgnoringVisibilityWindowInsets()) + */ + getNavigationBarsIgnoringVisibilityWindowInsets(): WindowInsetsJson; + + + /** + * Gets the latest value of `WindowInsets.captionBar` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.captionBarWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.captionBar | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).captionBar()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getStatusBarsWindowInsets()) + */ + getCaptionBarWindowInsets(): WindowInsetsJson; + + /** + * Gets the latest value of `WindowInsets.captionBarIgnoringVisibility` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.captionBarIgnoringVisibilityWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.captionBarIgnoringVisibility | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).captionBarIgnoringVisibility()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getCaptionBarIgnoringVisibilityWindowInsets()) + */ + getCaptionBarIgnoringVisibilityWindowInsets(): WindowInsetsJson; + + + /** + * Gets the latest value of `WindowInsets.systemBars` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.systemBarsWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.systemBars | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).systemBars()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getSystemBarsWindowInsets()) + */ + getSystemBarsWindowInsets(): WindowInsetsJson; + + /** + * Gets the latest value of `WindowInsets.systemBarsIgnoringVisibility` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.systemBarsIgnoringVisibilityWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.systemBarsIgnoringVisibility | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).systemBarsIgnoringVisibility()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getSystemBarsIgnoringVisibilityWindowInsets()) + */ + getSystemBarsIgnoringVisibilityWindowInsets(): WindowInsetsJson; + + + /** + * Gets the latest value of `WindowInsets.ime` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.imeWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.ime | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).ime()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getImeWindowInsets()) + */ + getImeWindowInsets(): WindowInsetsJson; + + /** + * Gets the latest value of `WindowInsets.imeAnimationSource` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.imeAnimationSourceWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.imeAnimationSource | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).imeAnimationSource()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getImeAnimationSourceWindowInsets()) + */ + getImeAnimationSourceWindowInsets(): WindowInsetsJson; + + /** + * Gets the latest value of `WindowInsets.imeAnimationTarget` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.imeAnimationTargetWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.imeAnimationTarget | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).imeAnimationTarget()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getImeAnimationTargetWindowInsets()) + */ + getImeAnimationTargetWindowInsets(): WindowInsetsJson; + + /** + * Gets the latest value of `WindowInsets.tappableElement` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.tappableElementWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.tappableElement | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).tappableElement()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getTappableElementWindowInsets()) + */ + getTappableElementWindowInsets(): WindowInsetsJson; + + /** + * Gets the latest value of `WindowInsets.tappableElementIgnoringVisibility` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.tappableElementIgnoringVisibilityWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.tappableElementIgnoringVisibility | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).tappableElementIgnoringVisibility()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getTappableElementIgnoringVisibilityWindowInsets()) + */ + getTappableElementIgnoringVisibilityWindowInsets(): WindowInsetsJson; + + + /** + * Gets the latest value of `WindowInsets.systemGestures` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.systemGesturesWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.systemGestures | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).systemGestures()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getSystemGesturesWindowInsets()) + */ + getSystemGesturesWindowInsets(): WindowInsetsJson; + + /** + * Gets the latest value of `WindowInsets.mandatorySystemGestures` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.mandatorySystemGesturesWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.mandatorySystemGestures | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).mandatorySystemGestures()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getMandatorySystemGesturesWindowInsets()) + */ + getMandatorySystemGesturesWindowInsets(): WindowInsetsJson; + + + /** + * Gets the latest value of `WindowInsets.displayCutout` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.displayCutoutWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.displayCutout | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).displayCutout()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getDisplayCutoutWindowInsets()) + */ + getDisplayCutoutWindowInsets(): WindowInsetsJson; + + /** + * Gets the latest value of `WindowInsets.waterfall` from the Compose `WindowInsets` API. + * @returns a JSON object described by {@link WindowInsets}. + * @see {@link BridgeEventMap.waterfallWindowInsetsChanged} to react to changes. + * @see [WindowInsets.Companion.waterfall | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).waterfall()) + * @example + * const insets: WindowInsets = JSON.parse(Bridge.getWaterfallWindowInsets()) + */ + getWaterfallWindowInsets(): WindowInsetsJson; + + + /** + * Returns `DisplayShape.getPath()`. + * + * **WARNING!** This call requires API level 31 (Android 12). Returns `null` on earlier Android versions. + * + * @returns The cutout path or `null`, if there is no cutout. Always returns `null` on API level < 31. + * @see [DisplayCutout | Android Developers](https://developer.android.com/reference/android/view/DisplayCutout#getCutoutPath()) + */ + getDisplayCutoutPath(): string | null; + + /** + * Returns `DisplayCutout.getCutoutPath()`. + * + * **WARNING!** This call requires API level 34 (Android 14). Returns `null` on earlier Android versions. + * + * @returns The display shape path or `null`, if there is no cutout. Always returns `null` on API level < 34. + * @see [DisplayShape.getPath() | Android Developers](https://developer.android.com/reference/android/view/DisplayShape#getPath()) + */ + getDisplayShapePath(): string | null; +} + +// #endregion + + +// #region BRIDGE TO JS (BridgeEvent) + +/** Utility type - create a BridgeEvent type with name N and additional properties P. */ +type E = { name: N; } & P; +/** Utility type - create additional properties for a BridgeValueChangedEvent. */ +type V = { newValue: T; }; + +/** + * Sent when Bridge receives a broadcast intent with the action `Intent.ACTION_PACKAGE_ADDED`. + * Can be used to detect when an app was installed. + * @see [Intent.ACTION_PACKAGE_ADDED | Android Developers](https://developer.android.com/reference/android/content/Intent.html#ACTION_PACKAGE_ADDED) + */ +export type BridgeAppInstalledEvent = E<'appInstalled', { app: BridgeInstalledAppInfo; }>; + +/** + * Sent when Bridge receives a broadcast intent with the action `Intent.ACTION_PACKAGE_REPLACED`. + * Can be used to detect when an app was updated. + * @see [Intent.ACTION_PACKAGE_CHANGED | Android Developers](https://developer.android.com/reference/android/content/Intent.html#ACTION_PACKAGE_CHANGED) + * @see [Intent.ACTION_PACKAGE_REPLACED | Android Developers](https://developer.android.com/reference/android/content/Intent.html#ACTION_PACKAGE_REPLACED) + */ +export type BridgeAppChangedEvent = E<'appChanged', { app: BridgeInstalledAppInfo; }>; + +/** + * Sent when Bridge receives a broadcast intent with the action `Intent.ACTION_PACKAGE_REMOVED` when `Intent.EXTRA_REPLACING` is `false`. + * Can be used to detect when an app was uninstalled. + * @see [Intent.ACTION_PACKAGE_REMOVED | Android Developers](https://developer.android.com/reference/android/content/Intent.html#ACTION_PACKAGE_REMOVED) + */ +export type BridgeAppRemovedEvent = E<'appRemoved', { packageName: string; }>; + + +/** + * Maps an event `name` to additional properties included in the event object. + * @see {@link BridgeEvent} for an union of all possible event objects. + * @see {@link onBridgeEvent} to receive `BridgeEvent` objects. + */ + +/** + * Called in `onPause()` of the main Bridge activity. You can use this to pause any work you don't want going on in the background. + * @see [The activity lifecycle - onPause() | Android Developers](https://developer.android.com/guide/components/activities/activity-lifecycle#onpause) + * @see [Activity - onPause() | Android Developers](https://developer.android.com/reference/android/app/Activity#onPause()) + */ +export type BridgeBeforePauseEvent = E<'beforePause'>; + +/** + * Called in `onNewIntent()` of the main Bridge activity. You can use this to detect when the home button has been pressed. + * @see [Activity - onNewIntent() | Android Developers](https://developer.android.com/reference/android/app/Activity#onNewIntent(android.content.Intent)) + */ +export type BridgeNewIntentEvent = E<'newIntent'>; + +/** + * Called in `onResume()` of the main Bridge activity. You can use this to resume work paused in {@link beforePause}. + * @see [The activity lifecycle - onResume() | Android Developers](https://developer.android.com/guide/components/activities/activity-lifecycle#onresume) + */ +export type BridgeAfterResumeEvent = E<'afterResume'>; + + +/** + * Called after the Bridge button visibility setting changes, no matter what the source of the change was (Bridge settings, JS API, QS tile, ...). + */ +export type BridgeBridgeButtonVisibilityChangedEvent = E<'bridgeButtonVisibilityChanged', V>; + +/** + * Called after the "Draw system wallpaper behind WebView" Bridge setting changes, no matter what the source of the change was (Bridge settings, the JS API, ...). + */ +export type BridgeDrawSystemWallpaperBehindWebViewChangedEvent = E<'drawSystemWallpaperBehindWebViewChanged', V>; + +/** + * Called after the "Draw overscroll effects" Bridge setting changes, no matter what the source of the change was (Bridge settings, the JS API, ...). + */ +export type BridgeOverscrollEffectsChangedEvent = E<'overscrollEffectsChanged', V>; + +/** + * Called from `onConfigurationChanged()` of the main Bridge activity, when the system night mode changed. + */ +export type BridgeSystemNightModeChangedEvent = E<'systemNightModeChanged', V>; + +/** + * Called after the Bridge theme setting changes, no matter what the source of the change was (Bridge settings, the JS API, ...). + */ +export type BridgeBridgeThemeChangedEvent = E<'bridgeThemeChanged', V>; + +/** + * Called after the "Status bar appearance" Bridge setting changes, no matter what the source of the change was (Bridge settings, the JS API, ...). + */ +export type BridgeStatusBarAppearanceChangedEvent = E<'statusBarAppearanceChanged', V>; + +/** + * Called after the "Navigation bar appearance" Bridge setting changes, no matter what the source of the change was (Bridge settings, the JS API, ...). + */ +export type BridgeNavigationBarAppearanceChangedEvent = E<'navigationBarAppearanceChanged', V>; + +/** + * Called after Bridge is granted/revoked permissions necessary to change the system night mode. + */ +export type BridgeCanRequestSystemNightModeChangedEvent = E<'canRequestSystemNightModeChanged', V>; + +/** + * Called after Bridge is granted/revoked permissions necessary to lock the screen and/or when the project is allowed/disallowed to lock the screen from the Bridge settings. + */ +export type BridgeCanLockScreenChangedEvent = E<'canLockScreenChanged', V>; + + +/** + * Called when `WindowInsets.statusBars` changed. + * @see [WindowInsets.Companion.statusBars | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).statusBars()) + */ +export type BridgeStatusBarsWindowInsetsChangedEvent = E<'statusBarsWindowInsetsChanged', V>; + +/** + * Called when `WindowInsets.statusBarsIgnoringVisibility` changed. + * @see [WindowInsets.Companion.statusBarsIgnoringVisibility | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).statusBarsIgnoringVisibility()) + */ +export type BridgeStatusBarsIgnoringVisibilityWindowInsetsChangedEvent = E<'statusBarsIgnoringVisibilityWindowInsetsChanged', V>; + + +/** + * Called when `WindowInsets.navigationBars` changed. + * @see [WindowInsets.Companion.navigationBars | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).navigationBars()) + */ +export type BridgeNavigationBarsWindowInsetsChangedEvent = E<'navigationBarsWindowInsetsChanged', V>; + +/** + * Called when `WindowInsets.navigationBarsIgnoringVisibility` changed. + * @see [WindowInsets.Companion.navigationBarsIgnoringVisibility | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).navigationBarsIgnoringVisibility()) + */ +export type BridgeNavigationBarsIgnoringVisibilityWindowInsetsChangedEvent = E<'navigationBarsIgnoringVisibilityWindowInsetsChanged', V>; + + +/** + * Called when `WindowInsets.captionBar` changed. + * @see [WindowInsets.Companion.captionBar | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).captionBar()) + */ +export type BridgeCaptionBarWindowInsetsChangedEvent = E<'captionBarWindowInsetsChanged', V>; + +/** + * Called when `WindowInsets.captionBarIgnoringVisibility` changed. + * @see [WindowInsets.Companion.captionBarIgnoringVisibility | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).captionBarIgnoringVisibility()) + */ +export type BridgeCaptionBarIgnoringVisibilityWindowInsetsChangedEvent = E<'captionBarIgnoringVisibilityWindowInsetsChanged', V>; + + +/** + * Called when `WindowInsets.systemBars` changed. + * @see [WindowInsets.Companion.systemBars | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).systemBars()) + */ +export type BridgeSystemBarsWindowInsetsChangedEvent = E<'systemBarsWindowInsetsChanged', V>; + +/** + * Called when `WindowInsets.systemBarsIgnoringVisibility` changed. + * @see [WindowInsets.Companion.systemBarsIgnoringVisibility | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).systemBarsIgnoringVisibility()) + */ +export type BridgeSystemBarsIgnoringVisibilityWindowInsetsChangedEvent = E<'systemBarsIgnoringVisibilityWindowInsetsChanged', V>; + + +/** + * Called when `WindowInsets.ime` changed. + * @see [WindowInsets.Companion.ime | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).ime()) + */ +export type BridgeImeWindowInsetsChangedEvent = E<'imeWindowInsetsChanged', V>; + +/** + * Called when `WindowInsets.imeAnimationSource` changed. + * @see [WindowInsets.Companion.imeAnimationSource | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).imeAnimationSource()) + */ +export type BridgeImeAnimationSourceWindowInsetsChangedEvent = E<'imeAnimationSourceWindowInsetsChanged', V>; + +/** + * Called when `WindowInsets.imeAnimationTarget` changed. + * @see [WindowInsets.Companion.imeAnimationTarget | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).imeAnimationTarget()) + */ +export type BridgeImeAnimationTargetWindowInsetsChangedEvent = E<'imeAnimationTargetWindowInsetsChanged', V>; + + +/** + * Called when `WindowInsets.tappableElement` changed. + * @see [WindowInsets.Companion.tappableElement | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).tappableElement()) + */ +export type BridgeTappableElementWindowInsetsChangedEvent = E<'tappableElementWindowInsetsChanged', V>; + +/** + * Called when `WindowInsets.tappableElementIgnoringVisibility` changed. + * @see [WindowInsets.Companion.tappableElementIgnoringVisibility | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).tappableElementIgnoringVisibility()) + */ +export type BridgeTappableElementIgnoringVisibilityWindowInsetsChangedEvent = E<'tappableElementIgnoringVisibilityWindowInsetsChanged', V>; + + +/** + * Called when `WindowInsets.systemGestures` changed. + * @see [WindowInsets.Companion.systemGestures | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).systemGestures()) + */ +export type BridgeSystemGesturesWindowInsetsChangedEvent = E<'systemGesturesWindowInsetsChanged', V>; + +/** + * Called when `WindowInsets.mandatorySystemGestures` changed. + * @see [WindowInsets.Companion.mandatorySystemGestures | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).mandatorySystemGestures()) + */ +export type BridgeMandatorySystemGesturesWindowInsetsChangedEvent = E<'mandatorySystemGesturesWindowInsetsChanged', V>; + + +/** + * Called when `WindowInsets.displayCutout` changed. + * @see [WindowInsets.Companion.displayCutout | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).displayCutout()) + */ +export type BridgeDisplayCutoutWindowInsetsChangedEvent = E<'displayCutoutWindowInsetsChanged', V>; + +/** + * Called when `WindowInsets.waterfall` changed. + * @see [WindowInsets.Companion.waterfall | Android Developers](https://developer.android.com/reference/kotlin/androidx/compose/foundation/layout/WindowInsets.Companion#(androidx.compose.foundation.layout.WindowInsets.Companion).waterfall()) + */ +export type BridgeWaterfallWindowInsetsChangedEvent = E<'waterfallWindowInsetsChanged', V>; + +/** + * Convenience type - maps BridgeEvent names to BridgeEvent types. + */ +export type BridgeEventMap = { + appInstalled: BridgeAppInstalledEvent; + appChanged: BridgeAppChangedEvent; + appRemoved: BridgeAppRemovedEvent; + beforePause: BridgeBeforePauseEvent; + newIntent: BridgeNewIntentEvent; + afterResume: BridgeAfterResumeEvent; + bridgeButtonVisibilityChanged: BridgeBridgeButtonVisibilityChangedEvent; + drawSystemWallpaperBehindWebViewChanged: BridgeDrawSystemWallpaperBehindWebViewChangedEvent; + overscrollEffectsChanged: BridgeOverscrollEffectsChangedEvent; + systemNightModeChanged: BridgeSystemNightModeChangedEvent; + bridgeThemeChanged: BridgeBridgeThemeChangedEvent; + statusBarAppearanceChanged: BridgeStatusBarAppearanceChangedEvent; + navigationBarAppearanceChanged: BridgeNavigationBarAppearanceChangedEvent; + canRequestSystemNightModeChanged: BridgeCanRequestSystemNightModeChangedEvent; + canLockScreenChanged: BridgeCanLockScreenChangedEvent; + statusBarsWindowInsetsChanged: BridgeStatusBarsWindowInsetsChangedEvent; + statusBarsIgnoringVisibilityWindowInsetsChanged: BridgeStatusBarsIgnoringVisibilityWindowInsetsChangedEvent; + navigationBarsWindowInsetsChanged: BridgeNavigationBarsWindowInsetsChangedEvent; + navigationBarsIgnoringVisibilityWindowInsetsChanged: BridgeNavigationBarsIgnoringVisibilityWindowInsetsChangedEvent; + captionBarWindowInsetsChanged: BridgeCaptionBarWindowInsetsChangedEvent; + captionBarIgnoringVisibilityWindowInsetsChanged: BridgeCaptionBarIgnoringVisibilityWindowInsetsChangedEvent; + systemBarsWindowInsetsChanged: BridgeSystemBarsWindowInsetsChangedEvent; + systemBarsIgnoringVisibilityWindowInsetsChanged: BridgeSystemBarsIgnoringVisibilityWindowInsetsChangedEvent; + imeWindowInsetsChanged: BridgeImeWindowInsetsChangedEvent; + imeAnimationSourceWindowInsetsChanged: BridgeImeAnimationSourceWindowInsetsChangedEvent; + imeAnimationTargetWindowInsetsChanged: BridgeImeAnimationTargetWindowInsetsChangedEvent; + tappableElementWindowInsetsChanged: BridgeTappableElementWindowInsetsChangedEvent; + tappableElementIgnoringVisibilityWindowInsetsChanged: BridgeTappableElementIgnoringVisibilityWindowInsetsChangedEvent; + systemGesturesWindowInsetsChanged: BridgeSystemGesturesWindowInsetsChangedEvent; + mandatorySystemGesturesWindowInsetsChanged: BridgeMandatorySystemGesturesWindowInsetsChangedEvent; + displayCutoutWindowInsetsChanged: BridgeDisplayCutoutWindowInsetsChangedEvent; + waterfallWindowInsetsChanged: BridgeWaterfallWindowInsetsChangedEvent; +} + +/** Any valid {@link BridgeEvent} name. */ +export type BridgeEventName = BridgeEventMap[keyof BridgeEventMap]['name']; + +/** + * A union of all possible `BridgeEvent` types. + * @see {@link onBridgeEvent} to receive `BridgeEvent` objects. + * @example + * // accepts any `BridgeEvent` + * function onBridgeEvent(event: BridgeEvent) { ... } + * // only accepts the appInstalled event + * function onAppInstalledEvent(event: BridgeEvent['appInstalled']) { ... } + */ +export type BridgeEvent = BridgeEventMap[keyof BridgeEventMap]; + +/** + * Describes a function that accepts `BridgeEvent` objects. + * @see {@link BridgeEvent} for a union of all possible `BridgeEvent` objects. + * @see {@link onBridgeEvent} for how to receive `BridgeEvent` objects and set up multiple listeners. + */ +export type BridgeEventListener = (event: BridgeEvent) => void; + +// #endregion + + +// #region GLOBAL + +declare global +{ + /** + * The Bridge Launcher JS API. + * @see {@link onBridgeEvent} for listening to Bridge events. + */ + var Bridge: JSToBridgeAPI; + + /** + * Called by Bridge when an event occurs. + * @see {@link BridgeEvent} for a union of all possible `BridgeEvent` objects. + * @see {@link Bridge} for calling the Bridge JS API. + * @example + * // simple broadcaster (simple way to have more than one event listener) + * const bridgeEventListeners = new Set(); + * window.onBridgeEvent = event => listeners.forEach(l => l(event)); + * + * // subscribe to events + * bridgeEventListeners.add(event => { + * if (event.name === 'appInstalled') { + * // event will be narrowed to the appropriate type for autocompletion + * console.log(ev.app.packageName) + * } + * }) + */ + var onBridgeEvent: BridgeEventListener | undefined; +} + +// #endregion diff --git a/README.md b/README.md index db0a78d..1511959 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,5 @@ -# blhs +# Vue 3 + Vite -Bridge Launcher Home Screens I made for myself but published for no reason \ No newline at end of file +This template should help get you started developing with Vue 3 in Vite. The template uses Vue 3 ` + + diff --git a/package.json b/package.json new file mode 100644 index 0000000..30e18ac --- /dev/null +++ b/package.json @@ -0,0 +1,26 @@ +{ + "name": "blhs", + "private": true, + "version": "0.0.0", + "type": "module", + "scripts": { + "dev": "vite", + "build": "vite build", + "preview": "vite preview" + }, + "dependencies": { + "@bridgelauncher/api-mock": "^0.1.0", + "vue": "^3.5.13" + }, + "devDependencies": { + "@vitejs/plugin-vue": "^5.2.1", + "sass": "^1.86.2", + "vite": "^6.2.0" + }, + "packageManager": "pnpm@10.6.1+sha512.40ee09af407fa9fbb5fbfb8e1cb40fbb74c0af0c3e10e9224d7b53c7658528615b2c92450e74cfad91e3a2dcafe3ce4050d80bda71d757756d2ce2b66213e9a3", + "pnpm": { + "onlyBuiltDependencies": [ + "@parcel/watcher" + ] + } +} diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml new file mode 100644 index 0000000..f1ec6c5 --- /dev/null +++ b/pnpm-lock.yaml @@ -0,0 +1,1016 @@ +lockfileVersion: '9.0' + +settings: + autoInstallPeers: true + excludeLinksFromLockfile: false + +importers: + + .: + dependencies: + '@bridgelauncher/api-mock': + specifier: ^0.1.0 + version: 0.1.0 + vue: + specifier: ^3.5.13 + version: 3.5.13(typescript@5.8.2) + devDependencies: + '@vitejs/plugin-vue': + specifier: ^5.2.1 + version: 5.2.3(vite@6.2.5(sass@1.86.2))(vue@3.5.13(typescript@5.8.2)) + sass: + specifier: ^1.86.2 + version: 1.86.2 + vite: + specifier: ^6.2.0 + version: 6.2.5(sass@1.86.2) + +packages: + + '@babel/helper-string-parser@7.25.9': + resolution: {integrity: sha512-4A/SCr/2KLd5jrtOMFzaKjVtAei3+2r/NChoBNoZ3EyP/+GlhoaEGoWOZUmFmoITP7zOJyHIMm+DYRd8o3PvHA==} + engines: {node: '>=6.9.0'} + + '@babel/helper-validator-identifier@7.25.9': + resolution: {integrity: sha512-Ed61U6XJc3CVRfkERJWDz4dJwKe7iLmmJsbOGu9wSloNSFttHV0I8g6UAgb7qnK5ly5bGLPd4oXZlxCdANBOWQ==} + engines: {node: '>=6.9.0'} + + '@babel/parser@7.27.0': + resolution: {integrity: sha512-iaepho73/2Pz7w2eMS0Q5f83+0RKI7i4xmiYeBmDzfRVbQtTOG7Ts0S4HzJVsTMGI9keU8rNfuZr8DKfSt7Yyg==} + engines: {node: '>=6.0.0'} + hasBin: true + + '@babel/types@7.27.0': + resolution: {integrity: sha512-H45s8fVLYjbhFH62dIJ3WtmJ6RSPt/3DRO0ZcT2SUiYiQyz3BLVb9ADEnLl91m74aQPS3AzzeajZHYOalWe3bg==} + engines: {node: '>=6.9.0'} + + '@bridgelauncher/api-mock@0.1.0': + resolution: {integrity: sha512-NwxAKozdfvetalZBvO1ui2prED90aRFxNKXOMN3Z82cRg2xTUMmoLzFEYcmqVAZJ34Bny3ejS6FSbCfL9ZIxuQ==} + + '@bridgelauncher/api@0.1.0': + resolution: {integrity: sha512-vfZf3M+WLrRPy9jHK5yZFRR8wfNmN9pT7H5fKmGBl2sk8v1+eOmLZOHIAzLv12XrlWkKbaO3yLkIm6Hf5yyCOA==} + + '@esbuild/aix-ppc64@0.25.2': + resolution: {integrity: sha512-wCIboOL2yXZym2cgm6mlA742s9QeJ8DjGVaL39dLN4rRwrOgOyYSnOaFPhKZGLb2ngj4EyfAFjsNJwPXZvseag==} + engines: {node: '>=18'} + cpu: [ppc64] + os: [aix] + + '@esbuild/android-arm64@0.25.2': + resolution: {integrity: sha512-5ZAX5xOmTligeBaeNEPnPaeEuah53Id2tX4c2CVP3JaROTH+j4fnfHCkr1PjXMd78hMst+TlkfKcW/DlTq0i4w==} + engines: {node: '>=18'} + cpu: [arm64] + os: [android] + + '@esbuild/android-arm@0.25.2': + resolution: {integrity: sha512-NQhH7jFstVY5x8CKbcfa166GoV0EFkaPkCKBQkdPJFvo5u+nGXLEH/ooniLb3QI8Fk58YAx7nsPLozUWfCBOJA==} + engines: {node: '>=18'} + cpu: [arm] + os: [android] + + '@esbuild/android-x64@0.25.2': + resolution: {integrity: sha512-Ffcx+nnma8Sge4jzddPHCZVRvIfQ0kMsUsCMcJRHkGJ1cDmhe4SsrYIjLUKn1xpHZybmOqCWwB0zQvsjdEHtkg==} + engines: {node: '>=18'} + cpu: [x64] + os: [android] + + '@esbuild/darwin-arm64@0.25.2': + resolution: {integrity: sha512-MpM6LUVTXAzOvN4KbjzU/q5smzryuoNjlriAIx+06RpecwCkL9JpenNzpKd2YMzLJFOdPqBpuub6eVRP5IgiSA==} + engines: {node: '>=18'} + cpu: [arm64] + os: [darwin] + + '@esbuild/darwin-x64@0.25.2': + resolution: {integrity: sha512-5eRPrTX7wFyuWe8FqEFPG2cU0+butQQVNcT4sVipqjLYQjjh8a8+vUTfgBKM88ObB85ahsnTwF7PSIt6PG+QkA==} + engines: {node: '>=18'} + cpu: [x64] + os: [darwin] + + '@esbuild/freebsd-arm64@0.25.2': + resolution: {integrity: sha512-mLwm4vXKiQ2UTSX4+ImyiPdiHjiZhIaE9QvC7sw0tZ6HoNMjYAqQpGyui5VRIi5sGd+uWq940gdCbY3VLvsO1w==} + engines: {node: '>=18'} + cpu: [arm64] + os: [freebsd] + + '@esbuild/freebsd-x64@0.25.2': + resolution: {integrity: sha512-6qyyn6TjayJSwGpm8J9QYYGQcRgc90nmfdUb0O7pp1s4lTY+9D0H9O02v5JqGApUyiHOtkz6+1hZNvNtEhbwRQ==} + engines: {node: '>=18'} + cpu: [x64] + os: [freebsd] + + '@esbuild/linux-arm64@0.25.2': + resolution: {integrity: sha512-gq/sjLsOyMT19I8obBISvhoYiZIAaGF8JpeXu1u8yPv8BE5HlWYobmlsfijFIZ9hIVGYkbdFhEqC0NvM4kNO0g==} + engines: {node: '>=18'} + cpu: [arm64] + os: [linux] + + '@esbuild/linux-arm@0.25.2': + resolution: {integrity: sha512-UHBRgJcmjJv5oeQF8EpTRZs/1knq6loLxTsjc3nxO9eXAPDLcWW55flrMVc97qFPbmZP31ta1AZVUKQzKTzb0g==} + engines: {node: '>=18'} + cpu: [arm] + os: [linux] + + '@esbuild/linux-ia32@0.25.2': + resolution: {integrity: sha512-bBYCv9obgW2cBP+2ZWfjYTU+f5cxRoGGQ5SeDbYdFCAZpYWrfjjfYwvUpP8MlKbP0nwZ5gyOU/0aUzZ5HWPuvQ==} + engines: {node: '>=18'} + cpu: [ia32] + os: [linux] + + '@esbuild/linux-loong64@0.25.2': + resolution: {integrity: sha512-SHNGiKtvnU2dBlM5D8CXRFdd+6etgZ9dXfaPCeJtz+37PIUlixvlIhI23L5khKXs3DIzAn9V8v+qb1TRKrgT5w==} + engines: {node: '>=18'} + cpu: [loong64] + os: [linux] + + '@esbuild/linux-mips64el@0.25.2': + resolution: {integrity: sha512-hDDRlzE6rPeoj+5fsADqdUZl1OzqDYow4TB4Y/3PlKBD0ph1e6uPHzIQcv2Z65u2K0kpeByIyAjCmjn1hJgG0Q==} + engines: {node: '>=18'} + cpu: [mips64el] + os: [linux] + + '@esbuild/linux-ppc64@0.25.2': + resolution: {integrity: sha512-tsHu2RRSWzipmUi9UBDEzc0nLc4HtpZEI5Ba+Omms5456x5WaNuiG3u7xh5AO6sipnJ9r4cRWQB2tUjPyIkc6g==} + engines: {node: '>=18'} + cpu: [ppc64] + os: [linux] + + '@esbuild/linux-riscv64@0.25.2': + resolution: {integrity: sha512-k4LtpgV7NJQOml/10uPU0s4SAXGnowi5qBSjaLWMojNCUICNu7TshqHLAEbkBdAszL5TabfvQ48kK84hyFzjnw==} + engines: {node: '>=18'} + cpu: [riscv64] + os: [linux] + + '@esbuild/linux-s390x@0.25.2': + resolution: {integrity: sha512-GRa4IshOdvKY7M/rDpRR3gkiTNp34M0eLTaC1a08gNrh4u488aPhuZOCpkF6+2wl3zAN7L7XIpOFBhnaE3/Q8Q==} + engines: {node: '>=18'} + cpu: [s390x] + os: [linux] + + '@esbuild/linux-x64@0.25.2': + resolution: {integrity: sha512-QInHERlqpTTZ4FRB0fROQWXcYRD64lAoiegezDunLpalZMjcUcld3YzZmVJ2H/Cp0wJRZ8Xtjtj0cEHhYc/uUg==} + engines: {node: '>=18'} + cpu: [x64] + os: [linux] + + '@esbuild/netbsd-arm64@0.25.2': + resolution: {integrity: sha512-talAIBoY5M8vHc6EeI2WW9d/CkiO9MQJ0IOWX8hrLhxGbro/vBXJvaQXefW2cP0z0nQVTdQ/eNyGFV1GSKrxfw==} + engines: {node: '>=18'} + cpu: [arm64] + os: [netbsd] + + '@esbuild/netbsd-x64@0.25.2': + resolution: {integrity: sha512-voZT9Z+tpOxrvfKFyfDYPc4DO4rk06qamv1a/fkuzHpiVBMOhpjK+vBmWM8J1eiB3OLSMFYNaOaBNLXGChf5tg==} + engines: {node: '>=18'} + cpu: [x64] + os: [netbsd] + + '@esbuild/openbsd-arm64@0.25.2': + resolution: {integrity: sha512-dcXYOC6NXOqcykeDlwId9kB6OkPUxOEqU+rkrYVqJbK2hagWOMrsTGsMr8+rW02M+d5Op5NNlgMmjzecaRf7Tg==} + engines: {node: '>=18'} + cpu: [arm64] + os: [openbsd] + + '@esbuild/openbsd-x64@0.25.2': + resolution: {integrity: sha512-t/TkWwahkH0Tsgoq1Ju7QfgGhArkGLkF1uYz8nQS/PPFlXbP5YgRpqQR3ARRiC2iXoLTWFxc6DJMSK10dVXluw==} + engines: {node: '>=18'} + cpu: [x64] + os: [openbsd] + + '@esbuild/sunos-x64@0.25.2': + resolution: {integrity: sha512-cfZH1co2+imVdWCjd+D1gf9NjkchVhhdpgb1q5y6Hcv9TP6Zi9ZG/beI3ig8TvwT9lH9dlxLq5MQBBgwuj4xvA==} + engines: {node: '>=18'} + cpu: [x64] + os: [sunos] + + '@esbuild/win32-arm64@0.25.2': + resolution: {integrity: sha512-7Loyjh+D/Nx/sOTzV8vfbB3GJuHdOQyrOryFdZvPHLf42Tk9ivBU5Aedi7iyX+x6rbn2Mh68T4qq1SDqJBQO5Q==} + engines: {node: '>=18'} + cpu: [arm64] + os: [win32] + + '@esbuild/win32-ia32@0.25.2': + resolution: {integrity: sha512-WRJgsz9un0nqZJ4MfhabxaD9Ft8KioqU3JMinOTvobbX6MOSUigSBlogP8QB3uxpJDsFS6yN+3FDBdqE5lg9kg==} + engines: {node: '>=18'} + cpu: [ia32] + os: [win32] + + '@esbuild/win32-x64@0.25.2': + resolution: {integrity: sha512-kM3HKb16VIXZyIeVrM1ygYmZBKybX8N4p754bw390wGO3Tf2j4L2/WYL+4suWujpgf6GBYs3jv7TyUivdd05JA==} + engines: {node: '>=18'} + cpu: [x64] + os: [win32] + + '@jridgewell/sourcemap-codec@1.5.0': + resolution: {integrity: sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==} + + '@parcel/watcher-android-arm64@2.5.1': + resolution: {integrity: sha512-KF8+j9nNbUN8vzOFDpRMsaKBHZ/mcjEjMToVMJOhTozkDonQFFrRcfdLWn6yWKCmJKmdVxSgHiYvTCef4/qcBA==} + engines: {node: '>= 10.0.0'} + cpu: [arm64] + os: [android] + + '@parcel/watcher-darwin-arm64@2.5.1': + resolution: {integrity: sha512-eAzPv5osDmZyBhou8PoF4i6RQXAfeKL9tjb3QzYuccXFMQU0ruIc/POh30ePnaOyD1UXdlKguHBmsTs53tVoPw==} + engines: {node: '>= 10.0.0'} + cpu: [arm64] + os: [darwin] + + '@parcel/watcher-darwin-x64@2.5.1': + resolution: {integrity: sha512-1ZXDthrnNmwv10A0/3AJNZ9JGlzrF82i3gNQcWOzd7nJ8aj+ILyW1MTxVk35Db0u91oD5Nlk9MBiujMlwmeXZg==} + engines: {node: '>= 10.0.0'} + cpu: [x64] + os: [darwin] + + '@parcel/watcher-freebsd-x64@2.5.1': + resolution: {integrity: sha512-SI4eljM7Flp9yPuKi8W0ird8TI/JK6CSxju3NojVI6BjHsTyK7zxA9urjVjEKJ5MBYC+bLmMcbAWlZ+rFkLpJQ==} + engines: {node: '>= 10.0.0'} + cpu: [x64] + os: [freebsd] + + '@parcel/watcher-linux-arm-glibc@2.5.1': + resolution: {integrity: sha512-RCdZlEyTs8geyBkkcnPWvtXLY44BCeZKmGYRtSgtwwnHR4dxfHRG3gR99XdMEdQ7KeiDdasJwwvNSF5jKtDwdA==} + engines: {node: '>= 10.0.0'} + cpu: [arm] + os: [linux] + + '@parcel/watcher-linux-arm-musl@2.5.1': + resolution: {integrity: sha512-6E+m/Mm1t1yhB8X412stiKFG3XykmgdIOqhjWj+VL8oHkKABfu/gjFj8DvLrYVHSBNC+/u5PeNrujiSQ1zwd1Q==} + engines: {node: '>= 10.0.0'} + cpu: [arm] + os: [linux] + + '@parcel/watcher-linux-arm64-glibc@2.5.1': + resolution: {integrity: sha512-LrGp+f02yU3BN9A+DGuY3v3bmnFUggAITBGriZHUREfNEzZh/GO06FF5u2kx8x+GBEUYfyTGamol4j3m9ANe8w==} + engines: {node: '>= 10.0.0'} + cpu: [arm64] + os: [linux] + + '@parcel/watcher-linux-arm64-musl@2.5.1': + resolution: {integrity: sha512-cFOjABi92pMYRXS7AcQv9/M1YuKRw8SZniCDw0ssQb/noPkRzA+HBDkwmyOJYp5wXcsTrhxO0zq1U11cK9jsFg==} + engines: {node: '>= 10.0.0'} + cpu: [arm64] + os: [linux] + + '@parcel/watcher-linux-x64-glibc@2.5.1': + resolution: {integrity: sha512-GcESn8NZySmfwlTsIur+49yDqSny2IhPeZfXunQi48DMugKeZ7uy1FX83pO0X22sHntJ4Ub+9k34XQCX+oHt2A==} + engines: {node: '>= 10.0.0'} + cpu: [x64] + os: [linux] + + '@parcel/watcher-linux-x64-musl@2.5.1': + resolution: {integrity: sha512-n0E2EQbatQ3bXhcH2D1XIAANAcTZkQICBPVaxMeaCVBtOpBZpWJuf7LwyWPSBDITb7In8mqQgJ7gH8CILCURXg==} + engines: {node: '>= 10.0.0'} + cpu: [x64] + os: [linux] + + '@parcel/watcher-win32-arm64@2.5.1': + resolution: {integrity: sha512-RFzklRvmc3PkjKjry3hLF9wD7ppR4AKcWNzH7kXR7GUe0Igb3Nz8fyPwtZCSquGrhU5HhUNDr/mKBqj7tqA2Vw==} + engines: {node: '>= 10.0.0'} + cpu: [arm64] + os: [win32] + + '@parcel/watcher-win32-ia32@2.5.1': + resolution: {integrity: sha512-c2KkcVN+NJmuA7CGlaGD1qJh1cLfDnQsHjE89E60vUEMlqduHGCdCLJCID5geFVM0dOtA3ZiIO8BoEQmzQVfpQ==} + engines: {node: '>= 10.0.0'} + cpu: [ia32] + os: [win32] + + '@parcel/watcher-win32-x64@2.5.1': + resolution: {integrity: sha512-9lHBdJITeNR++EvSQVUcaZoWupyHfXe1jZvGZ06O/5MflPcuPLtEphScIBL+AiCWBO46tDSHzWyD0uDmmZqsgA==} + engines: {node: '>= 10.0.0'} + cpu: [x64] + os: [win32] + + '@parcel/watcher@2.5.1': + resolution: {integrity: sha512-dfUnCxiN9H4ap84DvD2ubjw+3vUNpstxa0TneY/Paat8a3R4uQZDLSvWjmznAY/DoahqTHl9V46HF/Zs3F29pg==} + engines: {node: '>= 10.0.0'} + + '@rollup/rollup-android-arm-eabi@4.39.0': + resolution: {integrity: sha512-lGVys55Qb00Wvh8DMAocp5kIcaNzEFTmGhfFd88LfaogYTRKrdxgtlO5H6S49v2Nd8R2C6wLOal0qv6/kCkOwA==} + cpu: [arm] + os: [android] + + '@rollup/rollup-android-arm64@4.39.0': + resolution: {integrity: sha512-It9+M1zE31KWfqh/0cJLrrsCPiF72PoJjIChLX+rEcujVRCb4NLQ5QzFkzIZW8Kn8FTbvGQBY5TkKBau3S8cCQ==} + cpu: [arm64] + os: [android] + + '@rollup/rollup-darwin-arm64@4.39.0': + resolution: {integrity: sha512-lXQnhpFDOKDXiGxsU9/l8UEGGM65comrQuZ+lDcGUx+9YQ9dKpF3rSEGepyeR5AHZ0b5RgiligsBhWZfSSQh8Q==} + cpu: [arm64] + os: [darwin] + + '@rollup/rollup-darwin-x64@4.39.0': + resolution: {integrity: sha512-mKXpNZLvtEbgu6WCkNij7CGycdw9cJi2k9v0noMb++Vab12GZjFgUXD69ilAbBh034Zwn95c2PNSz9xM7KYEAQ==} + cpu: [x64] + os: [darwin] + + '@rollup/rollup-freebsd-arm64@4.39.0': + resolution: {integrity: sha512-jivRRlh2Lod/KvDZx2zUR+I4iBfHcu2V/BA2vasUtdtTN2Uk3jfcZczLa81ESHZHPHy4ih3T/W5rPFZ/hX7RtQ==} + cpu: [arm64] + os: [freebsd] + + '@rollup/rollup-freebsd-x64@4.39.0': + resolution: {integrity: sha512-8RXIWvYIRK9nO+bhVz8DwLBepcptw633gv/QT4015CpJ0Ht8punmoHU/DuEd3iw9Hr8UwUV+t+VNNuZIWYeY7Q==} + cpu: [x64] + os: [freebsd] + + '@rollup/rollup-linux-arm-gnueabihf@4.39.0': + resolution: {integrity: sha512-mz5POx5Zu58f2xAG5RaRRhp3IZDK7zXGk5sdEDj4o96HeaXhlUwmLFzNlc4hCQi5sGdR12VDgEUqVSHer0lI9g==} + cpu: [arm] + os: [linux] + + '@rollup/rollup-linux-arm-musleabihf@4.39.0': + resolution: {integrity: sha512-+YDwhM6gUAyakl0CD+bMFpdmwIoRDzZYaTWV3SDRBGkMU/VpIBYXXEvkEcTagw/7VVkL2vA29zU4UVy1mP0/Yw==} + cpu: [arm] + os: [linux] + + '@rollup/rollup-linux-arm64-gnu@4.39.0': + resolution: {integrity: sha512-EKf7iF7aK36eEChvlgxGnk7pdJfzfQbNvGV/+l98iiMwU23MwvmV0Ty3pJ0p5WQfm3JRHOytSIqD9LB7Bq7xdQ==} + cpu: [arm64] + os: [linux] + + '@rollup/rollup-linux-arm64-musl@4.39.0': + resolution: {integrity: sha512-vYanR6MtqC7Z2SNr8gzVnzUul09Wi1kZqJaek3KcIlI/wq5Xtq4ZPIZ0Mr/st/sv/NnaPwy/D4yXg5x0B3aUUA==} + cpu: [arm64] + os: [linux] + + '@rollup/rollup-linux-loongarch64-gnu@4.39.0': + resolution: {integrity: sha512-NMRUT40+h0FBa5fb+cpxtZoGAggRem16ocVKIv5gDB5uLDgBIwrIsXlGqYbLwW8YyO3WVTk1FkFDjMETYlDqiw==} + cpu: [loong64] + os: [linux] + + '@rollup/rollup-linux-powerpc64le-gnu@4.39.0': + resolution: {integrity: sha512-0pCNnmxgduJ3YRt+D+kJ6Ai/r+TaePu9ZLENl+ZDV/CdVczXl95CbIiwwswu4L+K7uOIGf6tMo2vm8uadRaICQ==} + cpu: [ppc64] + os: [linux] + + '@rollup/rollup-linux-riscv64-gnu@4.39.0': + resolution: {integrity: sha512-t7j5Zhr7S4bBtksT73bO6c3Qa2AV/HqiGlj9+KB3gNF5upcVkx+HLgxTm8DK4OkzsOYqbdqbLKwvGMhylJCPhQ==} + cpu: [riscv64] + os: [linux] + + '@rollup/rollup-linux-riscv64-musl@4.39.0': + resolution: {integrity: sha512-m6cwI86IvQ7M93MQ2RF5SP8tUjD39Y7rjb1qjHgYh28uAPVU8+k/xYWvxRO3/tBN2pZkSMa5RjnPuUIbrwVxeA==} + cpu: [riscv64] + os: [linux] + + '@rollup/rollup-linux-s390x-gnu@4.39.0': + resolution: {integrity: sha512-iRDJd2ebMunnk2rsSBYlsptCyuINvxUfGwOUldjv5M4tpa93K8tFMeYGpNk2+Nxl+OBJnBzy2/JCscGeO507kA==} + cpu: [s390x] + os: [linux] + + '@rollup/rollup-linux-x64-gnu@4.39.0': + resolution: {integrity: sha512-t9jqYw27R6Lx0XKfEFe5vUeEJ5pF3SGIM6gTfONSMb7DuG6z6wfj2yjcoZxHg129veTqU7+wOhY6GX8wmf90dA==} + cpu: [x64] + os: [linux] + + '@rollup/rollup-linux-x64-musl@4.39.0': + resolution: {integrity: sha512-ThFdkrFDP55AIsIZDKSBWEt/JcWlCzydbZHinZ0F/r1h83qbGeenCt/G/wG2O0reuENDD2tawfAj2s8VK7Bugg==} + cpu: [x64] + os: [linux] + + '@rollup/rollup-win32-arm64-msvc@4.39.0': + resolution: {integrity: sha512-jDrLm6yUtbOg2TYB3sBF3acUnAwsIksEYjLeHL+TJv9jg+TmTwdyjnDex27jqEMakNKf3RwwPahDIt7QXCSqRQ==} + cpu: [arm64] + os: [win32] + + '@rollup/rollup-win32-ia32-msvc@4.39.0': + resolution: {integrity: sha512-6w9uMuza+LbLCVoNKL5FSLE7yvYkq9laSd09bwS0tMjkwXrmib/4KmoJcrKhLWHvw19mwU+33ndC69T7weNNjQ==} + cpu: [ia32] + os: [win32] + + '@rollup/rollup-win32-x64-msvc@4.39.0': + resolution: {integrity: sha512-yAkUOkIKZlK5dl7u6dg897doBgLXmUHhIINM2c+sND3DZwnrdQkkSiDh7N75Ll4mM4dxSkYfXqU9fW3lLkMFug==} + cpu: [x64] + os: [win32] + + '@types/estree@1.0.7': + resolution: {integrity: sha512-w28IoSUCJpidD/TGviZwwMJckNESJZXFu7NBZ5YJ4mEUnNraUn9Pm8HSZm/jDF1pDWYKspWE7oVphigUPRakIQ==} + + '@vitejs/plugin-vue@5.2.3': + resolution: {integrity: sha512-IYSLEQj4LgZZuoVpdSUCw3dIynTWQgPlaRP6iAvMle4My0HdYwr5g5wQAfwOeHQBmYwEkqF70nRpSilr6PoUDg==} + engines: {node: ^18.0.0 || >=20.0.0} + peerDependencies: + vite: ^5.0.0 || ^6.0.0 + vue: ^3.2.25 + + '@vue/compiler-core@3.5.13': + resolution: {integrity: sha512-oOdAkwqUfW1WqpwSYJce06wvt6HljgY3fGeM9NcVA1HaYOij3mZG9Rkysn0OHuyUAGMbEbARIpsG+LPVlBJ5/Q==} + + '@vue/compiler-dom@3.5.13': + resolution: {integrity: sha512-ZOJ46sMOKUjO3e94wPdCzQ6P1Lx/vhp2RSvfaab88Ajexs0AHeV0uasYhi99WPaogmBlRHNRuly8xV75cNTMDA==} + + '@vue/compiler-sfc@3.5.13': + resolution: {integrity: sha512-6VdaljMpD82w6c2749Zhf5T9u5uLBWKnVue6XWxprDobftnletJ8+oel7sexFfM3qIxNmVE7LSFGTpv6obNyaQ==} + + '@vue/compiler-ssr@3.5.13': + resolution: {integrity: sha512-wMH6vrYHxQl/IybKJagqbquvxpWCuVYpoUJfCqFZwa/JY1GdATAQ+TgVtgrwwMZ0D07QhA99rs/EAAWfvG6KpA==} + + '@vue/reactivity@3.5.13': + resolution: {integrity: sha512-NaCwtw8o48B9I6L1zl2p41OHo/2Z4wqYGGIK1Khu5T7yxrn+ATOixn/Udn2m+6kZKB/J7cuT9DbWWhRxqixACg==} + + '@vue/runtime-core@3.5.13': + resolution: {integrity: sha512-Fj4YRQ3Az0WTZw1sFe+QDb0aXCerigEpw418pw1HBUKFtnQHWzwojaukAs2X/c9DQz4MQ4bsXTGlcpGxU/RCIw==} + + '@vue/runtime-dom@3.5.13': + resolution: {integrity: sha512-dLaj94s93NYLqjLiyFzVs9X6dWhTdAlEAciC3Moq7gzAc13VJUdCnjjRurNM6uTLFATRHexHCTu/Xp3eW6yoog==} + + '@vue/server-renderer@3.5.13': + resolution: {integrity: sha512-wAi4IRJV/2SAW3htkTlB+dHeRmpTiVIK1OGLWV1yeStVSebSQQOwGwIq0D3ZIoBj2C2qpgz5+vX9iEBkTdk5YA==} + peerDependencies: + vue: 3.5.13 + + '@vue/shared@3.5.13': + resolution: {integrity: sha512-/hnE/qP5ZoGpol0a5mDi45bOd7t3tjYJBjsgCsivow7D48cJeV5l05RD82lPqi7gRiphZM37rnhW1l6ZoCNNnQ==} + + braces@3.0.3: + resolution: {integrity: sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==} + engines: {node: '>=8'} + + chokidar@4.0.3: + resolution: {integrity: sha512-Qgzu8kfBvo+cA4962jnP1KkS6Dop5NS6g7R5LFYJr4b8Ub94PPQXUksCw9PvXoeXPRRddRNC5C1JQUR2SMGtnA==} + engines: {node: '>= 14.16.0'} + + csstype@3.1.3: + resolution: {integrity: sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw==} + + detect-libc@1.0.3: + resolution: {integrity: sha512-pGjwhsmsp4kL2RTz08wcOlGN83otlqHeD/Z5T8GXZB+/YcpQ/dgo+lbU8ZsGxV0HIvqqxo9l7mqYwyYMD9bKDg==} + engines: {node: '>=0.10'} + hasBin: true + + entities@4.5.0: + resolution: {integrity: sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==} + engines: {node: '>=0.12'} + + esbuild@0.25.2: + resolution: {integrity: sha512-16854zccKPnC+toMywC+uKNeYSv+/eXkevRAfwRD/G9Cleq66m8XFIrigkbvauLLlCfDL45Q2cWegSg53gGBnQ==} + engines: {node: '>=18'} + hasBin: true + + estree-walker@2.0.2: + resolution: {integrity: sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w==} + + fill-range@7.1.1: + resolution: {integrity: sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==} + engines: {node: '>=8'} + + fsevents@2.3.3: + resolution: {integrity: sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==} + engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} + os: [darwin] + + immutable@5.1.1: + resolution: {integrity: sha512-3jatXi9ObIsPGr3N5hGw/vWWcTkq6hUYhpQz4k0wLC+owqWi/LiugIw9x0EdNZ2yGedKN/HzePiBvaJRXa0Ujg==} + + is-extglob@2.1.1: + resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==} + engines: {node: '>=0.10.0'} + + is-glob@4.0.3: + resolution: {integrity: sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==} + engines: {node: '>=0.10.0'} + + is-number@7.0.0: + resolution: {integrity: sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==} + engines: {node: '>=0.12.0'} + + magic-string@0.30.17: + resolution: {integrity: sha512-sNPKHvyjVf7gyjwS4xGTaW/mCnF8wnjtifKBEhxfZ7E/S8tQ0rssrwGNn6q8JH/ohItJfSQp9mBtQYuTlH5QnA==} + + micromatch@4.0.8: + resolution: {integrity: sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==} + engines: {node: '>=8.6'} + + nanoid@3.3.11: + resolution: {integrity: sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w==} + engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} + hasBin: true + + node-addon-api@7.1.1: + resolution: {integrity: sha512-5m3bsyrjFWE1xf7nz7YXdN4udnVtXK6/Yfgn5qnahL6bCkf2yKt4k3nuTKAtT4r3IG8JNR2ncsIMdZuAzJjHQQ==} + + picocolors@1.1.1: + resolution: {integrity: sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==} + + picomatch@2.3.1: + resolution: {integrity: sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==} + engines: {node: '>=8.6'} + + postcss@8.5.3: + resolution: {integrity: sha512-dle9A3yYxlBSrt8Fu+IpjGT8SY8hN0mlaA6GY8t0P5PjIOZemULz/E2Bnm/2dcUOena75OTNkHI76uZBNUUq3A==} + engines: {node: ^10 || ^12 || >=14} + + readdirp@4.1.2: + resolution: {integrity: sha512-GDhwkLfywWL2s6vEjyhri+eXmfH6j1L7JE27WhqLeYzoh/A3DBaYGEj2H/HFZCn/kMfim73FXxEJTw06WtxQwg==} + engines: {node: '>= 14.18.0'} + + rollup@4.39.0: + resolution: {integrity: sha512-thI8kNc02yNvnmJp8dr3fNWJ9tCONDhp6TV35X6HkKGGs9E6q7YWCHbe5vKiTa7TAiNcFEmXKj3X/pG2b3ci0g==} + engines: {node: '>=18.0.0', npm: '>=8.0.0'} + hasBin: true + + sass@1.86.2: + resolution: {integrity: sha512-Rpfn0zAIDqvnSb2DihJTDFjbhqLHu91Wqac9rxontWk7R+2txcPjuujMqu1eeoezh5kAblVCS5EdFdyr0Jmu+w==} + engines: {node: '>=14.0.0'} + hasBin: true + + source-map-js@1.2.1: + resolution: {integrity: sha512-UXWMKhLOwVKb728IUtQPXxfYU+usdybtUrK/8uGE8CQMvrhOpwvzDBwj0QhSL7MQc7vIsISBG8VQ8+IDQxpfQA==} + engines: {node: '>=0.10.0'} + + to-regex-range@5.0.1: + resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==} + engines: {node: '>=8.0'} + + typescript@5.8.2: + resolution: {integrity: sha512-aJn6wq13/afZp/jT9QZmwEjDqqvSGp1VT5GVg+f/t6/oVyrgXM6BY1h9BRh/O5p3PlUPAe+WuiEZOmb/49RqoQ==} + engines: {node: '>=14.17'} + hasBin: true + + vite@6.2.5: + resolution: {integrity: sha512-j023J/hCAa4pRIUH6J9HemwYfjB5llR2Ps0CWeikOtdR8+pAURAk0DoJC5/mm9kd+UgdnIy7d6HE4EAvlYhPhA==} + engines: {node: ^18.0.0 || ^20.0.0 || >=22.0.0} + hasBin: true + peerDependencies: + '@types/node': ^18.0.0 || ^20.0.0 || >=22.0.0 + jiti: '>=1.21.0' + less: '*' + lightningcss: ^1.21.0 + sass: '*' + sass-embedded: '*' + stylus: '*' + sugarss: '*' + terser: ^5.16.0 + tsx: ^4.8.1 + yaml: ^2.4.2 + peerDependenciesMeta: + '@types/node': + optional: true + jiti: + optional: true + less: + optional: true + lightningcss: + optional: true + sass: + optional: true + sass-embedded: + optional: true + stylus: + optional: true + sugarss: + optional: true + terser: + optional: true + tsx: + optional: true + yaml: + optional: true + + vue@3.5.13: + resolution: {integrity: sha512-wmeiSMxkZCSc+PM2w2VRsOYAZC8GdipNFRTsLSfodVqI9mbejKeXEGr8SckuLnrQPGe3oJN5c3K0vpoU9q/wCQ==} + peerDependencies: + typescript: '*' + peerDependenciesMeta: + typescript: + optional: true + +snapshots: + + '@babel/helper-string-parser@7.25.9': {} + + '@babel/helper-validator-identifier@7.25.9': {} + + '@babel/parser@7.27.0': + dependencies: + '@babel/types': 7.27.0 + + '@babel/types@7.27.0': + dependencies: + '@babel/helper-string-parser': 7.25.9 + '@babel/helper-validator-identifier': 7.25.9 + + '@bridgelauncher/api-mock@0.1.0': + dependencies: + '@bridgelauncher/api': 0.1.0 + typescript: 5.8.2 + + '@bridgelauncher/api@0.1.0': {} + + '@esbuild/aix-ppc64@0.25.2': + optional: true + + '@esbuild/android-arm64@0.25.2': + optional: true + + '@esbuild/android-arm@0.25.2': + optional: true + + '@esbuild/android-x64@0.25.2': + optional: true + + '@esbuild/darwin-arm64@0.25.2': + optional: true + + '@esbuild/darwin-x64@0.25.2': + optional: true + + '@esbuild/freebsd-arm64@0.25.2': + optional: true + + '@esbuild/freebsd-x64@0.25.2': + optional: true + + '@esbuild/linux-arm64@0.25.2': + optional: true + + '@esbuild/linux-arm@0.25.2': + optional: true + + '@esbuild/linux-ia32@0.25.2': + optional: true + + '@esbuild/linux-loong64@0.25.2': + optional: true + + '@esbuild/linux-mips64el@0.25.2': + optional: true + + '@esbuild/linux-ppc64@0.25.2': + optional: true + + '@esbuild/linux-riscv64@0.25.2': + optional: true + + '@esbuild/linux-s390x@0.25.2': + optional: true + + '@esbuild/linux-x64@0.25.2': + optional: true + + '@esbuild/netbsd-arm64@0.25.2': + optional: true + + '@esbuild/netbsd-x64@0.25.2': + optional: true + + '@esbuild/openbsd-arm64@0.25.2': + optional: true + + '@esbuild/openbsd-x64@0.25.2': + optional: true + + '@esbuild/sunos-x64@0.25.2': + optional: true + + '@esbuild/win32-arm64@0.25.2': + optional: true + + '@esbuild/win32-ia32@0.25.2': + optional: true + + '@esbuild/win32-x64@0.25.2': + optional: true + + '@jridgewell/sourcemap-codec@1.5.0': {} + + '@parcel/watcher-android-arm64@2.5.1': + optional: true + + '@parcel/watcher-darwin-arm64@2.5.1': + optional: true + + '@parcel/watcher-darwin-x64@2.5.1': + optional: true + + '@parcel/watcher-freebsd-x64@2.5.1': + optional: true + + '@parcel/watcher-linux-arm-glibc@2.5.1': + optional: true + + '@parcel/watcher-linux-arm-musl@2.5.1': + optional: true + + '@parcel/watcher-linux-arm64-glibc@2.5.1': + optional: true + + '@parcel/watcher-linux-arm64-musl@2.5.1': + optional: true + + '@parcel/watcher-linux-x64-glibc@2.5.1': + optional: true + + '@parcel/watcher-linux-x64-musl@2.5.1': + optional: true + + '@parcel/watcher-win32-arm64@2.5.1': + optional: true + + '@parcel/watcher-win32-ia32@2.5.1': + optional: true + + '@parcel/watcher-win32-x64@2.5.1': + optional: true + + '@parcel/watcher@2.5.1': + dependencies: + detect-libc: 1.0.3 + is-glob: 4.0.3 + micromatch: 4.0.8 + node-addon-api: 7.1.1 + optionalDependencies: + '@parcel/watcher-android-arm64': 2.5.1 + '@parcel/watcher-darwin-arm64': 2.5.1 + '@parcel/watcher-darwin-x64': 2.5.1 + '@parcel/watcher-freebsd-x64': 2.5.1 + '@parcel/watcher-linux-arm-glibc': 2.5.1 + '@parcel/watcher-linux-arm-musl': 2.5.1 + '@parcel/watcher-linux-arm64-glibc': 2.5.1 + '@parcel/watcher-linux-arm64-musl': 2.5.1 + '@parcel/watcher-linux-x64-glibc': 2.5.1 + '@parcel/watcher-linux-x64-musl': 2.5.1 + '@parcel/watcher-win32-arm64': 2.5.1 + '@parcel/watcher-win32-ia32': 2.5.1 + '@parcel/watcher-win32-x64': 2.5.1 + optional: true + + '@rollup/rollup-android-arm-eabi@4.39.0': + optional: true + + '@rollup/rollup-android-arm64@4.39.0': + optional: true + + '@rollup/rollup-darwin-arm64@4.39.0': + optional: true + + '@rollup/rollup-darwin-x64@4.39.0': + optional: true + + '@rollup/rollup-freebsd-arm64@4.39.0': + optional: true + + '@rollup/rollup-freebsd-x64@4.39.0': + optional: true + + '@rollup/rollup-linux-arm-gnueabihf@4.39.0': + optional: true + + '@rollup/rollup-linux-arm-musleabihf@4.39.0': + optional: true + + '@rollup/rollup-linux-arm64-gnu@4.39.0': + optional: true + + '@rollup/rollup-linux-arm64-musl@4.39.0': + optional: true + + '@rollup/rollup-linux-loongarch64-gnu@4.39.0': + optional: true + + '@rollup/rollup-linux-powerpc64le-gnu@4.39.0': + optional: true + + '@rollup/rollup-linux-riscv64-gnu@4.39.0': + optional: true + + '@rollup/rollup-linux-riscv64-musl@4.39.0': + optional: true + + '@rollup/rollup-linux-s390x-gnu@4.39.0': + optional: true + + '@rollup/rollup-linux-x64-gnu@4.39.0': + optional: true + + '@rollup/rollup-linux-x64-musl@4.39.0': + optional: true + + '@rollup/rollup-win32-arm64-msvc@4.39.0': + optional: true + + '@rollup/rollup-win32-ia32-msvc@4.39.0': + optional: true + + '@rollup/rollup-win32-x64-msvc@4.39.0': + optional: true + + '@types/estree@1.0.7': {} + + '@vitejs/plugin-vue@5.2.3(vite@6.2.5(sass@1.86.2))(vue@3.5.13(typescript@5.8.2))': + dependencies: + vite: 6.2.5(sass@1.86.2) + vue: 3.5.13(typescript@5.8.2) + + '@vue/compiler-core@3.5.13': + dependencies: + '@babel/parser': 7.27.0 + '@vue/shared': 3.5.13 + entities: 4.5.0 + estree-walker: 2.0.2 + source-map-js: 1.2.1 + + '@vue/compiler-dom@3.5.13': + dependencies: + '@vue/compiler-core': 3.5.13 + '@vue/shared': 3.5.13 + + '@vue/compiler-sfc@3.5.13': + dependencies: + '@babel/parser': 7.27.0 + '@vue/compiler-core': 3.5.13 + '@vue/compiler-dom': 3.5.13 + '@vue/compiler-ssr': 3.5.13 + '@vue/shared': 3.5.13 + estree-walker: 2.0.2 + magic-string: 0.30.17 + postcss: 8.5.3 + source-map-js: 1.2.1 + + '@vue/compiler-ssr@3.5.13': + dependencies: + '@vue/compiler-dom': 3.5.13 + '@vue/shared': 3.5.13 + + '@vue/reactivity@3.5.13': + dependencies: + '@vue/shared': 3.5.13 + + '@vue/runtime-core@3.5.13': + dependencies: + '@vue/reactivity': 3.5.13 + '@vue/shared': 3.5.13 + + '@vue/runtime-dom@3.5.13': + dependencies: + '@vue/reactivity': 3.5.13 + '@vue/runtime-core': 3.5.13 + '@vue/shared': 3.5.13 + csstype: 3.1.3 + + '@vue/server-renderer@3.5.13(vue@3.5.13(typescript@5.8.2))': + dependencies: + '@vue/compiler-ssr': 3.5.13 + '@vue/shared': 3.5.13 + vue: 3.5.13(typescript@5.8.2) + + '@vue/shared@3.5.13': {} + + braces@3.0.3: + dependencies: + fill-range: 7.1.1 + optional: true + + chokidar@4.0.3: + dependencies: + readdirp: 4.1.2 + + csstype@3.1.3: {} + + detect-libc@1.0.3: + optional: true + + entities@4.5.0: {} + + esbuild@0.25.2: + optionalDependencies: + '@esbuild/aix-ppc64': 0.25.2 + '@esbuild/android-arm': 0.25.2 + '@esbuild/android-arm64': 0.25.2 + '@esbuild/android-x64': 0.25.2 + '@esbuild/darwin-arm64': 0.25.2 + '@esbuild/darwin-x64': 0.25.2 + '@esbuild/freebsd-arm64': 0.25.2 + '@esbuild/freebsd-x64': 0.25.2 + '@esbuild/linux-arm': 0.25.2 + '@esbuild/linux-arm64': 0.25.2 + '@esbuild/linux-ia32': 0.25.2 + '@esbuild/linux-loong64': 0.25.2 + '@esbuild/linux-mips64el': 0.25.2 + '@esbuild/linux-ppc64': 0.25.2 + '@esbuild/linux-riscv64': 0.25.2 + '@esbuild/linux-s390x': 0.25.2 + '@esbuild/linux-x64': 0.25.2 + '@esbuild/netbsd-arm64': 0.25.2 + '@esbuild/netbsd-x64': 0.25.2 + '@esbuild/openbsd-arm64': 0.25.2 + '@esbuild/openbsd-x64': 0.25.2 + '@esbuild/sunos-x64': 0.25.2 + '@esbuild/win32-arm64': 0.25.2 + '@esbuild/win32-ia32': 0.25.2 + '@esbuild/win32-x64': 0.25.2 + + estree-walker@2.0.2: {} + + fill-range@7.1.1: + dependencies: + to-regex-range: 5.0.1 + optional: true + + fsevents@2.3.3: + optional: true + + immutable@5.1.1: {} + + is-extglob@2.1.1: + optional: true + + is-glob@4.0.3: + dependencies: + is-extglob: 2.1.1 + optional: true + + is-number@7.0.0: + optional: true + + magic-string@0.30.17: + dependencies: + '@jridgewell/sourcemap-codec': 1.5.0 + + micromatch@4.0.8: + dependencies: + braces: 3.0.3 + picomatch: 2.3.1 + optional: true + + nanoid@3.3.11: {} + + node-addon-api@7.1.1: + optional: true + + picocolors@1.1.1: {} + + picomatch@2.3.1: + optional: true + + postcss@8.5.3: + dependencies: + nanoid: 3.3.11 + picocolors: 1.1.1 + source-map-js: 1.2.1 + + readdirp@4.1.2: {} + + rollup@4.39.0: + dependencies: + '@types/estree': 1.0.7 + optionalDependencies: + '@rollup/rollup-android-arm-eabi': 4.39.0 + '@rollup/rollup-android-arm64': 4.39.0 + '@rollup/rollup-darwin-arm64': 4.39.0 + '@rollup/rollup-darwin-x64': 4.39.0 + '@rollup/rollup-freebsd-arm64': 4.39.0 + '@rollup/rollup-freebsd-x64': 4.39.0 + '@rollup/rollup-linux-arm-gnueabihf': 4.39.0 + '@rollup/rollup-linux-arm-musleabihf': 4.39.0 + '@rollup/rollup-linux-arm64-gnu': 4.39.0 + '@rollup/rollup-linux-arm64-musl': 4.39.0 + '@rollup/rollup-linux-loongarch64-gnu': 4.39.0 + '@rollup/rollup-linux-powerpc64le-gnu': 4.39.0 + '@rollup/rollup-linux-riscv64-gnu': 4.39.0 + '@rollup/rollup-linux-riscv64-musl': 4.39.0 + '@rollup/rollup-linux-s390x-gnu': 4.39.0 + '@rollup/rollup-linux-x64-gnu': 4.39.0 + '@rollup/rollup-linux-x64-musl': 4.39.0 + '@rollup/rollup-win32-arm64-msvc': 4.39.0 + '@rollup/rollup-win32-ia32-msvc': 4.39.0 + '@rollup/rollup-win32-x64-msvc': 4.39.0 + fsevents: 2.3.3 + + sass@1.86.2: + dependencies: + chokidar: 4.0.3 + immutable: 5.1.1 + source-map-js: 1.2.1 + optionalDependencies: + '@parcel/watcher': 2.5.1 + + source-map-js@1.2.1: {} + + to-regex-range@5.0.1: + dependencies: + is-number: 7.0.0 + optional: true + + typescript@5.8.2: {} + + vite@6.2.5(sass@1.86.2): + dependencies: + esbuild: 0.25.2 + postcss: 8.5.3 + rollup: 4.39.0 + optionalDependencies: + fsevents: 2.3.3 + sass: 1.86.2 + + vue@3.5.13(typescript@5.8.2): + dependencies: + '@vue/compiler-dom': 3.5.13 + '@vue/compiler-sfc': 3.5.13 + '@vue/runtime-dom': 3.5.13 + '@vue/server-renderer': 3.5.13(vue@3.5.13(typescript@5.8.2)) + '@vue/shared': 3.5.13 + optionalDependencies: + typescript: 5.8.2 diff --git a/public/mock/notice.txt b/public/mock/notice.txt new file mode 100644 index 0000000..1ef1267 --- /dev/null +++ b/public/mock/notice.txt @@ -0,0 +1,9 @@ +This is the mock folder, put your `icons` folder and `apps.json` in the folder where this file is located + +How to obtain? (you may ask) +1. Open Bridge Launcher +2. Open it's Settings +3. Scroll down to 'development' +4. Click 'Export' +5. Select any path +6. Transfer the needed files (`icons` folder and `apps.json`) here \ No newline at end of file diff --git a/public/vite.svg b/public/vite.svg new file mode 100644 index 0000000..e7b8dfb --- /dev/null +++ b/public/vite.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/public/vue.svg b/public/vue.svg new file mode 100644 index 0000000..770e9d3 --- /dev/null +++ b/public/vue.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/src/App.vue b/src/App.vue new file mode 100644 index 0000000..d8e1cde --- /dev/null +++ b/src/App.vue @@ -0,0 +1,29 @@ + + + + + diff --git a/src/components/AppIcon.vue b/src/components/AppIcon.vue new file mode 100644 index 0000000..aced530 --- /dev/null +++ b/src/components/AppIcon.vue @@ -0,0 +1,43 @@ + + + + + diff --git a/src/main.js b/src/main.js new file mode 100644 index 0000000..e5cdc31 --- /dev/null +++ b/src/main.js @@ -0,0 +1,13 @@ +import { createApp } from 'vue' +import './style.scss' +import App from './App.vue' +import { BridgeMock } from '@bridgelauncher/api-mock'; + +if (!window.Bridge) { + window.Bridge = new BridgeMock({ + appsUrl: '/mock/apps.json', + makeGetDefaultIconUrl: (packageName) => `/mock/icons/default/${packageName}.png`, + }); +} + +createApp(App).mount('#app') diff --git a/src/style.scss b/src/style.scss new file mode 100644 index 0000000..4674f48 --- /dev/null +++ b/src/style.scss @@ -0,0 +1,7 @@ +// SCSS goes here + +body { + margin: 0; + padding: 0; + box-sizing: border-box; +} \ No newline at end of file diff --git a/vite.config.js b/vite.config.js new file mode 100644 index 0000000..543b61b --- /dev/null +++ b/vite.config.js @@ -0,0 +1,15 @@ +import { defineConfig } from 'vite' +import vue from '@vitejs/plugin-vue' +import sass from 'sass'; + +// https://vite.dev/config/ +export default defineConfig({ + plugins: [vue()], + css: { + preprocessorOptions: { + sass: { + implementation: sass, + }, + }, + }, +})