26 lines
451 B
Go
26 lines
451 B
Go
// Copyright (c) 2021 David Vogel
|
|
//
|
|
// This software is released under the MIT License.
|
|
// https://opensource.org/licenses/MIT
|
|
|
|
package input
|
|
|
|
import (
|
|
"github.com/vugu/vgrouter"
|
|
"github.com/vugu/vugu"
|
|
)
|
|
|
|
type ButtonNav struct {
|
|
vgrouter.NavigatorRef
|
|
AttrMap vugu.AttrMap
|
|
|
|
SymbolSlot vugu.Builder // Slot for the symbol.
|
|
DefaultSlot vugu.Builder
|
|
|
|
URL string
|
|
}
|
|
|
|
func (c *ButtonNav) handleClick(event vugu.DOMEvent) {
|
|
c.Navigate(c.URL, nil)
|
|
}
|