mirror of
https://github.com/eduardolat/pgbackweb.git
synced 2026-01-26 14:39:24 -06:00
30 lines
731 B
Go
30 lines
731 B
Go
package component
|
|
|
|
import (
|
|
lucide "github.com/eduardolat/gomponents-lucide"
|
|
"github.com/eduardolat/pgbackweb/internal/view/web/alpine"
|
|
"github.com/maragudk/gomponents"
|
|
"github.com/maragudk/gomponents/components"
|
|
"github.com/maragudk/gomponents/html"
|
|
)
|
|
|
|
func StarOnGithub(size size) gomponents.Node {
|
|
return html.A(
|
|
alpine.XData("alpineStarOnGithub()"),
|
|
alpine.XCloak(),
|
|
components.Classes{
|
|
"btn btn-neutral": true,
|
|
"btn-sm": size == SizeSm,
|
|
"btn-lg": size == SizeLg,
|
|
},
|
|
html.Href("https://github.com/eduardolat/pgbackweb"),
|
|
html.Target("_blank"),
|
|
lucide.Github(),
|
|
SpanText("Star on Github"),
|
|
html.Span(
|
|
alpine.XShow("stars"),
|
|
alpine.XText("'( ' + stars + ' )'"),
|
|
),
|
|
)
|
|
}
|