Skip to content

Commit

Permalink
update chromium revision
Browse files Browse the repository at this point in the history
  • Loading branch information
ysmood committed Apr 1, 2024
1 parent 0340433 commit 002ad72
Show file tree
Hide file tree
Showing 36 changed files with 3,970 additions and 1,620 deletions.
3 changes: 0 additions & 3 deletions .golangci.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
run:
skip-dirs-use-default: false

linters:
enable-all: true
disable:
Expand Down
8 changes: 4 additions & 4 deletions lib/launcher/revision.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

package launcher

// RevisionDefault for chromium.
const RevisionDefault = 1131657
// RevisionDefault for chromium
const RevisionDefault = 1278087

// RevisionPlaywright for arm linux.
const RevisionPlaywright = 1080
// RevisionPlaywright for arm linux
const RevisionPlaywright = 1105
4 changes: 2 additions & 2 deletions lib/proto/accessibility.go
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ type AccessibilityAXValueSource struct {
// Superseded (optional) Whether this source is superseded by a higher priority source.
Superseded bool `json:"superseded,omitempty"`

// NativeSource (optional) The native markup source for this value, e.g. a <label> element.
// NativeSource (optional) The native markup source for this value, e.g. a `<label>` element.
NativeSource AccessibilityAXValueNativeSourceType `json:"nativeSource,omitempty"`

// NativeSourceValue (optional) The value, such as a node or node list, of the native source.
Expand Down Expand Up @@ -525,7 +525,7 @@ type AccessibilityGetChildAXNodesResult struct {

// AccessibilityQueryAXTree (experimental) Query a DOM node's accessibility subtree for accessible name and role.
// This command computes the name and role for all nodes in the subtree, including those that are
// ignored for accessibility, and returns those that mactch the specified name and role. If no DOM
// ignored for accessibility, and returns those that match the specified name and role. If no DOM
// node is specified, or the DOM node does not exist, the command returns an error. If neither
// `accessibleName` or `role` is specified, it returns all the accessibility nodes in the subtree.
type AccessibilityQueryAXTree struct {
Expand Down
31 changes: 31 additions & 0 deletions lib/proto/animation.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,9 @@ type AnimationAnimation struct {
PlaybackRate float64 `json:"playbackRate"`

// StartTime `Animation`'s start time.
// Milliseconds for time based animations and
// percentage [0 - 100] for scroll driven animations
// (i.e. when viewOrScrollTimeline exists).
StartTime float64 `json:"startTime"`

// CurrentTime `Animation`'s current time.
Expand All @@ -54,6 +57,31 @@ type AnimationAnimation struct {
// CSSID (optional) A unique ID for `Animation` representing the sources that triggered this CSS
// animation/transition.
CSSID string `json:"cssId,omitempty"`

// ViewOrScrollTimeline (optional) View or scroll timeline
ViewOrScrollTimeline *AnimationViewOrScrollTimeline `json:"viewOrScrollTimeline,omitempty"`
}

// AnimationViewOrScrollTimeline Timeline instance.
type AnimationViewOrScrollTimeline struct {
// SourceNodeID (optional) Scroll container node
SourceNodeID DOMBackendNodeID `json:"sourceNodeId,omitempty"`

// StartOffset (optional) Represents the starting scroll position of the timeline
// as a length offset in pixels from scroll origin.
StartOffset *float64 `json:"startOffset,omitempty"`

// EndOffset (optional) Represents the ending scroll position of the timeline
// as a length offset in pixels from scroll origin.
EndOffset *float64 `json:"endOffset,omitempty"`

// SubjectNodeID (optional) The element whose principal box's visibility in the
// scrollport defined the progress of the timeline.
// Does not exist for animations with ScrollTimeline
SubjectNodeID DOMBackendNodeID `json:"subjectNodeId,omitempty"`

// Axis Orientation of the scroll
Axis DOMScrollOrientation `json:"axis"`
}

// AnimationAnimationEffect AnimationEffect instance.
Expand All @@ -71,6 +99,9 @@ type AnimationAnimationEffect struct {
Iterations float64 `json:"iterations"`

// Duration `AnimationEffect`'s iteration duration.
// Milliseconds for time based animations and
// percentage [0 - 100] for scroll driven animations
// (i.e. when viewOrScrollTimeline exists).
Duration float64 `json:"duration"`

// Direction `AnimationEffect`'s playback direction.
Expand Down
277 changes: 232 additions & 45 deletions lib/proto/audits.go

Large diffs are not rendered by default.

172 changes: 172 additions & 0 deletions lib/proto/autofill.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,172 @@
// This file is generated by "./lib/proto/generate"

package proto

/*
Autofill
Defines commands and events for Autofill.
*/

// AutofillCreditCard ...
type AutofillCreditCard struct {
// Number 16-digit credit card number.
Number string `json:"number"`

// Name of the credit card owner.
Name string `json:"name"`

// ExpiryMonth 2-digit expiry month.
ExpiryMonth string `json:"expiryMonth"`

// ExpiryYear 4-digit expiry year.
ExpiryYear string `json:"expiryYear"`

// Cvc 3-digit card verification code.
Cvc string `json:"cvc"`
}

// AutofillAddressField ...
type AutofillAddressField struct {
// Name address field name, for example GIVEN_NAME.
Name string `json:"name"`

// Value address field value, for example Jon Doe.
Value string `json:"value"`
}

// AutofillAddressFields A list of address fields.
type AutofillAddressFields struct {
// Fields ...
Fields []*AutofillAddressField `json:"fields"`
}

// AutofillAddress ...
type AutofillAddress struct {
// Fields fields and values defining an address.
Fields []*AutofillAddressField `json:"fields"`
}

// AutofillAddressUI Defines how an address can be displayed like in chrome://settings/addresses.
// Address UI is a two dimensional array, each inner array is an "address information line", and when rendered in a UI surface should be displayed as such.
// The following address UI for instance:
// [[{name: "GIVE_NAME", value: "Jon"}, {name: "FAMILY_NAME", value: "Doe"}], [{name: "CITY", value: "Munich"}, {name: "ZIP", value: "81456"}]]
// should allow the receiver to render:
// Jon Doe
// Munich 81456.
type AutofillAddressUI struct {
// AddressFields A two dimension array containing the representation of values from an address profile.
AddressFields []*AutofillAddressFields `json:"addressFields"`
}

// AutofillFillingStrategy Specified whether a filled field was done so by using the html autocomplete attribute or autofill heuristics.
type AutofillFillingStrategy string

const (
// AutofillFillingStrategyAutocompleteAttribute enum const.
AutofillFillingStrategyAutocompleteAttribute AutofillFillingStrategy = "autocompleteAttribute"

// AutofillFillingStrategyAutofillInferred enum const.
AutofillFillingStrategyAutofillInferred AutofillFillingStrategy = "autofillInferred"
)

// AutofillFilledField ...
type AutofillFilledField struct {
// HTMLType The type of the field, e.g text, password etc.
HTMLType string `json:"htmlType"`

// ID the html id
ID string `json:"id"`

// Name the html name
Name string `json:"name"`

// Value the field value
Value string `json:"value"`

// AutofillType The actual field type, e.g FAMILY_NAME
AutofillType string `json:"autofillType"`

// FillingStrategy The filling strategy
FillingStrategy AutofillFillingStrategy `json:"fillingStrategy"`

// FrameID The frame the field belongs to
FrameID PageFrameID `json:"frameId"`

// FieldID The form field's DOM node
FieldID DOMBackendNodeID `json:"fieldId"`
}

// AutofillTrigger Trigger autofill on a form identified by the fieldId.
// If the field and related form cannot be autofilled, returns an error.
type AutofillTrigger struct {
// FieldID Identifies a field that serves as an anchor for autofill.
FieldID DOMBackendNodeID `json:"fieldId"`

// FrameID (optional) Identifies the frame that field belongs to.
FrameID PageFrameID `json:"frameId,omitempty"`

// Card Credit card information to fill out the form. Credit card data is not saved.
Card *AutofillCreditCard `json:"card"`
}

// ProtoReq name.
func (m AutofillTrigger) ProtoReq() string { return "Autofill.trigger" }

// Call sends the request.
func (m AutofillTrigger) Call(c Client) error {
return call(m.ProtoReq(), m, nil, c)
}

// AutofillSetAddresses Set addresses so that developers can verify their forms implementation.
type AutofillSetAddresses struct {
// Addresses ...
Addresses []*AutofillAddress `json:"addresses"`
}

// ProtoReq name.
func (m AutofillSetAddresses) ProtoReq() string { return "Autofill.setAddresses" }

// Call sends the request.
func (m AutofillSetAddresses) Call(c Client) error {
return call(m.ProtoReq(), m, nil, c)
}

// AutofillDisable Disables autofill domain notifications.
type AutofillDisable struct{}

// ProtoReq name.
func (m AutofillDisable) ProtoReq() string { return "Autofill.disable" }

// Call sends the request.
func (m AutofillDisable) Call(c Client) error {
return call(m.ProtoReq(), m, nil, c)
}

// AutofillEnable Enables autofill domain notifications.
type AutofillEnable struct{}

// ProtoReq name.
func (m AutofillEnable) ProtoReq() string { return "Autofill.enable" }

// Call sends the request.
func (m AutofillEnable) Call(c Client) error {
return call(m.ProtoReq(), m, nil, c)
}

// AutofillAddressFormFilled Emitted when an address form is filled.
type AutofillAddressFormFilled struct {
// FilledFields Information about the fields that were filled
FilledFields []*AutofillFilledField `json:"filledFields"`

// AddressUI An UI representation of the address used to fill the form.
// Consists of a 2D array where each child represents an address/profile line.
AddressUI *AutofillAddressUI `json:"addressUi"`
}

// ProtoEvent name.
func (evt AutofillAddressFormFilled) ProtoEvent() string {
return "Autofill.addressFormFilled"
}
29 changes: 26 additions & 3 deletions lib/proto/browser.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,9 @@ const (
// BrowserPermissionTypeBackgroundFetch enum const.
BrowserPermissionTypeBackgroundFetch BrowserPermissionType = "backgroundFetch"

// BrowserPermissionTypeCapturedSurfaceControl enum const.
BrowserPermissionTypeCapturedSurfaceControl BrowserPermissionType = "capturedSurfaceControl"

// BrowserPermissionTypeClipboardReadWrite enum const.
BrowserPermissionTypeClipboardReadWrite BrowserPermissionType = "clipboardReadWrite"

Expand Down Expand Up @@ -118,6 +121,9 @@ const (
// BrowserPermissionTypeStorageAccess enum const.
BrowserPermissionTypeStorageAccess BrowserPermissionType = "storageAccess"

// BrowserPermissionTypeSpeakerSelection enum const.
BrowserPermissionTypeSpeakerSelection BrowserPermissionType = "speakerSelection"

// BrowserPermissionTypeTopLevelStorageAccess enum const.
BrowserPermissionTypeTopLevelStorageAccess BrowserPermissionType = "topLevelStorageAccess"

Expand Down Expand Up @@ -152,7 +158,7 @@ const (
)

// BrowserPermissionDescriptor (experimental) Definition of PermissionDescriptor defined in the Permissions API:
// https://w3c.github.io/permissions/#dictdef-permissiondescriptor.
// https://w3c.github.io/permissions/#dom-permissiondescriptor.
type BrowserPermissionDescriptor struct {
// Name of permission.
// See https://cs.chromium.org/chromium/src/third_party/blink/renderer/modules/permissions/permission_descriptor.idl for valid permission names.
Expand Down Expand Up @@ -253,7 +259,7 @@ func (m BrowserGrantPermissions) Call(c Client) error {
return call(m.ProtoReq(), m, nil, c)
}

// BrowserResetPermissions (experimental) Reset all permission management for all origins.
// BrowserResetPermissions Reset all permission management for all origins.
type BrowserResetPermissions struct {
// BrowserContextID (optional) BrowserContext to reset permissions. When omitted, default browser context is used.
BrowserContextID BrowserBrowserContextID `json:"browserContextId,omitempty"`
Expand Down Expand Up @@ -288,7 +294,7 @@ const (
type BrowserSetDownloadBehavior struct {
// Behavior Whether to allow all or deny all download requests, or use default Chrome behavior if
// available (otherwise deny). |allowAndName| allows download and names files according to
// their dowmload guids.
// their download guids.
Behavior BrowserSetDownloadBehaviorBehavior `json:"behavior"`

// BrowserContextID (optional) BrowserContext to set download behavior. When omitted, default browser context is used.
Expand Down Expand Up @@ -555,6 +561,23 @@ func (m BrowserExecuteBrowserCommand) Call(c Client) error {
return call(m.ProtoReq(), m, nil, c)
}

// BrowserAddPrivacySandboxEnrollmentOverride Allows a site to use privacy sandbox features that require enrollment
// without the site actually being enrolled. Only supported on page targets.
type BrowserAddPrivacySandboxEnrollmentOverride struct {
// URL ...
URL string `json:"url"`
}

// ProtoReq name.
func (m BrowserAddPrivacySandboxEnrollmentOverride) ProtoReq() string {
return "Browser.addPrivacySandboxEnrollmentOverride"
}

// Call sends the request.
func (m BrowserAddPrivacySandboxEnrollmentOverride) Call(c Client) error {
return call(m.ProtoReq(), m, nil, c)
}

// BrowserDownloadWillBegin (experimental) Fired when page is about to start a download.
type BrowserDownloadWillBegin struct {
// FrameID Id of the frame that caused the download to begin.
Expand Down
8 changes: 7 additions & 1 deletion lib/proto/cache_storage.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,9 @@ type CacheStorageCache struct {
// StorageKey Storage key of the cache.
StorageKey string `json:"storageKey"`

// StorageBucket (optional) Storage bucket of the cache.
StorageBucket *StorageStorageBucket `json:"storageBucket,omitempty"`

// CacheName The name of the cache.
CacheName string `json:"cacheName"`
}
Expand Down Expand Up @@ -124,12 +127,15 @@ func (m CacheStorageDeleteEntry) Call(c Client) error {

// CacheStorageRequestCacheNames Requests cache names.
type CacheStorageRequestCacheNames struct {
// SecurityOrigin (optional) At least and at most one of securityOrigin, storageKey must be specified.
// SecurityOrigin (optional) At least and at most one of securityOrigin, storageKey, storageBucket must be specified.
// Security origin.
SecurityOrigin string `json:"securityOrigin,omitempty"`

// StorageKey (optional) Storage key.
StorageKey string `json:"storageKey,omitempty"`

// StorageBucket (optional) Storage bucket. If not specified, it uses the default bucket.
StorageBucket *StorageStorageBucket `json:"storageBucket,omitempty"`
}

// ProtoReq name.
Expand Down
Loading

0 comments on commit 002ad72

Please sign in to comment.