update

package
v0.0.0-...-23f44f6 Latest Latest
Warning

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

Go to latest
Published: Nov 25, 2022 License: BSD-3-Clause Imports: 1 Imported by: 0

Documentation

Overview

Package update provides a customizable update button

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Button

type Button struct {
	app.Compo
	ID    string // ID is the ID of the button
	Class string // Class is the string-separated list of classes to apply to the button
	Title string // Title is the title of the button
	Body  app.UI // Body is the body of the button
	// contains filtered or unexported fields
}

Button is an update button

func New

func New(id, class, title string, body app.UI) *Button

New makes a new update button with the given id, class, body, and title

func (*Button) OnAppUpdate

func (b *Button) OnAppUpdate(ctx app.Context)

OnAppUpdate is called when the app is ready for an update

func (*Button) OnClick

func (b *Button) OnClick(ctx app.Context, e app.Event)

OnClick is called when someone clicks on the update button

func (*Button) Render

func (b *Button) Render() app.UI

Render returns the UI of the update button

Jump to

Keyboard shortcuts

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