Some preliminary rejiggin'
This commit is contained in:
parent
2ab596dcce
commit
347b74ce97
1
elm.json
1
elm.json
|
@ -16,6 +16,7 @@
|
|||
"elm/url": "1.0.0",
|
||||
"elm-community/json-extra": "4.3.0",
|
||||
"elm-community/string-extra": "4.0.1",
|
||||
"fapian/elm-html-aria": "1.4.0",
|
||||
"pablohirafuji/elm-markdown": "2.0.5"
|
||||
},
|
||||
"indirect": {
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -30,6 +30,6 @@
|
|||
"npm-run-all": "4.1.5"
|
||||
},
|
||||
"dependencies": {
|
||||
"elm-format": "^0.8.5"
|
||||
"elm-format": "^0.8.6"
|
||||
}
|
||||
}
|
||||
|
|
|
@ -29,7 +29,20 @@ i.fas, i.fab {
|
|||
}
|
||||
|
||||
|
||||
/* Categories */
|
||||
/* Filtering */
|
||||
|
||||
#filter {
|
||||
position: fixed;
|
||||
left: 0;
|
||||
}
|
||||
|
||||
#filter > div {
|
||||
margin-bottom: 1rem;
|
||||
}
|
||||
|
||||
#filter h3 {
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
.category-tile {
|
||||
cursor: pointer;
|
||||
|
@ -96,31 +109,6 @@ i.fas, i.fab {
|
|||
}
|
||||
|
||||
|
||||
/* Search bar*/
|
||||
|
||||
.search-bar-container {
|
||||
margin: 2em;
|
||||
display: flex;
|
||||
flex-flow: row wrap;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.search-bar-input, .search-dropdown {
|
||||
margin: 0.5em;
|
||||
height: calc(1.5em + .75rem + 2px);
|
||||
background-color: var(--white);
|
||||
border: 1px solid var(--dark-pink);
|
||||
border-radius: .5rem;
|
||||
}
|
||||
|
||||
.search-bar-input {
|
||||
width: 30rem;
|
||||
}
|
||||
|
||||
.search-dropdown {
|
||||
width: 10rem;
|
||||
}
|
||||
|
||||
/* Navbar */
|
||||
.navbar-text {
|
||||
color: var(--dark-blue);
|
||||
|
@ -142,3 +130,9 @@ i.fas, i.fab {
|
|||
.card-body p {
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 768px) {
|
||||
#filter {
|
||||
width: 100%;
|
||||
position: relative;
|
||||
}
|
||||
|
|
|
@ -1,8 +1,9 @@
|
|||
module Pages.Top exposing (Model, Msg, Params, page)
|
||||
|
||||
import Enum exposing (Enum)
|
||||
import Html exposing (Html, a, button, div, h2, h5, i, img, li, p, span, text, ul, form, label, select, option, input)
|
||||
import Html exposing (Html, a, button, div, h2, h3, h5, i, img, li, p, span, text, ul, form, label, select, option, input)
|
||||
import Html.Attributes exposing (alt, class, href, src, style, id, for, value)
|
||||
import Html.Attributes.Aria exposing (ariaLabel)
|
||||
import Html.Events exposing (onClick, onInput)
|
||||
import Http
|
||||
import Json.Decode as Decode
|
||||
|
@ -335,28 +336,34 @@ viewApps model =
|
|||
|
||||
Success ->
|
||||
div [ class "row justify-content-center" ]
|
||||
[ div [ class "col-md-3" ] [
|
||||
h2 [ class "app-headings" ] [text "Categories"]
|
||||
, div [] (List.map viewCategories categories.list)
|
||||
[ div [ class "col-md-3", id "filter" ] [
|
||||
h2 [ class "app-headings" ] [text "Filter"]
|
||||
, form [] [
|
||||
div [] [
|
||||
h3 [] [text "Categories"]
|
||||
, div [] (List.map viewCategories categories.list)
|
||||
]
|
||||
, div [] [
|
||||
h3 [] [text "Search"]
|
||||
, input [ ariaLabel "search", id "text", onInput FilterText ] []
|
||||
]
|
||||
, div [] [
|
||||
h3 [] [text "Status"]
|
||||
, select [ class "search-dropdown", id "level", onInput FilterScore ] [
|
||||
option [ ] [ text "any" ]
|
||||
, option [ value "5" ] [ text "5 (production)" ]
|
||||
, option [ value "4" ] [ text "4 (beta)" ]
|
||||
, option [ value "3" ] [ text "3 (alpha)" ]
|
||||
, option [ value "2" ] [ text "2 (pre-alpha)" ]
|
||||
, option [ value "1" ] [ text "1 (work-in-progress)" ]
|
||||
]
|
||||
]
|
||||
]
|
||||
, div [ class "col-md-6" ]
|
||||
]
|
||||
, div [ class "col-md-6 offset-md-3" ]
|
||||
[ div [ class "row" ]
|
||||
[ div [ class "col-sm-12" ] [
|
||||
div [] [
|
||||
form [ class "search-bar-container" ] [
|
||||
label [ for "text" ] [ text "Search" ]
|
||||
, input [ class "search-bar-input", id "text", onInput FilterText ] []
|
||||
, label [ for "level" ] [ text " and show only items that have at least " ]
|
||||
, select [ class "search-dropdown", id "level", onInput FilterScore ] [
|
||||
option [ ] [ text "any" ]
|
||||
, option [ value "5" ] [ text "5 (production)" ]
|
||||
, option [ value "4" ] [ text "4 (beta)" ]
|
||||
, option [ value "3" ] [ text "3 (alpha)" ]
|
||||
, option [ value "2" ] [ text "2 (pre-alpha)" ]
|
||||
, option [ value "1" ] [ text "1 (work-in-progress)" ]
|
||||
]
|
||||
, text "builds "
|
||||
]
|
||||
]
|
||||
]
|
||||
]
|
||||
|
|
Loading…
Reference in New Issue