-
-
Notifications
You must be signed in to change notification settings - Fork 66
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Finish refactoring types in AeroSandbox
- Loading branch information
Showing
42 changed files
with
230 additions
and
253 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,26 @@ | ||
import { InterceptionFeaturesEnum } from "$types/index.d"; | ||
import { InterceptionFeaturesEnum } from "$types/apiInterceptors"; | ||
|
||
// TODO: Put all of these terms in the API Interception Glossary | ||
|
||
/** @note: These do not cover Origin Isolation although Origin Emulation is a type of Origin Isolation. Origin Emulation is a superset of Origin Isolation. */ | ||
const originEmulationFeatures = | ||
InterceptionFeaturesEnum.corsEmulation | | ||
InterceptionFeaturesEnum.cacheEmulation | | ||
InterceptionFeaturesEnum.privacySandbox | | ||
InterceptionFeaturesEnum.nestedSWs; | ||
InterceptionFeaturesEnum.corsEmulation | | ||
InterceptionFeaturesEnum.cacheEmulation | | ||
InterceptionFeaturesEnum.privacySandbox | | ||
InterceptionFeaturesEnum.nestedSWs; | ||
/** @note: These do not cover Origin Concealers although Origin Isolation is a type of Origin Concealing. Origin Isolation is a superset of Origin Concealment. */ | ||
const miscOriginIsolators = InterceptionFeaturesEnum.messageIsolation; | ||
const miscOriginConcealers = | ||
InterceptionFeaturesEnum.elementConcealment | | ||
InterceptionFeaturesEnum.errorConcealment; | ||
InterceptionFeaturesEnum.elementConcealment | | ||
InterceptionFeaturesEnum.errorConcealment; | ||
const defaultSWProxyFeatures = originEmulationFeatures | miscOriginConcealers; | ||
const defaultProxyFeatures = | ||
defaultSWProxyFeatures | InterceptionFeaturesEnum.requestUrlProxifier; | ||
defaultSWProxyFeatures | InterceptionFeaturesEnum.requestUrlProxifier; | ||
|
||
export { | ||
originEmulationFeatures, | ||
miscOriginIsolators, | ||
miscOriginConcealers, | ||
defaultSWProxyFeatures, | ||
defaultProxyFeatures | ||
originEmulationFeatures, | ||
miscOriginIsolators, | ||
miscOriginConcealers, | ||
defaultSWProxyFeatures, | ||
defaultProxyFeatures, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
import { AeroGlobalType } from "$types/$aero.d"; | ||
|
||
// The rest of the aero props are set in the SW injects before this file is executed | ||
// I have no use for this file yet |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import { SupportEnum, InterceptionFeaturesEnum } from "$types/apiInterceptors"; | ||
|
||
import type { BareTransport } from "@mercuryworkshop/bare-mux"; | ||
|
||
export interface AeroSandboxConfig { | ||
proxyConfig: ProxyConfig; | ||
/** These enum members enable code inside of the Proxy handler that provide other things you may want to use AeroSandbox for */ | ||
specialInterceptionFeatures?: InterceptionFeaturesEnum; | ||
supports: SupportEnum; | ||
proxyGlobalContext: "$aero"; | ||
} | ||
|
||
// This is the typical proxy config. This is only what is used to format and unformat urls. | ||
export type ProxyConfig = { | ||
BareTransport: BareTransport; | ||
prefix: string; | ||
encodeUrl: (url: string) => string; | ||
decodeUrl: (url: string) => string; | ||
// This is for WebRTC proxying. The API is disabled, if this isn't provided. | ||
webrtcTurnServers?: string[]; | ||
}; |
Oops, something went wrong.