Commit 3848448d authored by Alexandre Delanoë's avatar Alexandre Delanoë

[READ] cosmetics to read code.

parent 93c0523c
...@@ -25,12 +25,12 @@ data Routes ...@@ -25,12 +25,12 @@ data Routes
instance showRoutes :: Show Routes where instance showRoutes :: Show Routes where
show Home = "Home" show Home = "Home"
show Login = "Login" show Login = "Login"
show AddCorpus = "AddCorpus" show AddCorpus = "AddCorpus"
show DocView = "DocView" show DocView = "DocView"
show SearchView = "SearchView" show SearchView = "SearchView"
show UserPage = "UserPage" show UserPage = "UserPage"
int :: Match Int int :: Match Int
int = floor <$> num int = floor <$> num
...@@ -45,13 +45,13 @@ routing = ...@@ -45,13 +45,13 @@ routing =
<|> addcorpusRoute <|> addcorpusRoute
<|> home <|> home
where where
userPageRoute = UserPage <$ route "userPage" userPageRoute = UserPage <$ route "userPage"
searchRoute = SearchView <$ route "search" searchRoute = SearchView <$ route "search"
docviewRoute = DocView <$ route "docView" docviewRoute = DocView <$ route "docView"
addcorpusRoute = AddCorpus <$ route "addCorpus" addcorpusRoute = AddCorpus <$ route "addCorpus"
loginRoute = Login <$ route "login" loginRoute = Login <$ route "login"
home = Home <$ lit "" home = Home <$ lit ""
route str = lit "" *> lit str route str = lit "" *> lit str
routeHandler :: forall e. (Maybe Routes -> Routes -> Eff ( dom :: DOM, console :: CONSOLE | e) Unit) -> Maybe Routes -> Routes -> Eff (dom :: DOM, console :: CONSOLE | e) Unit routeHandler :: forall e. (Maybe Routes -> Routes -> Eff ( dom :: DOM, console :: CONSOLE | e) Unit) -> Maybe Routes -> Routes -> Eff (dom :: DOM, console :: CONSOLE | e) Unit
routeHandler dispatchAction old new = do routeHandler dispatchAction old new = do
......
...@@ -73,10 +73,10 @@ searchSpec = simpleSpec performAction render ...@@ -73,10 +73,10 @@ searchSpec = simpleSpec performAction render
, br'[] , br'[]
] ]
] ]
, div [className "col-md-2"] , div [ className "col-md-2"]
[ br' [] [ br' []
, br' [] , br' []
, button [onClick \_ -> dispatch GO] [text "GO"] , button [onClick \_ -> dispatch GO] [text "GO"]
] ]
, br' [] , br' []
] ]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment