Documentation ¶
Overview ¶
Package page implements the Page domain. Actions and events related to the inspected page belong to the page domain.
Index ¶
- func NewClient(conn *rpcc.Conn) *domainClient
- type AdFrameExplanation
- type AdFrameStatus
- type AdFrameType
- type AddCompilationCacheArgs
- type AddScriptToEvaluateOnLoadArgs
- type AddScriptToEvaluateOnLoadReply
- type AddScriptToEvaluateOnNewDocumentArgs
- type AddScriptToEvaluateOnNewDocumentReply
- type AppManifestError
- type AppManifestParsedProperties
- type BackForwardCacheNotRestoredExplanation
- type BackForwardCacheNotRestoredExplanationTree
- type BackForwardCacheNotRestoredReason
- type BackForwardCacheNotRestoredReasonType
- type BackForwardCacheNotUsedClient
- type BackForwardCacheNotUsedReply
- type CaptureScreenshotArgs
- func (a *CaptureScreenshotArgs) SetCaptureBeyondViewport(captureBeyondViewport bool) *CaptureScreenshotArgs
- func (a *CaptureScreenshotArgs) SetClip(clip Viewport) *CaptureScreenshotArgs
- func (a *CaptureScreenshotArgs) SetFormat(format string) *CaptureScreenshotArgs
- func (a *CaptureScreenshotArgs) SetFromSurface(fromSurface bool) *CaptureScreenshotArgs
- func (a *CaptureScreenshotArgs) SetQuality(quality int) *CaptureScreenshotArgs
- type CaptureScreenshotReply
- type CaptureSnapshotArgs
- type CaptureSnapshotReply
- type ClientNavigationDisposition
- type ClientNavigationReason
- type CompilationCacheParams
- type CompilationCacheProducedClient
- type CompilationCacheProducedReply
- type CreateIsolatedWorldArgs
- type CreateIsolatedWorldReply
- type CrossOriginIsolatedContextType
- type DOMContentEventFiredClient
- type DOMContentEventFiredReply
- type DialogType
- type DocumentOpenedClient
- type DocumentOpenedReply
- type DownloadProgressClient
- type DownloadProgressReply
- type DownloadWillBeginClient
- type DownloadWillBeginReply
- type FileChooserOpenedClient
- type FileChooserOpenedReply
- type FontFamilies
- type FontSizes
- type Frame
- type FrameAttachedClient
- type FrameAttachedReply
- type FrameClearedScheduledNavigationClient
- type FrameClearedScheduledNavigationReply
- type FrameDetachedClient
- type FrameDetachedReply
- type FrameID
- type FrameNavigatedClient
- type FrameNavigatedReply
- type FrameRequestedNavigationClient
- type FrameRequestedNavigationReply
- type FrameResizedClient
- type FrameResizedReply
- type FrameResource
- type FrameResourceTree
- type FrameScheduledNavigationClient
- type FrameScheduledNavigationReply
- type FrameStartedLoadingClient
- type FrameStartedLoadingReply
- type FrameStoppedLoadingClient
- type FrameStoppedLoadingReply
- type FrameTree
- type GatedAPIFeatures
- type GenerateTestReportArgs
- type GetAppIDReply
- type GetAppManifestReply
- type GetFrameTreeReply
- type GetInstallabilityErrorsReply
- type GetLayoutMetricsReply
- type GetManifestIconsReply
- type GetNavigationHistoryReply
- type GetOriginTrialsArgs
- type GetOriginTrialsReply
- type GetPermissionsPolicyStateArgs
- type GetPermissionsPolicyStateReply
- type GetResourceContentArgs
- type GetResourceContentReply
- type GetResourceTreeReply
- type HandleJavaScriptDialogArgs
- type InstallabilityError
- type InstallabilityErrorArgument
- type InterstitialHiddenClient
- type InterstitialHiddenReply
- type InterstitialShownClient
- type InterstitialShownReply
- type JavascriptDialogClosedClient
- type JavascriptDialogClosedReply
- type JavascriptDialogOpeningClient
- type JavascriptDialogOpeningReply
- type LayoutViewport
- type LifecycleEventClient
- type LifecycleEventReply
- type LoadEventFiredClient
- type LoadEventFiredReply
- type NavigateArgs
- func (a *NavigateArgs) SetFrameID(frameID FrameID) *NavigateArgs
- func (a *NavigateArgs) SetReferrer(referrer string) *NavigateArgs
- func (a *NavigateArgs) SetReferrerPolicy(referrerPolicy ReferrerPolicy) *NavigateArgs
- func (a *NavigateArgs) SetTransitionType(transitionType TransitionType) *NavigateArgs
- type NavigateReply
- type NavigateToHistoryEntryArgs
- type NavigatedWithinDocumentClient
- type NavigatedWithinDocumentReply
- type NavigationEntry
- type NavigationType
- type OriginTrial
- type OriginTrialStatus
- type OriginTrialToken
- type OriginTrialTokenStatus
- type OriginTrialTokenWithStatus
- type OriginTrialUsageRestriction
- type PermissionsPolicyBlockLocator
- type PermissionsPolicyBlockReason
- type PermissionsPolicyFeature
- type PermissionsPolicyFeatureState
- type PrerenderAttemptCompletedClient
- type PrerenderAttemptCompletedReply
- type PrerenderFinalStatus
- type PrintToPDFArgs
- func (a *PrintToPDFArgs) SetDisplayHeaderFooter(displayHeaderFooter bool) *PrintToPDFArgs
- func (a *PrintToPDFArgs) SetFooterTemplate(footerTemplate string) *PrintToPDFArgs
- func (a *PrintToPDFArgs) SetHeaderTemplate(headerTemplate string) *PrintToPDFArgs
- func (a *PrintToPDFArgs) SetLandscape(landscape bool) *PrintToPDFArgs
- func (a *PrintToPDFArgs) SetMarginBottom(marginBottom float64) *PrintToPDFArgs
- func (a *PrintToPDFArgs) SetMarginLeft(marginLeft float64) *PrintToPDFArgs
- func (a *PrintToPDFArgs) SetMarginRight(marginRight float64) *PrintToPDFArgs
- func (a *PrintToPDFArgs) SetMarginTop(marginTop float64) *PrintToPDFArgs
- func (a *PrintToPDFArgs) SetPageRanges(pageRanges string) *PrintToPDFArgs
- func (a *PrintToPDFArgs) SetPaperHeight(paperHeight float64) *PrintToPDFArgs
- func (a *PrintToPDFArgs) SetPaperWidth(paperWidth float64) *PrintToPDFArgs
- func (a *PrintToPDFArgs) SetPreferCSSPageSize(preferCSSPageSize bool) *PrintToPDFArgs
- func (a *PrintToPDFArgs) SetPrintBackground(printBackground bool) *PrintToPDFArgs
- func (a *PrintToPDFArgs) SetScale(scale float64) *PrintToPDFArgs
- func (a *PrintToPDFArgs) SetTransferMode(transferMode string) *PrintToPDFArgs
- type PrintToPDFReply
- type ProduceCompilationCacheArgs
- type ReferrerPolicy
- type ReloadArgs
- type RemoveScriptToEvaluateOnLoadArgs
- type RemoveScriptToEvaluateOnNewDocumentArgs
- type ScreencastFrameAckArgs
- type ScreencastFrameClient
- type ScreencastFrameMetadata
- type ScreencastFrameReply
- type ScreencastVisibilityChangedClient
- type ScreencastVisibilityChangedReply
- type ScriptFontFamilies
- type ScriptIdentifier
- type SearchInResourceArgs
- type SearchInResourceReply
- type SecureContextType
- type SetAdBlockingEnabledArgs
- type SetBypassCSPArgs
- type SetDocumentContentArgs
- type SetDownloadBehaviorArgs
- type SetFontFamiliesArgs
- type SetFontSizesArgs
- type SetInterceptFileChooserDialogArgs
- type SetLifecycleEventsEnabledArgs
- type SetSPCTransactionModeArgs
- type SetWebLifecycleStateArgs
- type StartScreencastArgs
- func (a *StartScreencastArgs) SetEveryNthFrame(everyNthFrame int) *StartScreencastArgs
- func (a *StartScreencastArgs) SetFormat(format string) *StartScreencastArgs
- func (a *StartScreencastArgs) SetMaxHeight(maxHeight int) *StartScreencastArgs
- func (a *StartScreencastArgs) SetMaxWidth(maxWidth int) *StartScreencastArgs
- func (a *StartScreencastArgs) SetQuality(quality int) *StartScreencastArgs
- type TransitionType
- type Viewport
- type VisualViewport
- type WindowOpenClient
- type WindowOpenReply
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AdFrameExplanation ¶ added in v0.32.0
type AdFrameExplanation string
AdFrameExplanation
Note: This type is experimental.
const ( AdFrameExplanationNotSet AdFrameExplanation = "" AdFrameExplanationParentIsAd AdFrameExplanation = "ParentIsAd" AdFrameExplanationCreatedByAdScript AdFrameExplanation = "CreatedByAdScript" AdFrameExplanationMatchedBlockingRule AdFrameExplanation = "MatchedBlockingRule" )
AdFrameExplanation as enums.
func (AdFrameExplanation) String ¶ added in v0.32.0
func (e AdFrameExplanation) String() string
func (AdFrameExplanation) Valid ¶ added in v0.32.0
func (e AdFrameExplanation) Valid() bool
type AdFrameStatus ¶ added in v0.32.0
type AdFrameStatus struct { AdFrameType AdFrameType `json:"adFrameType"` // No description. Explanations []AdFrameExplanation `json:"explanations,omitempty"` // No description. }
AdFrameStatus Indicates whether a frame has been identified as an ad and why.
Note: This type is experimental.
type AdFrameType ¶ added in v0.31.0
type AdFrameType string
AdFrameType Indicates whether a frame has been identified as an ad.
Note: This type is experimental.
const ( AdFrameTypeNotSet AdFrameType = "" AdFrameTypeNone AdFrameType = "none" AdFrameTypeChild AdFrameType = "child" AdFrameTypeRoot AdFrameType = "root" )
AdFrameType as enums.
func (AdFrameType) String ¶ added in v0.31.0
func (e AdFrameType) String() string
func (AdFrameType) Valid ¶ added in v0.31.0
func (e AdFrameType) Valid() bool
type AddCompilationCacheArgs ¶ added in v0.18.6
type AddCompilationCacheArgs struct { URL string `json:"url"` // No description. Data []byte `json:"data"` // Base64-encoded data (Encoded as a base64 string when passed over JSON) }
AddCompilationCacheArgs represents the arguments for AddCompilationCache in the Page domain.
func NewAddCompilationCacheArgs ¶ added in v0.18.6
func NewAddCompilationCacheArgs(url string, data []byte) *AddCompilationCacheArgs
NewAddCompilationCacheArgs initializes AddCompilationCacheArgs with the required arguments.
type AddScriptToEvaluateOnLoadArgs ¶
type AddScriptToEvaluateOnLoadArgs struct {
ScriptSource string `json:"scriptSource"` // No description.
}
AddScriptToEvaluateOnLoadArgs represents the arguments for AddScriptToEvaluateOnLoad in the Page domain.
func NewAddScriptToEvaluateOnLoadArgs ¶
func NewAddScriptToEvaluateOnLoadArgs(scriptSource string) *AddScriptToEvaluateOnLoadArgs
NewAddScriptToEvaluateOnLoadArgs initializes AddScriptToEvaluateOnLoadArgs with the required arguments.
type AddScriptToEvaluateOnLoadReply ¶
type AddScriptToEvaluateOnLoadReply struct {
Identifier ScriptIdentifier `json:"identifier"` // Identifier of the added script.
}
AddScriptToEvaluateOnLoadReply represents the return values for AddScriptToEvaluateOnLoad in the Page domain.
type AddScriptToEvaluateOnNewDocumentArgs ¶
type AddScriptToEvaluateOnNewDocumentArgs struct { Source string `json:"source"` // No description. // WorldName If specified, creates an isolated world with the given // name and evaluates given script in it. This world name will be used // as the ExecutionContextDescription::name when the corresponding // event is emitted. // // Note: This property is experimental. WorldName *string `json:"worldName,omitempty"` // IncludeCommandLineAPI Specifies whether command line API should be // available to the script, defaults to false. // // Note: This property is experimental. IncludeCommandLineAPI *bool `json:"includeCommandLineAPI,omitempty"` }
AddScriptToEvaluateOnNewDocumentArgs represents the arguments for AddScriptToEvaluateOnNewDocument in the Page domain.
func NewAddScriptToEvaluateOnNewDocumentArgs ¶
func NewAddScriptToEvaluateOnNewDocumentArgs(source string) *AddScriptToEvaluateOnNewDocumentArgs
NewAddScriptToEvaluateOnNewDocumentArgs initializes AddScriptToEvaluateOnNewDocumentArgs with the required arguments.
func (*AddScriptToEvaluateOnNewDocumentArgs) SetIncludeCommandLineAPI ¶ added in v0.32.0
func (a *AddScriptToEvaluateOnNewDocumentArgs) SetIncludeCommandLineAPI(includeCommandLineAPI bool) *AddScriptToEvaluateOnNewDocumentArgs
SetIncludeCommandLineAPI sets the IncludeCommandLineAPI optional argument. Specifies whether command line API should be available to the script, defaults to false.
Note: This property is experimental.
func (*AddScriptToEvaluateOnNewDocumentArgs) SetWorldName ¶ added in v0.19.1
func (a *AddScriptToEvaluateOnNewDocumentArgs) SetWorldName(worldName string) *AddScriptToEvaluateOnNewDocumentArgs
SetWorldName sets the WorldName optional argument. If specified, creates an isolated world with the given name and evaluates given script in it. This world name will be used as the ExecutionContextDescription::name when the corresponding event is emitted.
Note: This property is experimental.
type AddScriptToEvaluateOnNewDocumentReply ¶
type AddScriptToEvaluateOnNewDocumentReply struct {
Identifier ScriptIdentifier `json:"identifier"` // Identifier of the added script.
}
AddScriptToEvaluateOnNewDocumentReply represents the return values for AddScriptToEvaluateOnNewDocument in the Page domain.
type AppManifestError ¶
type AppManifestError struct { Message string `json:"message"` // Error message. Critical int `json:"critical"` // If criticial, this is a non-recoverable parse error. Line int `json:"line"` // Error line. Column int `json:"column"` // Error column. }
AppManifestError Error while paring app manifest.
type AppManifestParsedProperties ¶ added in v0.26.0
type AppManifestParsedProperties struct {
Scope string `json:"scope"` // Computed scope value
}
AppManifestParsedProperties Parsed app manifest properties.
Note: This type is experimental.
type BackForwardCacheNotRestoredExplanation ¶ added in v0.32.0
type BackForwardCacheNotRestoredExplanation struct { Type BackForwardCacheNotRestoredReasonType `json:"type"` // Type of the reason Reason BackForwardCacheNotRestoredReason `json:"reason"` // Not restored reason Context *string `json:"context,omitempty"` // Context associated with the reason. The meaning of this context is dependent on the reason: - EmbedderExtensionSentMessageToCachedFrame: the extension ID. }
BackForwardCacheNotRestoredExplanation
Note: This type is experimental.
type BackForwardCacheNotRestoredExplanationTree ¶ added in v0.33.0
type BackForwardCacheNotRestoredExplanationTree struct { URL string `json:"url"` // URL of each frame Explanations []BackForwardCacheNotRestoredExplanation `json:"explanations"` // Not restored reasons of each frame Children []BackForwardCacheNotRestoredExplanationTree `json:"children"` // Array of children frame }
BackForwardCacheNotRestoredExplanationTree
Note: This type is experimental.
type BackForwardCacheNotRestoredReason ¶ added in v0.32.0
type BackForwardCacheNotRestoredReason string
BackForwardCacheNotRestoredReason List of not restored reasons for back-forward cache.
Note: This type is experimental.
const ( BackForwardCacheNotRestoredReasonNotSet BackForwardCacheNotRestoredReason = "" BackForwardCacheNotRestoredReasonNotPrimaryMainFrame BackForwardCacheNotRestoredReason = "NotPrimaryMainFrame" BackForwardCacheNotRestoredReasonBackForwardCacheDisabled BackForwardCacheNotRestoredReason = "BackForwardCacheDisabled" BackForwardCacheNotRestoredReasonRelatedActiveContentsExist BackForwardCacheNotRestoredReason = "RelatedActiveContentsExist" BackForwardCacheNotRestoredReasonHTTPStatusNotOK BackForwardCacheNotRestoredReason = "HTTPStatusNotOK" BackForwardCacheNotRestoredReasonSchemeNotHTTPOrHTTPS BackForwardCacheNotRestoredReason = "SchemeNotHTTPOrHTTPS" BackForwardCacheNotRestoredReasonLoading BackForwardCacheNotRestoredReason = "Loading" BackForwardCacheNotRestoredReasonWasGrantedMediaAccess BackForwardCacheNotRestoredReason = "WasGrantedMediaAccess" BackForwardCacheNotRestoredReasonDisableForRenderFrameHostCalled BackForwardCacheNotRestoredReason = "DisableForRenderFrameHostCalled" BackForwardCacheNotRestoredReasonDomainNotAllowed BackForwardCacheNotRestoredReason = "DomainNotAllowed" BackForwardCacheNotRestoredReasonHTTPMethodNotGET BackForwardCacheNotRestoredReason = "HTTPMethodNotGET" BackForwardCacheNotRestoredReasonTimeout BackForwardCacheNotRestoredReason = "Timeout" BackForwardCacheNotRestoredReasonCacheLimit BackForwardCacheNotRestoredReason = "CacheLimit" BackForwardCacheNotRestoredReasonJavaScriptExecution BackForwardCacheNotRestoredReason = "JavaScriptExecution" BackForwardCacheNotRestoredReasonRendererProcessKilled BackForwardCacheNotRestoredReason = "RendererProcessKilled" BackForwardCacheNotRestoredReasonRendererProcessCrashed BackForwardCacheNotRestoredReason = "RendererProcessCrashed" BackForwardCacheNotRestoredReasonSchedulerTrackedFeatureUsed BackForwardCacheNotRestoredReason = "SchedulerTrackedFeatureUsed" BackForwardCacheNotRestoredReasonConflictingBrowsingInstance BackForwardCacheNotRestoredReason = "ConflictingBrowsingInstance" BackForwardCacheNotRestoredReasonCacheFlushed BackForwardCacheNotRestoredReason = "CacheFlushed" BackForwardCacheNotRestoredReasonServiceWorkerVersionActivation BackForwardCacheNotRestoredReason = "ServiceWorkerVersionActivation" BackForwardCacheNotRestoredReasonSessionRestored BackForwardCacheNotRestoredReason = "SessionRestored" BackForwardCacheNotRestoredReasonServiceWorkerPostMessage BackForwardCacheNotRestoredReason = "ServiceWorkerPostMessage" BackForwardCacheNotRestoredReasonEnteredBackForwardCacheBeforeServiceWorkerHostAdded BackForwardCacheNotRestoredReason = "EnteredBackForwardCacheBeforeServiceWorkerHostAdded" BackForwardCacheNotRestoredReasonRenderFrameHostReusedSameSite BackForwardCacheNotRestoredReason = "RenderFrameHostReused_SameSite" BackForwardCacheNotRestoredReasonRenderFrameHostReusedCrossSite BackForwardCacheNotRestoredReason = "RenderFrameHostReused_CrossSite" BackForwardCacheNotRestoredReasonServiceWorkerClaim BackForwardCacheNotRestoredReason = "ServiceWorkerClaim" BackForwardCacheNotRestoredReasonIgnoreEventAndEvict BackForwardCacheNotRestoredReason = "IgnoreEventAndEvict" BackForwardCacheNotRestoredReasonHaveInnerContents BackForwardCacheNotRestoredReason = "HaveInnerContents" BackForwardCacheNotRestoredReasonTimeoutPuttingInCache BackForwardCacheNotRestoredReason = "TimeoutPuttingInCache" BackForwardCacheNotRestoredReasonBackForwardCacheDisabledByLowMemory BackForwardCacheNotRestoredReason = "BackForwardCacheDisabledByLowMemory" BackForwardCacheNotRestoredReasonBackForwardCacheDisabledByCommandLine BackForwardCacheNotRestoredReason = "BackForwardCacheDisabledByCommandLine" BackForwardCacheNotRestoredReasonNetworkRequestDatapipeDrainedAsBytesConsumer BackForwardCacheNotRestoredReason = "NetworkRequestDatapipeDrainedAsBytesConsumer" BackForwardCacheNotRestoredReasonNetworkRequestRedirected BackForwardCacheNotRestoredReason = "NetworkRequestRedirected" BackForwardCacheNotRestoredReasonNetworkRequestTimeout BackForwardCacheNotRestoredReason = "NetworkRequestTimeout" BackForwardCacheNotRestoredReasonNetworkExceedsBufferLimit BackForwardCacheNotRestoredReason = "NetworkExceedsBufferLimit" BackForwardCacheNotRestoredReasonBackForwardCacheDisabledForPrerender BackForwardCacheNotRestoredReason = "BackForwardCacheDisabledForPrerender" BackForwardCacheNotRestoredReasonUserAgentOverrideDiffers BackForwardCacheNotRestoredReason = "UserAgentOverrideDiffers" BackForwardCacheNotRestoredReasonForegroundCacheLimit BackForwardCacheNotRestoredReason = "ForegroundCacheLimit" BackForwardCacheNotRestoredReasonBrowsingInstanceNotSwapped BackForwardCacheNotRestoredReason = "BrowsingInstanceNotSwapped" BackForwardCacheNotRestoredReasonBackForwardCacheDisabledForDelegate BackForwardCacheNotRestoredReason = "BackForwardCacheDisabledForDelegate" BackForwardCacheNotRestoredReasonUnloadHandlerExistsInMainFrame BackForwardCacheNotRestoredReason = "UnloadHandlerExistsInMainFrame" BackForwardCacheNotRestoredReasonUnloadHandlerExistsInSubFrame BackForwardCacheNotRestoredReason = "UnloadHandlerExistsInSubFrame" BackForwardCacheNotRestoredReasonServiceWorkerUnregistration BackForwardCacheNotRestoredReason = "ServiceWorkerUnregistration" BackForwardCacheNotRestoredReasonCacheControlNoStore BackForwardCacheNotRestoredReason = "CacheControlNoStore" BackForwardCacheNotRestoredReasonCacheControlNoStoreCookieModified BackForwardCacheNotRestoredReason = "CacheControlNoStoreCookieModified" BackForwardCacheNotRestoredReasonCacheControlNoStoreHTTPOnlyCookieModified BackForwardCacheNotRestoredReason = "CacheControlNoStoreHTTPOnlyCookieModified" BackForwardCacheNotRestoredReasonNoResponseHead BackForwardCacheNotRestoredReason = "NoResponseHead" BackForwardCacheNotRestoredReasonUnknown BackForwardCacheNotRestoredReason = "Unknown" BackForwardCacheNotRestoredReasonErrorDocument BackForwardCacheNotRestoredReason = "ErrorDocument" BackForwardCacheNotRestoredReasonFencedFramesEmbedder BackForwardCacheNotRestoredReason = "FencedFramesEmbedder" BackForwardCacheNotRestoredReasonWebSocket BackForwardCacheNotRestoredReason = "WebSocket" BackForwardCacheNotRestoredReasonWebTransport BackForwardCacheNotRestoredReason = "WebTransport" BackForwardCacheNotRestoredReasonWebRTC BackForwardCacheNotRestoredReason = "WebRTC" BackForwardCacheNotRestoredReasonMainResourceHasCacheControlNoStore BackForwardCacheNotRestoredReason = "MainResourceHasCacheControlNoStore" BackForwardCacheNotRestoredReasonMainResourceHasCacheControlNoCache BackForwardCacheNotRestoredReason = "MainResourceHasCacheControlNoCache" BackForwardCacheNotRestoredReasonSubresourceHasCacheControlNoStore BackForwardCacheNotRestoredReason = "SubresourceHasCacheControlNoStore" BackForwardCacheNotRestoredReasonSubresourceHasCacheControlNoCache BackForwardCacheNotRestoredReason = "SubresourceHasCacheControlNoCache" BackForwardCacheNotRestoredReasonContainsPlugins BackForwardCacheNotRestoredReason = "ContainsPlugins" BackForwardCacheNotRestoredReasonDocumentLoaded BackForwardCacheNotRestoredReason = "DocumentLoaded" BackForwardCacheNotRestoredReasonDedicatedWorkerOrWorklet BackForwardCacheNotRestoredReason = "DedicatedWorkerOrWorklet" BackForwardCacheNotRestoredReasonOutstandingNetworkRequestOthers BackForwardCacheNotRestoredReason = "OutstandingNetworkRequestOthers" BackForwardCacheNotRestoredReasonOutstandingIndexedDBTransaction BackForwardCacheNotRestoredReason = "OutstandingIndexedDBTransaction" BackForwardCacheNotRestoredReasonRequestedNotificationsPermission BackForwardCacheNotRestoredReason = "RequestedNotificationsPermission" BackForwardCacheNotRestoredReasonRequestedMIDIPermission BackForwardCacheNotRestoredReason = "RequestedMIDIPermission" BackForwardCacheNotRestoredReasonRequestedAudioCapturePermission BackForwardCacheNotRestoredReason = "RequestedAudioCapturePermission" BackForwardCacheNotRestoredReasonRequestedVideoCapturePermission BackForwardCacheNotRestoredReason = "RequestedVideoCapturePermission" BackForwardCacheNotRestoredReasonRequestedBackForwardCacheBlockedSensors BackForwardCacheNotRestoredReason = "RequestedBackForwardCacheBlockedSensors" BackForwardCacheNotRestoredReasonRequestedBackgroundWorkPermission BackForwardCacheNotRestoredReason = "RequestedBackgroundWorkPermission" BackForwardCacheNotRestoredReasonBroadcastChannel BackForwardCacheNotRestoredReason = "BroadcastChannel" BackForwardCacheNotRestoredReasonIndexedDBConnection BackForwardCacheNotRestoredReason = "IndexedDBConnection" BackForwardCacheNotRestoredReasonWebXR BackForwardCacheNotRestoredReason = "WebXR" BackForwardCacheNotRestoredReasonWebLocks BackForwardCacheNotRestoredReason = "WebLocks" BackForwardCacheNotRestoredReasonWebHID BackForwardCacheNotRestoredReason = "WebHID" BackForwardCacheNotRestoredReasonRequestedStorageAccessGrant BackForwardCacheNotRestoredReason = "RequestedStorageAccessGrant" BackForwardCacheNotRestoredReasonWebNFC BackForwardCacheNotRestoredReason = "WebNfc" BackForwardCacheNotRestoredReasonOutstandingNetworkRequestFetch BackForwardCacheNotRestoredReason = "OutstandingNetworkRequestFetch" BackForwardCacheNotRestoredReasonOutstandingNetworkRequestXHR BackForwardCacheNotRestoredReason = "OutstandingNetworkRequestXHR" BackForwardCacheNotRestoredReasonAppBanner BackForwardCacheNotRestoredReason = "AppBanner" BackForwardCacheNotRestoredReasonPrinting BackForwardCacheNotRestoredReason = "Printing" BackForwardCacheNotRestoredReasonWebDatabase BackForwardCacheNotRestoredReason = "WebDatabase" BackForwardCacheNotRestoredReasonPictureInPicture BackForwardCacheNotRestoredReason = "PictureInPicture" BackForwardCacheNotRestoredReasonPortal BackForwardCacheNotRestoredReason = "Portal" BackForwardCacheNotRestoredReasonSpeechRecognizer BackForwardCacheNotRestoredReason = "SpeechRecognizer" BackForwardCacheNotRestoredReasonIdleManager BackForwardCacheNotRestoredReason = "IdleManager" BackForwardCacheNotRestoredReasonPaymentManager BackForwardCacheNotRestoredReason = "PaymentManager" BackForwardCacheNotRestoredReasonSpeechSynthesis BackForwardCacheNotRestoredReason = "SpeechSynthesis" BackForwardCacheNotRestoredReasonKeyboardLock BackForwardCacheNotRestoredReason = "KeyboardLock" BackForwardCacheNotRestoredReasonWebOTPService BackForwardCacheNotRestoredReason = "WebOTPService" BackForwardCacheNotRestoredReasonOutstandingNetworkRequestDirectSocket BackForwardCacheNotRestoredReason = "OutstandingNetworkRequestDirectSocket" BackForwardCacheNotRestoredReasonInjectedJavascript BackForwardCacheNotRestoredReason = "InjectedJavascript" BackForwardCacheNotRestoredReasonInjectedStyleSheet BackForwardCacheNotRestoredReason = "InjectedStyleSheet" BackForwardCacheNotRestoredReasonDummy BackForwardCacheNotRestoredReason = "Dummy" BackForwardCacheNotRestoredReasonContentSecurityHandler BackForwardCacheNotRestoredReason = "ContentSecurityHandler" BackForwardCacheNotRestoredReasonContentWebAuthenticationAPI BackForwardCacheNotRestoredReason = "ContentWebAuthenticationAPI" BackForwardCacheNotRestoredReasonContentFileChooser BackForwardCacheNotRestoredReason = "ContentFileChooser" BackForwardCacheNotRestoredReasonContentSerial BackForwardCacheNotRestoredReason = "ContentSerial" BackForwardCacheNotRestoredReasonContentFileSystemAccess BackForwardCacheNotRestoredReason = "ContentFileSystemAccess" BackForwardCacheNotRestoredReasonContentMediaDevicesDispatcherHost BackForwardCacheNotRestoredReason = "ContentMediaDevicesDispatcherHost" BackForwardCacheNotRestoredReasonContentWebBluetooth BackForwardCacheNotRestoredReason = "ContentWebBluetooth" BackForwardCacheNotRestoredReasonContentWebUSB BackForwardCacheNotRestoredReason = "ContentWebUSB" BackForwardCacheNotRestoredReasonContentMediaSessionService BackForwardCacheNotRestoredReason = "ContentMediaSessionService" BackForwardCacheNotRestoredReasonContentScreenReader BackForwardCacheNotRestoredReason = "ContentScreenReader" BackForwardCacheNotRestoredReasonEmbedderPopupBlockerTabHelper BackForwardCacheNotRestoredReason = "EmbedderPopupBlockerTabHelper" BackForwardCacheNotRestoredReasonEmbedderSafeBrowsingTriggeredPopupBlocker BackForwardCacheNotRestoredReason = "EmbedderSafeBrowsingTriggeredPopupBlocker" BackForwardCacheNotRestoredReasonEmbedderSafeBrowsingThreatDetails BackForwardCacheNotRestoredReason = "EmbedderSafeBrowsingThreatDetails" BackForwardCacheNotRestoredReasonEmbedderAppBannerManager BackForwardCacheNotRestoredReason = "EmbedderAppBannerManager" BackForwardCacheNotRestoredReasonEmbedderDOMDistillerViewerSource BackForwardCacheNotRestoredReason = "EmbedderDomDistillerViewerSource" BackForwardCacheNotRestoredReasonEmbedderDOMDistillerSelfDeletingRequestDelegate BackForwardCacheNotRestoredReason = "EmbedderDomDistillerSelfDeletingRequestDelegate" BackForwardCacheNotRestoredReasonEmbedderOomInterventionTabHelper BackForwardCacheNotRestoredReason = "EmbedderOomInterventionTabHelper" BackForwardCacheNotRestoredReasonEmbedderOfflinePage BackForwardCacheNotRestoredReason = "EmbedderOfflinePage" BackForwardCacheNotRestoredReasonEmbedderChromePasswordManagerClientBindCredentialManager BackForwardCacheNotRestoredReason = "EmbedderChromePasswordManagerClientBindCredentialManager" BackForwardCacheNotRestoredReasonEmbedderPermissionRequestManager BackForwardCacheNotRestoredReason = "EmbedderPermissionRequestManager" BackForwardCacheNotRestoredReasonEmbedderModalDialog BackForwardCacheNotRestoredReason = "EmbedderModalDialog" BackForwardCacheNotRestoredReasonEmbedderExtensions BackForwardCacheNotRestoredReason = "EmbedderExtensions" BackForwardCacheNotRestoredReasonEmbedderExtensionMessaging BackForwardCacheNotRestoredReason = "EmbedderExtensionMessaging" BackForwardCacheNotRestoredReasonEmbedderExtensionMessagingForOpenPort BackForwardCacheNotRestoredReason = "EmbedderExtensionMessagingForOpenPort" BackForwardCacheNotRestoredReasonEmbedderExtensionSentMessageToCachedFrame BackForwardCacheNotRestoredReason = "EmbedderExtensionSentMessageToCachedFrame" )
BackForwardCacheNotRestoredReason as enums.
func (BackForwardCacheNotRestoredReason) String ¶ added in v0.32.0
func (e BackForwardCacheNotRestoredReason) String() string
func (BackForwardCacheNotRestoredReason) Valid ¶ added in v0.32.0
func (e BackForwardCacheNotRestoredReason) Valid() bool
type BackForwardCacheNotRestoredReasonType ¶ added in v0.32.0
type BackForwardCacheNotRestoredReasonType string
BackForwardCacheNotRestoredReasonType Types of not restored reasons for back-forward cache.
Note: This type is experimental.
const ( BackForwardCacheNotRestoredReasonTypeNotSet BackForwardCacheNotRestoredReasonType = "" BackForwardCacheNotRestoredReasonTypeSupportPending BackForwardCacheNotRestoredReasonType = "SupportPending" BackForwardCacheNotRestoredReasonTypePageSupportNeeded BackForwardCacheNotRestoredReasonType = "PageSupportNeeded" BackForwardCacheNotRestoredReasonTypeCircumstantial BackForwardCacheNotRestoredReasonType = "Circumstantial" )
BackForwardCacheNotRestoredReasonType as enums.
func (BackForwardCacheNotRestoredReasonType) String ¶ added in v0.32.0
func (e BackForwardCacheNotRestoredReasonType) String() string
func (BackForwardCacheNotRestoredReasonType) Valid ¶ added in v0.32.0
func (e BackForwardCacheNotRestoredReasonType) Valid() bool
type BackForwardCacheNotUsedClient ¶ added in v0.32.0
type BackForwardCacheNotUsedClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*BackForwardCacheNotUsedReply, error) rpcc.Stream }
BackForwardCacheNotUsedClient is a client for BackForwardCacheNotUsed events. Fired for failed bfcache history navigations if BackForwardCache feature is enabled. Do not assume any ordering with the Page.frameNavigated event. This event is fired only for main-frame history navigation where the document changes (non-same-document navigations), when bfcache navigation fails.
type BackForwardCacheNotUsedReply ¶ added in v0.32.0
type BackForwardCacheNotUsedReply struct { LoaderID network.LoaderID `json:"loaderId"` // The loader id for the associated navgation. FrameID FrameID `json:"frameId"` // The frame id of the associated frame. NotRestoredExplanations []BackForwardCacheNotRestoredExplanation `json:"notRestoredExplanations"` // Array of reasons why the page could not be cached. This must not be empty. NotRestoredExplanationsTree *BackForwardCacheNotRestoredExplanationTree `json:"notRestoredExplanationsTree,omitempty"` // Tree structure of reasons why the page could not be cached for each frame. }
BackForwardCacheNotUsedReply is the reply for BackForwardCacheNotUsed events.
type CaptureScreenshotArgs ¶
type CaptureScreenshotArgs struct { // Format Image compression format (defaults to png). // // Values: "jpeg", "png", "webp". Format *string `json:"format,omitempty"` Quality *int `json:"quality,omitempty"` // Compression quality from range [0..100] (jpeg only). Clip *Viewport `json:"clip,omitempty"` // Capture the screenshot of a given region only. // FromSurface Capture the screenshot from the surface, rather than // the view. Defaults to true. // // Note: This property is experimental. FromSurface *bool `json:"fromSurface,omitempty"` // CaptureBeyondViewport Capture the screenshot beyond the viewport. // Defaults to false. // // Note: This property is experimental. CaptureBeyondViewport *bool `json:"captureBeyondViewport,omitempty"` }
CaptureScreenshotArgs represents the arguments for CaptureScreenshot in the Page domain.
func NewCaptureScreenshotArgs ¶
func NewCaptureScreenshotArgs() *CaptureScreenshotArgs
NewCaptureScreenshotArgs initializes CaptureScreenshotArgs with the required arguments.
func (*CaptureScreenshotArgs) SetCaptureBeyondViewport ¶ added in v0.31.0
func (a *CaptureScreenshotArgs) SetCaptureBeyondViewport(captureBeyondViewport bool) *CaptureScreenshotArgs
SetCaptureBeyondViewport sets the CaptureBeyondViewport optional argument. Capture the screenshot beyond the viewport. Defaults to false.
Note: This property is experimental.
func (*CaptureScreenshotArgs) SetClip ¶ added in v0.9.1
func (a *CaptureScreenshotArgs) SetClip(clip Viewport) *CaptureScreenshotArgs
SetClip sets the Clip optional argument. Capture the screenshot of a given region only.
func (*CaptureScreenshotArgs) SetFormat ¶
func (a *CaptureScreenshotArgs) SetFormat(format string) *CaptureScreenshotArgs
SetFormat sets the Format optional argument. Image compression format (defaults to png).
Values: "jpeg", "png", "webp".
func (*CaptureScreenshotArgs) SetFromSurface ¶
func (a *CaptureScreenshotArgs) SetFromSurface(fromSurface bool) *CaptureScreenshotArgs
SetFromSurface sets the FromSurface optional argument. Capture the screenshot from the surface, rather than the view. Defaults to true.
Note: This property is experimental.
func (*CaptureScreenshotArgs) SetQuality ¶
func (a *CaptureScreenshotArgs) SetQuality(quality int) *CaptureScreenshotArgs
SetQuality sets the Quality optional argument. Compression quality from range [0..100] (jpeg only).
type CaptureScreenshotReply ¶
type CaptureScreenshotReply struct {
Data []byte `json:"data"` // Base64-encoded image data. (Encoded as a base64 string when passed over JSON)
}
CaptureScreenshotReply represents the return values for CaptureScreenshot in the Page domain.
type CaptureSnapshotArgs ¶ added in v0.21.0
type CaptureSnapshotArgs struct { // Format Format (defaults to mhtml). // // Values: "mhtml". Format *string `json:"format,omitempty"` }
CaptureSnapshotArgs represents the arguments for CaptureSnapshot in the Page domain.
func NewCaptureSnapshotArgs ¶ added in v0.21.0
func NewCaptureSnapshotArgs() *CaptureSnapshotArgs
NewCaptureSnapshotArgs initializes CaptureSnapshotArgs with the required arguments.
func (*CaptureSnapshotArgs) SetFormat ¶ added in v0.21.0
func (a *CaptureSnapshotArgs) SetFormat(format string) *CaptureSnapshotArgs
SetFormat sets the Format optional argument. Format (defaults to mhtml).
Values: "mhtml".
type CaptureSnapshotReply ¶ added in v0.21.0
type CaptureSnapshotReply struct {
Data string `json:"data"` // Serialized page data.
}
CaptureSnapshotReply represents the return values for CaptureSnapshot in the Page domain.
type ClientNavigationDisposition ¶ added in v0.29.0
type ClientNavigationDisposition string
ClientNavigationDisposition
Note: This type is experimental.
const ()
ClientNavigationDisposition as enums.
func (ClientNavigationDisposition) String ¶ added in v0.29.0
func (e ClientNavigationDisposition) String() string
func (ClientNavigationDisposition) Valid ¶ added in v0.29.0
func (e ClientNavigationDisposition) Valid() bool
type ClientNavigationReason ¶ added in v0.23.0
type ClientNavigationReason string
ClientNavigationReason
Note: This type is experimental.
const ()
ClientNavigationReason as enums.
func (ClientNavigationReason) String ¶ added in v0.23.0
func (e ClientNavigationReason) String() string
func (ClientNavigationReason) Valid ¶ added in v0.23.0
func (e ClientNavigationReason) Valid() bool
type CompilationCacheParams ¶ added in v0.31.0
type CompilationCacheParams struct { URL string `json:"url"` // The URL of the script to produce a compilation cache entry for. Eager *bool `json:"eager,omitempty"` // A hint to the backend whether eager compilation is recommended. (the actual compilation mode used is upon backend discretion). }
CompilationCacheParams Per-script compilation cache parameters for `Page.produceCompilationCache`
Note: This type is experimental.
type CompilationCacheProducedClient ¶ added in v0.18.6
type CompilationCacheProducedClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*CompilationCacheProducedReply, error) rpcc.Stream }
CompilationCacheProducedClient is a client for CompilationCacheProduced events. Issued for every compilation cache generated. Is only available if Page.setGenerateCompilationCache is enabled.
type CompilationCacheProducedReply ¶ added in v0.18.6
type CompilationCacheProducedReply struct { URL string `json:"url"` // No description. Data []byte `json:"data"` // Base64-encoded data (Encoded as a base64 string when passed over JSON) }
CompilationCacheProducedReply is the reply for CompilationCacheProduced events.
type CreateIsolatedWorldArgs ¶
type CreateIsolatedWorldArgs struct { FrameID FrameID `json:"frameId"` // Id of the frame in which the isolated world should be created. WorldName *string `json:"worldName,omitempty"` // An optional name which is reported in the Execution Context. GrantUniveralAccess *bool `json:"grantUniveralAccess,omitempty"` // Whether or not universal access should be granted to the isolated world. This is a powerful option, use with caution. }
CreateIsolatedWorldArgs represents the arguments for CreateIsolatedWorld in the Page domain.
func NewCreateIsolatedWorldArgs ¶
func NewCreateIsolatedWorldArgs(frameID FrameID) *CreateIsolatedWorldArgs
NewCreateIsolatedWorldArgs initializes CreateIsolatedWorldArgs with the required arguments.
func (*CreateIsolatedWorldArgs) SetGrantUniveralAccess ¶
func (a *CreateIsolatedWorldArgs) SetGrantUniveralAccess(grantUniveralAccess bool) *CreateIsolatedWorldArgs
SetGrantUniveralAccess sets the GrantUniveralAccess optional argument. Whether or not universal access should be granted to the isolated world. This is a powerful option, use with caution.
func (*CreateIsolatedWorldArgs) SetWorldName ¶
func (a *CreateIsolatedWorldArgs) SetWorldName(worldName string) *CreateIsolatedWorldArgs
SetWorldName sets the WorldName optional argument. An optional name which is reported in the Execution Context.
type CreateIsolatedWorldReply ¶
type CreateIsolatedWorldReply struct {
ExecutionContextID runtime.ExecutionContextID `json:"executionContextId"` // Execution context of the isolated world.
}
CreateIsolatedWorldReply represents the return values for CreateIsolatedWorld in the Page domain.
type CrossOriginIsolatedContextType ¶ added in v0.31.0
type CrossOriginIsolatedContextType string
CrossOriginIsolatedContextType Indicates whether the frame is cross-origin isolated and why it is the case.
Note: This type is experimental.
const ( CrossOriginIsolatedContextTypeNotSet CrossOriginIsolatedContextType = "" CrossOriginIsolatedContextTypeIsolated CrossOriginIsolatedContextType = "Isolated" CrossOriginIsolatedContextTypeNotIsolated CrossOriginIsolatedContextType = "NotIsolated" CrossOriginIsolatedContextTypeNotIsolatedFeatureDisabled CrossOriginIsolatedContextType = "NotIsolatedFeatureDisabled" )
CrossOriginIsolatedContextType as enums.
func (CrossOriginIsolatedContextType) String ¶ added in v0.31.0
func (e CrossOriginIsolatedContextType) String() string
func (CrossOriginIsolatedContextType) Valid ¶ added in v0.31.0
func (e CrossOriginIsolatedContextType) Valid() bool
type DOMContentEventFiredClient ¶
type DOMContentEventFiredClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*DOMContentEventFiredReply, error) rpcc.Stream }
DOMContentEventFiredClient is a client for DOMContentEventFired events.
type DOMContentEventFiredReply ¶
type DOMContentEventFiredReply struct {
Timestamp network.MonotonicTime `json:"timestamp"` // No description.
}
DOMContentEventFiredReply is the reply for DOMContentEventFired events.
type DialogType ¶
type DialogType string
DialogType Javascript dialog type.
const ( DialogTypeNotSet DialogType = "" DialogTypeAlert DialogType = "alert" DialogTypeConfirm DialogType = "confirm" DialogTypePrompt DialogType = "prompt" DialogTypeBeforeunload DialogType = "beforeunload" )
DialogType as enums.
func (DialogType) String ¶
func (e DialogType) String() string
func (DialogType) Valid ¶
func (e DialogType) Valid() bool
type DocumentOpenedClient ¶ added in v0.31.0
type DocumentOpenedClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*DocumentOpenedReply, error) rpcc.Stream }
DocumentOpenedClient is a client for DocumentOpened events. Fired when opening document to write to.
type DocumentOpenedReply ¶ added in v0.31.0
type DocumentOpenedReply struct {
Frame Frame `json:"frame"` // Frame object.
}
DocumentOpenedReply is the reply for DocumentOpened events.
type DownloadProgressClient ¶ added in v0.26.0
type DownloadProgressClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*DownloadProgressReply, error) rpcc.Stream }
DownloadProgressClient is a client for DownloadProgress events. Fired when download makes progress. Last call has |done| == true. Deprecated. Use Browser.downloadProgress instead.
type DownloadProgressReply ¶ added in v0.26.0
type DownloadProgressReply struct { GUID string `json:"guid"` // Global unique identifier of the download. TotalBytes float64 `json:"totalBytes"` // Total expected bytes to download. ReceivedBytes float64 `json:"receivedBytes"` // Total bytes received. // State Download status. // // Values: "inProgress", "completed", "canceled". State string `json:"state"` }
DownloadProgressReply is the reply for DownloadProgress events.
type DownloadWillBeginClient ¶ added in v0.23.2
type DownloadWillBeginClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*DownloadWillBeginReply, error) rpcc.Stream }
DownloadWillBeginClient is a client for DownloadWillBegin events. Fired when page is about to start a download. Deprecated. Use Browser.downloadWillBegin instead.
type DownloadWillBeginReply ¶ added in v0.23.2
type DownloadWillBeginReply struct { FrameID FrameID `json:"frameId"` // Id of the frame that caused download to begin. GUID string `json:"guid"` // Global unique identifier of the download. URL string `json:"url"` // URL of the resource being downloaded. SuggestedFilename string `json:"suggestedFilename"` // Suggested file name of the resource (the actual name of the file saved on disk may differ). }
DownloadWillBeginReply is the reply for DownloadWillBegin events.
type FileChooserOpenedClient ¶ added in v0.24.1
type FileChooserOpenedClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*FileChooserOpenedReply, error) rpcc.Stream }
FileChooserOpenedClient is a client for FileChooserOpened events. Emitted only when `page.interceptFileChooser` is enabled.
type FileChooserOpenedReply ¶ added in v0.24.1
type FileChooserOpenedReply struct { // FrameID Id of the frame containing input node. // // Note: This property is experimental. FrameID FrameID `json:"frameId"` // BackendNodeID Input node id. // // Note: This property is experimental. BackendNodeID dom.BackendNodeID `json:"backendNodeId"` // Mode Input mode. // // Values: "selectSingle", "selectMultiple". Mode string `json:"mode"` }
FileChooserOpenedReply is the reply for FileChooserOpened events.
type FontFamilies ¶ added in v0.18.4
type FontFamilies struct { Standard *string `json:"standard,omitempty"` // The standard font-family. Fixed *string `json:"fixed,omitempty"` // The fixed font-family. Serif *string `json:"serif,omitempty"` // The serif font-family. SansSerif *string `json:"sansSerif,omitempty"` // The sansSerif font-family. Cursive *string `json:"cursive,omitempty"` // The cursive font-family. Fantasy *string `json:"fantasy,omitempty"` // The fantasy font-family. Math *string `json:"math,omitempty"` // The math font-family. }
FontFamilies Generic font families collection.
Note: This type is experimental.
type FontSizes ¶ added in v0.18.4
type FontSizes struct { Standard *int `json:"standard,omitempty"` // Default standard font size. Fixed *int `json:"fixed,omitempty"` // Default fixed font size. }
FontSizes Default font sizes.
Note: This type is experimental.
type Frame ¶
type Frame struct { ID FrameID `json:"id"` // Frame unique identifier. ParentID *FrameID `json:"parentId,omitempty"` // Parent frame identifier. LoaderID network.LoaderID `json:"loaderId"` // Identifier of the loader associated with this frame. Name *string `json:"name,omitempty"` // Frame's name as specified in the tag. URL string `json:"url"` // Frame document's URL without fragment. // URLFragment Frame document's URL fragment including the '#'. // // Note: This property is experimental. URLFragment *string `json:"urlFragment,omitempty"` // DomainAndRegistry Frame document's registered domain, taking the // public suffixes list into account. Extracted from the Frame's url. // Example URLs: http://www.google.com/file.html -> "google.com" // http://a.b.co.uk/file.html -> "b.co.uk" // // Note: This property is experimental. DomainAndRegistry string `json:"domainAndRegistry"` SecurityOrigin string `json:"securityOrigin"` // Frame document's security origin. MimeType string `json:"mimeType"` // Frame document's mimeType as determined by the browser. // UnreachableURL If the frame failed to load, this contains the URL // that could not be loaded. Note that unlike url above, this URL may // contain a fragment. // // Note: This property is experimental. UnreachableURL *string `json:"unreachableUrl,omitempty"` // AdFrameStatus Indicates whether this frame was tagged as an ad and // why. // // Note: This property is experimental. AdFrameStatus *AdFrameStatus `json:"adFrameStatus,omitempty"` // SecureContextType Indicates whether the main document is a secure // context and explains why that is the case. // // Note: This property is experimental. SecureContextType SecureContextType `json:"secureContextType"` // CrossOriginIsolatedContextType Indicates whether this is a cross // origin isolated context. // // Note: This property is experimental. CrossOriginIsolatedContextType CrossOriginIsolatedContextType `json:"crossOriginIsolatedContextType"` // GatedAPIFeatures Indicated which gated APIs / features are // available. // // Note: This property is experimental. GatedAPIFeatures []GatedAPIFeatures `json:"gatedAPIFeatures"` }
Frame Information about the Frame on the page.
type FrameAttachedClient ¶
type FrameAttachedClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*FrameAttachedReply, error) rpcc.Stream }
FrameAttachedClient is a client for FrameAttached events. Fired when frame has been attached to its parent.
type FrameAttachedReply ¶
type FrameAttachedReply struct { FrameID FrameID `json:"frameId"` // Id of the frame that has been attached. ParentFrameID FrameID `json:"parentFrameId"` // Parent frame identifier. Stack *runtime.StackTrace `json:"stack,omitempty"` // JavaScript stack trace of when frame was attached, only set if frame initiated from script. }
FrameAttachedReply is the reply for FrameAttached events.
type FrameClearedScheduledNavigationClient ¶
type FrameClearedScheduledNavigationClient interface { // triggered, context canceled or connection closed. Recv() (*FrameClearedScheduledNavigationReply, error) rpcc.Stream }
FrameClearedScheduledNavigationClient is a client for FrameClearedScheduledNavigation events. Fired when frame no longer has a scheduled navigation.
type FrameClearedScheduledNavigationReply ¶
type FrameClearedScheduledNavigationReply struct {
}FrameClearedScheduledNavigationReply is the reply for FrameClearedScheduledNavigation events.
type FrameDetachedClient ¶
type FrameDetachedClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*FrameDetachedReply, error) rpcc.Stream }
FrameDetachedClient is a client for FrameDetached events. Fired when frame has been detached from its parent.
type FrameDetachedReply ¶
type FrameDetachedReply struct { FrameID FrameID `json:"frameId"` // Id of the frame that has been detached. // Reason // // Values: "remove", "swap". // // Note: This property is experimental. Reason string `json:"reason"` }
FrameDetachedReply is the reply for FrameDetached events.
type FrameNavigatedClient ¶
type FrameNavigatedClient interface { // triggered, context canceled or connection closed. Recv() (*FrameNavigatedReply, error) rpcc.Stream }
FrameNavigatedClient is a client for FrameNavigated events. Fired once navigation of the frame has completed. Frame is now associated with the new loader.
type FrameNavigatedReply ¶
type FrameNavigatedReply struct { // // Note: This property is experimental. Type NavigationType `json:"type"` }
FrameNavigatedReply is the reply for FrameNavigated events.
type FrameRequestedNavigationClient ¶ added in v0.23.0
type FrameRequestedNavigationClient interface { // triggered, context canceled or connection closed. Recv() (*FrameRequestedNavigationReply, error) rpcc.Stream }
FrameRequestedNavigationClient is a client for FrameRequestedNavigation events. Fired when a renderer-initiated navigation is requested. Navigation may still be canceled after the event is issued.
type FrameRequestedNavigationReply ¶ added in v0.23.0
type FrameRequestedNavigationReply struct {}
FrameRequestedNavigationReply is the reply for FrameRequestedNavigation events.
type FrameResizedClient ¶
type FrameResizedClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*FrameResizedReply, error) rpcc.Stream }
FrameResizedClient is a client for FrameResized events.
type FrameResizedReply ¶
type FrameResizedReply struct { }
FrameResizedReply is the reply for FrameResized events.
type FrameResource ¶
type FrameResource struct { URL string `json:"url"` // Resource URL. Type network.ResourceType `json:"type"` // Type of this resource. MimeType string `json:"mimeType"` // Resource mimeType as determined by the browser. LastModified network.TimeSinceEpoch `json:"lastModified,omitempty"` // last-modified timestamp as reported by server. ContentSize *float64 `json:"contentSize,omitempty"` // Resource content size. Failed *bool `json:"failed,omitempty"` // True if the resource failed to load. Canceled *bool `json:"canceled,omitempty"` // True if the resource was canceled during loading. }
FrameResource Information about the Resource on the page.
Note: This type is experimental.
type FrameResourceTree ¶
type FrameResourceTree struct { Frame Frame `json:"frame"` // Frame information for this tree item. ChildFrames []FrameResourceTree `json:"childFrames,omitempty"` // Child frames. Resources []FrameResource `json:"resources"` // Information about frame resources. }
FrameResourceTree Information about the Frame hierarchy along with their cached resources.
Note: This type is experimental.
type FrameScheduledNavigationClient ¶
type FrameScheduledNavigationClient interface { // triggered, context canceled or connection closed. Recv() (*FrameScheduledNavigationReply, error) rpcc.Stream }
FrameScheduledNavigationClient is a client for FrameScheduledNavigation events. Fired when frame schedules a potential navigation.
type FrameScheduledNavigationReply ¶
type FrameScheduledNavigationReply struct {}
FrameScheduledNavigationReply is the reply for FrameScheduledNavigation events.
type FrameStartedLoadingClient ¶
type FrameStartedLoadingClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*FrameStartedLoadingReply, error) rpcc.Stream }
FrameStartedLoadingClient is a client for FrameStartedLoading events. Fired when frame has started loading.
type FrameStartedLoadingReply ¶
type FrameStartedLoadingReply struct {
FrameID FrameID `json:"frameId"` // Id of the frame that has started loading.
}
FrameStartedLoadingReply is the reply for FrameStartedLoading events.
type FrameStoppedLoadingClient ¶
type FrameStoppedLoadingClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*FrameStoppedLoadingReply, error) rpcc.Stream }
FrameStoppedLoadingClient is a client for FrameStoppedLoading events. Fired when frame has stopped loading.
type FrameStoppedLoadingReply ¶
type FrameStoppedLoadingReply struct {
FrameID FrameID `json:"frameId"` // Id of the frame that has stopped loading.
}
FrameStoppedLoadingReply is the reply for FrameStoppedLoading events.
type FrameTree ¶ added in v0.14.2
type FrameTree struct { Frame Frame `json:"frame"` // Frame information for this tree item. ChildFrames []FrameTree `json:"childFrames,omitempty"` // Child frames. }
FrameTree Information about the Frame hierarchy.
type GatedAPIFeatures ¶ added in v0.31.0
type GatedAPIFeatures string
GatedAPIFeatures
Note: This type is experimental.
const ( GatedAPIFeaturesNotSet GatedAPIFeatures = "" GatedAPIFeaturesPerformanceMeasureMemory GatedAPIFeatures = "PerformanceMeasureMemory" GatedAPIFeaturesPerformanceProfile GatedAPIFeatures = "PerformanceProfile" )
GatedAPIFeatures as enums.
func (GatedAPIFeatures) String ¶ added in v0.31.0
func (e GatedAPIFeatures) String() string
func (GatedAPIFeatures) Valid ¶ added in v0.31.0
func (e GatedAPIFeatures) Valid() bool
type GenerateTestReportArgs ¶ added in v0.19.0
type GenerateTestReportArgs struct { Message string `json:"message"` // Message to be displayed in the report. Group *string `json:"group,omitempty"` // Specifies the endpoint group to deliver the report to. }
GenerateTestReportArgs represents the arguments for GenerateTestReport in the Page domain.
func NewGenerateTestReportArgs ¶ added in v0.19.0
func NewGenerateTestReportArgs(message string) *GenerateTestReportArgs
NewGenerateTestReportArgs initializes GenerateTestReportArgs with the required arguments.
func (*GenerateTestReportArgs) SetGroup ¶ added in v0.19.0
func (a *GenerateTestReportArgs) SetGroup(group string) *GenerateTestReportArgs
SetGroup sets the Group optional argument. Specifies the endpoint group to deliver the report to.
type GetAppIDReply ¶ added in v0.33.0
type GetAppIDReply struct { AppID *string `json:"appId,omitempty"` // App id, either from manifest's id attribute or computed from start_url RecommendedID *string `json:"recommendedId,omitempty"` // Recommendation for manifest's id attribute to match current id computed from start_url }
GetAppIDReply represents the return values for GetAppID in the Page domain.
type GetAppManifestReply ¶
type GetAppManifestReply struct { URL string `json:"url"` // Manifest location. Errors []AppManifestError `json:"errors"` // No description. Data *string `json:"data,omitempty"` // Manifest content. // Parsed Parsed manifest properties // // Note: This property is experimental. Parsed *AppManifestParsedProperties `json:"parsed,omitempty"` }
GetAppManifestReply represents the return values for GetAppManifest in the Page domain.
type GetFrameTreeReply ¶ added in v0.14.2
type GetFrameTreeReply struct {
FrameTree FrameTree `json:"frameTree"` // Present frame tree structure.
}
GetFrameTreeReply represents the return values for GetFrameTree in the Page domain.
type GetInstallabilityErrorsReply ¶ added in v0.23.1
type GetInstallabilityErrorsReply struct {
InstallabilityErrors []InstallabilityError `json:"installabilityErrors"` // No description.
}
GetInstallabilityErrorsReply represents the return values for GetInstallabilityErrors in the Page domain.
type GetLayoutMetricsReply ¶
type GetLayoutMetricsReply struct { // LayoutViewport is deprecated. // // Deprecated: Deprecated metrics relating to the layout viewport. Is // in device pixels. Use `cssLayoutViewport` instead. LayoutViewport LayoutViewport `json:"layoutViewport"` // VisualViewport is deprecated. // // Deprecated: Deprecated metrics relating to the visual viewport. Is // in device pixels. Use `cssVisualViewport` instead. VisualViewport VisualViewport `json:"visualViewport"` // ContentSize is deprecated. // // Deprecated: Deprecated size of scrollable area. Is in DP. Use // `cssContentSize` instead. ContentSize dom.Rect `json:"contentSize"` CSSLayoutViewport LayoutViewport `json:"cssLayoutViewport"` // Metrics relating to the layout viewport in CSS pixels. CSSVisualViewport VisualViewport `json:"cssVisualViewport"` // Metrics relating to the visual viewport in CSS pixels. CSSContentSize dom.Rect `json:"cssContentSize"` // Size of scrollable area in CSS pixels. }
GetLayoutMetricsReply represents the return values for GetLayoutMetrics in the Page domain.
type GetManifestIconsReply ¶ added in v0.26.0
type GetManifestIconsReply struct {
PrimaryIcon *string `json:"primaryIcon,omitempty"` // No description.
}
GetManifestIconsReply represents the return values for GetManifestIcons in the Page domain.
type GetNavigationHistoryReply ¶
type GetNavigationHistoryReply struct {}
GetNavigationHistoryReply represents the return values for GetNavigationHistory in the Page domain.
type GetOriginTrialsArgs ¶ added in v0.33.0
type GetOriginTrialsArgs struct {
FrameID FrameID `json:"frameId"` // No description.
}
GetOriginTrialsArgs represents the arguments for GetOriginTrials in the Page domain.
func NewGetOriginTrialsArgs ¶ added in v0.33.0
func NewGetOriginTrialsArgs(frameID FrameID) *GetOriginTrialsArgs
NewGetOriginTrialsArgs initializes GetOriginTrialsArgs with the required arguments.
type GetOriginTrialsReply ¶ added in v0.33.0
type GetOriginTrialsReply struct {
OriginTrials []OriginTrial `json:"originTrials"` // No description.
}
GetOriginTrialsReply represents the return values for GetOriginTrials in the Page domain.
type GetPermissionsPolicyStateArgs ¶ added in v0.31.0
type GetPermissionsPolicyStateArgs struct {
FrameID FrameID `json:"frameId"` // No description.
}
GetPermissionsPolicyStateArgs represents the arguments for GetPermissionsPolicyState in the Page domain.
func NewGetPermissionsPolicyStateArgs ¶ added in v0.31.0
func NewGetPermissionsPolicyStateArgs(frameID FrameID) *GetPermissionsPolicyStateArgs
NewGetPermissionsPolicyStateArgs initializes GetPermissionsPolicyStateArgs with the required arguments.
type GetPermissionsPolicyStateReply ¶ added in v0.31.0
type GetPermissionsPolicyStateReply struct {
States []PermissionsPolicyFeatureState `json:"states"` // No description.
}
GetPermissionsPolicyStateReply represents the return values for GetPermissionsPolicyState in the Page domain.
type GetResourceContentArgs ¶
type GetResourceContentArgs struct { FrameID FrameID `json:"frameId"` // Frame id to get resource for. URL string `json:"url"` // URL of the resource to get content for. }
GetResourceContentArgs represents the arguments for GetResourceContent in the Page domain.
func NewGetResourceContentArgs ¶
func NewGetResourceContentArgs(frameID FrameID, url string) *GetResourceContentArgs
NewGetResourceContentArgs initializes GetResourceContentArgs with the required arguments.
type GetResourceContentReply ¶
type GetResourceContentReply struct { Content string `json:"content"` // Resource content. Base64Encoded bool `json:"base64Encoded"` // True, if content was served as base64. }
GetResourceContentReply represents the return values for GetResourceContent in the Page domain.
type GetResourceTreeReply ¶
type GetResourceTreeReply struct {
FrameTree FrameResourceTree `json:"frameTree"` // Present frame / resource tree structure.
}
GetResourceTreeReply represents the return values for GetResourceTree in the Page domain.
type HandleJavaScriptDialogArgs ¶
type HandleJavaScriptDialogArgs struct { Accept bool `json:"accept"` // Whether to accept or dismiss the dialog. PromptText *string `json:"promptText,omitempty"` // The text to enter into the dialog prompt before accepting. Used only if this is a prompt dialog. }
HandleJavaScriptDialogArgs represents the arguments for HandleJavaScriptDialog in the Page domain.
func NewHandleJavaScriptDialogArgs ¶
func NewHandleJavaScriptDialogArgs(accept bool) *HandleJavaScriptDialogArgs
NewHandleJavaScriptDialogArgs initializes HandleJavaScriptDialogArgs with the required arguments.
func (*HandleJavaScriptDialogArgs) SetPromptText ¶
func (a *HandleJavaScriptDialogArgs) SetPromptText(promptText string) *HandleJavaScriptDialogArgs
SetPromptText sets the PromptText optional argument. The text to enter into the dialog prompt before accepting. Used only if this is a prompt dialog.
type InstallabilityError ¶ added in v0.26.0
type InstallabilityError struct { ErrorID string `json:"errorId"` // The error id (e.g. 'manifest-missing-suitable-icon'). ErrorArguments []InstallabilityErrorArgument `json:"errorArguments"` // The list of error arguments (e.g. {name:'minimum-icon-size-in-pixels', value:'64'}). }
InstallabilityError The installability error
Note: This type is experimental.
type InstallabilityErrorArgument ¶ added in v0.26.0
type InstallabilityErrorArgument struct { Name string `json:"name"` // Argument name (e.g. name:'minimum-icon-size-in-pixels'). Value string `json:"value"` // Argument value (e.g. value:'64'). }
InstallabilityErrorArgument
Note: This type is experimental.
type InterstitialHiddenClient ¶
type InterstitialHiddenClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*InterstitialHiddenReply, error) rpcc.Stream }
InterstitialHiddenClient is a client for InterstitialHidden events. Fired when interstitial page was hidden
type InterstitialHiddenReply ¶
type InterstitialHiddenReply struct { }
InterstitialHiddenReply is the reply for InterstitialHidden events.
type InterstitialShownClient ¶
type InterstitialShownClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*InterstitialShownReply, error) rpcc.Stream }
InterstitialShownClient is a client for InterstitialShown events. Fired when interstitial page was shown
type InterstitialShownReply ¶
type InterstitialShownReply struct { }
InterstitialShownReply is the reply for InterstitialShown events.
type JavascriptDialogClosedClient ¶
type JavascriptDialogClosedClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*JavascriptDialogClosedReply, error) rpcc.Stream }
JavascriptDialogClosedClient is a client for JavascriptDialogClosed events. Fired when a JavaScript initiated dialog (alert, confirm, prompt, or onbeforeunload) has been closed.
type JavascriptDialogClosedReply ¶
type JavascriptDialogClosedReply struct { Result bool `json:"result"` // Whether dialog was confirmed. UserInput string `json:"userInput"` // User input in case of prompt. }
JavascriptDialogClosedReply is the reply for JavascriptDialogClosed events.
type JavascriptDialogOpeningClient ¶
type JavascriptDialogOpeningClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*JavascriptDialogOpeningReply, error) rpcc.Stream }
JavascriptDialogOpeningClient is a client for JavascriptDialogOpening events. Fired when a JavaScript initiated dialog (alert, confirm, prompt, or onbeforeunload) is about to open.
type JavascriptDialogOpeningReply ¶
type JavascriptDialogOpeningReply struct { URL string `json:"url"` // Frame url. Message string `json:"message"` // Message that will be displayed by the dialog. Type DialogType `json:"type"` // Dialog type. HasBrowserHandler bool `json:"hasBrowserHandler"` // True iff browser is capable showing or acting on the given dialog. When browser has no dialog handler for given target, calling alert while Page domain is engaged will stall the page execution. Execution can be resumed via calling Page.handleJavaScriptDialog. DefaultPrompt *string `json:"defaultPrompt,omitempty"` // Default dialog prompt. }
JavascriptDialogOpeningReply is the reply for JavascriptDialogOpening events.
type LayoutViewport ¶
type LayoutViewport struct { PageX int `json:"pageX"` // Horizontal offset relative to the document (CSS pixels). PageY int `json:"pageY"` // Vertical offset relative to the document (CSS pixels). ClientWidth int `json:"clientWidth"` // Width (CSS pixels), excludes scrollbar if present. ClientHeight int `json:"clientHeight"` // Height (CSS pixels), excludes scrollbar if present. }
LayoutViewport Layout viewport position and dimensions.
type LifecycleEventClient ¶ added in v0.11.4
type LifecycleEventClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*LifecycleEventReply, error) rpcc.Stream }
LifecycleEventClient is a client for LifecycleEvent events. Fired for top level page lifecycle events such as navigation, load, paint, etc.
type LifecycleEventReply ¶ added in v0.11.4
type LifecycleEventReply struct { FrameID FrameID `json:"frameId"` // Id of the frame. LoaderID network.LoaderID `json:"loaderId"` // Loader identifier. Empty string if the request is fetched from worker. Name string `json:"name"` // No description. Timestamp network.MonotonicTime `json:"timestamp"` // No description. }
LifecycleEventReply is the reply for LifecycleEvent events.
type LoadEventFiredClient ¶
type LoadEventFiredClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*LoadEventFiredReply, error) rpcc.Stream }
LoadEventFiredClient is a client for LoadEventFired events.
type LoadEventFiredReply ¶
type LoadEventFiredReply struct {
Timestamp network.MonotonicTime `json:"timestamp"` // No description.
}
LoadEventFiredReply is the reply for LoadEventFired events.
type NavigateArgs ¶
type NavigateArgs struct { // // Note: This property is experimental. ReferrerPolicy ReferrerPolicy `json:"referrerPolicy,omitempty"` }
NavigateArgs represents the arguments for Navigate in the Page domain.
func NewNavigateArgs ¶
func NewNavigateArgs(url string) *NavigateArgs
NewNavigateArgs initializes NavigateArgs with the required arguments.
func (*NavigateArgs) SetFrameID ¶ added in v0.16.1
func (a *NavigateArgs) SetFrameID(frameID FrameID) *NavigateArgs
SetFrameID sets the FrameID optional argument. Frame id to navigate, if not specified navigates the top frame.
func (*NavigateArgs) SetReferrer ¶
func (a *NavigateArgs) SetReferrer(referrer string) *NavigateArgs
SetReferrer sets the Referrer optional argument. Referrer URL.
func (*NavigateArgs) SetReferrerPolicy ¶ added in v0.26.0
func (a *NavigateArgs) SetReferrerPolicy(referrerPolicy ReferrerPolicy) *NavigateArgs
SetReferrerPolicy sets the ReferrerPolicy optional argument. Referrer-policy used for the navigation.
Note: This property is experimental.
func (*NavigateArgs) SetTransitionType ¶
func (a *NavigateArgs) SetTransitionType(transitionType TransitionType) *NavigateArgs
SetTransitionType sets the TransitionType optional argument. Intended transition type.
type NavigateReply ¶
type NavigateReply struct {}
NavigateReply represents the return values for Navigate in the Page domain.
type NavigateToHistoryEntryArgs ¶
type NavigateToHistoryEntryArgs struct {
}NavigateToHistoryEntryArgs represents the arguments for NavigateToHistoryEntry in the Page domain.
func NewNavigateToHistoryEntryArgs ¶
func NewNavigateToHistoryEntryArgs(entryID int) *NavigateToHistoryEntryArgs
NewNavigateToHistoryEntryArgs initializes NavigateToHistoryEntryArgs with the required arguments.
type NavigatedWithinDocumentClient ¶ added in v0.17.4
type NavigatedWithinDocumentClient interface { // triggered, context canceled or connection closed. Recv() (*NavigatedWithinDocumentReply, error) rpcc.Stream }
NavigatedWithinDocumentClient is a client for NavigatedWithinDocument events. Fired when same-document navigation happens, e.g. due to history API usage or anchor navigation.
type NavigatedWithinDocumentReply ¶ added in v0.17.4
type NavigatedWithinDocumentReply struct {}
NavigatedWithinDocumentReply is the reply for NavigatedWithinDocument events.
type NavigationType ¶ added in v0.32.0
type NavigationType string
NavigationType The type of a frameNavigated event.
Note: This type is experimental.
const ()
NavigationType as enums.
func (NavigationType) String ¶ added in v0.32.0
func (e NavigationType) String() string
func (NavigationType) Valid ¶ added in v0.32.0
func (e NavigationType) Valid() bool
type OriginTrial ¶ added in v0.32.0
type OriginTrial struct { TrialName string `json:"trialName"` // No description. Status OriginTrialStatus `json:"status"` // No description. TokensWithStatus []OriginTrialTokenWithStatus `json:"tokensWithStatus"` // No description. }
OriginTrial
Note: This type is experimental.
type OriginTrialStatus ¶ added in v0.32.0
type OriginTrialStatus string
OriginTrialStatus Status for an Origin Trial.
Note: This type is experimental.
const ( OriginTrialStatusNotSet OriginTrialStatus = "" OriginTrialStatusEnabled OriginTrialStatus = "Enabled" OriginTrialStatusValidTokenNotProvided OriginTrialStatus = "ValidTokenNotProvided" OriginTrialStatusOSNotSupported OriginTrialStatus = "OSNotSupported" OriginTrialStatusTrialNotAllowed OriginTrialStatus = "TrialNotAllowed" )
OriginTrialStatus as enums.
func (OriginTrialStatus) String ¶ added in v0.32.0
func (e OriginTrialStatus) String() string
func (OriginTrialStatus) Valid ¶ added in v0.32.0
func (e OriginTrialStatus) Valid() bool
type OriginTrialToken ¶ added in v0.32.0
type OriginTrialToken struct { Origin string `json:"origin"` // No description. MatchSubDomains bool `json:"matchSubDomains"` // No description. TrialName string `json:"trialName"` // No description. ExpiryTime network.TimeSinceEpoch `json:"expiryTime"` // No description. IsThirdParty bool `json:"isThirdParty"` // No description. UsageRestriction OriginTrialUsageRestriction `json:"usageRestriction"` // No description. }
OriginTrialToken
Note: This type is experimental.
type OriginTrialTokenStatus ¶ added in v0.32.0
type OriginTrialTokenStatus string
OriginTrialTokenStatus Origin Trial(https://www.chromium.org/blink/origin-trials) support. Status for an Origin Trial token.
Note: This type is experimental.
const ( OriginTrialTokenStatusNotSet OriginTrialTokenStatus = "" OriginTrialTokenStatusSuccess OriginTrialTokenStatus = "Success" OriginTrialTokenStatusNotSupported OriginTrialTokenStatus = "NotSupported" OriginTrialTokenStatusInsecure OriginTrialTokenStatus = "Insecure" OriginTrialTokenStatusExpired OriginTrialTokenStatus = "Expired" OriginTrialTokenStatusWrongOrigin OriginTrialTokenStatus = "WrongOrigin" OriginTrialTokenStatusInvalidSignature OriginTrialTokenStatus = "InvalidSignature" OriginTrialTokenStatusMalformed OriginTrialTokenStatus = "Malformed" OriginTrialTokenStatusWrongVersion OriginTrialTokenStatus = "WrongVersion" OriginTrialTokenStatusFeatureDisabled OriginTrialTokenStatus = "FeatureDisabled" OriginTrialTokenStatusTokenDisabled OriginTrialTokenStatus = "TokenDisabled" OriginTrialTokenStatusFeatureDisabledForUser OriginTrialTokenStatus = "FeatureDisabledForUser" OriginTrialTokenStatusUnknownTrial OriginTrialTokenStatus = "UnknownTrial" )
OriginTrialTokenStatus as enums.
func (OriginTrialTokenStatus) String ¶ added in v0.32.0
func (e OriginTrialTokenStatus) String() string
func (OriginTrialTokenStatus) Valid ¶ added in v0.32.0
func (e OriginTrialTokenStatus) Valid() bool
type OriginTrialTokenWithStatus ¶ added in v0.32.0
type OriginTrialTokenWithStatus struct { RawTokenText string `json:"rawTokenText"` // No description. ParsedToken *OriginTrialToken `json:"parsedToken,omitempty"` // `parsedToken` is present only when the token is extractable and parsable. Status OriginTrialTokenStatus `json:"status"` // No description. }
OriginTrialTokenWithStatus
Note: This type is experimental.
type OriginTrialUsageRestriction ¶ added in v0.32.0
type OriginTrialUsageRestriction string
OriginTrialUsageRestriction
Note: This type is experimental.
const ( OriginTrialUsageRestrictionNotSet OriginTrialUsageRestriction = "" OriginTrialUsageRestrictionNone OriginTrialUsageRestriction = "None" OriginTrialUsageRestrictionSubset OriginTrialUsageRestriction = "Subset" )
OriginTrialUsageRestriction as enums.
func (OriginTrialUsageRestriction) String ¶ added in v0.32.0
func (e OriginTrialUsageRestriction) String() string
func (OriginTrialUsageRestriction) Valid ¶ added in v0.32.0
func (e OriginTrialUsageRestriction) Valid() bool
type PermissionsPolicyBlockLocator ¶ added in v0.31.0
type PermissionsPolicyBlockLocator struct { FrameID FrameID `json:"frameId"` // No description. BlockReason PermissionsPolicyBlockReason `json:"blockReason"` // No description. }
PermissionsPolicyBlockLocator
Note: This type is experimental.
type PermissionsPolicyBlockReason ¶ added in v0.31.0
type PermissionsPolicyBlockReason string
PermissionsPolicyBlockReason Reason for a permissions policy feature to be disabled.
Note: This type is experimental.
const ( PermissionsPolicyBlockReasonNotSet PermissionsPolicyBlockReason = "" PermissionsPolicyBlockReasonHeader PermissionsPolicyBlockReason = "Header" PermissionsPolicyBlockReasonIframeAttribute PermissionsPolicyBlockReason = "IframeAttribute" PermissionsPolicyBlockReasonInFencedFrameTree PermissionsPolicyBlockReason = "InFencedFrameTree" )
PermissionsPolicyBlockReason as enums.
func (PermissionsPolicyBlockReason) String ¶ added in v0.31.0
func (e PermissionsPolicyBlockReason) String() string
func (PermissionsPolicyBlockReason) Valid ¶ added in v0.31.0
func (e PermissionsPolicyBlockReason) Valid() bool
type PermissionsPolicyFeature ¶ added in v0.31.0
type PermissionsPolicyFeature string
PermissionsPolicyFeature All Permissions Policy features. This enum should match the one defined in third_party/blink/renderer/core/permissions_policy/permissions_policy_features.json5.
Note: This type is experimental.
const ( PermissionsPolicyFeatureNotSet PermissionsPolicyFeature = "" PermissionsPolicyFeatureAccelerometer PermissionsPolicyFeature = "accelerometer" PermissionsPolicyFeatureAmbientLightSensor PermissionsPolicyFeature = "ambient-light-sensor" PermissionsPolicyFeatureAttributionReporting PermissionsPolicyFeature = "attribution-reporting" PermissionsPolicyFeatureAutoplay PermissionsPolicyFeature = "autoplay" PermissionsPolicyFeatureBluetooth PermissionsPolicyFeature = "bluetooth" PermissionsPolicyFeatureBrowsingTopics PermissionsPolicyFeature = "browsing-topics" PermissionsPolicyFeatureCamera PermissionsPolicyFeature = "camera" PermissionsPolicyFeatureChDpr PermissionsPolicyFeature = "ch-dpr" PermissionsPolicyFeatureChDeviceMemory PermissionsPolicyFeature = "ch-device-memory" PermissionsPolicyFeatureChDownlink PermissionsPolicyFeature = "ch-downlink" PermissionsPolicyFeatureChEct PermissionsPolicyFeature = "ch-ect" PermissionsPolicyFeatureChPrefersColorScheme PermissionsPolicyFeature = "ch-prefers-color-scheme" PermissionsPolicyFeatureChRtt PermissionsPolicyFeature = "ch-rtt" PermissionsPolicyFeatureChSaveData PermissionsPolicyFeature = "ch-save-data" PermissionsPolicyFeatureChUa PermissionsPolicyFeature = "ch-ua" PermissionsPolicyFeatureChUaArch PermissionsPolicyFeature = "ch-ua-arch" PermissionsPolicyFeatureChUaBitness PermissionsPolicyFeature = "ch-ua-bitness" PermissionsPolicyFeatureChUaPlatform PermissionsPolicyFeature = "ch-ua-platform" PermissionsPolicyFeatureChUaModel PermissionsPolicyFeature = "ch-ua-model" PermissionsPolicyFeatureChUaMobile PermissionsPolicyFeature = "ch-ua-mobile" PermissionsPolicyFeatureChUaFull PermissionsPolicyFeature = "ch-ua-full" PermissionsPolicyFeatureChUaFullVersion PermissionsPolicyFeature = "ch-ua-full-version" PermissionsPolicyFeatureChUaFullVersionList PermissionsPolicyFeature = "ch-ua-full-version-list" PermissionsPolicyFeatureChUaPlatformVersion PermissionsPolicyFeature = "ch-ua-platform-version" PermissionsPolicyFeatureChUaReduced PermissionsPolicyFeature = "ch-ua-reduced" PermissionsPolicyFeatureChUaWow64 PermissionsPolicyFeature = "ch-ua-wow64" PermissionsPolicyFeatureChViewportHeight PermissionsPolicyFeature = "ch-viewport-height" PermissionsPolicyFeatureChViewportWidth PermissionsPolicyFeature = "ch-viewport-width" PermissionsPolicyFeatureChWidth PermissionsPolicyFeature = "ch-width" PermissionsPolicyFeatureClipboardRead PermissionsPolicyFeature = "clipboard-read" PermissionsPolicyFeatureClipboardWrite PermissionsPolicyFeature = "clipboard-write" PermissionsPolicyFeatureCrossOriginIsolated PermissionsPolicyFeature = "cross-origin-isolated" PermissionsPolicyFeatureDirectSockets PermissionsPolicyFeature = "direct-sockets" PermissionsPolicyFeatureDisplayCapture PermissionsPolicyFeature = "display-capture" PermissionsPolicyFeatureDocumentDomain PermissionsPolicyFeature = "document-domain" PermissionsPolicyFeatureEncryptedMedia PermissionsPolicyFeature = "encrypted-media" PermissionsPolicyFeatureExecutionWhileOutOfViewport PermissionsPolicyFeature = "execution-while-out-of-viewport" PermissionsPolicyFeatureExecutionWhileNotRendered PermissionsPolicyFeature = "execution-while-not-rendered" PermissionsPolicyFeatureFocusWithoutUserActivation PermissionsPolicyFeature = "focus-without-user-activation" PermissionsPolicyFeatureFullscreen PermissionsPolicyFeature = "fullscreen" PermissionsPolicyFeatureFrobulate PermissionsPolicyFeature = "frobulate" PermissionsPolicyFeatureGamepad PermissionsPolicyFeature = "gamepad" PermissionsPolicyFeatureGeolocation PermissionsPolicyFeature = "geolocation" PermissionsPolicyFeatureGyroscope PermissionsPolicyFeature = "gyroscope" PermissionsPolicyFeatureHid PermissionsPolicyFeature = "hid" PermissionsPolicyFeatureIdleDetection PermissionsPolicyFeature = "idle-detection" PermissionsPolicyFeatureInterestCohort PermissionsPolicyFeature = "interest-cohort" PermissionsPolicyFeatureJoinAdInterestGroup PermissionsPolicyFeature = "join-ad-interest-group" PermissionsPolicyFeatureKeyboardMap PermissionsPolicyFeature = "keyboard-map" PermissionsPolicyFeatureLocalFonts PermissionsPolicyFeature = "local-fonts" PermissionsPolicyFeatureMagnetometer PermissionsPolicyFeature = "magnetometer" PermissionsPolicyFeatureMicrophone PermissionsPolicyFeature = "microphone" PermissionsPolicyFeatureMidi PermissionsPolicyFeature = "midi" PermissionsPolicyFeatureOtpCredentials PermissionsPolicyFeature = "otp-credentials" PermissionsPolicyFeaturePayment PermissionsPolicyFeature = "payment" PermissionsPolicyFeaturePictureInPicture PermissionsPolicyFeature = "picture-in-picture" PermissionsPolicyFeaturePublickeyCredentialsGet PermissionsPolicyFeature = "publickey-credentials-get" PermissionsPolicyFeatureRunAdAuction PermissionsPolicyFeature = "run-ad-auction" PermissionsPolicyFeatureScreenWakeLock PermissionsPolicyFeature = "screen-wake-lock" PermissionsPolicyFeatureSerial PermissionsPolicyFeature = "serial" PermissionsPolicyFeatureStorageAccessAPI PermissionsPolicyFeature = "storage-access-api" PermissionsPolicyFeatureSyncXhr PermissionsPolicyFeature = "sync-xhr" PermissionsPolicyFeatureTrustTokenRedemption PermissionsPolicyFeature = "trust-token-redemption" PermissionsPolicyFeatureUSB PermissionsPolicyFeature = "usb" PermissionsPolicyFeatureVerticalScroll PermissionsPolicyFeature = "vertical-scroll" PermissionsPolicyFeatureWindowPlacement PermissionsPolicyFeature = "window-placement" PermissionsPolicyFeatureXrSpatialTracking PermissionsPolicyFeature = "xr-spatial-tracking" )
PermissionsPolicyFeature as enums.
func (PermissionsPolicyFeature) String ¶ added in v0.31.0
func (e PermissionsPolicyFeature) String() string
func (PermissionsPolicyFeature) Valid ¶ added in v0.31.0
func (e PermissionsPolicyFeature) Valid() bool
type PermissionsPolicyFeatureState ¶ added in v0.31.0
type PermissionsPolicyFeatureState struct { Feature PermissionsPolicyFeature `json:"feature"` // No description. Allowed bool `json:"allowed"` // No description. Locator *PermissionsPolicyBlockLocator `json:"locator,omitempty"` // No description. }
PermissionsPolicyFeatureState
Note: This type is experimental.
type PrerenderAttemptCompletedClient ¶ added in v0.33.0
type PrerenderAttemptCompletedClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*PrerenderAttemptCompletedReply, error) rpcc.Stream }
PrerenderAttemptCompletedClient is a client for PrerenderAttemptCompleted events. Fired when a prerender attempt is completed.
type PrerenderAttemptCompletedReply ¶ added in v0.33.0
type PrerenderAttemptCompletedReply struct { InitiatingFrameID FrameID `json:"initiatingFrameId"` // The frame id of the frame initiating prerendering. PrerenderingURL string `json:"prerenderingUrl"` // No description. FinalStatus PrerenderFinalStatus `json:"finalStatus"` // No description. }
PrerenderAttemptCompletedReply is the reply for PrerenderAttemptCompleted events.
type PrerenderFinalStatus ¶ added in v0.33.0
type PrerenderFinalStatus string
PrerenderFinalStatus List of FinalStatus reasons for Prerender2.
const ( PrerenderFinalStatusNotSet PrerenderFinalStatus = "" PrerenderFinalStatusActivated PrerenderFinalStatus = "Activated" PrerenderFinalStatusDestroyed PrerenderFinalStatus = "Destroyed" PrerenderFinalStatusLowEndDevice PrerenderFinalStatus = "LowEndDevice" PrerenderFinalStatusCrossOriginRedirect PrerenderFinalStatus = "CrossOriginRedirect" PrerenderFinalStatusInvalidSchemeRedirect PrerenderFinalStatus = "InvalidSchemeRedirect" PrerenderFinalStatusMojoBinderPolicy PrerenderFinalStatus = "MojoBinderPolicy" PrerenderFinalStatusRendererProcessCrashed PrerenderFinalStatus = "RendererProcessCrashed" PrerenderFinalStatusRendererProcessKilled PrerenderFinalStatus = "RendererProcessKilled" PrerenderFinalStatusDownload PrerenderFinalStatus = "Download" PrerenderFinalStatusTriggerDestroyed PrerenderFinalStatus = "TriggerDestroyed" PrerenderFinalStatusClientCertRequested PrerenderFinalStatus = "ClientCertRequested" PrerenderFinalStatusMaxNumOfRunningPrerendersExceeded PrerenderFinalStatus = "MaxNumOfRunningPrerendersExceeded" PrerenderFinalStatusCancelAllHostsForTesting PrerenderFinalStatus = "CancelAllHostsForTesting" PrerenderFinalStatusDidFailLoad PrerenderFinalStatus = "DidFailLoad" PrerenderFinalStatusStop PrerenderFinalStatus = "Stop" PrerenderFinalStatusSSLCertificateError PrerenderFinalStatus = "SslCertificateError" PrerenderFinalStatusLoginAuthRequested PrerenderFinalStatus = "LoginAuthRequested" PrerenderFinalStatusUaChangeRequiresReload PrerenderFinalStatus = "UaChangeRequiresReload" PrerenderFinalStatusBlockedByClient PrerenderFinalStatus = "BlockedByClient" PrerenderFinalStatusAudioOutputDeviceRequested PrerenderFinalStatus = "AudioOutputDeviceRequested" PrerenderFinalStatusMixedContent PrerenderFinalStatus = "MixedContent" PrerenderFinalStatusTriggerBackgrounded PrerenderFinalStatus = "TriggerBackgrounded" PrerenderFinalStatusEmbedderTriggeredAndSameOriginRedirected PrerenderFinalStatus = "EmbedderTriggeredAndSameOriginRedirected" PrerenderFinalStatusEmbedderTriggeredAndCrossOriginRedirected PrerenderFinalStatus = "EmbedderTriggeredAndCrossOriginRedirected" PrerenderFinalStatusEmbedderTriggeredAndDestroyed PrerenderFinalStatus = "EmbedderTriggeredAndDestroyed" )
PrerenderFinalStatus as enums.
func (PrerenderFinalStatus) String ¶ added in v0.33.0
func (e PrerenderFinalStatus) String() string
func (PrerenderFinalStatus) Valid ¶ added in v0.33.0
func (e PrerenderFinalStatus) Valid() bool
type PrintToPDFArgs ¶
type PrintToPDFArgs struct { Landscape *bool `json:"landscape,omitempty"` // Paper orientation. Defaults to false. PrintBackground *bool `json:"printBackground,omitempty"` // Print background graphics. Defaults to false. Scale *float64 `json:"scale,omitempty"` // Scale of the webpage rendering. Defaults to 1. PaperWidth *float64 `json:"paperWidth,omitempty"` // Paper width in inches. Defaults to 8.5 inches. PaperHeight *float64 `json:"paperHeight,omitempty"` // Paper height in inches. Defaults to 11 inches. MarginTop *float64 `json:"marginTop,omitempty"` // Top margin in inches. Defaults to 1cm (~0.4 inches). MarginBottom *float64 `json:"marginBottom,omitempty"` // Bottom margin in inches. Defaults to 1cm (~0.4 inches). MarginLeft *float64 `json:"marginLeft,omitempty"` // Left margin in inches. Defaults to 1cm (~0.4 inches). MarginRight *float64 `json:"marginRight,omitempty"` // Right margin in inches. Defaults to 1cm (~0.4 inches). PageRanges *string `json:"pageRanges,omitempty"` // Paper ranges to print, one based, e.g., '1-5, 8, 11-13'. Pages are printed in the document order, not in the order specified, and no more than once. Defaults to empty string, which implies the entire document is printed. The page numbers are quietly capped to actual page count of the document, and ranges beyond the end of the document are ignored. If this results in no pages to print, an error is reported. It is an error to specify a range with start greater than end. HeaderTemplate *string `json:"headerTemplate,omitempty"` // HTML template for the print header. Should be valid HTML markup with following classes used to inject printing values into them: - `date`: formatted print date - `title`: document title - `url`: document location - `pageNumber`: current page number - `totalPages`: total pages in the document For example, `<span class=title></span>` would generate span containing the title. PreferCSSPageSize *bool `json:"preferCSSPageSize,omitempty"` // Whether or not to prefer page size as defined by css. Defaults to false, in which case the content will be scaled to fit the paper size. // TransferMode return as stream // // Values: "ReturnAsBase64", "ReturnAsStream". // // Note: This property is experimental. TransferMode *string `json:"transferMode,omitempty"` }
PrintToPDFArgs represents the arguments for PrintToPDF in the Page domain.
func NewPrintToPDFArgs ¶
func NewPrintToPDFArgs() *PrintToPDFArgs
NewPrintToPDFArgs initializes PrintToPDFArgs with the required arguments.
func (*PrintToPDFArgs) SetDisplayHeaderFooter ¶
func (a *PrintToPDFArgs) SetDisplayHeaderFooter(displayHeaderFooter bool) *PrintToPDFArgs
SetDisplayHeaderFooter sets the DisplayHeaderFooter optional argument. Display header and footer. Defaults to false.
func (*PrintToPDFArgs) SetFooterTemplate ¶ added in v0.15.4
func (a *PrintToPDFArgs) SetFooterTemplate(footerTemplate string) *PrintToPDFArgs
SetFooterTemplate sets the FooterTemplate optional argument. HTML template for the print footer. Should use the same format as the `headerTemplate`.
func (*PrintToPDFArgs) SetHeaderTemplate ¶ added in v0.15.4
func (a *PrintToPDFArgs) SetHeaderTemplate(headerTemplate string) *PrintToPDFArgs
SetHeaderTemplate sets the HeaderTemplate optional argument. HTML template for the print header. Should be valid HTML markup with following classes used to inject printing values into them: - `date`: formatted print date - `title`: document title - `url`: document location - `pageNumber`: current page number - `totalPages`: total pages in the document
For example, `<span class=title></span>` would generate span containing the title.
func (*PrintToPDFArgs) SetLandscape ¶
func (a *PrintToPDFArgs) SetLandscape(landscape bool) *PrintToPDFArgs
SetLandscape sets the Landscape optional argument. Paper orientation. Defaults to false.
func (*PrintToPDFArgs) SetMarginBottom ¶
func (a *PrintToPDFArgs) SetMarginBottom(marginBottom float64) *PrintToPDFArgs
SetMarginBottom sets the MarginBottom optional argument. Bottom margin in inches. Defaults to 1cm (~0.4 inches).
func (*PrintToPDFArgs) SetMarginLeft ¶
func (a *PrintToPDFArgs) SetMarginLeft(marginLeft float64) *PrintToPDFArgs
SetMarginLeft sets the MarginLeft optional argument. Left margin in inches. Defaults to 1cm (~0.4 inches).
func (*PrintToPDFArgs) SetMarginRight ¶
func (a *PrintToPDFArgs) SetMarginRight(marginRight float64) *PrintToPDFArgs
SetMarginRight sets the MarginRight optional argument. Right margin in inches. Defaults to 1cm (~0.4 inches).
func (*PrintToPDFArgs) SetMarginTop ¶
func (a *PrintToPDFArgs) SetMarginTop(marginTop float64) *PrintToPDFArgs
SetMarginTop sets the MarginTop optional argument. Top margin in inches. Defaults to 1cm (~0.4 inches).
func (*PrintToPDFArgs) SetPageRanges ¶
func (a *PrintToPDFArgs) SetPageRanges(pageRanges string) *PrintToPDFArgs
SetPageRanges sets the PageRanges optional argument. Paper ranges to print, one based, e.g., '1-5, 8, 11-13'. Pages are printed in the document order, not in the order specified, and no more than once. Defaults to empty string, which implies the entire document is printed. The page numbers are quietly capped to actual page count of the document, and ranges beyond the end of the document are ignored. If this results in no pages to print, an error is reported. It is an error to specify a range with start greater than end.
func (*PrintToPDFArgs) SetPaperHeight ¶
func (a *PrintToPDFArgs) SetPaperHeight(paperHeight float64) *PrintToPDFArgs
SetPaperHeight sets the PaperHeight optional argument. Paper height in inches. Defaults to 11 inches.
func (*PrintToPDFArgs) SetPaperWidth ¶
func (a *PrintToPDFArgs) SetPaperWidth(paperWidth float64) *PrintToPDFArgs
SetPaperWidth sets the PaperWidth optional argument. Paper width in inches. Defaults to 8.5 inches.
func (*PrintToPDFArgs) SetPreferCSSPageSize ¶ added in v0.16.4
func (a *PrintToPDFArgs) SetPreferCSSPageSize(preferCSSPageSize bool) *PrintToPDFArgs
SetPreferCSSPageSize sets the PreferCSSPageSize optional argument. Whether or not to prefer page size as defined by css. Defaults to false, in which case the content will be scaled to fit the paper size.
func (*PrintToPDFArgs) SetPrintBackground ¶
func (a *PrintToPDFArgs) SetPrintBackground(printBackground bool) *PrintToPDFArgs
SetPrintBackground sets the PrintBackground optional argument. Print background graphics. Defaults to false.
func (*PrintToPDFArgs) SetScale ¶
func (a *PrintToPDFArgs) SetScale(scale float64) *PrintToPDFArgs
SetScale sets the Scale optional argument. Scale of the webpage rendering. Defaults to 1.
func (*PrintToPDFArgs) SetTransferMode ¶ added in v0.23.4
func (a *PrintToPDFArgs) SetTransferMode(transferMode string) *PrintToPDFArgs
SetTransferMode sets the TransferMode optional argument. return as stream
Values: "ReturnAsBase64", "ReturnAsStream".
Note: This property is experimental.
type PrintToPDFReply ¶
type PrintToPDFReply struct { Data []byte `json:"data"` // Base64-encoded pdf data. Empty if |returnAsStream| is specified. (Encoded as a base64 string when passed over JSON) // Stream A handle of the stream that holds resulting PDF data. // // Note: This property is experimental. Stream *io.StreamHandle `json:"stream,omitempty"` }
PrintToPDFReply represents the return values for PrintToPDF in the Page domain.
type ProduceCompilationCacheArgs ¶ added in v0.31.0
type ProduceCompilationCacheArgs struct {
Scripts []CompilationCacheParams `json:"scripts"` // No description.
}
ProduceCompilationCacheArgs represents the arguments for ProduceCompilationCache in the Page domain.
func NewProduceCompilationCacheArgs ¶ added in v0.31.0
func NewProduceCompilationCacheArgs(scripts []CompilationCacheParams) *ProduceCompilationCacheArgs
NewProduceCompilationCacheArgs initializes ProduceCompilationCacheArgs with the required arguments.
type ReferrerPolicy ¶ added in v0.26.0
type ReferrerPolicy string
ReferrerPolicy The referring-policy used for the navigation.
Note: This type is experimental.
const ( ReferrerPolicyNotSet ReferrerPolicy = "" ReferrerPolicyNoReferrer ReferrerPolicy = "noReferrer" ReferrerPolicyNoReferrerWhenDowngrade ReferrerPolicy = "noReferrerWhenDowngrade" ReferrerPolicyOrigin ReferrerPolicy = "origin" ReferrerPolicyOriginWhenCrossOrigin ReferrerPolicy = "originWhenCrossOrigin" ReferrerPolicySameOrigin ReferrerPolicy = "sameOrigin" ReferrerPolicyStrictOrigin ReferrerPolicy = "strictOrigin" ReferrerPolicyStrictOriginWhenCrossOrigin ReferrerPolicy = "strictOriginWhenCrossOrigin" ReferrerPolicyUnsafeURL ReferrerPolicy = "unsafeUrl" )
ReferrerPolicy as enums.
func (ReferrerPolicy) String ¶ added in v0.26.0
func (e ReferrerPolicy) String() string
func (ReferrerPolicy) Valid ¶ added in v0.26.0
func (e ReferrerPolicy) Valid() bool
type ReloadArgs ¶
type ReloadArgs struct { IgnoreCache *bool `json:"ignoreCache,omitempty"` // If true, browser cache is ignored (as if the user pressed Shift+refresh). ScriptToEvaluateOnLoad *string `json:"scriptToEvaluateOnLoad,omitempty"` // If set, the script will be injected into all frames of the inspected page after reload. Argument will be ignored if reloading dataURL origin. }
ReloadArgs represents the arguments for Reload in the Page domain.
func NewReloadArgs ¶
func NewReloadArgs() *ReloadArgs
NewReloadArgs initializes ReloadArgs with the required arguments.
func (*ReloadArgs) SetIgnoreCache ¶
func (a *ReloadArgs) SetIgnoreCache(ignoreCache bool) *ReloadArgs
SetIgnoreCache sets the IgnoreCache optional argument. If true, browser cache is ignored (as if the user pressed Shift+refresh).
func (*ReloadArgs) SetScriptToEvaluateOnLoad ¶
func (a *ReloadArgs) SetScriptToEvaluateOnLoad(scriptToEvaluateOnLoad string) *ReloadArgs
SetScriptToEvaluateOnLoad sets the ScriptToEvaluateOnLoad optional argument. If set, the script will be injected into all frames of the inspected page after reload. Argument will be ignored if reloading dataURL origin.
type RemoveScriptToEvaluateOnLoadArgs ¶
type RemoveScriptToEvaluateOnLoadArgs struct {
Identifier ScriptIdentifier `json:"identifier"` // No description.
}
RemoveScriptToEvaluateOnLoadArgs represents the arguments for RemoveScriptToEvaluateOnLoad in the Page domain.
func NewRemoveScriptToEvaluateOnLoadArgs ¶
func NewRemoveScriptToEvaluateOnLoadArgs(identifier ScriptIdentifier) *RemoveScriptToEvaluateOnLoadArgs
NewRemoveScriptToEvaluateOnLoadArgs initializes RemoveScriptToEvaluateOnLoadArgs with the required arguments.
type RemoveScriptToEvaluateOnNewDocumentArgs ¶
type RemoveScriptToEvaluateOnNewDocumentArgs struct {
Identifier ScriptIdentifier `json:"identifier"` // No description.
}
RemoveScriptToEvaluateOnNewDocumentArgs represents the arguments for RemoveScriptToEvaluateOnNewDocument in the Page domain.
func NewRemoveScriptToEvaluateOnNewDocumentArgs ¶
func NewRemoveScriptToEvaluateOnNewDocumentArgs(identifier ScriptIdentifier) *RemoveScriptToEvaluateOnNewDocumentArgs
NewRemoveScriptToEvaluateOnNewDocumentArgs initializes RemoveScriptToEvaluateOnNewDocumentArgs with the required arguments.
type ScreencastFrameAckArgs ¶
type ScreencastFrameAckArgs struct {
SessionID int `json:"sessionId"` // Frame number.
}
ScreencastFrameAckArgs represents the arguments for ScreencastFrameAck in the Page domain.
func NewScreencastFrameAckArgs ¶
func NewScreencastFrameAckArgs(sessionID int) *ScreencastFrameAckArgs
NewScreencastFrameAckArgs initializes ScreencastFrameAckArgs with the required arguments.
type ScreencastFrameClient ¶
type ScreencastFrameClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*ScreencastFrameReply, error) rpcc.Stream }
ScreencastFrameClient is a client for ScreencastFrame events. Compressed image data requested by the `startScreencast`.
type ScreencastFrameMetadata ¶
type ScreencastFrameMetadata struct { OffsetTop float64 `json:"offsetTop"` // Top offset in DIP. PageScaleFactor float64 `json:"pageScaleFactor"` // Page scale factor. DeviceWidth float64 `json:"deviceWidth"` // Device screen width in DIP. DeviceHeight float64 `json:"deviceHeight"` // Device screen height in DIP. ScrollOffsetX float64 `json:"scrollOffsetX"` // Position of horizontal scroll in CSS pixels. ScrollOffsetY float64 `json:"scrollOffsetY"` // Position of vertical scroll in CSS pixels. Timestamp network.TimeSinceEpoch `json:"timestamp,omitempty"` // Frame swap timestamp. }
ScreencastFrameMetadata Screencast frame metadata.
Note: This type is experimental.
type ScreencastFrameReply ¶
type ScreencastFrameReply struct { Data []byte `json:"data"` // Base64-encoded compressed image. (Encoded as a base64 string when passed over JSON) Metadata ScreencastFrameMetadata `json:"metadata"` // Screencast frame metadata. SessionID int `json:"sessionId"` // Frame number. }
ScreencastFrameReply is the reply for ScreencastFrame events.
type ScreencastVisibilityChangedClient ¶
type ScreencastVisibilityChangedClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*ScreencastVisibilityChangedReply, error) rpcc.Stream }
ScreencastVisibilityChangedClient is a client for ScreencastVisibilityChanged events. Fired when the page with currently enabled screencast was shown or hidden `.
type ScreencastVisibilityChangedReply ¶
type ScreencastVisibilityChangedReply struct {
Visible bool `json:"visible"` // True if the page is visible.
}
ScreencastVisibilityChangedReply is the reply for ScreencastVisibilityChanged events.
type ScriptFontFamilies ¶ added in v0.33.0
type ScriptFontFamilies struct { Script string `json:"script"` // Name of the script which these font families are defined for. FontFamilies FontFamilies `json:"fontFamilies"` // Generic font families collection for the script. }
ScriptFontFamilies Font families collection for a script.
Note: This type is experimental.
type SearchInResourceArgs ¶
type SearchInResourceArgs struct { FrameID FrameID `json:"frameId"` // Frame id for resource to search in. URL string `json:"url"` // URL of the resource to search in. Query string `json:"query"` // String to search for. CaseSensitive *bool `json:"caseSensitive,omitempty"` // If true, search is case sensitive. IsRegex *bool `json:"isRegex,omitempty"` // If true, treats string parameter as regex. }
SearchInResourceArgs represents the arguments for SearchInResource in the Page domain.
func NewSearchInResourceArgs ¶
func NewSearchInResourceArgs(frameID FrameID, url string, query string) *SearchInResourceArgs
NewSearchInResourceArgs initializes SearchInResourceArgs with the required arguments.
func (*SearchInResourceArgs) SetCaseSensitive ¶
func (a *SearchInResourceArgs) SetCaseSensitive(caseSensitive bool) *SearchInResourceArgs
SetCaseSensitive sets the CaseSensitive optional argument. If true, search is case sensitive.
func (*SearchInResourceArgs) SetIsRegex ¶
func (a *SearchInResourceArgs) SetIsRegex(isRegex bool) *SearchInResourceArgs
SetIsRegex sets the IsRegex optional argument. If true, treats string parameter as regex.
type SearchInResourceReply ¶
type SearchInResourceReply struct {
Result []debugger.SearchMatch `json:"result"` // List of search matches.
}
SearchInResourceReply represents the return values for SearchInResource in the Page domain.
type SecureContextType ¶ added in v0.31.0
type SecureContextType string
SecureContextType Indicates whether the frame is a secure context and why it is the case.
Note: This type is experimental.
const ( SecureContextTypeNotSet SecureContextType = "" SecureContextTypeSecure SecureContextType = "Secure" SecureContextTypeSecureLocalhost SecureContextType = "SecureLocalhost" SecureContextTypeInsecureScheme SecureContextType = "InsecureScheme" SecureContextTypeInsecureAncestor SecureContextType = "InsecureAncestor" )
SecureContextType as enums.
func (SecureContextType) String ¶ added in v0.31.0
func (e SecureContextType) String() string
func (SecureContextType) Valid ¶ added in v0.31.0
func (e SecureContextType) Valid() bool
type SetAdBlockingEnabledArgs ¶ added in v0.9.1
type SetAdBlockingEnabledArgs struct {
Enabled bool `json:"enabled"` // Whether to block ads.
}
SetAdBlockingEnabledArgs represents the arguments for SetAdBlockingEnabled in the Page domain.
func NewSetAdBlockingEnabledArgs ¶ added in v0.9.1
func NewSetAdBlockingEnabledArgs(enabled bool) *SetAdBlockingEnabledArgs
NewSetAdBlockingEnabledArgs initializes SetAdBlockingEnabledArgs with the required arguments.
type SetBypassCSPArgs ¶ added in v0.17.4
type SetBypassCSPArgs struct {
Enabled bool `json:"enabled"` // Whether to bypass page CSP.
}
SetBypassCSPArgs represents the arguments for SetBypassCSP in the Page domain.
func NewSetBypassCSPArgs ¶ added in v0.17.4
func NewSetBypassCSPArgs(enabled bool) *SetBypassCSPArgs
NewSetBypassCSPArgs initializes SetBypassCSPArgs with the required arguments.
type SetDocumentContentArgs ¶
type SetDocumentContentArgs struct { FrameID FrameID `json:"frameId"` // Frame id to set HTML for. HTML string `json:"html"` // HTML content to set. }
SetDocumentContentArgs represents the arguments for SetDocumentContent in the Page domain.
func NewSetDocumentContentArgs ¶
func NewSetDocumentContentArgs(frameID FrameID, html string) *SetDocumentContentArgs
NewSetDocumentContentArgs initializes SetDocumentContentArgs with the required arguments.
type SetDownloadBehaviorArgs ¶ added in v0.11.4
type SetDownloadBehaviorArgs struct { // Behavior Whether to allow all or deny all download requests, or use // default Chrome behavior if available (otherwise deny). // // Values: "deny", "allow", "default". Behavior string `json:"behavior"` DownloadPath *string `json:"downloadPath,omitempty"` // The default path to save downloaded files to. This is required if behavior is set to 'allow' }
SetDownloadBehaviorArgs represents the arguments for SetDownloadBehavior in the Page domain.
func NewSetDownloadBehaviorArgs ¶ added in v0.11.4
func NewSetDownloadBehaviorArgs(behavior string) *SetDownloadBehaviorArgs
NewSetDownloadBehaviorArgs initializes SetDownloadBehaviorArgs with the required arguments.
func (*SetDownloadBehaviorArgs) SetDownloadPath ¶ added in v0.11.4
func (a *SetDownloadBehaviorArgs) SetDownloadPath(downloadPath string) *SetDownloadBehaviorArgs
SetDownloadPath sets the DownloadPath optional argument. The default path to save downloaded files to. This is required if behavior is set to 'allow'
type SetFontFamiliesArgs ¶ added in v0.18.4
type SetFontFamiliesArgs struct { FontFamilies FontFamilies `json:"fontFamilies"` // Specifies font families to set. If a font family is not specified, it won't be changed. ForScripts []ScriptFontFamilies `json:"forScripts,omitempty"` // Specifies font families to set for individual scripts. }
SetFontFamiliesArgs represents the arguments for SetFontFamilies in the Page domain.
func NewSetFontFamiliesArgs ¶ added in v0.18.4
func NewSetFontFamiliesArgs(fontFamilies FontFamilies) *SetFontFamiliesArgs
NewSetFontFamiliesArgs initializes SetFontFamiliesArgs with the required arguments.
func (*SetFontFamiliesArgs) SetForScripts ¶ added in v0.33.0
func (a *SetFontFamiliesArgs) SetForScripts(forScripts []ScriptFontFamilies) *SetFontFamiliesArgs
SetForScripts sets the ForScripts optional argument. Specifies font families to set for individual scripts.
type SetFontSizesArgs ¶ added in v0.18.4
type SetFontSizesArgs struct {
FontSizes FontSizes `json:"fontSizes"` // Specifies font sizes to set. If a font size is not specified, it won't be changed.
}
SetFontSizesArgs represents the arguments for SetFontSizes in the Page domain.
func NewSetFontSizesArgs ¶ added in v0.18.4
func NewSetFontSizesArgs(fontSizes FontSizes) *SetFontSizesArgs
NewSetFontSizesArgs initializes SetFontSizesArgs with the required arguments.
type SetInterceptFileChooserDialogArgs ¶ added in v0.24.1
type SetInterceptFileChooserDialogArgs struct {
Enabled bool `json:"enabled"` // No description.
}
SetInterceptFileChooserDialogArgs represents the arguments for SetInterceptFileChooserDialog in the Page domain.
func NewSetInterceptFileChooserDialogArgs ¶ added in v0.24.1
func NewSetInterceptFileChooserDialogArgs(enabled bool) *SetInterceptFileChooserDialogArgs
NewSetInterceptFileChooserDialogArgs initializes SetInterceptFileChooserDialogArgs with the required arguments.
type SetLifecycleEventsEnabledArgs ¶ added in v0.14.2
type SetLifecycleEventsEnabledArgs struct {
Enabled bool `json:"enabled"` // If true, starts emitting lifecycle events.
}
SetLifecycleEventsEnabledArgs represents the arguments for SetLifecycleEventsEnabled in the Page domain.
func NewSetLifecycleEventsEnabledArgs ¶ added in v0.14.2
func NewSetLifecycleEventsEnabledArgs(enabled bool) *SetLifecycleEventsEnabledArgs
NewSetLifecycleEventsEnabledArgs initializes SetLifecycleEventsEnabledArgs with the required arguments.
type SetSPCTransactionModeArgs ¶ added in v0.33.0
type SetSPCTransactionModeArgs struct { // Mode // // Values: "none", "autoaccept", "autoreject". Mode string `json:"mode"` }
SetSPCTransactionModeArgs represents the arguments for SetSPCTransactionMode in the Page domain.
func NewSetSPCTransactionModeArgs ¶ added in v0.33.0
func NewSetSPCTransactionModeArgs(mode string) *SetSPCTransactionModeArgs
NewSetSPCTransactionModeArgs initializes SetSPCTransactionModeArgs with the required arguments.
type SetWebLifecycleStateArgs ¶ added in v0.18.1
type SetWebLifecycleStateArgs struct { // State Target lifecycle state // // Values: "frozen", "active". State string `json:"state"` }
SetWebLifecycleStateArgs represents the arguments for SetWebLifecycleState in the Page domain.
func NewSetWebLifecycleStateArgs ¶ added in v0.18.1
func NewSetWebLifecycleStateArgs(state string) *SetWebLifecycleStateArgs
NewSetWebLifecycleStateArgs initializes SetWebLifecycleStateArgs with the required arguments.
type StartScreencastArgs ¶
type StartScreencastArgs struct { // Format Image compression format. // // Values: "jpeg", "png". Format *string `json:"format,omitempty"` Quality *int `json:"quality,omitempty"` // Compression quality from range [0..100]. MaxWidth *int `json:"maxWidth,omitempty"` // Maximum screenshot width. MaxHeight *int `json:"maxHeight,omitempty"` // Maximum screenshot height. EveryNthFrame *int `json:"everyNthFrame,omitempty"` // Send every n-th frame. }
StartScreencastArgs represents the arguments for StartScreencast in the Page domain.
func NewStartScreencastArgs ¶
func NewStartScreencastArgs() *StartScreencastArgs
NewStartScreencastArgs initializes StartScreencastArgs with the required arguments.
func (*StartScreencastArgs) SetEveryNthFrame ¶
func (a *StartScreencastArgs) SetEveryNthFrame(everyNthFrame int) *StartScreencastArgs
SetEveryNthFrame sets the EveryNthFrame optional argument. Send every n-th frame.
func (*StartScreencastArgs) SetFormat ¶
func (a *StartScreencastArgs) SetFormat(format string) *StartScreencastArgs
SetFormat sets the Format optional argument. Image compression format.
Values: "jpeg", "png".
func (*StartScreencastArgs) SetMaxHeight ¶
func (a *StartScreencastArgs) SetMaxHeight(maxHeight int) *StartScreencastArgs
SetMaxHeight sets the MaxHeight optional argument. Maximum screenshot height.
func (*StartScreencastArgs) SetMaxWidth ¶
func (a *StartScreencastArgs) SetMaxWidth(maxWidth int) *StartScreencastArgs
SetMaxWidth sets the MaxWidth optional argument. Maximum screenshot width.
func (*StartScreencastArgs) SetQuality ¶
func (a *StartScreencastArgs) SetQuality(quality int) *StartScreencastArgs
SetQuality sets the Quality optional argument. Compression quality from range [0..100].
type TransitionType ¶
type TransitionType string
TransitionType Transition type.
const ( TransitionTypeNotSet TransitionType = "" TransitionTypeLink TransitionType = "link" TransitionTypeTyped TransitionType = "typed" TransitionTypeAddressBar TransitionType = "address_bar" TransitionTypeAutoBookmark TransitionType = "auto_bookmark" TransitionTypeAutoSubframe TransitionType = "auto_subframe" TransitionTypeManualSubframe TransitionType = "manual_subframe" TransitionTypeGenerated TransitionType = "generated" TransitionTypeAutoToplevel TransitionType = "auto_toplevel" TransitionTypeFormSubmit TransitionType = "form_submit" TransitionTypeReload TransitionType = "reload" TransitionTypeKeyword TransitionType = "keyword" TransitionTypeKeywordGenerated TransitionType = "keyword_generated" TransitionTypeOther TransitionType = "other" )
TransitionType as enums.
func (TransitionType) String ¶
func (e TransitionType) String() string
func (TransitionType) Valid ¶
func (e TransitionType) Valid() bool
type Viewport ¶ added in v0.9.1
type Viewport struct { X float64 `json:"x"` // X offset in device independent pixels (dip). Y float64 `json:"y"` // Y offset in device independent pixels (dip). Width float64 `json:"width"` // Rectangle width in device independent pixels (dip). Height float64 `json:"height"` // Rectangle height in device independent pixels (dip). Scale float64 `json:"scale"` // Page scale factor. }
Viewport Viewport for capturing screenshot.
type VisualViewport ¶
type VisualViewport struct { OffsetX float64 `json:"offsetX"` // Horizontal offset relative to the layout viewport (CSS pixels). OffsetY float64 `json:"offsetY"` // Vertical offset relative to the layout viewport (CSS pixels). PageX float64 `json:"pageX"` // Horizontal offset relative to the document (CSS pixels). PageY float64 `json:"pageY"` // Vertical offset relative to the document (CSS pixels). ClientWidth float64 `json:"clientWidth"` // Width (CSS pixels), excludes scrollbar if present. ClientHeight float64 `json:"clientHeight"` // Height (CSS pixels), excludes scrollbar if present. Scale float64 `json:"scale"` // Scale relative to the ideal viewport (size at width=device-width). Zoom *float64 `json:"zoom,omitempty"` // Page zoom factor (CSS to device independent pixels ratio). }
VisualViewport Visual viewport position, dimensions, and scale.
type WindowOpenClient ¶ added in v0.14.1
type WindowOpenClient interface { // Recv calls RecvMsg on rpcc.Stream, blocks until the event is // triggered, context canceled or connection closed. Recv() (*WindowOpenReply, error) rpcc.Stream }
WindowOpenClient is a client for WindowOpen events. Fired when a new window is going to be opened, via window.open(), link click, form submission, etc.
type WindowOpenReply ¶ added in v0.14.1
type WindowOpenReply struct { URL string `json:"url"` // The URL for the new window. WindowName string `json:"windowName"` // Window name. WindowFeatures []string `json:"windowFeatures"` // An array of enabled window features. UserGesture bool `json:"userGesture"` // Whether or not it was triggered by user gesture. }
WindowOpenReply is the reply for WindowOpen events.