From b37d052b4f651db9af9437734490366ed53f1153 Mon Sep 17 00:00:00 2001 From: Roman Galochkin Date: Wed, 26 Feb 2020 15:33:30 +0300 Subject: [PATCH] Adds a flex --- src/DistBuilder.re | 202 +++++++++++++++++++++++++-------------------- 1 file changed, 111 insertions(+), 91 deletions(-) diff --git a/src/DistBuilder.re b/src/DistBuilder.re index b1984b11..d951856a 100644 --- a/src/DistBuilder.re +++ b/src/DistBuilder.re @@ -36,6 +36,12 @@ module FieldString = { }; }; +module Styles = { + open Css; + let row = + style([display(`flex), selector("div > div", [flex(`num(1.))])]); +}; + module FieldFloat = { [@react.component] let make = (~field, ~label) => { @@ -84,98 +90,112 @@ let make = () => { field=FormConfig.GuesstimatorString label="GuesstimatorString" /> - - E.ste}> - e |> handleChange}> - - {"Complete" |> E.ste} - - - {"LeftLimited" |> E.ste} - - - {"RightLimited" |> E.ste} - - - {"LeftAndRightLimited" |> E.ste} - - - - } - /> - - - - E.ste}> - e |> handleChange}> - - {"UnspecifiedDistribution" |> E.ste} - - - {"TimeDistribution" |> E.ste} - - - - } - /> - - E.ste}> - { - e |> handleChange; +
+
+ + E.ste}> + e |> handleChange}> + + {"Complete" |> E.ste} + + + {"LeftLimited" |> E.ste} + + + {"RightLimited" |> E.ste} + + + {"LeftAndRightLimited" |> E.ste} + + + + } + /> +
+
+
+ +
+
+
+
+ + E.ste}> + e |> handleChange}> + + {"UnspecifiedDistribution" |> E.ste} + + + {"TimeDistribution" |> E.ste} + + + + } + /> +
+
+ + E.ste}> + { + e |> handleChange; - _ => (); - }} - /> - - } - /> - - E.ste}> - e |> handleChange}> - - {"days" |> E.ste} - - - {"hours" |> E.ste} - - - {"milliseconds" |> E.ste} - - - {"minutes" |> E.ste} - - - {"months" |> E.ste} - - - {"quarters" |> E.ste} - - - {"seconds" |> E.ste} - - - {"weeks" |> E.ste} - - - {"years" |> E.ste} - - - - } - /> + _ => (); + }} + /> + + } + /> +
+
+ + E.ste}> + e |> handleChange}> + + {"days" |> E.ste} + + + {"hours" |> E.ste} + + + {"milliseconds" |> E.ste} + + + {"minutes" |> E.ste} + + + {"months" |> E.ste} + + + {"quarters" |> E.ste} + + + {"seconds" |> E.ste} + + + {"weeks" |> E.ste} + + + {"years" |> E.ste} + + + + } + /> +
+
{reform.state.formState == Submitting ? "Loading" |> E.ste