diff --git a/src/cljs/auto_ap/views/components/switch_field.cljs b/src/cljs/auto_ap/views/components/switch_field.cljs new file mode 100644 index 00000000..039742db --- /dev/null +++ b/src/cljs/auto_ap/views/components/switch_field.cljs @@ -0,0 +1,6 @@ +(ns auto-ap.views.components.switch-field) + +(defn switch-field [{:keys [id label on-change checked]}] + [:<> + [:input.switch {:type "checkbox" :id id :on-change on-change :checked checked}] + [:label {:for id} label]])