diff --git a/components/dropdown.templ b/components/dropdown.templ index 2291729..140d886 100644 --- a/components/dropdown.templ +++ b/components/dropdown.templ @@ -1,22 +1,22 @@ package components -import "strconv" - type DropdownProps struct { Route string - Options []int + Options []string Value string } templ Dropdown(props DropdownProps) { - for _, option := range props.Options { + > + { option } + } } diff --git a/components/dropdown_templ.go b/components/dropdown_templ.go index 1404451..f535798 100644 --- a/components/dropdown_templ.go +++ b/components/dropdown_templ.go @@ -8,11 +8,9 @@ package components import "github.com/a-h/templ" import templruntime "github.com/a-h/templ/runtime" -import "strconv" - type DropdownProps struct { Route string - Options []int + Options []string Value string } @@ -34,14 +32,14 @@ func Dropdown(props DropdownProps) templ.Component { templ_7745c5c3_Var1 = templ.NopComponent } ctx = templ.ClearChildren(ctx) - _, templ_7745c5c3_Err = templ_7745c5c3_Buffer.WriteString("