browser

package
v0.2.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 22, 2026 License: MIT Imports: 12 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package browser supplies optional browser implementations of the shared client-plugin contracts. Its minimal bundle is a distribution profile, not gateway behavior; callers may layer, replace, or omit every row.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bundle

type Bundle struct {
	Profile  plugin.Profile
	Lock     plugin.Lock
	Plan     plugin.Plan
	Manifest presentation.ClientManifest

	ModuleStore  *host.ModuleStoreFactory
	ManifestHost *host.ManifestFactory
	Shell        *host.BrowserShellFactory
}

func ComposeDeveloperBundle

func ComposeDeveloperBundle(
	profileName, catalogDigest string,
	alternatives []DeveloperImplementationAlternative,
) (*Bundle, error)

ComposeDeveloperBundle constructs the shipped WebSocket developer profile with caller-supplied, content-addressed implementation alternatives for its existing entries. Alternatives are declared in the immutable descriptor and manifest but remain unloaded until an authenticated replacement manifest selects them. This API cannot add entries or widen contracts, endpoints, permissions, or grants.

func ComposeDeveloperWebRTCBundle

func ComposeDeveloperWebRTCBundle(
	profileName, catalogDigest string,
	alternatives []DeveloperImplementationAlternative,
) (*Bundle, error)

ComposeDeveloperWebRTCBundle is the media-enabled counterpart to ComposeDeveloperBundle. It admits alternatives only for existing entries and cannot widen the locked WebRTC profile's topology or authority.

func ComposeTextBundle

func ComposeTextBundle(profileName string, extensions []ClientModule) (*Bundle, error)

ComposeTextBundle layers caller-supplied descriptor modules over the normal slots, WebSocket transport, reducer, session-configuration, and text-view providers. Extensions receive only services named by their requirements and only grants declared here; this API adds no host effect or implicit authority.

func DeveloperBundle

func DeveloperBundle() (*Bundle, error)

DeveloperBundle layers session-scoped graph inspection over the same transport, reducer, slots, and text view used by MinimalBundle. Inspection is a separate capability-bearing client plugin and can be removed without changing realtime protocol behavior or the view that renders conversation.

func DeveloperBundleWithEffectsCatalog

func DeveloperBundleWithEffectsCatalog(catalogDigest string) (*Bundle, error)

DeveloperBundleWithEffectsCatalog composes the developer WebSocket client against one exact host effect catalog. Custom host effect profiles pass the digest exposed by their EffectsFactory, so the socket cannot substitute a different declaration set after manifest verification.

func DeveloperWebRTCBundle

func DeveloperWebRTCBundle() (*Bundle, error)

DeveloperWebRTCBundle selects a native browser media provider and WebRTC transport while retaining the same reducer, views, and management client as DeveloperBundle. The profile is a lockable composition, not a transport branch inside those consumers.

func DeveloperWebRTCBundleWithEffectsCatalog

func DeveloperWebRTCBundleWithEffectsCatalog(catalogDigest string) (*Bundle, error)

DeveloperWebRTCBundleWithEffectsCatalog is the media-enabled counterpart of DeveloperBundleWithEffectsCatalog.

func MinimalBundle

func MinimalBundle() (*Bundle, error)

MinimalBundle constructs the shipped text/WebSocket client profile from independent slot, transport, reducer, and view plugins.

func ObserverDeveloperBundle

func ObserverDeveloperBundle() (*Bundle, error)

ObserverDeveloperBundle is the normal inspection and authoring composition. It deliberately omits local effects, effect declarations, artifact stores, and confirmation views: an effects-enabled deployment must select DeveloperBundle and mount an explicit receipt verifier/issuer authority.

func ObserverDeveloperWebRTCBundle

func ObserverDeveloperWebRTCBundle() (*Bundle, error)

ObserverDeveloperWebRTCBundle is the media-enabled observer composition. Like ObserverDeveloperBundle it cannot advertise or execute local effects; WebRTC media, video, diagnostics, inspection, and authoring remain separate descriptor-locked plugins.

type ClientModule

type ClientModule struct {
	Entry        string
	Entrypoint   string
	PluginName   string
	Source       []byte
	Alternatives []ClientModuleAlternative
	Provides     []plugin.Contract
	Requires     []plugin.Requirement
	StateSchema  *plugin.Contract
	Lifecycle    plugin.Lifecycle
	Permissions  []plugin.Permission
	Grants       []plugin.Permission
}

ClientModule is one caller-supplied browser plugin in a composed text client. Its exact source bytes become both the served asset identity and the implementation artifact identity. Revision is fixed at 1; changed source changes the immutable artifact and plan fingerprints.

type ClientModuleAlternative

type ClientModuleAlternative struct {
	Entrypoint string
	Source     []byte
}

ClientModuleAlternative is another immutable implementation asset admitted by the same descriptor and client plan. It is declared and content-addressed at boot, but remains unloaded and inactive until an exact candidate manifest selects and verifies it. Alternatives do not widen contracts, dependencies, or permission ceilings.

type DeveloperImplementationAlternative

type DeveloperImplementationAlternative struct {
	Entry      string
	Entrypoint string
	Source     []byte
}

DeveloperImplementationAlternative is another immutable browser module admitted for one existing entry in a composed developer profile. The entry's descriptor, dependencies, lifecycle declaration, permission ceiling, and grants remain those of the shipped profile; only exact implementation bytes and their content-addressed identity can differ.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL