mirror of
https://github.com/NoRedInk/noredink-ui.git
synced 2024-12-24 06:02:36 +03:00
49 lines
1.2 KiB
Elm
49 lines
1.2 KiB
Elm
module Examples.Text.Writing exposing (example, State, Msg)
|
|
|
|
{-|
|
|
|
|
@docs example, State, Msg
|
|
|
|
-}
|
|
|
|
import Category exposing (Category(..))
|
|
import Example exposing (Example)
|
|
import Html.Styled exposing (text)
|
|
import KeyboardSupport exposing (Direction(..), Key(..))
|
|
import Nri.Ui.Text.Writing.V1 as TextWriting
|
|
|
|
|
|
{-| -}
|
|
type alias State =
|
|
()
|
|
|
|
|
|
{-| -}
|
|
type alias Msg =
|
|
()
|
|
|
|
|
|
example : Example State Msg
|
|
example =
|
|
{ name = "Text.Writing"
|
|
, version = 1
|
|
, categories = [ Text ]
|
|
, keyboardSupport = []
|
|
, state = ()
|
|
, update = \_ state -> ( state, Cmd.none )
|
|
, subscriptions = \_ -> Sub.none
|
|
, preview = [ TextWriting.footnote [ text "This is a footnote. " ] ]
|
|
, view =
|
|
\_ ->
|
|
let
|
|
longerBody =
|
|
"""Be on the lookout for a new and improved assignment
|
|
creation form! Soon, you'll be able to easily see a summary
|
|
of the content you're assigning, as well as an estimate for
|
|
how long the assignment will take.
|
|
"""
|
|
in
|
|
[ TextWriting.footnote [ text <| "This is a footnote. " ++ longerBody ]
|
|
]
|
|
}
|