diff --git a/docs/appActions.md b/docs/appActions.md deleted file mode 100644 index 92b5ef49830..00000000000 --- a/docs/appActions.md +++ /dev/null @@ -1,1147 +0,0 @@ -# Global - - - - - -* * * - -### setState(appState) - -Dispatches an event to the main process to replace the app state -This is called from the main process on startup before anything else - -**Parameters** - -**appState**: `object`, Initial app state object (not yet converted to ImmutableJS) - - - -### newWindow(frameOpts, browserOpts, restoredState, cb) - -Dispatches an event to the main process to create a new window. - -**Parameters** - -**frameOpts**: `Object`, Options for the first frame in the window. - -**browserOpts**: `Object`, Options for the browser. - -**restoredState**: `Object`, State for the window to restore. - -**cb**: `function`, Callback to call after the window is loaded, will only work if called from the main process. - - - -### frameChanged(frame) - -Frame props changed - -**Parameters** - -**frame**: `Object`, Frame props changed - - - -### tabCreated(tabValue) - -A new tab has been created - -**Parameters** - -**tabValue**: `Object`, A new tab has been created - - - -### tabMoved(tabId, frameOpts, browserOpts, windowId) - -A tab has been moved to another window - -**Parameters** - -**tabId**: `Number`, A tab has been moved to another window - -**frameOpts**: `Object`, A tab has been moved to another window - -**browserOpts**: `Object`, A tab has been moved to another window - -**windowId**: `Number`, A tab has been moved to another window - - - -### createTabRequested(createProperties) - -A request for a new tab has been made with the specified createProperties - -**Parameters** - -**createProperties**: `Object`, A request for a new tab has been made with the specified createProperties - - - -### loadURLRequested(tabId, url) - -A request for a URL load - -**Parameters** - -**tabId**: `number`, the tab ID to load the URL inside of - -**url**: `string`, The url to load - - - -### loadURLInActiveTabRequested(windowId, url) - -A request for a URL load for the active tab of the specified window - -**Parameters** - -**windowId**: `number`, the window ID to load the URL inside of - -**url**: `string`, The url to load - - - -### simpleShareActiveTabRequested(windowId, shareType) - -A request for a URL email share occurred - -**Parameters** - -**windowId**: `number`, the window ID to use for the active tab - -**shareType**: `string`, The type of share to do, must be one of: "email", "facebook", "pinterest", "twitter", "googlePlus", "linkedIn", "buffer", "reddit", or "digg" - - - -### tabUpdated(tabValue, changeInfo) - -A tab has been updated - -**Parameters** - -**tabValue**: `Object`, A tab has been updated - -**changeInfo**: `Object`, from chrome-tabs-updated - - - -### tabActivateRequested(tabId) - -Dispatches a message to the store to set a new frame as the active frame. - -**Parameters** - -**tabId**: `Number`, the tabId to activate - - - -### tabIndexChanged(tabId, index) - -Dispatches a message to the store to change the tab index - -**Parameters** - -**tabId**: `Number`, the tabId - -**index**: `Number`, the new index - - - -### tabCloseRequested(tabId, forceClosePinned) - -Dispatches a message to close the tabId - -**Parameters** - -**tabId**: `Number`, the tabId to close - -**forceClosePinned**: `Boolean`, force close if pinned - - - -### tabClosed(tabId) - -Notifies that a tab has been closed - -**Parameters** - -**tabId**: `number`, Notifies that a tab has been closed - - - -### addSite(siteDetail, tag, skipSync) - -Adds a site to the site list - -**Parameters** - -**siteDetail**: `Object`, Properties of the site in question, can also be an array of siteDetail - -**tag**: `string`, A tag to associate with the site. e.g. bookmarks. - -**skipSync**: `boolean`, Set true if a site isn't eligible for Sync (e.g. if addSite was triggered by Sync) - - - -### removeSite(siteDetail, tag, skipSync) - -Removes a site from the site list - -**Parameters** - -**siteDetail**: `Object`, Properties of the site in question - -**tag**: `string`, A tag to associate with the site. e.g. bookmarks. - -**skipSync**: `boolean`, Set true if a site isn't eligible for Sync (e.g. if this removal was triggered by Sync) - - - -### moveSite(sourceKey, destinationKey, prepend, destinationIsParent) - -Dispatches a message to move a site locations. - -**Parameters** - -**sourceKey**: `string`, the source key of the source moved site - -**destinationKey**: `string`, the destination key of the destination moved site - -**prepend**: `boolean`, Whether or not to prepend to the destinationLocation - If false, the destinationDetail is considered a sibling. - -**destinationIsParent**: `boolean`, Whether or not the destinationDetail should be considered the new parent. - - - -### mergeDownloadDetail(downloadId, downloadDetail) - -Dispatches a message to add/edit download details -If set, also indicates that add/edit is shown - -**Parameters** - -**downloadId**: `string`, A unique ID for the download - -**downloadDetail**: `Object`, Properties for the download - - - -### clearCompletedDownloads() - -Dispatches a message to clear all completed downloads - - - -### ledgerRecoverySucceeded() - -Dispatches a message indicating ledger recovery succeeded - - - -### ledgerRecoveryFailed() - -Dispatches a message indicating ledger recovery failed - - - -### defaultWindowParamsChanged(size, position) - -Sets the default window size / position - -**Parameters** - -**size**: `Array`, [width, height] - -**position**: `Array`, [x, y] - - - -### setResourceETag(resourceName, etag) - -Sets the etag value for a downloaded data file. -This is used for keeping track of when to re-download adblock and tracking -protection data. - -**Parameters** - -**resourceName**: `string`, 'adblock' or 'trackingProtection' - -**etag**: `string`, The etag of the reosurce from the http response - - - -### setResourceLastCheck(resourceName, lastCheck) - -Sets the lastCheck date.getTime() value for the data file - -**Parameters** - -**resourceName**: `string`, 'adblock', 'trackingProtection', or 'httpsEverywhere' - -**lastCheck**: `number`, The last check date of the reosurce from the http response - - - -### setResourceEnabled(resourceName, enabled) - -Sets whether the resource is enabled or not. - -**Parameters** - -**resourceName**: `string`, 'adblock', 'trackingProtection', or 'httpsEverywhere' - -**enabled**: `boolean`, true if the resource is enabled. - - - -### resourceReady(resourceName) - -Indicates a resource is ready - -**Parameters** - -**resourceName**: `string`, 'widevine' - - - -### addResourceCount(resourceName, count) - -Checks how many resources were blocked. - -**Parameters** - -**resourceName**: `string`, 'adblock', 'trackingProtection', or 'httpsEverywhere' - -**count**: `number`, number of blocked resources to add to the global count - - - -### setUpdateLastCheck() - -Sets the update.lastCheckTimestamp to the current -epoch timestamp (milliseconds) - - - -### setUpdateStatus(status, verbose, metadata) - -Sets the update status - -**Parameters** - -**status**: `string`, update status from js/constants/updateStatus.js. - -**verbose**: `boolean`, Whether to show UI for all the update steps. - -**metadata**: `object`, Metadata from the pdate server, with info like release notes. - - - -### changeSetting(key, value) - -Changes an application level setting - -**Parameters** - -**key**: `string`, The key name for the setting - -**value**: `string`, The value of the setting - - - -### changeSiteSetting(hostPattern, key, value, temp, skipSync) - -Change a hostPattern's config - -**Parameters** - -**hostPattern**: `string`, The host pattern to update the config for - -**key**: `string`, The config key to update - -**value**: `string | number`, The value to update to - -**temp**: `boolean`, Whether to change temporary or persistent - settings. defaults to false (persistent). - -**skipSync**: `boolean`, Set true if a site isn't eligible for Sync (e.g. if addSite was triggered by Sync) - - - -### removeSiteSetting(hostPattern, key, temp, skipSync) - -Removes a site setting - -**Parameters** - -**hostPattern**: `string`, The host pattern to update the config for - -**key**: `string`, The config key to update - -**temp**: `boolean`, Whether to change temporary or persistent - settings. defaults to false (persistent). - -**skipSync**: `boolean`, Set true if a site isn't eligible for Sync (e.g. if addSite was triggered by Sync) - - - -### setSkipSync(path, skipSync) - -Changes the skipSync flag on an appState path. - -**Parameters** - -**path**: `Array.<string>`, Changes the skipSync flag on an appState path. - -**skipSync**: `boolean`, Changes the skipSync flag on an appState path. - - - -### updateLedgerInfo(ledgerInfo) - -Updates ledger information for the payments pane - -**Parameters** - -**ledgerInfo**: `object`, the current ledger state - - - -### updateLocationInfo(locationInfo) - -Updates location information for the URL bar - -**Parameters** - -**locationInfo**: `object`, the current location synopsis - - - -### updatePublisherInfo(publisherInfo) - -Updates publisher information for the payments pane - -**Parameters** - -**publisherInfo**: `object`, the current publisher synopsis - - - -### showNotification(detail) - -Shows a message in the notification bar - -**Parameters** - -**detail**: `Object`, Shows a message in the notification bar - - - -### hideNotification(message) - -Hides a message in the notification bar - -**Parameters** - -**message**: `string`, Hides a message in the notification bar - - - -### setLoginRequiredDetail(tabId, detail) - -Adds information about pending basic auth login requests - -**Parameters** - -**tabId**: `number`, The tabId that generated the request - -**detail**: `string`, login request info - - - -### onClearBrowsingData() - -Clears the data specified in clearDataDetail - - - -### importBrowserData(selected) - -Import browser data specified in selected - -**Parameters** - -**selected**: `object`, the browser data to import as per doc/state.md's importBrowserDataSelected - - - -### addAutofillAddress(detail) - -Add address data - -**Parameters** - -**detail**: `object`, the address to add as per doc/state.md's autofillAddressDetail - - - -### removeAutofillAddress(detail) - -Remove address data - -**Parameters** - -**detail**: `object`, the address to remove as per doc/state.md's autofillAddressDetail - - - -### addAutofillCreditCard(detail) - -Add credit card data - -**Parameters** - -**detail**: `object`, the credit card to add as per doc/state.md's autofillCreditCardDetail - - - -### removeAutofillCreditCard(detail) - -Remove credit card data - -**Parameters** - -**detail**: `object`, the credit card to remove as per doc/state.md's autofillCreditCardDetail - - - -### autofillDataChanged(addressGuids, creditCardGuids) - -Autofill data changed - -**Parameters** - -**addressGuids**: `Array`, the guid array to access address entries in autofill DB - -**creditCardGuids**: `Array`, the guid array to access credit card entries in autofill DB - - - -### windowBlurred(windowId) - -Dispatches a message when windowId loses focus - -**Parameters** - -**windowId**: `Number`, the unique id of the window - - - -### windowFocused(windowId) - -Dispatches a message when windowId gains focus - -**Parameters** - -**windowId**: `Number`, the unique id of the window - - - -### setMenubarTemplate(menubarTemplate) - -Saves current menubar template for use w/ Windows titlebar - -**Parameters** - -**menubarTemplate**: `Object`, JSON used to build the menu - - - -### networkConnected() - -Dispatches a message when the network is re-connected -after being disconnected - - - -### networkDisconnected() - -Dispatches a message when the network is disconnected - - - -### defaultBrowserUpdated(useBrave) - -Dispatch a message to set default browser - -**Parameters** - -**useBrave**: `boolean`, whether set Brave as default browser - - - -### defaultBrowserCheckComplete() - -Dispatch a message to indicate default browser check is complete - - - -### populateHistory() - -Notify the AppStore to provide default history values. - - - -### dataURLCopied() - -Dispatch a message to copy data URL to clipboard - - - -### shuttingDown() - -Dispatches a message when the app is shutting down. - - - -### downloadRevealed(downloadId) - -Dispatches a message when a download is being revealed. -Typically this will open the download directory in finder / explorer and select the icon. - -**Parameters** - -**downloadId**: `string`, ID of the download being revealed - - - -### downloadOpened(downloadId) - -Dispatches a message when a download is being opened. - -**Parameters** - -**downloadId**: `string`, ID of the download being opened - - - -### downloadActionPerformed(downloadId, downloadAction) - -Dispatches a message when an electron download action is being performed (pause, resume, cancel) - -**Parameters** - -**downloadId**: `string`, ID of the download item the action is being performed to - -**downloadAction**: `string`, the action to perform from constants/electronDownloadItemActions.js - - - -### downloadCopiedToClipboard(downloadId) - -Dispatches a message when a download URL is being copied to the clipboard - -**Parameters** - -**downloadId**: `string`, ID of the download item being copied to the clipboard - - - -### downloadDeleted(downloadId) - -Dispatches a message when a download is being deleted - -**Parameters** - -**downloadId**: `string`, ID of the download item being deleted - - - -### downloadCleared(downloadId) - -Dispatches a message when a download is being cleared - -**Parameters** - -**downloadId**: `string`, ID of the download item being cleared - - - -### downloadRedownloaded(downloadId) - -Dispatches a message when a download is being redownloaded - -**Parameters** - -**downloadId**: `string`, ID of the download item being redownloaded - - - -### showDownloadDeleteConfirmation() - -Shows delete confirmation bar in download item panel - - - -### hideDownloadDeleteConfirmation() - -Hides delete confirmation bar in download item panel - - - -### clipboardTextCopied(text) - -Dispatches a message when text is updated to the clipboard - -**Parameters** - -**text**: `string`, clipboard text which is copied - - - -### toggleDevTools(tabId) - -Dispatches a message to toogle the dev tools on/off for the specified tabId - -**Parameters** - -**tabId**: `number`, The tabId - - - -### tabCloned(tabId, options) - -Dispatches a message when a tab is being cloned - -**Parameters** - -**tabId**: `number`, The tabId of the tab to clone - -**options**: `object`, object containing options such as acive, back, and forward booleans - - - -### noScriptExceptionsAdded(hostPattern, origins, temporary) - -Dispatches a message when noscript exceptions are added for an origin - -**Parameters** - -**hostPattern**: `string`, Dispatches a message when noscript exceptions are added for an origin - -**origins**: `Object.<string, (boolean|number)>`, Dispatches a message when noscript exceptions are added for an origin - -**temporary**: `boolean`, Dispatches a message when noscript exceptions are added for an origin - - - -### setObjectId(objectId, objectPath) - -Dispatches a message to set objectId for a syncable object. - -**Parameters** - -**objectId**: `Array.<number>`, Dispatches a message to set objectId for a syncable object. - -**objectPath**: `Array.<string>`, Dispatches a message to set objectId for a syncable object. - - - -### pendingSyncRecordsAdded(records) - -Add records sent with sync lib's SEND_SYNC_RECORDS to the appState -records pending upload. After we download records via the sync lib -we run pendingSyncRecordsRemoved. - -**Parameters** - -**records**: `Object`, Array. - - - -### pendingSyncRecordsRemoved(records) - -Remove records from the appState's records pending upload. -This function is called after we download the records from the sync -library. - -**Parameters** - -**records**: `Object`, Array. - - - -### saveSyncDevices(devices) - -Dispatch to update sync devices cache. -NOTE: deviceId is a string! Normally it's Array. but that can't -be an object key. Use syncUtil.deviceIdToString() - -**Parameters** - -**devices**: `Object`, {[deviceId]: {lastRecordTimestamp=, name=}} - - - -### saveSyncInitData(seed, deviceId, lastFetchTimestamp, seedQr) - -Dispatches a message when sync init data needs to be saved - -**Parameters** - -**seed**: `Array.<number> | null`, Dispatches a message when sync init data needs to be saved - -**deviceId**: `Array.<number> | null`, Dispatches a message when sync init data needs to be saved - -**lastFetchTimestamp**: `number | null`, Dispatches a message when sync init data needs to be saved - -**seedQr**: `string`, Dispatches a message when sync init data needs to be saved - - - -### setSyncSetupError(error) - -Sets the sync setup error, or null for no error. - -**Parameters** - -**error**: `string | null`, Sets the sync setup error, or null for no error. - - - -### applySiteRecords(records) - -Dispatches a message to apply a batch of site records from Brave Sync -TODO: Refactor this to merge it into addSite/removeSite - -**Parameters** - -**records**: `Array.<Object>`, Dispatches a message to apply a batch of site records from Brave Sync -TODO: Refactor this to merge it into addSite/removeSite - - - -### createSyncCache() - -Dispatch to populate the sync object id -> appState key path mapping cache - - - -### resetSyncData() - -Dispatches a message to delete sync data. - - - -### tabMessageBoxDismissed(tabId, detail) - -Close a tab's open alert/confirm/etc (triggered by clicking OK/cancel). - -**Parameters** - -**tabId**: `number`, The tabId - -**detail**: `Object`, Object containing: suppressCheckbox (boolean) - - - -### tabMessageBoxUpdated(tabId, detail) - -Update the detail object for the open alert/confirm/prompt (triggers re-render) - -**Parameters** - -**tabId**: `number`, The tabId - -**detail**: `Object`, Replacement object - - - -### navigatorHandlerRegistered(partition, protocol, location) - -Action triggered by registering navigation handler - -**Parameters** - -**partition**: `string`, session partition - -**protocol**: `string`, navigator protocol - -**location**: `string`, location where handler was triggered - - - -### navigatorHandlerUnregistered(partition, protocol, location) - -Action triggered by un-registering navigation handler - -**Parameters** - -**partition**: `string`, session partition - -**protocol**: `string`, navigator protocol - -**location**: `string`, location where handler was triggered - - - -### defaultDownloadPath() - -Open dialog for default download path setting - - - -### enableUndefinedPublishers(publishers) - -Change all undefined publishers in site settings to defined sites -also change all undefined ledgerPayments to value true - -**Parameters** - -**publishers**: `Object`, publishers from the synopsis - - - -### changeLedgerPinnedPercentages(publishers) - -Update ledger publishers pinned percentages according to the new synopsis - -**Parameters** - -**publishers**: `Object`, updated publishers - - - -### tabPinned(tabId) - -Update ledger publishers pinned percentages according to the new synopsis -Open dialog for default download path setting -Dispatches a message when a tab is being pinned - -**Parameters** - -**tabId**: `number`, The tabId of the tab to pin - - - -### dragEnded() - -Notifies the app that a drag operation stopped from within the app - - - -### dataDropped() - -Notifies the app that a drop operation occurred - - - -### draggedOver() - -Notifies the app that a drop operation occurred - - - -### onGoBack(tabId) - -Go back in a history for a given tab - -**Parameters** - -**tabId**: `number`, Tab id used for an action - - - -### onGoForward(tabId) - -Go forward in a history for a given tab - -**Parameters** - -**tabId**: `number`, Tab id used for an action - - - -### onGoToIndex(tabId, index) - -Go to specific item in a history for a given tab - -**Parameters** - -**tabId**: `number`, Tab id used for an action - -**index**: `number`, Index in the history - - - -### onGoBackLong(tabId, rect) - -Go back in a history for a given tab - -**Parameters** - -**tabId**: `number`, Tab id used for an action - -**rect**: `ClientRect`, Parent element position for this action - - - -### onGoForwardLong(tabId, rect) - -Go forward in a history for a given tab - -**Parameters** - -**tabId**: `number`, Tab id used for an action - -**rect**: `ClientRect`, Parent element position for this action - - - -### dragCancelled() - -Notifies the app that a drop operation was cancelled -because ESC was pressed. - - - -### autoplayBlocked(tabId) - -Notifies autoplay has been blocked - -**Parameters** - -**tabId**: `number`, Tab id of current frame - - - -### savePassword() - -Handle 'save-password' event from muon - - - -### updatePassword() - -Handle 'update-password' event from muon - - - -### deletePassword(passwordDetail) - -Deletes login credentials - -**Parameters** - -**passwordDetail**: `Object`, login details - - - -### clearPasswords() - -Deletes all saved login credentials - - - -### deletePasswordSite() - -Delete legacy "never saved password" list - - - -### urlBarTextChanged(windowId, tabId, input) - -Indicates that the urlbar text has changed, usually from user input - -**Parameters** - -**windowId**: `number`, The window ID the text is being changed inside of - -**tabId**: `number`, The tab ID the text is being changed inside of - -**input**: `string`, The text that was entered into the URL bar - - - -### searchSuggestionResultsAvailable(tabId, searchResults) - -New URL bar suggestion search results are available. -This is typically from a service like Duck Duck Go auto complete for the portion of text that the user typed in. - -**Parameters** - -**tabId**: `number`, the tab id for the action - -**searchResults**: , The search results for the currently entered URL bar text. - - - -### urlBarSuggestionsChanged(windowId, suggestionList, selectedIndex) - -Indicates URL bar suggestions and selected index. - -**Parameters** - -**windowId**: `number`, the window ID - -**suggestionList**: `Array.<Object>`, The list of suggestions for the entered URL bar text. This can be generated from history, bookmarks, etc. - -**selectedIndex**: `number`, The index for the selected item (users can select items with down arrow on their keyboard) - - - -### urlBarSelectedIndexChanged(windowId, selectedIndex) - -Indicates URL bar selected index - -**Parameters** - -**windowId**: `number`, the window ID - -**selectedIndex**: `number`, The index for the selected item (users can select items with down arrow on their keyboard) - - - -### defaultSearchEngineLoaded(searchDetail) - -Dispatches a message to set the search engine details. - -**Parameters** - -**searchDetail**: `Object`, the search details - - - -### updateLogOpened() - -Dispatches a message to indicate that the update log is being opened - - - -### onToggleBrowsingData() - -Save temp setting for clear browsing data - - - -### onCancelBrowsingData() - -Clear temp setting for clear browsing data - - - - -* * * - - - - - - - - - - diff --git a/docs/windowActions.md b/docs/windowActions.md deleted file mode 100644 index 453dd20ed7c..00000000000 --- a/docs/windowActions.md +++ /dev/null @@ -1,825 +0,0 @@ -# Global - - - - - -* * * - -### setState(windowState) - -Dispatches an event to the main process to replace the window state - -**Parameters** - -**windowState**: `object`, Initial window state object - - - -### setNavigated(location, key, isNavigatedInPage, tabId) - -Dispatches a message to the store to let it know a page has been navigated. - -**Parameters** - -**location**: `string`, The URL of the page that was navigated to. - -**key**: `number`, The frame key to modify. - -**isNavigatedInPage**: `boolean`, true if it was a navigation within the same page. - -**tabId**: `number`, the tab id - - - -### setSecurityState(tabId, securityState) - -Dispatches a message to set the security state. - -**Parameters** - -**tabId**: `Object`, Tab id of the frame properties to modify. - -**securityState**: `Object`, The security state properties that have - changed. - - - -### frameTabIdChanged(frameProps, oldTabId, newTabId) - -Dispatches a message to change the frame tabId - -**Parameters** - -**frameProps**: `Object`, The frame properties - -**oldTabId**: `Number`, the current tabId - -**newTabId**: `Number`, the new tabId - - - -### frameGuestInstanceIdChanged(frameProps, oldGuestInstanceId, newGuestInstanceId) - -Dispatches a message when the guestInstanceId changes for a frame - -**Parameters** - -**frameProps**: `Object`, The frame properties - -**oldGuestInstanceId**: `Number`, the current guestInstanceId - -**newGuestInstanceId**: `Number`, the new guestInstanceId - - - -### setFrameError(frameProps, errorDetails) - -Dispatches a message to set the frame error state - -**Parameters** - -**frameProps**: `Object`, The frame properties - -**errorDetails**: `Object`, The error properties - changed. - - - -### setFindbarShown(frameKey, shown) - -Shows/hides the find-in-page bar. - -**Parameters** - -**frameKey**: `number`, Key of the frame that we want to modify - -**shown**: `boolean`, Whether to show the find bar - - - -### setFindbarSelected(frameKey, selected) - -Highlight text in the find bar - -**Parameters** - -**frameKey**: `Object`, The frame key to modify - -**selected**: `boolean`, Whether to select the find bar search text - - - -### onWebviewLoadStart(frameProps, location) - -Dispatches a message to the store to indicate that the webview is loading. - -**Parameters** - -**frameProps**: `Object`, The frame properties for the webview in question. - -**location**: `string`, The location being loaded. - - - -### onWebviewLoadEnd(frameProps) - -Dispatches a message to the store to indicate that the webview is done loading. - -**Parameters** - -**frameProps**: `Object`, The frame properties for the webview in question. - - - -### setFullScreen(tabId, isFullScreen, showFullScreenWarning) - -Dispatches a message to the store to indicate that the webview entered full screen mode. - -**Parameters** - -**tabId**: `Object`, Tab id of the frame to put in full screen - -**isFullScreen**: `boolean`, true if the webview is entering full screen mode. - -**showFullScreenWarning**: `boolean`, true if a warning about entering full screen should be shown. - - - -### closeFrame(frameKey) - -Dispatches a message to close a frame - -**Parameters** - -**frameKey**: `Object`, Frame key of the frame to close - - - -### closeFrames(framePropsList) - -Dispatches a message to close multiple frames - -**Parameters** - -**framePropsList**: `Array.<Object>`, The properties of all frames to close - - - -### closeOtherFrames(tabId, isCloseRight, isCloseLeft) - -Dispatches a message to close multiple frames - -**Parameters** - -**tabId**: `string`, Frame that we want to ignore when closing all tabs - -**isCloseRight**: `boolean`, Close frames to the right of the frame provided - -**isCloseLeft**: `boolean`, Close frames to the left of the frame provided - - - -### undoClosedFrame() - -Dispatches a message to the store to undo a closed frame -The new frame is expected to appear at the index it was last closed at - - - -### clearClosedFrames() - -Dispatches a message to the store to clear closed frames - - - -### setFocusedFrame(location, tabId) - -Dispatches a message to the store when the frame is active and the window is focused - -**Parameters** - -**location**: `Object`, location for the webview in question. - -**tabId**: `Object`, tabId for the webview in question. - - - -### setPreviewFrame(frameKey) - -Dispatches a message to the store to set a preview frame. -This should only be called internally by `WINDOW_SET_TAB_HOVER_STATE` -when we need to delay updating the preview frame value - -**Parameters** - -**frameKey**: `Object`, the frame key for the webview in question. - - - -### setTabPageIndex(index) - -Dispatches a message to the store to set the tab page index. - -**Parameters** - -**index**: `number`, the tab page index to change to - - - -### setTabBreakpoint(frameKey, breakpoint) - -Dispatches a message to the store to set the tab breakpoint. - -**Parameters** - -**frameKey**: `Object`, the frame key for the webview in question. - -**breakpoint**: `string`, the tab breakpoint to change to - - - -### setTabHoverState(frameKey, hoverState) - -Dispatches a message to the store to set the current tab hover state. - -**Parameters** - -**frameKey**: `Object`, the frame key for the webview in question. - -**hoverState**: `boolean`, whether or not mouse is over tab - - - -### setTabPageHoverState(tabPageIndex, hoverState) - -Dispatches a message to the store to set the current tab hover state. - -**Parameters** - -**tabPageIndex**: `Object`, the frame key for the webview in question. - -**hoverState**: `boolean`, whether or not mouse is over tabPage - - - -### setPreviewTabPageIndex(previewTabPageIndex) - -Dispatches a message to the store to set the tab page index being previewed. - -**Parameters** - -**previewTabPageIndex**: `number`, The tab page index to preview - - - -### setTabPageIndexByFrame(frameProps) - -Dispatches a message to the store to set the tab page index. - -**Parameters** - -**frameProps**: `number`, The frame props to center around - - - -### moveTab(sourceFrameKey, destinationFrameKey, prepend) - -Dispatches a message to the store to indicate that the specified frame should move locations. - -**Parameters** - -**sourceFrameKey**: `Object`, the frame key for the webview to move. - -**destinationFrameKey**: `Object`, the frame key for the webview to move to. - -**prepend**: `boolean`, Whether or not to prepend to the destinationFrameProps - - - -### activeSuggestionClicked(isForSecondaryAction, shiftKey) - -The active URL bar suggestion was clicked - -**Parameters** - -**isForSecondaryAction**: `boolean`, Whether the secondary action is expected - which happens when a modifier key is pressed. - -**shiftKey**: `boolean`, Whether the shift key is being pressed - - - -### previousUrlBarSuggestionSelected() - -The previous suggestion is being selected - - - -### nextUrlBarSuggestionSelected() - -The next suggestion is being selected - - - -### urlBarAutocompleteEnabled(enabled) - -autocomplete for urlbar is being enabled or disabled. -Autocomplete is defined to be the action of inserting text into the urlbar itself -to the first item's URL match if possible. The inserted text is auto selected so -that the next character inserted will replace it. -This is sometimes only temporarily disabled, e.g. a user is pressing backspace. - -**Parameters** - -**enabled**: `boolean`, true if the urlbar should autocomplete - - - -### urlBarSelected() - -Indicates the URLbar has been selected - - - -### setUrlBarActive(isActive) - -Marks the URL bar as active or not. -If the URL bar is active that means it's in a position that it should be displaying -autocomplete. It may choose not to display autocomplete and still be active if there -are no autocomplete results. - -**Parameters** - -**isActive**: `boolean`, Whether or not the URL bar should be marked as active - - - -### frameShortcutChanged(frameProps, activeShortcut, activeShortcutDetails) - -Dispatches a message to the store to indicate that the pending frame shortcut info should be updated. - -**Parameters** - -**frameProps**: `Object`, Properties of the frame in question - -**activeShortcut**: `string`, The text for the new shortcut. Usually this is null to clear info which was previously -set from an IPC call. - -**activeShortcutDetails**: `string`, Parameters for the shortcut action - - - -### setFindDetail(frameKey, findDetail) - -Dispatches a message to set the find-in-page details. - -**Parameters** - -**frameKey**: `Object`, Frame key of the frame in question - -**findDetail**: `Object`, the find details - - - -### addBookmark() - -Used for displaying bookmark hanger -when adding bookmark site or folder - - - -### editBookmark() - -Used for displaying bookmark hanger -when editing bookmark site or folder - - - -### onBookmarkClose() - -Used for closing a bookmark dialog - - - -### setContextMenuDetail(detail) - -Dispatches a message to set context menu detail. -If set, also indicates that the context menu is shown. - -**Parameters** - -**detail**: `Object`, The context menu detail - - - -### setPopupWindowDetail(detail) - -Dispatches a message to set popup window detail. -If set, also indicates that the popup window is shown. - -**Parameters** - -**detail**: `Object`, The popup window detail - - - -### setAudioMuted(frameKey, tabId, muted) - -Dispatches a message to indicate that the frame should be muted - -**Parameters** - -**frameKey**: `number`, Key of the frame in question - -**tabId**: `number`, Id of the tab in question - -**muted**: `boolean`, true if the frame is muted - - - -### muteAllAudio(frameList) - -Dispatches a mute/unmute call to all frames in a provided list. - -**Parameters** - -**frameList**: `Object`, List of frames to consider (frameKey and tabId) - - - -### setAudioPlaybackActive(frameProps, audioPlaybackActive) - -Dispatches a message to indicate that audio is playing - -**Parameters** - -**frameProps**: `Object`, Properties of the frame in question - -**audioPlaybackActive**: `boolean`, true if audio is playing in the frame - - - -### setThemeColor(frameProps, themeColor, computedThemeColor) - -Dispatches a message to indicate that the theme color has changed for a page - -**Parameters** - -**frameProps**: `Object`, Properties of the frame in question - -**themeColor**: `string`, Theme color of the frame - -**computedThemeColor**: `string`, Computed theme color of the - frame which is used if no frame color is present - - - -### setFavicon(frameProps, favicon) - -Dispatches a message to indicate that the favicon has changed - -**Parameters** - -**frameProps**: `Object`, Properties of the frame in question - -**favicon**: `string`, A url to the favicon to use - - - -### setLastZoomPercentage(frameProps, percentage) - -Dispatches a message to store the last zoom percentage. -This is mainly just used to trigger updates throughout React. - -**Parameters** - -**frameProps**: `object`, The frame to set blocked info on - -**percentage**: `number`, The new zoom percentage - - - -### savePosition(position) - -Saves the position of the window in the window state - -**Parameters** - -**position**: `Array`, [x, y] - - - -### setMouseInTitlebar(mouseInTitlebar) - -Dispatches a message to indicate if the mouse is in the titlebar - -**Parameters** - -**mouseInTitlebar**: `boolean`, true if the mouse is in the titlebar - - - -### setSiteInfoVisible(isVisible) - -Dispatches a message to indicate the site info, such as # of blocked ads, should be shown - -**Parameters** - -**isVisible**: `boolean`, true if the site info should be shown - - - -### setBraveryPanelDetail(braveryPanelDetail) - -Dispatches a message to indicate the bravery panel should be shown - -**Parameters** - -**braveryPanelDetail**: `Object`, Details about how to show the bravery panel. - Set to undefined to hide the panel. See state documentation for more info. - - - -### setDownloadsToolbarVisible(isVisible) - -Dispatches a message to indicate if the downloads toolbar is visible - -**Parameters** - -**isVisible**: `boolean`, true if the site info should be shown - - - -### setReleaseNotesVisible(isVisible) - -Dispatches a message to indicate the release notes should be visible - -**Parameters** - -**isVisible**: `boolean`, true if the site info should be shown - - - -### setLinkHoverPreview(href, showOnRight) - -Dispatches a message to indicate the href preview should be shown -for a hovered link - -**Parameters** - -**href**: `string`, the href of the link - -**showOnRight**: `boolean`, display in the right corner - - - -### setBlockedBy(tabId, blockType, location) - -Dispatches a message to indicate the site info, such as # of blocked ads, should be shown - -**Parameters** - -**tabId**: `object`, Tab id for the frame to set blocked info on - -**blockType**: `string`, type of the block - -**location**: `string`, URL that was blocked - - - -### setRedirectedBy(tabId, ruleset, location) - -Similar to setBlockedBy but for httpse redirects - -**Parameters** - -**tabId**: `Object`, Tab id of the frame to set blocked info on - -**ruleset**: `string`, Name of the HTTPS Everywhere ruleset XML file - -**location**: `string`, URL that was redirected - - - -### setNoScriptVisible(isVisible) - -Sets/toggles whether the noscriptinfo dialog is visible. - -**Parameters** - -**isVisible**: `boolean`, if undefined, toggle the current state - - - -### addHistory(frameProps) - -Adds a history entry - -**Parameters** - -**frameProps**: `Object`, The frame properties to change history for. - - - -### setClearBrowsingDataPanelVisible(isVisible) - -Sets whether the clear browsing data popup is visible - -**Parameters** - -**isVisible**: `boolean`, Sets whether the clear browsing data popup is visible - - - -### setImportBrowserDataDetail(importBrowserDataDetail) - -Sets the import browser data popup detail - -**Parameters** - -**importBrowserDataDetail**: `Array`, list of supported browsers - - - -### setImportBrowserDataSelected(selected) - -Sets the selected import browser data - -**Parameters** - -**selected**: `Object`, selected browser data to import - - - -### widevinePanelDetailChanged(widevinePanelDetail) - -Widevine popup detail changed - -**Parameters** - -**widevinePanelDetail**: `Object`, detail of the widevine panel - - - -### setAutofillAddressDetail(property, newValue, wholeObject) - -Sets the manage autofill address popup detail - -**Parameters** - -**property**: `string`, Property that we want change - -**newValue**: `string`, New value for this property - -**wholeObject**: `Object`, Whole object of address detail - - - -### setAutofillCreditCardDetail(property, newValue, wholeObject) - -Sets the manage autofill credit card popup detail - -**Parameters** - -**property**: `string`, Property that we want change - -**newValue**: `string`, New value for this property - -**wholeObject**: `Object`, Whole object of credit card detail - - - -### setBlockedRunInsecureContent(frameProps, source) - -Sets source of blocked active mixed content. - -**Parameters** - -**frameProps**: `Object`, The frame to set source of -blocked active mixed content on - -**source**: `string`, Source of blocked active mixed content - - - -### toggleMenubarVisible(isVisible) - -(Windows only) -Dispatches a message to indicate the custom rendered Menubar should be toggled (shown/hidden) - -**Parameters** - -**isVisible**: `boolean`, (optional) - - - -### clickMenubarSubmenu(label) - -(Windows only) -Used to trigger the click() action for a menu -Called from the Menubar control, handled in menu.js - -**Parameters** - -**label**: `string`, text of the label that was clicked - - - -### resetMenuState() - -Used by `main.js` when click happens on content area (not on a link or react control). -- closes context menu -- closes popup menu -- nulls out menubar item selected (Windows only) -- hides menubar if auto-hide preference is set (Windows only) - - - -### setMenuBarSelectedIndex(index) - -(Windows only) -Used to track selected index of a menu bar -Needed because arrow keys can be used to navigate the custom menu - -**Parameters** - -**index**: `number`, zero based index of the item. - Index excludes menu separators and hidden items. - - - -### setContextMenuSelectedIndex(index) - -Used to track selected index of a context menu -Needed because arrow keys can be used to navigate the context menu - -**Parameters** - -**index**: `number`, zero based index of the item. - Index excludes menu separators and hidden items. - - - -### setLastFocusedSelector(selector) - -(Windows only at the moment) -Used to track last selected element (typically the URL bar or the frame) -Important because focus is lost when using the custom menu and needs -to be returned in order for the cut/copy operation to work - -**Parameters** - -**selector**: `string`, selector used w/ querySelectorAll to return focus - after a menu item is selected (via the custom titlebar / menubar) - - - -### gotResponseDetails(tabId, details) - -Used to get response details (such as the HTTP response code) from a response -See `eventStore.js` for an example use-case - -**Parameters** - -**tabId**: `number`, the tab id to set - -**details**: `Object`, object containing response details - - - -### setBookmarksToolbarSelectedFolderId(folderId) - -Fired when the mouse clicks or hovers over a bookmark folder in the bookmarks toolbar - -**Parameters** - -**folderId**: `number`, from the siteDetail for the bookmark folder - If set to null, no menu is open. If set to -1, mouse is over a bookmark, not a folder - - - -### setModalDialogDetail(className, props) - -Set Modal Dialog detail - -**Parameters** - -**className**: `string`, name of modal dialog - -**props**: `Object`, properties of the modal dialog - - - - -* * * - - - - - - - - - - diff --git a/package.json b/package.json index 5567ff58db4..c6fe0870633 100644 --- a/package.json +++ b/package.json @@ -20,7 +20,6 @@ "clean-sb-data": "node ./tools/clean.js userData SafeBrowsingData.dat", "clean-session-store": "node ./tools/clean.js userData session-store-1", "clean-tp-data": "node ./tools/clean.js userData TrackingProtection.dat", - "docs": "jsdox js/actions/appActions.js js/actions/windowActions.js --output docs", "download-languages": "node ./tools/downloadLanguages", "download-sync-client": "node ./tools/downloadSyncClient", "electron-rebuild": "electron-rebuild", @@ -158,7 +157,6 @@ "joi": "^10.2.2", "jsdom": "9.4.1", "jsdom-global": "2.0.0", - "jsdox": "^0.4.9", "json-loader": "^0.5.4", "jsonfile": "^2.2.3", "less": "^2.5.3", @@ -219,9 +217,7 @@ ] }, "pre-commit": { - "run": [ - "docs" - ], + "run": [], "template": "COMMIT_TEMPLATE" }, "pre-push": {