2020-04-01 02:00:29 +03:00
|
|
|
module Examples.Logo exposing (example, State, Msg)
|
2019-10-30 04:31:51 +03:00
|
|
|
|
|
|
|
{-|
|
|
|
|
|
2020-04-01 02:00:29 +03:00
|
|
|
@docs example, State, Msg
|
2019-10-30 04:31:51 +03:00
|
|
|
|
|
|
|
-}
|
|
|
|
|
2020-03-24 03:33:42 +03:00
|
|
|
import Category exposing (Category(..))
|
2019-10-30 04:47:38 +03:00
|
|
|
import Css
|
2020-03-31 23:33:05 +03:00
|
|
|
import Example exposing (Example)
|
2019-10-30 04:31:51 +03:00
|
|
|
import Examples.IconExamples as IconExamples
|
2022-03-15 21:06:13 +03:00
|
|
|
import Html.Styled as Html
|
2021-11-05 22:50:05 +03:00
|
|
|
import Html.Styled.Attributes exposing (css)
|
2019-10-30 04:31:51 +03:00
|
|
|
import Nri.Ui.Colors.V1 as Colors
|
|
|
|
import Nri.Ui.Logo.V1 as Logo
|
2021-11-05 22:50:05 +03:00
|
|
|
import Nri.Ui.Svg.V1 as Svg
|
2019-10-30 04:31:51 +03:00
|
|
|
|
|
|
|
|
|
|
|
{-| -}
|
2020-04-01 02:00:29 +03:00
|
|
|
type alias State =
|
2022-03-21 23:41:54 +03:00
|
|
|
IconExamples.Settings
|
2020-04-01 02:00:29 +03:00
|
|
|
|
|
|
|
|
|
|
|
{-| -}
|
|
|
|
type alias Msg =
|
2022-03-21 23:41:54 +03:00
|
|
|
IconExamples.Msg
|
2020-04-01 02:00:29 +03:00
|
|
|
|
|
|
|
|
|
|
|
{-| -}
|
|
|
|
example : Example State Msg
|
2019-10-30 04:31:51 +03:00
|
|
|
example =
|
2020-09-09 21:43:10 +03:00
|
|
|
{ name = "Logo"
|
|
|
|
, version = 1
|
2020-06-19 23:41:28 +03:00
|
|
|
, categories = [ Icons ]
|
2020-06-20 00:45:32 +03:00
|
|
|
, keyboardSupport = []
|
2022-03-21 23:41:54 +03:00
|
|
|
, state = IconExamples.init
|
|
|
|
, update = IconExamples.update
|
2020-03-31 23:33:05 +03:00
|
|
|
, subscriptions = \_ -> Sub.none
|
2021-11-05 22:50:05 +03:00
|
|
|
, preview =
|
|
|
|
Html.div [ css [ Css.marginBottom (Css.px 8) ] ] [ Svg.toHtml Logo.noredink ]
|
|
|
|
:: IconExamples.preview
|
|
|
|
[ Logo.facebook
|
|
|
|
, Logo.twitter
|
|
|
|
, Logo.cleverC
|
|
|
|
, Logo.googleG
|
|
|
|
]
|
2020-03-31 23:33:05 +03:00
|
|
|
, view =
|
2022-03-21 23:41:54 +03:00
|
|
|
\settings ->
|
2022-03-21 23:23:58 +03:00
|
|
|
let
|
|
|
|
viewExampleSection =
|
2022-03-21 23:41:54 +03:00
|
|
|
IconExamples.viewWithCustomStyles settings
|
2022-03-21 23:23:58 +03:00
|
|
|
in
|
2022-03-21 23:41:54 +03:00
|
|
|
[ IconExamples.viewSettings settings
|
|
|
|
, viewExampleSection "NRI"
|
2020-03-31 23:33:05 +03:00
|
|
|
[ ( "noredink"
|
|
|
|
, Logo.noredink
|
|
|
|
, [ Css.height (Css.px 25)
|
|
|
|
, Css.width (Css.px 100)
|
|
|
|
, Css.margin (Css.px 4)
|
|
|
|
]
|
|
|
|
)
|
2019-10-30 04:47:38 +03:00
|
|
|
]
|
2022-03-21 23:23:58 +03:00
|
|
|
, viewExampleSection "Social Media"
|
2022-01-18 22:39:52 +03:00
|
|
|
[ ( "facebook", Logo.facebook, defaults )
|
2020-03-31 23:33:05 +03:00
|
|
|
, ( "twitter", Logo.twitter, defaults )
|
2022-01-18 22:39:52 +03:00
|
|
|
]
|
2022-03-21 23:23:58 +03:00
|
|
|
, viewExampleSection "Clever"
|
2022-01-18 22:39:52 +03:00
|
|
|
[ ( "clever"
|
2020-03-31 23:33:05 +03:00
|
|
|
, Logo.clever
|
|
|
|
, [ Css.height (Css.px 25)
|
|
|
|
, Css.width (Css.px 100)
|
|
|
|
, Css.margin (Css.px 4)
|
|
|
|
, Css.color Colors.azure
|
|
|
|
]
|
|
|
|
)
|
2022-01-18 22:39:52 +03:00
|
|
|
, ( "cleverC", Logo.cleverC, defaults )
|
2022-02-09 01:47:19 +03:00
|
|
|
, ( "cleverLibrary"
|
|
|
|
, Logo.cleverLibrary
|
|
|
|
, [ Css.height (Css.px 25)
|
|
|
|
, Css.width (Css.px 100)
|
|
|
|
, Css.margin (Css.px 4)
|
|
|
|
]
|
|
|
|
)
|
2022-01-18 22:39:52 +03:00
|
|
|
]
|
2022-03-21 23:23:58 +03:00
|
|
|
, viewExampleSection "Google"
|
2022-01-18 22:39:52 +03:00
|
|
|
[ ( "googleClassroom"
|
2020-03-31 23:33:05 +03:00
|
|
|
, Logo.googleClassroom
|
|
|
|
, defaults
|
|
|
|
)
|
2022-01-18 22:39:52 +03:00
|
|
|
, ( "googleG", Logo.googleG, defaults )
|
|
|
|
]
|
2022-03-21 23:23:58 +03:00
|
|
|
, viewExampleSection "LMS"
|
2022-01-18 22:39:52 +03:00
|
|
|
[ ( "canvas"
|
|
|
|
, Logo.canvas
|
|
|
|
, [ Css.height (Css.px 25)
|
|
|
|
, Css.width (Css.px 100)
|
|
|
|
, Css.margin (Css.px 4)
|
|
|
|
]
|
|
|
|
)
|
|
|
|
, ( "schoology"
|
|
|
|
, Logo.schoology
|
|
|
|
, [ Css.height (Css.px 25)
|
|
|
|
, Css.width (Css.px 100)
|
|
|
|
, Css.margin (Css.px 4)
|
|
|
|
]
|
2021-10-18 21:06:43 +03:00
|
|
|
)
|
2019-10-30 04:47:38 +03:00
|
|
|
]
|
2019-10-30 04:31:51 +03:00
|
|
|
]
|
|
|
|
}
|
2019-10-30 04:47:38 +03:00
|
|
|
|
|
|
|
|
|
|
|
defaults : List Css.Style
|
|
|
|
defaults =
|
|
|
|
[ Css.height (Css.px 25)
|
|
|
|
, Css.width (Css.px 25)
|
|
|
|
, Css.margin (Css.px 4)
|
|
|
|
, Css.color Colors.azure
|
|
|
|
]
|