类型 AlertDialogOptions

API 文档由 Go 源码生成,内容为英文。

type AlertDialogOptions struct {
	Layer    uint16
	Scope    ui.ID
	ActionID ui.ID
	CancelID ui.ID
	Size     AlertDialogSize
	// ActionVariant styles the confirming button; the zero value is the default
	// (primary) one. A confirmation of something that cannot be undone passes
	// ButtonDestructive. The cancel button is always the outline variant.
	ActionVariant ButtonVariant
	// ContentSize.Width defaults to 512 (320 for AlertDialogSmall). A zero
	// ContentSize.Height sizes a dialog without media to its title, description
	// and buttons, so a plain confirmation has no empty body above its footer;
	// set it to leave room for custom body UI, or to size a dialog with media.
	ContentSize ui.Size
	// ButtonSize sizes the two buttons and the footer with them; the zero value
	// is ButtonSizeDefault.
	ButtonSize ButtonSize
	// InitialFocusID names the control that takes focus when the confirmation
	// opens. Zero leaves focus where the runtime puts it.
	InitialFocusID ui.ID
}

AlertDialogOptions contains caller-owned modal and action identities.