Fix links, change sort, add Utils
This commit is contained in:
@ -63,7 +63,7 @@ init url =
|
||||
|
||||
default_image : String
|
||||
-- FIXME: change to absolute URL, if this works?
|
||||
default_image = "http://localhost:8000/logo.png"
|
||||
default_image = "/logo.png"
|
||||
|
||||
|
||||
-- UPDATE
|
||||
@ -146,9 +146,11 @@ body model =
|
||||
div [ class "pt-3" ]
|
||||
[ case model.status of
|
||||
Failure ->
|
||||
div [ ]
|
||||
[ text "I could not load a random cat for some reason. "
|
||||
, button [ onClick MorePlease ] [ text "Try Again!" ]
|
||||
div []
|
||||
[ div [ class "alert alert-danger" ]
|
||||
[ p [] [ text "Unable to load app data" ]
|
||||
, button [ class "btn btn-danger", onClick MorePlease ] [ text "Try Again!" ]
|
||||
]
|
||||
]
|
||||
|
||||
Loading ->
|
||||
@ -242,7 +244,7 @@ loadApp =
|
||||
-- fetch app JSON and README in parallel
|
||||
Http.get
|
||||
-- FIXME: change to absolute URL, if this works?
|
||||
{ url = "http://localhost:8000/abra-apps-list.json"
|
||||
{ url = "/abra-apps-list.json"
|
||||
, expect = Http.expectJson GotApps appListDecoder }
|
||||
|
||||
|
||||
@ -259,7 +261,7 @@ loadREADME app =
|
||||
text ""
|
||||
in
|
||||
Http.get
|
||||
-- FIXME add branch name to apps.json, load actual README
|
||||
-- FIXME use live Gitea link
|
||||
{ url = "http://localhost:1234/coop-cloud/" ++ app.slug ++ "/raw/branch/" ++ app.default_branch ++ "/README.md"
|
||||
, expect = Http.expectString GotText }
|
||||
|
||||
|
Reference in New Issue
Block a user