1{-# OPTIONS_GHC -Wall #-}
2{-# LANGUAGE OverloadedStrings #-}
6 , inVirtualDom, inCore, inHtml, inBrowser
7 , toString, toText, canonicalToText
8 , isKernel, getKernel, canonicalIsKernel
13import qualified Data.Text as Text
14import Data.Text (Text)
16import qualified Elm.Package as Package
23type Raw = Text -- must be non-empty
28 { _package :: !Package.Name
38inVirtualDom :: Raw -> Canonical
40 Canonical Package.virtualDom raw
43inCore :: Raw -> Canonical
45 Canonical Package.core raw
48inHtml :: Raw -> Canonical
50 Canonical Package.html raw
53inBrowser :: Raw -> Canonical
55 Canonical Package.browser raw
62toString :: Raw -> String
73canonicalToText :: Canonical -> Text
74canonicalToText (Canonical _ name) =
82isKernel :: Raw -> Bool
84 Text.isPrefixOf "Elm.Kernel." name
87getKernel :: Raw -> Text
92canonicalIsKernel :: Canonical -> Bool
93canonicalIsKernel (Canonical _ name) =
101instance Binary Canonical where
102 put (Canonical home name) =
106 Canonical <$> get <*> get
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list