SYMBOL INDEX (325 symbols across 79 files) FILE: scripts/hooks/artifactBuildCompleted.mjs function artifactBuildCompleted (line 6) | async function artifactBuildCompleted(context) { FILE: scripts/hooks/notarize-options.mjs function getPasswordFromKeychain (line 4) | function getPasswordFromKeychain(account, service) { function prepareNotarizeEnv (line 21) | async function prepareNotarizeEnv(env = process.env) { function hasNotarizeCredentials (line 51) | function hasNotarizeCredentials(env = process.env) { function getNotarizeOptions (line 59) | async function getNotarizeOptions(appPath, env = process.env) { FILE: scripts/libs/build-env.mjs function hasValue (line 1) | function hasValue(value) { function getFirstConfiguredEnv (line 5) | function getFirstConfiguredEnv(env, names) { function isEnvFlagEnabled (line 15) | function isEnvFlagEnabled(value) { FILE: scripts/libs/build-log.mjs constant PLATFORM_LABELS (line 4) | const PLATFORM_LABELS = { constant PLATFORM_COLORS (line 10) | const PLATFORM_COLORS = { function formatTimestamp (line 16) | function formatTimestamp(date = new Date()) { function formatLogLine (line 20) | function formatLogLine(message) { function formatDuration (line 24) | function formatDuration(ms) { function logBanner (line 41) | function logBanner(message) { function logStep (line 45) | function logStep(message) { function logSuccess (line 49) | function logSuccess(message) { function logWarning (line 53) | function logWarning(message) { function logPlatform (line 57) | function logPlatform(platform, message) { FILE: scripts/libs/build-plan.mjs constant PLATFORM_ORDER (line 5) | const PLATFORM_ORDER = ['mac', 'win', 'linux'] function resolvePlatformName (line 7) | function resolvePlatformName(name) { function formatArch (line 20) | function formatArch(arch) { function getBuildPlan (line 28) | function getBuildPlan(makeFor, targetPlatformsConfigs) { function createBuildTracker (line 51) | function createBuildTracker({ plan, compression, macBuildState, winBuild... FILE: scripts/libs/build-state.mjs function hasSigningIdentityEnv (line 4) | function hasSigningIdentityEnv(env = process.env) { function describeNotarizationSetup (line 8) | function describeNotarizationSetup(env = process.env) { function resolveMacBuildState (line 29) | async function resolveMacBuildState(plan, env = process.env) { function resolveWindowsBuildState (line 94) | function resolveWindowsBuildState(plan, env = process.env) { FILE: scripts/libs/my-exec.mjs function myExec (line 3) | function myExec(cmd, ...args) { FILE: scripts/make.mjs constant TARGET_PLATFORMS_CONFIGS (line 26) | const TARGET_PLATFORMS_CONFIGS = { constant WINDOWS_TIMESTAMP_SERVER (line 48) | const WINDOWS_TIMESTAMP_SERVER = 'http://rfc3161timestamp.globalsign.com... function createBuilderConfig (line 50) | function createBuilderConfig(hooks, macBuildState, winBuildState) { function main (line 289) | async function main() { FILE: scripts/release-config.mjs constant DEFAULT_GITHUB_REPOSITORY (line 6) | const DEFAULT_GITHUB_REPOSITORY = 'oldj/SwitchHosts' function getReleaseVersion (line 8) | function getReleaseVersion() { function getFullVersion (line 12) | function getFullVersion() { function getReleaseTag (line 16) | function getReleaseTag(env = process.env) { function resolveGithubRepository (line 29) | function resolveGithubRepository(env = process.env) { function isReleaseArtifactFile (line 49) | function isReleaseArtifactFile(fileName, fullVersion = getFullVersion()) { FILE: scripts/upload-diagnostics.mjs function getCauseField (line 1) | function getCauseField(cause, field) { function normalizeTarget (line 7) | function normalizeTarget(target) { function getCause (line 30) | function getCause(error) { function pickEnumerableFields (line 42) | function pickEnumerableFields(value) { function extractErrorDetails (line 55) | function extractErrorDetails(error) { function buildDiagnostic (line 72) | function buildDiagnostic({ function formatDiagnosticSummary (line 110) | function formatDiagnosticSummary(diagnostic) { function formatRetrySummary (line 135) | function formatRetrySummary(diagnostic, delayLabel) { function buildDebugPayload (line 156) | function buildDebugPayload(diagnostic, error) { function attachDiagnostic (line 170) | function attachDiagnostic(error, diagnostic) { FILE: scripts/upload-progress.mjs constant PROGRESS_BAR_FORMAT (line 4) | const PROGRESS_BAR_FORMAT = '[:bar]' constant PROGRESS_BAR_WIDTH (line 5) | const PROGRESS_BAR_WIDTH = 24 function clamp (line 7) | function clamp(value, min, max) { function formatPercent (line 11) | function formatPercent(value) { function formatEta (line 15) | function formatEta(seconds) { function truncateFileName (line 32) | function truncateFileName(fileName, maxLength = 36) { function formatProgressMessage (line 49) | function formatProgressMessage(snapshot) { function fitFileNameToWidth (line 61) | function fitFileNameToWidth(fileName, availableWidth, fallbackMaxLength ... function formatTtyProgressLines (line 77) | function formatTtyProgressLines(snapshot, barText, columns) { function buildSnapshot (line 95) | function buildSnapshot(state, now) { function createCaptureStream (line 132) | function createCaptureStream(columns = 120) { function createUploadProgressTracker (line 156) | function createUploadProgressTracker({ FILE: scripts/upload-release.mjs function log (line 52) | function log(message) { function logFileList (line 56) | function logFileList(files) { function getArtifactVersion (line 63) | function getArtifactVersion(fileName) { function sleep (line 68) | function sleep(ms) { function getRetryDelayMs (line 74) | function getRetryDelayMs(attempt) { function formatRetryDelay (line 78) | function formatRetryDelay(ms) { function isRetryableStatus (line 82) | function isRetryableStatus(status) { function isRetryableFetchError (line 86) | function isRetryableFetchError(error) { function getProgressSnapshot (line 109) | function getProgressSnapshot(progressTracker) { function logDiagnosticDebug (line 113) | function logDiagnosticDebug(error) { function readReleaseFiles (line 124) | async function readReleaseFiles() { function githubRequest (line 160) | async function githubRequest( function findReleaseByTag (line 238) | async function findReleaseByTag() { function createDraftRelease (line 265) | async function createDraftRelease() { function getUploadUrl (line 282) | function getUploadUrl(release) { function deleteAsset (line 286) | async function deleteAsset(assetId, assetName) { function tryDeleteAssetByName (line 294) | async function tryDeleteAssetByName(releaseId, assetName) { function uploadAsset (line 309) | async function uploadAsset(uploadUrl, file, { fileIndex, releaseId, prog... function main (line 425) | async function main() { FILE: scripts/vars.mjs constant APP_NAME (line 9) | const APP_NAME = 'SwitchHosts' FILE: src/common/data.d.ts type HostsType (line 3) | type HostsType = 'local' | 'remote' | 'group' | 'folder' type FolderModeType (line 4) | type FolderModeType = 0 | 1 | 2 // 0: 默认; 1: 单选; 2: 多选 type IHostsListObject (line 6) | interface IHostsListObject { type IHostsContentObject (line 31) | interface IHostsContentObject { type ITrashcanObject (line 38) | interface ITrashcanObject { type ITrashcanListObject (line 44) | interface ITrashcanListObject extends ITrashcanObject, ITreeNodeData { type IHostsHistoryObject (line 53) | interface IHostsHistoryObject { type VersionType (line 60) | type VersionType = [number, number, number, number] type IHostsBasicData (line 62) | interface IHostsBasicData { type IOperationResult (line 68) | interface IOperationResult { type ICommandRunResult (line 75) | interface ICommandRunResult { FILE: src/common/default_configs.ts type WriteModeType (line 4) | type WriteModeType = null | 'overwrite' | 'append' type ThemeType (line 5) | type ThemeType = 'light' | 'dark' | 'system' type ProtocolType (line 6) | type ProtocolType = 'http' | 'https' type DefaultLocaleType (line 7) | type DefaultLocaleType = LocaleName | undefined type ConfigsType (line 44) | type ConfigsType = typeof configs FILE: src/common/hostsFn.ts type PartHostsObjectType (line 9) | type PartHostsObjectType = Partial & { id: string } type Predicate (line 11) | type Predicate = (obj: IHostsListObject) => boolean FILE: src/common/i18n/index.ts type LocaleName (line 33) | type LocaleName = keyof typeof languages class I18N (line 35) | class I18N { method constructor (line 39) | constructor(locale: LocaleName = 'en') { method trans (line 54) | trans(key: LanguageKey, words?: string[]) { FILE: src/common/newlines.ts type LineEnding (line 1) | type LineEnding = '\n' | '\r\n' constant LINE_ENDING_RE (line 3) | const LINE_ENDING_RE = /\r\n?/g function normalizeLineEndings (line 5) | function normalizeLineEndings(content: string): string { function getLineEndingForPlatform (line 9) | function getLineEndingForPlatform(platform = process.platform): LineEndi... function restoreLineEndings (line 17) | function restoreLineEndings(content: string, lineEnding: LineEnding): st... FILE: src/common/normalize.ts type INormalizeOptions (line 13) | type INormalizeOptions = Partial type IHostsLineObj (line 15) | interface IHostsLineObj { type IDomainsIPMap (line 21) | interface IDomainsIPMap { FILE: src/common/tree.ts type NodeIdType (line 1) | type NodeIdType = string type ITreeNodeData (line 3) | interface ITreeNodeData { type IWithChildren (line 17) | interface IWithChildren { function flatten (line 21) | function flatten(tree_list: T[]): T[] { type IWidthId (line 39) | interface IWidthId extends IWithChildren { function getNodeById (line 43) | function getNodeById( FILE: src/common/types.d.ts type LanguageDict (line 12) | type LanguageDict = typeof lang type LanguageKey (line 13) | type LanguageKey = keyof LanguageDict type IActionFunc (line 15) | interface IActionFunc { type Actions (line 19) | type Actions = typeof actions & IActionFunc type IMenuItemOption (line 21) | interface IMenuItemOption extends MenuItemConstructorOptions { type IPopupMenuOption (line 27) | interface IPopupMenuOption { type IFindPosition (line 32) | interface IFindPosition { type IFindSplitter (line 44) | interface IFindSplitter { type IFindItem (line 51) | interface IFindItem { type IFindShowSourceParam (line 59) | type IFindShowSourceParam = IFindPosition & { FILE: src/common/update.ts type AppUpdateInfo (line 1) | interface AppUpdateInfo { type AppUpdateProgress (line 7) | interface AppUpdateProgress { type AppDownloadedUpdateInfo (line 14) | interface AppDownloadedUpdateInfo extends AppUpdateInfo { FILE: src/main/actions/find/addHistory.ts constant MAX_LENGTH (line 9) | const MAX_LENGTH = 20 FILE: src/main/actions/find/addReplaceHistory.ts constant MAX_LENGTH (line 9) | const MAX_LENGTH = 20 FILE: src/main/actions/find/findBy.ts type IFindOptions (line 13) | interface IFindOptions { FILE: src/main/actions/find/findPositionsInContent.ts type MatchResult (line 8) | type MatchResult = Pick< FILE: src/main/actions/find/setHistory.ts type IFindHistoryData (line 8) | interface IFindHistoryData { FILE: src/main/actions/find/splitContent.ts type MatchResult (line 8) | type MatchResult = Pick & { FILE: src/main/actions/hosts/setSystemHosts.ts type IWriteResult (line 24) | interface IWriteResult { constant CONTENT_START (line 32) | const CONTENT_START = '# --- SWITCHHOSTS_CONTENT_START ---' FILE: src/main/core/message.ts function sendBack (line 60) | function sendBack(sender: any, event_name: string, data: [any] | [any, a... FILE: src/main/core/updater.ts function normalizeReleaseNotes (line 11) | function normalizeReleaseNotes(releaseNotes: UpdateInfo['releaseNotes'])... function toAppUpdateInfo (line 36) | function toAppUpdateInfo(info: UpdateInfo): AppUpdateInfo { function toProgressPayload (line 44) | function toProgressPayload(info: ProgressInfo): AppUpdateProgress { function toDownloadedUpdateInfo (line 53) | function toDownloadedUpdateInfo(event: UpdateDownloadedEvent): AppDownlo... function bindUpdaterEvents (line 60) | function bindUpdaterEvents() { function checkUpdate (line 102) | async function checkUpdate(): Promise { function downloadUpdate (line 119) | async function downloadUpdate() { function installUpdate (line 130) | async function installUpdate() { FILE: src/main/data/index.ts function getSwhDb (line 35) | async function getSwhDb(): Promise { FILE: src/main/libs/getDataDir.ts function getDefaultDataDir (line 9) | function getDefaultDataDir() { FILE: src/main/libs/request.ts type IParams (line 12) | interface IParams { type IRequestOptions (line 16) | interface IRequestOptions { FILE: src/main/libs/tracer.ts class Tracer (line 5) | class Tracer { method constructor (line 8) | constructor() { method add (line 12) | add(action: string) { method emit (line 16) | async emit() { FILE: src/main/preload.ts type Window (line 13) | interface Window { type EventHandler (line 18) | type EventHandler = (...args: any[]) => void FILE: src/main/types.d.ts type ActionData (line 13) | interface ActionData { type IHostsWriteOptions (line 19) | interface IHostsWriteOptions { FILE: src/main/ui/menu.ts method click (line 95) | click() { method click (line 102) | click() { method click (line 114) | click(_item: MenuItem, focusedWindow) { method click (line 122) | click(_item: MenuItem, focusedWindow) { method click (line 180) | click() { method click (line 186) | click() { FILE: src/main/ui/tray/index.ts method click (line 100) | click() { method click (line 113) | async click() { FILE: src/renderer/common/PageWrapper.tsx type IProps (line 9) | interface IProps { function PageWrapper (line 13) | function PageWrapper(props: IProps) { FILE: src/renderer/components/BrowserLink.tsx type Props (line 10) | interface Props { FILE: src/renderer/components/Editor/hosts_highlight.ts constant HOSTS_LINE_RE (line 15) | const HOSTS_LINE_RE = /^\s*([\d.]+|[\da-f:.%lo]+)\s+\w/i constant COMMENT_LINE_RE (line 17) | const COMMENT_LINE_RE = /^(\s*)#\s*/ type LineInfo (line 20) | interface LineInfo { type InsertTransform (line 31) | interface InsertTransform { type RemoveTransform (line 37) | interface RemoveTransform { type Transform (line 43) | type Transform = InsertTransform | RemoveTransform type CommentToggleResult (line 45) | interface CommentToggleResult { type ToggleLineResult (line 52) | interface ToggleLineResult { function escapeHtml (line 58) | function escapeHtml(text: string): string { function isHostsCommentLine (line 67) | function isHostsCommentLine(line: string): boolean { function isValidHostsLine (line 71) | function isValidHostsLine(line: string): boolean { function highlightHostsLine (line 75) | function highlightHostsLine(line: string): string { function highlightHostsText (line 96) | function highlightHostsText(code: string): string { function highlightHosts (line 104) | function highlightHosts(editor: HTMLElement, _pos?: Position): void { function getLines (line 108) | function getLines(code: string): LineInfo[] { function getLineIndexAtOffset (line 123) | function getLineIndexAtOffset(lines: LineInfo[], offset: number): number { function toggleLine (line 135) | function toggleLine(line: string, lineStart: number): ToggleLineResult { function mapOffset (line 169) | function mapOffset(offset: number, transforms: Transform[]): number { function getLineStartOffsets (line 193) | function getLineStartOffsets(lines: string[]): number[] { function getSelectionRange (line 205) | function getSelectionRange(selectionStart: number, selectionEnd: number) { function toggleCommentLines (line 218) | function toggleCommentLines( function toggleCommentBySelection (line 272) | function toggleCommentBySelection( function toggleCommentByLine (line 296) | function toggleCommentByLine( FILE: src/renderer/components/History.tsx type IHistoryProps (line 32) | interface IHistoryProps { FILE: src/renderer/components/HostsViewer.tsx type Props (line 9) | interface Props { FILE: src/renderer/components/ItemIcon.tsx type Props (line 15) | interface Props { FILE: src/renderer/components/Lang.tsx type Props (line 10) | interface Props { FILE: src/renderer/components/LeftPanel/TrashcanItem.tsx type Props (line 16) | interface Props { method click (line 33) | click() { method click (line 47) | click() { method click (line 58) | click() { FILE: src/renderer/components/LeftPanel/index.tsx type Props (line 15) | interface Props { method click (line 26) | click() { FILE: src/renderer/components/List/ListItem.tsx type Props (line 23) | interface Props { method click (line 98) | click() { method click (line 104) | async click() { method click (line 137) | click() { FILE: src/renderer/components/List/index.tsx type Props (line 24) | interface Props { FILE: src/renderer/components/Pref/Advanced.tsx type IProps (line 13) | interface IProps { FILE: src/renderer/components/Pref/Commands.tsx type IProps (line 12) | interface IProps { FILE: src/renderer/components/Pref/CommandsHistory.tsx type Props (line 14) | interface Props { FILE: src/renderer/components/Pref/General.tsx type IProps (line 13) | interface IProps { FILE: src/renderer/components/Pref/Proxy.tsx type IProps (line 11) | interface IProps { FILE: src/renderer/components/SetWriteMode.tsx type Props (line 16) | interface Props {} type IPendingData (line 18) | interface IPendingData { FILE: src/renderer/components/SideDrawer.tsx type SideDrawerProps (line 5) | interface SideDrawerProps extends Omit) => void type INodeProps (line 23) | interface INodeProps { function diff (line 275) | function diff(a: T[], b: T[]): T[] { function isEqual (line 279) | function isEqual(prevProps: INodeProps, nextProps: INodeProps): boolean { FILE: src/renderer/components/Tree/Tree.tsx type DropWhereType (line 14) | type DropWhereType = 'before' | 'in' | 'after' type MultipleSelectType (line 15) | type MultipleSelectType = 0 | 1 | 2 type ITreeProps (line 17) | interface ITreeProps { FILE: src/renderer/components/Tree/fn.ts type IObj (line 5) | interface IObj { type KeyMapType (line 9) | type KeyMapType = [string, string] function flatten (line 11) | function flatten(tree_list: ITreeNodeData[]): ITreeNodeData[] { function getParentList (line 29) | function getParentList(tree_list: ITreeNodeData[], id: NodeIdType): ITre... function getNodeById (line 88) | function getNodeById(tree_list: ITreeNodeData[], id: NodeIdType): ITreeN... function isChildOf (line 95) | function isChildOf(tree_list: ITreeNodeData[], a_id: NodeIdType, b_id: N... function isSelfOrChild (line 104) | function isSelfOrChild(item: ITreeNodeData, id: NodeIdType | null): bool... function objKeyMap (line 110) | function objKeyMap(obj: IObj, key_maps: KeyMapType[], reversed: boolean ... function treeKeyMap (line 138) | function treeKeyMap( function keyMapReverse (line 150) | function keyMapReverse(key_maps: KeyMapType[]): KeyMapType[] { function isParent (line 154) | function isParent(tree_list: ITreeNodeData[], item: ITreeNodeData, id: s... function canBeSelected (line 159) | function canBeSelected( function selectTo (line 183) | function selectTo( FILE: src/renderer/components/Tree/index.tsx type KeyMapType (line 10) | type KeyMapType = _KeyMapType FILE: src/renderer/components/UpdateDialog.tsx type UpdateStage (line 9) | type UpdateStage = 'available' | 'downloading' | 'downloaded' FILE: src/renderer/core/PopupMenu.ts type OffFunction (line 11) | type OffFunction = () => void class PopupMenu (line 13) | class PopupMenu { method constructor (line 18) | constructor(menu_items: IMenuItemOption[]) { method show (line 23) | show() { method onHide (line 56) | private onHide() { FILE: src/renderer/core/agent.ts method get (line 11) | get(obj, key: keyof Actions) { FILE: src/renderer/models/useConfigs.ts function useConfigs (line 11) | function useConfigs() { FILE: src/renderer/models/useHostsData.ts function useHostsData (line 12) | function useHostsData() { FILE: src/renderer/models/useI18n.ts function useI18n (line 10) | function useI18n() { FILE: src/renderer/pages/find.tsx type IFindPositionShow (line 29) | interface IFindPositionShow extends IFindPosition { method click (line 295) | click() { method click (line 313) | click() { FILE: test/_base.ts type Global (line 17) | interface Global { FILE: test/main/setSystemHosts.test.ts method add (line 19) | add() {} FILE: test/scripts/upload-progress.test.ts method log (line 16) | log() {} method log (line 46) | log() {} method log (line 62) | log() {} method log (line 86) | log() {} method log (line 115) | log(message) { class FakeProgressBar (line 141) | class FakeProgressBar { method interrupt (line 146) | interrupt(message: string) { method render (line 150) | render() {} method terminate (line 152) | terminate() {} method tick (line 154) | tick(delta: number) { method update (line 158) | update(ratio: number) { method clearLine (line 164) | clearLine() {} method cursorTo (line 165) | cursorTo() {} method moveCursor (line 167) | moveCursor() {} method write (line 168) | write(chunk: string) { method log (line 177) | log(message) { FILE: test/setup.ts class BrowserWindowMock (line 18) | class BrowserWindowMock { method fromWebContents (line 19) | static fromWebContents() { method closeDevTools (line 28) | closeDevTools() {} method openDevTools (line 29) | openDevTools() {} method once (line 30) | once() {} method setPermissionRequestHandler (line 32) | setPermissionRequestHandler() {} method onBeforeSendHeaders (line 34) | onBeforeSendHeaders() {} method onHeadersReceived (line 35) | onHeadersReceived() {} method toggleDevTools (line 38) | toggleDevTools() {} method constructor (line 41) | constructor(options?: { width?: number; height?: number }) { method focus (line 46) | focus() { method getBounds (line 50) | getBounds() { method hide (line 54) | hide() { method isFocused (line 59) | isFocused() { method isVisible (line 63) | isVisible() { method loadURL (line 67) | loadURL() { method on (line 71) | on() { method setPosition (line 75) | setPosition(x: number, y: number) { method setVisibleOnAllWorkspaces (line 80) | setVisibleOnAllWorkspaces() {} method show (line 82) | show() { method getPath (line 90) | getPath(name: string) { method quit (line 98) | quit() {} method whenReady (line 99) | whenReady() { method hide (line 103) | hide() {} method show (line 104) | show() { method buildFromTemplate (line 111) | buildFromTemplate() { method setToolTip (line 117) | setToolTip() {} method setContextMenu (line 118) | setContextMenu() {} method on (line 119) | on() {} method popUpContextMenu (line 120) | popUpContextMenu() {} method getBounds (line 121) | getBounds() { method getCursorScreenPoint (line 126) | getCursorScreenPoint() { method getDisplayNearestPoint (line 129) | getDisplayNearestPoint() { method openExternal (line 137) | openExternal() { method showItemInFolder (line 140) | showItemInFolder() { method showOpenDialog (line 145) | showOpenDialog() { method showSaveDialog (line 148) | showSaveDialog() { method emit (line 153) | emit() {} method on (line 154) | on() {} method handle (line 155) | handle() {} method removeHandler (line 156) | removeHandler() {} method removeAllListeners (line 157) | removeAllListeners() {} method invoke (line 160) | invoke() { method on (line 163) | on() {} method send (line 164) | send() {} method removeAllListeners (line 165) | removeAllListeners() {} method exposeInMainWorld (line 168) | exposeInMainWorld() {} FILE: typings.d.ts type ReactSVG (line 10) | interface ReactSVG {