      [:button {:on-click #(on-reset) :style {:margin-top "0.5em"}}
       "play again"])])
 
+(defn board-decider [{:keys [on-guess on-reset flavortext answertext]} boards choice guess]
+  [:fieldset {:on-click #(when (some? guess) (on-reset))}
+   [:legend flavortext]
+   [:div {:style {:background-color (when (some? guess)
+                                      (if (= guess (= 0 choice))
+                                        "#efe"
+                                        "#fee"))}}
+    [board-element (nth boards choice)]
+    [:span {:style {:display (when (nil? guess) "none")}}
+     (nth answertext choice)]]
+   [:div
+    (for [[value text] {true "yes" false "no"}]
+      [:button {:disabled (some? guess)
+                :on-click #(on-guess value)
+                :style {:margin-top "0.5em"}}
+       text])]
+   (when (some? guess)
+     [:button {:on-click #(on-reset)}
+      "play again"])])
+
 (defn choose-corr [x xs]
   (let [game-state (atom {})
         init-game! (fn []

                        :flavortext "Which is unbiased?"
                        :answertext (map #(str % " ●") (cons x xs))}
         boards keymap guess]))))

(defn main-page []
  (let [app-state (atom {:game nil})]

       (case (:game @app-state)
         "choose-corr" [choose-corr 0.5 [0.25 0.33 0.67 0.75]]
         "choose-bias" [choose-bias 0.5 [0.25 0.33 0.67 0.75]]
         "decide-corr" [decide-corr 0.5 [0.25 0.33 0.67 0.75]]
         "decide-bias" [decide-bias 0.5 [0.25 0.33 0.67 0.75]]
         nil)])))

(reagent/render-component [main-page]
