packages feed

dhall-docs 1.0.0 → 1.0.1

raw patch · 72 files changed

+2996/−464 lines, 72 filesdep +cryptonitedep +memorydep +transformersdep −tardep ~dhalldep ~megaparsecPVP ok

version bump matches the API change (PVP)

Dependencies added: cryptonite, memory, transformers

Dependencies removed: tar

Dependency ranges changed: dhall, megaparsec

API changes (from Hackage documentation)

Files

CHANGELOG.md view
@@ -1,3 +1,13 @@+1.0.1++* Improved jump to definition support+    * [Jump to definition on `let` bindings](https://github.com/dhall-lang/dhall-haskell/pull/1966)+    * [Jump to definition on `λ` bindings](https://github.com/dhall-lang/dhall-haskell/pull/1982)+    * [Jump to definition on record fields](https://github.com/dhall-lang/dhall-haskell/pull/1991)+* [BUG FIX: Support for long path names](https://github.com/dhall-lang/dhall-haskell/pull/1976)+* [BUG FIX: Support for large directory trees](https://github.com/dhall-lang/dhall-haskell/pull/2006)+* [Add `dhall-docs` `man` page](https://github.com/dhall-lang/dhall-haskell/pull/2010)+ 1.0.0  * [Generate documentation from header comment](https://github.com/dhall-lang/dhall-haskell/pull/1929)
dhall-docs.cabal view
@@ -1,5 +1,5 @@ Name: dhall-docs-Version: 1.0.0+Version: 1.0.1 Cabal-Version: >=1.10 Build-Type: Simple Tested-With: GHC == 8.6.1@@ -41,9 +41,10 @@     tasty/data/comments/invalid/*.txt     tasty/data/comments/valid/*.txt Data-Files:-    *.css-    *.js-    *.svg+    assets/*.css+    assets/*.js+    assets/*.svg+    man/dhall-docs.1 Data-Dir:     src/Dhall/data @@ -62,21 +63,23 @@         base                 >= 4.11.0.0  && < 5   ,         bytestring                           < 0.11,         containers                                 ,+        cryptonite                           < 0.28,         directory            >= 1.3.0.0   && < 1.4 ,-        dhall                >= 1.34.0    && < 1.35,+        dhall                >= 1.35.0    && < 1.36,         file-embed           >= 0.0.10.0           ,         filepath             >= 1.4       && < 1.5 ,         lens-family-core     >= 1.0.0     && < 2.2 ,         lucid                >= 2.9.12    && < 2.10,         mmark                >= 0.0.7.0   && < 0.8 ,-        megaparsec           >= 7         && < 8.1 ,+        megaparsec           >= 7         && < 9.1 ,+        memory                               < 0.16,         path                 >= 0.7.0     && < 0.9 ,         path-io              >= 1.6.0     && < 1.7 ,         prettyprinter        >= 1.5.1     && < 1.8 ,-        tar                  >= 0.5.1.0   && < 0.6 ,         text                 >= 0.11.1.0  && < 1.3 ,+        transformers         >= 0.2.0.0  && < 0.6 ,         mtl                  >= 2.2.1     && < 2.3 ,-        optparse-applicative >= 0.14.0.0  && < 0.16+        optparse-applicative >= 0.14.0.0  && < 0.17     Exposed-Modules:         Dhall.Docs         Dhall.Docs.Core
src/Dhall/Docs/CodeRenderer.hs view
@@ -1,9 +1,28 @@+{-# LANGUAGE LambdaCase        #-} {-# LANGUAGE NamedFieldPuns    #-} {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE RecordWildCards   #-}+{-# LANGUAGE ViewPatterns      #-}  {-| Contains the logic to render the source code inside a HTML. It also provides-    context-sensitive features such as jump-to-definition+    context-sensitive features such as jump-to-definition.++    Rendering an expression consists on the following steps:++    * An 'Expr Src Import' with its parsed 'Text' is processed into+      a '[SourceCodeFragment]'+    * Each 'SourceCodeFragment' tells the 'renderSourceCodeFragment' how to+      render that function as HTML including the injected information through+      HTML data-attributes++    To render a Dhall file you should use 'renderCodeWithHyperLinks' which+    takes a 'Text' that was used to parse the 'Expr Src Import', and returns+    the generated 'Html ()' with the same structure (i.e. whitespaces)+    from the 'Text' argument.++    To render code-snippets (e.g. assertions from examples, type from source code)+    you should use 'renderCodeSnippet' which uses the output of @dhall format@+    as the 'Text' argument to call later 'renderCodeWithHyperLinks' -} module Dhall.Docs.CodeRenderer     ( renderCodeWithHyperLinks@@ -11,26 +30,40 @@     , ExprType(..)     ) where -import Data.Text       (Text)-import Data.Void       (Void)+import Control.Monad.Trans.Writer.Strict (Writer)+import Data.Text                         (Text)+import Data.Void                         (Void)+import Dhall.Context                     (Context) import Dhall.Core-    ( Expr (..)+    ( Binding (..)+    , Expr (..)+    , FieldSelection (..)     , File (..)     , FilePrefix (..)+    , FunctionBinding (..)     , Import (..)     , ImportHashed (..)     , ImportType (..)+    , RecordField (..)     , Scheme (..)     , URL (..)+    , Var (..)     ) import Dhall.Docs.Util-import Dhall.Src       (Src (..))+import Dhall.Src                         (Src (..)) import Lucid+import Text.Megaparsec.Pos               (SourcePos (..)) -import qualified Data.Text+import qualified Control.Monad.Trans.Writer.Strict     as Writer+import qualified Data.Maybe as Maybe+import qualified Data.List+import qualified Data.Set                              as Set+import qualified Data.Text                             as Text import qualified Data.Text.Prettyprint.Doc             as Pretty import qualified Data.Text.Prettyprint.Doc.Render.Text as Pretty.Text+import qualified Dhall.Context                         as Context import qualified Dhall.Core                            as Core+import qualified Dhall.Map                             as Map import qualified Dhall.Parser import qualified Dhall.Pretty import qualified Lens.Family                           as Lens@@ -40,108 +73,321 @@ -- >>> :set -XOverloadedStrings -- >>> import Dhall.Core (Directory (..)) --- | Given a Dhall expression return all imports with their location on the file.---   Contents are already sorted by 'Src', which allows 'renderAsHtml' to traverse---   the return of this function to inject anchors-getImports :: Expr Src Import -> [(Src, Import)]-getImports (Note src (Embed a)) = [(src, a)]-getImports expr = concatMap getImports $ Lens.toListOf Core.subExpressions expr+-- | Get the source line and column from a 'SourcePos' as an 'Int'+getSourceLine, getSourceColumn :: SourcePos -> Int+getSourceLine = SourcePos.unPos . SourcePos.sourceLine+getSourceColumn = SourcePos.unPos . SourcePos.sourceColumn +{-| Every 'Expr' constructor has extra information that tell us what to highlight on+    hover and where to jump on click events. 'JtdInfo' record that extra+    information.+-}+data JtdInfo+    {-| Each field in a Dhall record (type or literal) is associated with a+        'NameDecl', and selector-expressions behave like 'Var's by using a+        'NameUse' with the field 'NameDecl' to jump to that label.++        For example, a Dhall expression like this:++        > { a = foo, b = bar }++        has the following 'JtdInfo':++        > RecordFields (Set.fromList [NameDecl posA "a" jtdInfoA, NameDecl posB "b" jtdInfoB])++        ... where++        * @posA@ and @posB@ record the source position used to make them+        unique across the rendered source code+        * @jtdInfoA@ and @jtdInfoB@ are the associated 'JtdInfo' inferred from+        @foo@ and @bar@+    -}+    = RecordFields (Set.Set NameDecl)+    -- | Default type for cases we don't handle+    | NoInfo+    deriving (Eq, Ord, Show)++{-| To make each name unique we record the source position where it was+    found.++    The names that we handle are the ones introduced by let-bindings, lambda+    arguments and record (types and literals) labels.+-}+data NameDecl = NameDecl Src Text JtdInfo+    deriving (Eq, Ord, Show)++makeHtmlId :: NameDecl -> Text+makeHtmlId (NameDecl Src{srcStart} _ _) =+       "var"+    <> Text.pack (show $ getSourceLine srcStart) <> "-"+    <> Text.pack (show $ getSourceColumn srcStart)++-- | Available ways of rendering source code as HTML+data SourceCodeType+    -- | Relative and remote imports are rendered using an HTML anchor tag.+    --   Other imports are rendered as plain-text+    = ImportExpr Import++    -- | Used to render a name declared in let-binding or function argument+    --   that is used in any expression+    | NameUse NameDecl++    -- | Used to render the declaration of a name. This is used to jump+    --   to that name after clicking an 'NameUse'+    | NameDeclaration NameDecl++{-| The 'Expr Src Import' parsed from a 'Text' is split into a+    '[SourceCodeFragment]'.+-}+data SourceCodeFragment =+    SourceCodeFragment+        Src -- ^ The start and end position of this fragment+        SourceCodeType -- ^ The type of 'SourceCodeFragment' that will guide HTML rendering++-- | Returns all 'SourceCodeFragment's in lexicographic order i.e. in the same+--   order as in the source code.+fragments :: Expr Src Import -> [SourceCodeFragment]+fragments = Data.List.sortBy sorter . removeUnusedDecls . Writer.execWriter . infer Context.empty+  where+    sorter (SourceCodeFragment Src{srcStart = srcStart0} _)+           (SourceCodeFragment Src{srcStart = srcStart1} _) = pos0 `compare` pos1+      where+        pos0 = (getSourceLine srcStart0, getSourceColumn srcStart0)+        pos1 = (getSourceLine srcStart1, getSourceColumn srcStart1)++    removeUnusedDecls sourceCodeFragments = filter isUsed sourceCodeFragments+      where+        makePosPair Src{srcStart} = (getSourceLine srcStart, getSourceColumn srcStart)+        nameUsePos (SourceCodeFragment _ (NameUse (NameDecl src _ _))) =+            Just $ makePosPair src+        nameUsePos _ = Nothing++        usedNames = Set.fromList $ Maybe.mapMaybe nameUsePos sourceCodeFragments++        isUsed (SourceCodeFragment _ (NameDeclaration (NameDecl src _ _))) =+            makePosPair src `Set.member` usedNames+        isUsed _ = True++    infer :: Context NameDecl -> Expr Src Import -> Writer [SourceCodeFragment] JtdInfo+    infer context = \case+        -- The parsed text of the import is located in it's `Note` constructor+        Note src (Embed a) -> Writer.tell [SourceCodeFragment src $ ImportExpr a] >> return NoInfo++        -- since we have to 'infer' the 'JtdInfo' of the annotation, we+        -- are not able to generate the 'SourceCodeFragment's in lexicographical+        -- without calling 'Data.List.sortBy' after+        Let (Binding+                (Just Src { srcEnd = srcEnd0 })+                name+                (Just Src { srcStart = srcStart1 })+                annotation+                _+                value) expr' -> do++            -- If annotation is missing, the type is inferred from the bound value+            case annotation of+                Nothing -> return ()+                Just (_, t) -> do+                    _ <- infer context t+                    return ()++            bindingJtdInfo <- infer context value++            let nameSrc = makeSrcForLabel srcEnd0 srcStart1 name+            let nameDecl = NameDecl nameSrc name bindingJtdInfo++            Writer.tell [SourceCodeFragment nameSrc (NameDeclaration nameDecl)]+            infer (Context.insert name nameDecl context) expr'++        Note src (Var (V name index)) ->+            case Context.lookup name index context of+                Nothing -> return NoInfo+                Just nameDecl@(NameDecl _ _ t) -> do+                    Writer.tell [SourceCodeFragment src $ NameUse nameDecl]+                    return t++        Lam (FunctionBinding+                (Just Src{srcEnd = srcEnd0})+                name+                (Just Src{srcStart = srcStart1})+                _+                t) expr -> do+            dhallType <- infer context t++            let nameSrc = makeSrcForLabel srcEnd0 srcStart1 name+            let nameDecl = NameDecl nameSrc name dhallType++            Writer.tell [SourceCodeFragment nameSrc (NameDeclaration nameDecl)]+            infer (Context.insert name nameDecl context) expr++        Field e (FieldSelection (Just Src{srcEnd=posStart}) label (Just Src{srcStart=posEnd})) -> do+            fields <- do+                dhallType <- infer context e+                case dhallType of+                    NoInfo -> return mempty+                    RecordFields s -> return $ Set.toList s++            let src = makeSrcForLabel posStart posEnd label+            let match (NameDecl _ l _) = l == label+            case filter match fields of+                x@(NameDecl _ _ t) : _ -> do+                    Writer.tell [SourceCodeFragment src (NameUse x)]+                    return t+                _ -> return NoInfo++        RecordLit (Map.toList -> l) -> handleRecordLike l++        Record (Map.toList -> l) -> handleRecordLike l++        Note _ e -> infer context e+        e -> do+            mapM_ (infer context) $ Lens.toListOf Core.subExpressions e+            return NoInfo++      where+        handleRecordLike l = RecordFields . Set.fromList <$> mapM f l+          where+            f (key, RecordField (Just Src{srcEnd = startPos}) val (Just Src{srcStart = endPos}) _) = do+                dhallType <- infer context val+                let nameSrc = makeSrcForLabel startPos endPos key+                let nameDecl = NameDecl nameSrc key dhallType+                Writer.tell [SourceCodeFragment nameSrc (NameDeclaration nameDecl)]+                return nameDecl+              where+            f _ = fileAnIssue "A `RecordField` of type `Expr Src Import` doesn't have `Just src*`"+ fileAsText :: File -> Text fileAsText File{..} = foldr (\d acc -> acc <> "/" <> d) "" (Core.components directory)     <> "/" <> file -{-| Given an 'Import', render the contents in an HTML element that will allow-    users to jump to another file or domain. The 'Text' argument is the contents-    inside the anchor tag+-- | Generic way of creating a Src for a label, taking quoted names into+--   account+makeSrcForLabel+    :: SourcePos  -- ^ Prefix whitespace end position, will be 'srcStart'+    -> SourcePos  -- ^ Suffix whitespace start position, will be 'srcEnd'+    -> Text       -- ^ Label name, will be the 'srcText' with surrounding @`@ if needed+    -> Src+makeSrcForLabel srcStart srcEnd name = Src {..}+  where+    realLength = getSourceColumn srcEnd - getSourceColumn srcStart+    srcText =+        if Text.length name == realLength then name+        else "`" <> name <> "`" -    Example:+renderSourceCodeFragment :: SourceCodeFragment -> Html ()+renderSourceCodeFragment (SourceCodeFragment Src{..} (ImportExpr import_)) =+    renderImport import_ srcText+  where+    {-  Given an 'Import', render the contents in an HTML element that will allow+        users to jump to another file or domain. The 'Text' argument is the contents+        inside the anchor tag -    >>> :set -Wno-missing-fields-    >>> let file = File { directory = Directory [], file = ""}-    >>> let url = URL { scheme = HTTPS, authority = "google.com", query = Nothing, path = file}-    >>> let import_ = Import {importHashed = ImportHashed { importType = Remote url }}-    >>> renderImport import_ "link for google"-    <a href="https://google.com/" target="_blank">link for google</a>--}-renderImport :: Import -> Text -> Html ()-renderImport (Import {importHashed = ImportHashed { importType }}) =-    case importType of-        Remote URL {..} -> a_ [href_ href, target_ "_blank"] . toHtml-          where-            scheme_ = case scheme of-                HTTP -> "http"-                HTTPS -> "https"+        Example: -            path_ = fileAsText path+        >>> :set -Wno-missing-fields+        >>> let file = File { directory = Directory [], file = ""}+        >>> let url = URL { scheme = HTTPS, authority = "google.com", query = Nothing, path = file}+        >>> let import_ = Import {importHashed = ImportHashed { importType = Remote url }}+        >>> renderImport import_ "link for google"+        <a href="https://google.com/" target="_blank">link for google</a>+    -}+    renderImport :: Import -> Text -> Html ()+    renderImport (Import {importHashed = ImportHashed { importType }}) =+        case importType of+            Remote URL {..} -> a_ [href_ href, target_ "_blank"] . toHtml+              where+                scheme_ = case scheme of+                    HTTP -> "http"+                    HTTPS -> "https" -            query_ = case query of-                Nothing -> ""-                Just d -> "?" <> d+                path_ = fileAsText path -            -- we don't include the headers here since we treat links to open a file-            -- in another tab-            href = scheme_ <> "://" <> authority <> path_ <> query_+                query_ = case query of+                    Nothing -> ""+                    Just d -> "?" <> d -        Local Here file -> a_ [href_ href] . toHtml-          where-            href = "." <> fileAsText file <> ".html"+                -- we don't include the headers here since we treat links to open a file+                -- in another tab+                href = scheme_ <> "://" <> authority <> path_ <> query_ -        Local Parent file -> a_ [href_ href] . toHtml-          where-            href = ".." <> fileAsText file <> ".html"+            Local Here file -> a_ [href_ href] . toHtml+              where+                href = "." <> fileAsText file <> ".html" -        _ -> toHtml+            Local Parent file -> a_ [href_ href] . toHtml+              where+                href = ".." <> fileAsText file <> ".html" +            _ -> toHtml++renderSourceCodeFragment (SourceCodeFragment Src{..} (NameDeclaration nameDecl)) =+    span_ attributes $ toHtml srcText+  where+    attributes =+        [id_ $ makeHtmlId nameDecl+        , class_ "name-decl"+        , data_ "name" $ makeHtmlId nameDecl ]+renderSourceCodeFragment (SourceCodeFragment Src{..} (NameUse nameDecl)) =+    a_ attributes $ toHtml srcText+  where+    attributes =+        [ href_ $ "#" <> makeHtmlId nameDecl+        , class_ "name-use"+        , data_ "name" $ makeHtmlId nameDecl+        ]+ -- | Given a Text and the parsed `Expr Src Import` from it, this will render the --   the source code on HTML with jump-to-definition on URL imports. Use this --   to render the source code with the same structure (whitespaces, comments, --   language elements) as the source file renderCodeWithHyperLinks :: Text -> Expr Src Import -> Html ()-renderCodeWithHyperLinks contents expr = pre_ $ go (1, 1) (Data.Text.lines contents) imports+renderCodeWithHyperLinks contents expr = pre_ $ go (1, 1) (Text.lines contents) imports   where-    imports = getImports expr+    imports = fragments expr      -- we keep the current line, column and consumed text as part of function argument-    go :: (Int, Int) -> [Text] -> [(Src, Import)] -> Html ()+    go :: (Int, Int) -> [Text] -> [SourceCodeFragment] -> Html ()     go _ textLines [] = mapM_ (\t -> toHtml t >> br_ []) textLines-    go (currLine, currCol) currentLines ((Src {..}, import_) : rest) = do-        let sourceLine = SourcePos.unPos . SourcePos.sourceLine-        let sourceColumn = SourcePos.unPos . SourcePos.sourceColumn -        let importStartLine = sourceLine srcStart-        let importEndLine = sourceLine srcEnd+    -- consume lines until we encounter the first 'SourceCodeFragment'+    go (currLineNumber, _) (currLine : restLines) scfs@((SourceCodeFragment Src {..} _) : _)+        | getSourceLine srcStart /= currLineNumber = do+            toHtml currLine+            br_ []+            go (currLineNumber + 1, 1) restLines scfs -        let importStartCol = sourceColumn srcStart-        let importEndCol = sourceColumn srcEnd+    go (_, currCol) currentLines (scf@(SourceCodeFragment Src {..} _) : rest) = do+        let importStartLine = getSourceLine srcStart+        let importEndLine = getSourceLine srcEnd -        let (prefixLines, restLines) = splitAt (importStartLine - currLine) currentLines-        let (importLines, suffixLines) = splitAt (importStartLine - importStartLine + 1) restLines+        let importStartCol = getSourceColumn srcStart+        let importEndCol = getSourceColumn srcEnd +        let (importLines, suffixLines) = splitAt (importEndLine - importStartLine + 1) currentLines+         -- calls to `head` and `last` here should never fail since `importLines`         -- have at least one element         let (firstImportLine, lastImportLine) = (head importLines, last importLines)-        let prefixCols = Data.Text.take (importStartCol - currCol) firstImportLine-        let suffixCols = Data.Text.drop (importEndCol - currCol) lastImportLine+        let prefixCols = Text.take (importStartCol - currCol) firstImportLine+        let suffixCols = Text.drop (importEndCol - currCol) lastImportLine -        -- prefix lines and columns-        mapM_ (\t -> toHtml t >> br_ []) prefixLines+        -- render the prefix column         toHtml prefixCols -        -- rendered import-        renderImport import_ srcText+        -- rendered element+        renderSourceCodeFragment scf          -- add a newline if last line of import consumes the remaining line on         -- the original text-        if Data.Text.null suffixCols then br_ [] else return ()+        if Text.null suffixCols then br_ [] else return () -        let suffix = if Data.Text.null suffixCols then suffixLines else suffixCols : suffixLines+        let suffix = if Text.null suffixCols then suffixLines else suffixCols : suffixLines          -- move the cursor to next line if no characterse are remaining on the         -- suffix cols, otherwise keep the last line and next char right after         -- the import. This is done to handle properly several imports on the         -- same line-        let nextPosition = if Data.Text.null suffixCols then+        let nextPosition = if Text.null suffixCols then                                (importEndLine + 1, 1)                            else (importEndLine, importEndCol) @@ -151,8 +397,9 @@ --   or the whole file data ExprType = TypeAnnotation | AssertionExample --- | Renders an AST /fragment/ from the source file AST. Use this only for that---   purpose. The difference between this and 'renderCodeWithHyperLinks' is because that+-- | Renders an AST /fragment/ from the source file AST. Use this when you don't+--   have access to the 'Text' that was used to generate the AST.+--   The difference between this and 'renderCodeWithHyperLinks' is that --   the extracted fragment's 'SourcePos's need to be re-generated to --   render them in a better way; just adding whitespace at the beginning of the --   first line won't render good results.@@ -171,12 +418,10 @@         Right e -> e         Left _ -> fileAnIssue "A failure has occurred while parsing a formatted file" -    typeLayout :: Pretty.Doc ann -> Pretty.SimpleDocStream ann     typeLayout = Pretty.removeTrailingWhitespace . Pretty.layoutSmart opts       where         -- this is done so the type of a dhall file fits in a single line         -- its a safe value, since types in source codes are not that large-        opts :: Pretty.LayoutOptions         opts = Pretty.defaultLayoutOptions                 { Pretty.layoutPageWidth =                     Pretty.Unbounded
src/Dhall/Docs/Comment.hs view
@@ -27,7 +27,6 @@ import qualified Data.List.NonEmpty      as NonEmpty import qualified Data.Maybe              as Maybe import qualified Data.Text-import qualified Dhall.Parser.Expression as Expression import qualified Dhall.Parser.Token      as Token import qualified Text.Megaparsec import qualified Text.Megaparsec.Pos     as Megaparsec.Pos@@ -93,7 +92,7 @@             | otherwise = (x :| [], ys)      singleLine = do-      sourcePos <- Expression.getSourcePos+      sourcePos <- Text.Megaparsec.getSourcePos       commentLine <- Token.lineComment       whitespace       pure (sourcePos, commentLine)
src/Dhall/Docs/Embedded.hs view
@@ -29,14 +29,14 @@  getDataDir :: IO [(Path Rel File, ByteString)] #if defined(EMBED)-getDataDir = mapM f $(embedDir "src/Dhall/data")+getDataDir = mapM f $(embedDir "src/Dhall/data/assets")   where     f :: (FilePath, ByteString) -> IO (Path Rel File, ByteString)     f (filePath, contents) = (,contents) <$> Path.parseRelFile filePath #else getDataDir = do     dir <- Path.parent-        <$> (getDataFileName "src/Dhall/data/index.css" >>= Path.parseAbsFile)+        <$> (getDataFileName "src/Dhall/data/assets/index.css" >>= Path.parseAbsFile)     files <- snd <$> Path.IO.listDir dir     Control.Monad.forM files $ \file -> do         contents <- ByteString.readFile $ Path.fromAbsFile file
src/Dhall/Docs/Store.hs view
@@ -1,19 +1,21 @@-{-| Utilities to interact with the dhall-docs home directory--}+-- | Utilities to interact with the dhall-docs home directory+ {-# OPTIONS_GHC -Wno-unused-imports #-} {-# LANGUAGE QuasiQuotes #-} - module Dhall.Docs.Store (getDocsHomeDirectory, makeHashForDirectory) where -import Dhall.Crypto (SHA256Digest (..), sha256Hash)-import Path         (Abs, Dir, Path, Rel)+import Crypto.Hash  (Digest, SHA256)+import Dhall.Crypto (SHA256Digest (..))+import Path         (Abs, Dir, Path, Rel, (</>)) import Path.IO      (XdgDirectory (..)) -import qualified Codec.Archive.Tar       as Tar-import qualified Codec.Archive.Tar.Entry as Tar.Entry-import qualified Data.ByteString.Lazy-import qualified Data.List+import qualified Control.Monad           as Monad+import qualified Crypto.Hash             as Hash+import qualified Data.ByteArray          as ByteArray+import qualified Data.ByteString         as ByteString+import qualified Data.ByteString.Char8   as ByteString.Char8+import qualified Data.List               as List import qualified Path import qualified Path.IO @@ -37,12 +39,27 @@ -} makeHashForDirectory :: Path Abs Dir -> IO SHA256Digest makeHashForDirectory dir = do-    -- Builds a map so key order is preserved between several calls-    files <- Data.List.sort . map Path.fromRelFile . snd-            <$> Path.IO.listDirRecurRel dir+    (dirs, files) <- Path.IO.listDirRecurRel dir -    let setTimeToZero entry = entry{Tar.Entry.entryTime = 0}-    inMemoryTarBytes <- Data.ByteString.Lazy.toStrict . Tar.write . map setTimeToZero-                <$> Tar.pack (Path.fromAbsDir dir) files+    let context0 = Hash.hashInit -    return $ sha256Hash inMemoryTarBytes+    let addDir context directory = do+            let nameBytes = ByteString.Char8.pack (Path.toFilePath directory)++            return $! Hash.hashUpdate context nameBytes++    context1 <- Monad.foldM addDir context0 (List.sort dirs)++    let addFile context file = do+            let nameBytes = ByteString.Char8.pack (Path.toFilePath file)++            contentBytes <- ByteString.readFile (Path.toFilePath (dir </> file))++            return $! Hash.hashUpdates context [ nameBytes, contentBytes ]++    context2 <- Monad.foldM addFile context1 (List.sort files)++    let digest :: Digest SHA256+        digest = Hash.hashFinalize context2++    return (SHA256Digest (ByteArray.convert digest))
+ src/Dhall/data/assets/dhall-icon.svg view
@@ -0,0 +1,1 @@+<?xml version="1.0" encoding="UTF-8" standalone="no"?><!-- Generator: Gravit.io --><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" style="isolation:isolate" viewBox="701 377 180 180" width="180pt" height="180pt"><defs><clipPath id="_clipPath_bHCrHBHhrzISq2YnO5draXOg8wrP22Y8"><rect x="701" y="377" width="180" height="180"/></clipPath></defs><g clip-path="url(#_clipPath_bHCrHBHhrzISq2YnO5draXOg8wrP22Y8)"><path d=" M 791 377 C 840.672 377 881 417.328 881 467 C 881 516.672 840.672 557 791 557 C 741.328 557 701 516.672 701 467 C 701 417.328 741.328 377 791 377 Z  M 773.725 507.794 C 778.868 506.416 784.161 509.472 785.539 514.615 C 786.917 519.757 783.861 525.051 778.718 526.429 C 773.576 527.807 768.282 524.751 766.904 519.608 C 765.526 514.466 768.582 509.172 773.725 507.794 Z  M 825.655 406.546 C 827.502 407.041 828.6 408.943 828.105 410.79 C 827.61 412.637 825.709 413.734 823.862 413.239 L 820.634 412.375 C 820.047 417.121 816.961 443.216 818.245 458.044 C 804.548 469.874 780.875 505.457 780.875 505.457 L 793.315 459.031 C 795.744 458.876 798.412 457.332 799.076 454.852 C 799.909 451.743 798.061 448.542 794.952 447.709 C 791.843 446.876 788.642 448.724 787.809 451.833 C 787.145 454.313 788.683 456.984 790.709 458.332 L 778.269 504.759 C 778.269 504.759 774.975 463.985 769.612 445.012 C 778.328 433.72 788.578 408.768 790.391 404.271 L 787.15 403.403 C 785.303 402.908 784.206 401.006 784.701 399.159 C 785.196 397.312 787.097 396.215 788.944 396.71 L 825.655 406.546 L 825.655 406.546 Z " fill-rule="evenodd" fill="rgb(235,235,235)"/></g></svg>
+ src/Dhall/data/assets/index.css view
@@ -0,0 +1,221 @@+/******** Common rules ********/++body {+    padding: 0;+    margin: 0;+    background-color: #EBEBEB;+    transition: 0.5s;+}++body * {+    font-family: 'Lato', sans-serif;+}++a {+    transition: 0.5s;+    color: #008489;+}++a:visited {+    color: #914669;+}++a:active {+    color: #FFA632;+}++/******** Markdown specific code ********/++code {+    font-family: 'Fira Code', monospace;+}++blockquote {+    border-left: 9px solid #aaa;+    background-color: #bdbdbd;+    padding: 0.2rem;+    color: #616161;+}++/******** Nav bar **********/++.nav-bar {+    display: flex;+    align-items: center;+    padding: 0.3rem;+    background-color: #484848;+    color: #EBEBEB;+    transition: 0.5s;+}++.nav-bar .dhall-icon {+    max-width: 2.5rem;+    margin: 0.5rem;+}++.nav-bar .package-title {+    font-size: 1.3rem;+    margin: 0;+    margin-left: 1rem;+}++.nav-bar a.nav-option {+    font-size: 1rem;+    height: 100%;+    margin: 0 0.5rem;+    cursor: pointer;+    transition: 0.5s;+    text-decoration: none;+}++.nav-bar a.nav-option:hover {+    text-decoration: underline;+    text-decoration-color: #EBEBEB;+}++.nav-bar a.nav-option:active, .nav-bar a.nav-option, .nav-bar a.nav-option:visited {+    color: #EBEBEB;+}++.nav-bar .nav-bar-content-divider {+    flex: 1;+}++/******** Main content **********/++.main-container {+    padding: 2rem;+    padding-top: 0;+    transition: 0.5s;+}++h2.doc-title span, h2.doc-title a {+    font-family: 'Fira Code', monospace;+}++span.crumb-divider:first-child {+    margin-left: 0;+}++span.crumb-divider {+    margin: 0 0.5rem;+}++a.title-crumb {+    text-decoration: none;+}++a.title-crumb:hover {+    text-decoration: underline;+}++a.copy-to-clipboard {+    margin-top: 0;+    color: #888 !important;+    user-select: none;+    cursor: pointer;+    text-decoration: none;+}++a.copy-to-clipboard:hover {+    text-decoration: underline;+}++h2.doc-title {+    margin-bottom: 0;+}++/******** Source code **********/+++.code-examples > pre {+    padding-top: 0 !important;+    padding-bottom: 0 !important;+}++.source-code {+    padding: 0rem;+}++.source-code pre {+    padding: 1rem;+    font-family: 'Fira Code', monospace;+    color: #333333;+}++.source-code span {+    font-family: 'Fira Code', monospace;+    color: #333333;+}++.source-code span.name-decl {+    border-bottom: 1px solid #bdbdbd;+}++.source-code a {+    transition: 0s;+    font-family: 'Fira Code', monospace;+}++.source-code a.name-use {+    text-decoration: none;+    color: inherit;+    border-bottom: 1px solid #bdbdbd;+}++.source-code .highlighted {+    background-color: #bdbdbd !important;+}++.dhall-type {+    font-family: 'Fira Code', monospace;+}++.dhall-type pre {+    display: inline;+    padding: 0;+}++span.of-type-token {+    margin-left: 0.5rem;+    margin-right: 0.5rem;+}++/******** Dark mode styling ********/++.dark-mode .main-container {+    color: #EBEBEB;+}++body.dark-mode {+    background-color: #484848;+}++.dark-mode .nav-bar {+    background-color: #5d5d5d;+}++.dark-mode a {+    color: #FFA632;+}++.dark-mode a:visited {+    color: #008489;+}++.dark-mode a:active {+    color: #914669;+}++.dark-mode .source-code pre {+    color: #D4D4D4;+}++.dark-mode .source-code span {+    color: #D4D4D4;+}+++.dark-mode a.copy-to-clipboard {+    color: #bdbdbd !important;+}
+ src/Dhall/data/assets/index.js view
@@ -0,0 +1,53 @@+const DARK_MODE_OPT = 'dark-mode'+const DARK_MODE_ACTIVE = 'dark-mode-active'+const DARK_MODE_INACTIVE = 'dark-mode-inactive'++function onReady() {+  if (localStorage.getItem(DARK_MODE_OPT) == DARK_MODE_ACTIVE) {+    document.body.classList.add('dark-mode')+  } else {+    document.body.classList.remove('dark-mode')+  }+  document.getElementById('switch-light-dark-mode')+    .addEventListener('click', () => {+      document.body.classList.toggle('dark-mode')+      if (document.body.classList.contains('dark-mode')) {+        localStorage.setItem(DARK_MODE_OPT, DARK_MODE_ACTIVE)+      } else {+        localStorage.setItem(DARK_MODE_OPT, DARK_MODE_INACTIVE)+      }+    })++  document.querySelectorAll('a.copy-to-clipboard').forEach(node =>+    node.addEventListener('click', () => {+      const temp = document.createElement('input')+      document.body.append(temp)+      temp.value = node.dataset.path+      temp.select()+      document.execCommand("copy");+      temp.remove()+    }))++  document.querySelectorAll('.source-code a.name-use, .source-code span.name-decl')+    .forEach(node => {+      node.addEventListener('mouseover', () => highlightNames(node.dataset.name, true))+      node.addEventListener('mouseout', () => highlightNames(node.dataset.name, false))+    })+}++function highlightNames(varId, highlight) {+  document.querySelectorAll(`#${varId}, [href="#${varId}"]`).forEach(node => {+    if (highlight) {+      node.classList.add('highlighted')+    } else {+      node.classList.remove('highlighted')+    }+  })+}+++if (document.readyState != 'loading'){+  onReady();+} else {+  document.addEventListener('DOMContentLoaded', onReady);+}
− src/Dhall/data/dhall-icon.svg
@@ -1,1 +0,0 @@-<?xml version="1.0" encoding="UTF-8" standalone="no"?><!-- Generator: Gravit.io --><svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" style="isolation:isolate" viewBox="701 377 180 180" width="180pt" height="180pt"><defs><clipPath id="_clipPath_bHCrHBHhrzISq2YnO5draXOg8wrP22Y8"><rect x="701" y="377" width="180" height="180"/></clipPath></defs><g clip-path="url(#_clipPath_bHCrHBHhrzISq2YnO5draXOg8wrP22Y8)"><path d=" M 791 377 C 840.672 377 881 417.328 881 467 C 881 516.672 840.672 557 791 557 C 741.328 557 701 516.672 701 467 C 701 417.328 741.328 377 791 377 Z  M 773.725 507.794 C 778.868 506.416 784.161 509.472 785.539 514.615 C 786.917 519.757 783.861 525.051 778.718 526.429 C 773.576 527.807 768.282 524.751 766.904 519.608 C 765.526 514.466 768.582 509.172 773.725 507.794 Z  M 825.655 406.546 C 827.502 407.041 828.6 408.943 828.105 410.79 C 827.61 412.637 825.709 413.734 823.862 413.239 L 820.634 412.375 C 820.047 417.121 816.961 443.216 818.245 458.044 C 804.548 469.874 780.875 505.457 780.875 505.457 L 793.315 459.031 C 795.744 458.876 798.412 457.332 799.076 454.852 C 799.909 451.743 798.061 448.542 794.952 447.709 C 791.843 446.876 788.642 448.724 787.809 451.833 C 787.145 454.313 788.683 456.984 790.709 458.332 L 778.269 504.759 C 778.269 504.759 774.975 463.985 769.612 445.012 C 778.328 433.72 788.578 408.768 790.391 404.271 L 787.15 403.403 C 785.303 402.908 784.206 401.006 784.701 399.159 C 785.196 397.312 787.097 396.215 788.944 396.71 L 825.655 406.546 L 825.655 406.546 Z " fill-rule="evenodd" fill="rgb(235,235,235)"/></g></svg>
− src/Dhall/data/index.css
@@ -1,229 +0,0 @@-/*-    primary-color: #C4C4C4-    secondary-color: #EBEBEB-    accent-color1: #FFA632-    accent-color2: #008489-    accent-color3: #914669-*/--/******** Common rules ********/--body {-    padding: 0;-    margin: 0;-    background-color: #EBEBEB;-    transition: 0.5s;-}--body * {-    font-family: 'Lato', sans-serif;-}--a {-    transition: 0.5s;-    color: #008489;-}--a:visited {-    color: #914669;-}--a:active {-    color: #FFA632;-}--/******** Markdown specific code ********/--code {-    font-family: 'Fira Code', monospace;-}--blockquote {-    border-left: 9px solid #aaa;-    background-color: #bdbdbd;-    padding: 0.2rem;-    color: #616161;-}--/******** Nav bar **********/--.nav-bar {-    display: flex;-    align-items: center;-    padding: 0.3rem;-    background-color: #484848;-    color: #EBEBEB;-    transition: 0.5s;-}--.nav-bar .dhall-icon {-    max-width: 2.5rem;-    margin: 0.5rem;-}--.nav-bar .package-title {-    font-size: 1.3rem;-    margin: 0;-    margin-left: 1rem;-}--.nav-bar a.nav-option {-    font-size: 1rem;-    height: 100%;-    margin: 0 0.5rem;-    cursor: pointer;-    transition: 0.5s;-    text-decoration: none;-}--.nav-bar a.nav-option:hover {-    text-decoration: underline;-    text-decoration-color: #EBEBEB;-}--.nav-bar a.nav-option:active, .nav-bar a.nav-option, .nav-bar a.nav-option:visited {-    color: #EBEBEB;-}--.nav-bar .nav-bar-content-divider {-    flex: 1;-}--/******** Main content **********/--.main-container {-    padding: 2rem;-    padding-top: 0;-    transition: 0.5s;-}--h2.doc-title span, h2.doc-title a {-    font-family: 'Fira Code', monospace;-}--span.crumb-divider:first-child {-    margin-left: 0;-}--span.crumb-divider {-    margin: 0 0.5rem;-}--a.title-crumb {-    text-decoration: none;-}--a.title-crumb:hover {-    text-decoration: underline;-}--a.copy-to-clipboard {-    margin-top: 0;-    color: #888 !important;-    user-select: none;-    cursor: pointer;-    text-decoration: none;-}--a.copy-to-clipboard:hover {-    text-decoration: underline;-}--h2.doc-title {-    margin-bottom: 0;-}--/******** Source code **********/---.code-examples > pre {-    padding-top: 0 !important;-    padding-bottom: 0 !important;-}--.source-code {-    padding: 0rem;-}--.source-code pre {-    padding: 1rem;-    font-family: 'Fira Code', monospace;-    color: #333333;-}--.source-code span {-    font-family: 'Fira Code', monospace;-    color: #333333;-}--.source-code a {-    font-family: 'Fira Code', monospace;-}--.dhall-type {-    font-family: 'Fira Code', monospace;-}--.dhall-type pre {-    display: inline;-    padding: 0;-}--span.of-type-token {-    margin-left: 0.5rem;-    margin-right: 0.5rem;-}--/******** Dark mode styling ********/--.dark-mode .main-container {-    color: #EBEBEB;-}--body.dark-mode {-    background-color: #484848;-}--.dark-mode .nav-bar {-    background-color: #5d5d5d;-}--.dark-mode a {-    color: #FFA632;-}--.dark-mode a:visited {-    color: #008489;-}--.dark-mode a:active {-    color: #914669;-}--.dark-mode .source-code pre {-    color: #D4D4D4;-}--.dark-mode .source-code span {-    color: #D4D4D4;-}--.dark-mode .source-code span.dhall-keyword {-    color: #569CD6;-}--.dark-mode .source-code span.dhall-syntax {-    color: #C586C0;-}--.dark-mode .source-code span.dhall-literal {-    color: #B5CEA8;-}--.dark-mode .source-code span.dhall-builtin {-    color: #4EC9B0;-}--.dark-mode a.copy-to-clipboard {-    color: #bdbdbd !important;-}
− src/Dhall/data/index.js
@@ -1,36 +0,0 @@-const DARK_MODE_OPT = 'dark-mode'-const DARK_MODE_ACTIVE = 'dark-mode-active'-const DARK_MODE_INACTIVE = 'dark-mode-inactive'--function onReady() {-  if (localStorage.getItem(DARK_MODE_OPT) == DARK_MODE_ACTIVE) {-    document.body.classList.add('dark-mode')-  } else {-    document.body.classList.remove('dark-mode')-  }-  document.getElementById('switch-light-dark-mode')-    .addEventListener('click', () => {-      document.body.classList.toggle('dark-mode')-      if (document.body.classList.contains('dark-mode')) {-        localStorage.setItem(DARK_MODE_OPT, DARK_MODE_ACTIVE)-      } else {-        localStorage.setItem(DARK_MODE_OPT, DARK_MODE_INACTIVE)-      }-    })--  document.querySelectorAll('a.copy-to-clipboard').forEach(node =>-    node.addEventListener('click', () => {-      const temp = document.createElement('input')-      document.body.append(temp)-      temp.value = node.dataset.path-      temp.select()-      document.execCommand("copy");-      temp.remove()-    }))-}--if (document.readyState != 'loading'){-  onReady();-} else {-  document.addEventListener('DOMContentLoaded', onReady);-}
+ src/Dhall/data/man/dhall-docs.1 view
@@ -0,0 +1,36 @@+.\" Automatically generated by Pandoc 2.10.1+.\"+.TH "dhall-docs (1)" "" "" "" ""+.hy+.SH NAME+.PP+dhall-docs - Dhall documentation tool+.SH DESCRIPTION+.PP+\f[B]dhall-docs\f[R] is a documentation generator for the Dhall language+.SH SYNOPSIS+.PP+dhall-docs --input DIR+.PP+dhall-docs --input DIR --output-link SYMLINK_DIR+.SH OPTIONS+.TP+\f[B]-h\f[R] \f[B]--help\f[R]+Display help+.TP+\f[B]--input\f[R]+Directory of Dhall package+.TP+\f[B]--output-link\f[R]+Directory for generated documentation, or symlink to directory.+Defaults to \[aq]./docs\[aq]+.TP+\f[B]--package-name\f[R]+Package name; defaults to the input directory if not given.+.TP+\f[B]--ascii\f[R]+Format rendered code using ASCII syntax+.SH BUGS+.PP+Please report any bugs you may come across to+https://github.com/dhall-language/dhall-haskell/issues.
− tasty/data/golden/IndexesExample.dhall.html
@@ -1,52 +0,0 @@-<!DOCTYPE HTML>-<html-  ><head-    ><title-    >/IndexesExample.dhall</title-    ><link href="index.css" type="text/css" rel="stylesheet"-    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"-            type="text/css" rel="stylesheet"-    /><script src="index.js" type="text/javascript"-    /><meta charset="UTF-8"/></head-  ><body-    ><div class="nav-bar"-      ><img src="dhall-icon.svg" class="dhall-icon"-      /><p class="package-title"-      >test-package</p-      ><div class="nav-bar-content-divider"-      /><a id="switch-light-dark-mode" class="nav-option"-      >Switch Light/Dark Mode</a></div-    ><div class="main-container"-      ><h2 class="doc-title"-        ><span class="crumb-divider"-        >/</span-        ><a href="index.html"-        >test-package</a-        ><span class="crumb-divider"-        >/</span-        ><span href="index.html" class="title-crumb"-        >IndexesExample.dhall</span></h2-      ><a data-path="/IndexesExample.dhall" class="copy-to-clipboard"-        ><i-          ><small-          >Copy path to clipboard</small></i></a-      ><br-      /><div class="doc-contents"-        ><p-          >This example shows that <code-          >dhall-docs</code> will find render the correct type on the-index respecting variable indices</p>-</div-      ><h3-      >Source</h3-      ><div class="source-code"-        ><pre-          >{-|<br-          />This example shows that `dhall-docs` will find render the correct type on the<br-          />index respecting variable indices<br-          />-}<br-          /><br-          />let x : Bool = True<br-          />let x : Natural = 1<br-          /><br-          />in x@1<br/></pre></div></div></body></html>
tasty/data/golden/InvalidMarkdown.dhall.html view
@@ -42,12 +42,19 @@           >--| This file contains a markdown error right here `<br           />--  did you notice it?<br           /><br-          />let Pair = <a href="./Pair.dhall.html"+          />let <span data-name="var4-5" id="var4-5" class="name-decl"+          >Pair</span+          > = <a href="./Pair.dhall.html"           >./Pair.dhall</a           ><br           /><br-          />let DeliveryStatus =<br-          />    &lt; Sent: Pair Natural Text {-| Message has been _sent_. It carries a ./Pair.dhall reference<br+          />let <span data-name="var6-5" id="var6-5" class="name-decl"+          >DeliveryStatus</span+          > =<br+          />    &lt; Sent: <a href="#var4-5" data-name="var4-5"+                              class="name-use"+          >Pair</a+          > Natural Text {-| Message has been _sent_. It carries a ./Pair.dhall reference<br           />                                    containing on the `first` field number of retries<br           />                                    and on the `second` field the delivered text<br           />                                -}<br@@ -55,4 +62,6 @@           />    | InQueue                   -- | Delivery for this message **hasn&#39;t** started<br           />    &gt;<br           /><br-          />in DeliveryStatus<br/></pre></div></div></body></html>+          />in <a href="#var6-5" data-name="var6-5" class="name-use"+          >DeliveryStatus</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToDefOnUnused.dhall.html view
@@ -0,0 +1,92 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToDefOnUnused.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToDefOnUnused.dhall</span></h2+      ><a data-path="/JumpToDefOnUnused.dhall" class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          ><code+          >dhall-docs</code> will detect some names (record fields, let-bindings and lam-bindings)+are unused and therefore won&#39;t be highlighted</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />`dhall-docs` will detect some names (record fields, let-bindings and lam-bindings)<br+          />are unused and therefore won&#39;t be highlighted<br+          />-}<br+          /><br+          />let unused = 1<br+          />let <span data-name="var7-5" id="var7-5" class="name-decl"+          >used</span+          > = 3<br+          /><br+          />let unusedRecord = { foo = 1 }<br+          />let <span data-name="var10-5" id="var10-5" class="name-decl"+          >usedRecord</span+          > = { <span data-name="var10-20" id="var10-20" class="name-decl"+          >foo</span+          > = 1 }<br+          /><br+          />let <span data-name="var12-5" id="var12-5" class="name-decl"+          >f</span+          > =<br+          />       \(unused : Bool)<br+          />    -&gt; \(<span data-name="var14-10" id="var14-10"+                              class="name-decl"+          >used</span+          > : Natural)<br+          />    -&gt; \(<span data-name="var15-10" id="var15-10"+                              class="name-decl"+          >r</span+          > : { unused : Text, <span data-name="var15-31" id="var15-31"+                                     class="name-decl"+          >used</span+          > : Natural}) -&gt; <a href="#var14-10" data-name="var14-10"+                                 class="name-use"+          >used</a+          > + <a href="#var15-10" data-name="var15-10" class="name-use"+          >r</a+          >.<a href="#var15-31" data-name="var15-31" class="name-use"+          >used</a+          ><br+          /><br+          />in <a href="#var7-5" data-name="var7-5" class="name-use"+          >used</a+          > + <a href="#var10-5" data-name="var10-5" class="name-use"+          >usedRecord</a+          >.<a href="#var10-20" data-name="var10-20" class="name-use"+          >foo</a+          > + <a href="#var12-5" data-name="var12-5" class="name-use"+          >f</a+          > True 1 { unused = &quot;foo&quot;, used = 3 }<br/></pre></div></div></body></html>
tasty/data/golden/JumpToHereImports.dhall.html view
@@ -36,7 +36,9 @@       >Source</h3       ><div class="source-code"         ><pre-          >let relatives =<br+          >let <span data-name="var1-5" id="var1-5" class="name-decl"+          >relatives</span+          > =<br           />    [ <a href="./IndexesExample.dhall.html"           >./IndexesExample.dhall</a           ><br@@ -48,11 +50,17 @@           ><br           />    ]<br           /><br-          />let moreRelatives =<br+          />let <span data-name="var7-5" id="var7-5" class="name-decl"+          >moreRelatives</span+          > =<br           />    [ <a href="./OrdinaryAnnotation.dhall.html"           >./OrdinaryAnnotation.dhall</a           > ,    <a href="./TwoAnnotations.dhall.html"           >./TwoAnnotations.dhall</a           > ]<br           /><br-          />in relatives # moreRelatives<br/></pre></div></div></body></html>+          />in <a href="#var1-5" data-name="var1-5" class="name-use"+          >relatives</a+          > # <a href="#var7-5" data-name="var7-5" class="name-use"+          >moreRelatives</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToLamBindingComplex.dhall.html view
@@ -0,0 +1,81 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToLamBindingComplex.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToLamBindingComplex.dhall</span></h2+      ><a data-path="/JumpToLamBindingComplex.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+        >A complex example of jump-to-definition on let-bindings</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />A complex example of jump-to-definition on let-bindings<br+          />-}<br+          />let <span data-name="var4-5" id="var4-5" class="name-decl"+          >fun</span+          > =<br+          />    λ(<span data-name="var5-7" id="var5-7" class="name-decl"+          >a</span+          > : Text) -&gt;<br+          />    λ(<span data-name="var6-7" id="var6-7" class="name-decl"+          >b</span+          > : Text) -&gt;<br+          />    λ(<span data-name="var7-7" id="var7-7" class="name-decl"+          >c</span+          > : Text) -&gt;<br+          />    λ(<span data-name="var8-7" id="var8-7" class="name-decl"+          >d</span+          > : Text) -&gt;<br+          />    [ <a href="#var5-7" data-name="var5-7" class="name-use"+          >a</a+          > ++ <a href="#var6-7" data-name="var6-7" class="name-use"+          >b</a+          >, <a href="#var6-7" data-name="var6-7" class="name-use"+          >b</a+          > ++ <a href="#var7-7" data-name="var7-7" class="name-use"+          >c</a+          >, <a href="#var7-7" data-name="var7-7" class="name-use"+          >c</a+          > ++ <a href="#var8-7" data-name="var8-7" class="name-use"+          >d</a+          >, <a href="#var8-7" data-name="var8-7" class="name-use"+          >d</a+          > ++ <a href="#var5-7" data-name="var5-7" class="name-use"+          >a</a+          > ]<br+          /><br+          />in <a href="#var4-5" data-name="var4-5" class="name-use"+          >fun</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToLamBindingSimple.dhall.html view
@@ -0,0 +1,124 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToLamBindingSimple.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToLamBindingSimple.dhall</span></h2+      ><a data-path="/JumpToLamBindingSimple.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          >This examples shows a demo of jumping to a let-binding definition. If you hover+the <code+          >a</code> paramter, the front-end will highlight all of its usages and if you+click it you will navigate to its definition.</p+        >+<p+        >The amount of empty lines left are intentional to show you how the browser jumps+to the declaration of a</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />This examples shows a demo of jumping to a let-binding definition. If you hover<br+          />the `a` paramter, the front-end will highlight all of its usages and if you<br+          />click it you will navigate to its definition.<br+          /><br+          />The amount of empty lines left are intentional to show you how the browser jumps<br+          />to the declaration of a<br+          />-}<br+          />let <span data-name="var9-5" id="var9-5" class="name-decl"+          >fun</span+          > = \(<span data-name="var9-13" id="var9-13" class="name-decl"+          >v</span+          > : Text) -&gt;<br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          />    <a href="#var9-13" data-name="var9-13" class="name-use"+          >v</a+          ><br+          /><br+          /><br+          /><br+          />in <a href="#var9-5" data-name="var9-5" class="name-use"+          >fun</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToLamBindingWithIndex.dhall.html view
@@ -0,0 +1,81 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToLamBindingWithIndex.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToLamBindingWithIndex.dhall</span></h2+      ><a data-path="/JumpToLamBindingWithIndex.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          >On this example, we introduce the <code+          >a</code+          > variable in the two parameters of the+<code+          >fun</code> function and the jump-to-definition engine correctly highlights the usage+when indexes are used</p>+</div+      ><h3+      >Examples</h3+      ><div class="source-code code-examples"+        ><pre+          >fun &quot;a&quot; &quot;b&quot; ≡ [ &quot;ab&quot; ]<br/></pre></div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />On this example, we introduce the `a` variable in the two parameters of the<br+          />`fun` function and the jump-to-definition engine correctly highlights the usage<br+          />when indexes are used<br+          />-}<br+          />let <span data-name="var6-5" id="var6-5" class="name-decl"+          >fun</span+          > =<br+          />    λ(<span data-name="var7-7" id="var7-7" class="name-decl"+          >a</span+          > : Text) -&gt;<br+          />    λ(<span data-name="var8-7" id="var8-7" class="name-decl"+          >a</span+          > : Text) -&gt;<br+          />    [ <a href="#var7-7" data-name="var7-7" class="name-use"+          >a@1</a+          > ++ <a href="#var8-7" data-name="var8-7" class="name-use"+          >a@0</a+          > ]<br+          /><br+          />let example0 = assert : <a href="#var6-5" data-name="var6-5"+                                       class="name-use"+          >fun</a+          > &quot;a&quot; &quot;b&quot; === [&quot;ab&quot;]<br+          /><br+          />in <a href="#var6-5" data-name="var6-5" class="name-use"+          >fun</a+          ><br+          /><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToLamBindingWithQuotes.dhall.html view
@@ -0,0 +1,76 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToLamBindingWithQuotes.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToLamBindingWithQuotes.dhall</span></h2+      ><a data-path="/JumpToLamBindingWithQuotes.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+        >This tests shows that the feature works for quoted vars on function parameters+as well</p>+</div+      ><h3+      >Examples</h3+      ><div class="source-code code-examples"+        ><pre+          >fun &quot;a&quot; &quot;b&quot; ≡ [ &quot;ab&quot; ]<br/></pre></div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />This tests shows that the feature works for quoted vars on function parameters<br+          />as well<br+          />-}<br+          />let <span data-name="var5-5" id="var5-5" class="name-decl"+          >fun</span+          > =<br+          />    λ(<span data-name="var6-7" id="var6-7" class="name-decl"+          >`param 1`</span+          > : Text) -&gt;<br+          />    λ(<span data-name="var7-7" id="var7-7" class="name-decl"+          >`param 2`</span+          > : Text) -&gt;<br+          />    [ <a href="#var6-7" data-name="var6-7" class="name-use"+          >`param 1`</a+          > ++ <a href="#var7-7" data-name="var7-7" class="name-use"+          >`param 2`</a+          > ]<br+          /><br+          />let example0 = assert : <a href="#var5-5" data-name="var5-5"+                                       class="name-use"+          >fun</a+          > &quot;a&quot; &quot;b&quot; === [&quot;ab&quot;]<br+          /><br+          />in <a href="#var5-5" data-name="var5-5" class="name-use"+          >fun</a+          ><br+          /><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToLamBindingWithShadowing.dhall.html view
@@ -0,0 +1,79 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToLamBindingWithShadowing.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToLamBindingWithShadowing.dhall</span></h2+      ><a data-path="/JumpToLamBindingWithShadowing.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          >On this example, the first parameter <code+          >a</code+          > is shadowed with the second declaration.+The jump-to-definintion on the usage of <code+          >a</code> should not highlight the first declaration,+and interacting with the first declaration should not change the others</p>+</div+      ><h3+      >Examples</h3+      ><div class="source-code code-examples"+        ><pre+          >fun &quot;a&quot; &quot;b&quot; ≡ [ &quot;bb&quot; ]<br/></pre></div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />On this example, the first parameter `a` is shadowed with the second declaration.<br+          />The jump-to-definintion on the usage of `a` should not highlight the first declaration,<br+          />and interacting with the first declaration should not change the others<br+          />-}<br+          />let <span data-name="var6-5" id="var6-5" class="name-decl"+          >fun</span+          > =<br+          />    λ(a : Text) -&gt;<br+          />    λ(<span data-name="var8-7" id="var8-7" class="name-decl"+          >a</span+          > : Text) -&gt;<br+          />    [ <a href="#var8-7" data-name="var8-7" class="name-use"+          >a</a+          > ++ <a href="#var8-7" data-name="var8-7" class="name-use"+          >a</a+          > ]<br+          /><br+          />let example0 = assert : <a href="#var6-5" data-name="var6-5"+                                       class="name-use"+          >fun</a+          > &quot;a&quot; &quot;b&quot; === [&quot;bb&quot;]<br+          /><br+          />in <a href="#var6-5" data-name="var6-5" class="name-use"+          >fun</a+          ><br+          /><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToLetBindingSimple.dhall.html view
@@ -0,0 +1,105 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToLetBindingSimple.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToLetBindingSimple.dhall</span></h2+      ><a data-path="/JumpToLetBindingSimple.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          >This examples shows a demo of jumping to a let-binding definition. If you hover+the <code+          >a</code> variable, the front-end will highlight all of its usages and if you+click it you will navigate to its definition.</p+        >+<p+        >The amount of empty lines left are intentional to show you how the browser jumps+to the declaration of a</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />This examples shows a demo of jumping to a let-binding definition. If you hover<br+          />the `a` variable, the front-end will highlight all of its usages and if you<br+          />click it you will navigate to its definition.<br+          /><br+          />The amount of empty lines left are intentional to show you how the browser jumps<br+          />to the declaration of a<br+          />-}<br+          />let <span data-name="var9-5" id="var9-5" class="name-decl"+          >a</span+          > = 1<br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          /><br+          />in<br+          /><br+          /><a href="#var9-5" data-name="var9-5" class="name-use"+          >a</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToLetBindingWithIndex.dhall.html view
@@ -0,0 +1,57 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToLetBindingWithIndex.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToLetBindingWithIndex.dhall</span></h2+      ><a data-path="/JumpToLetBindingWithIndex.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          >Although we have a similar example on this <a href="./RenderTypeIndexesExample.dhall"+          >file</a>,+this example showcases the jump-to-definition feature when indexes are used.</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />Although we have a similar example on this [file](./RenderTypeIndexesExample.dhall),<br+          />this example showcases the jump-to-definition feature when indexes are used.<br+          />-}<br+          />let <span data-name="var5-5" id="var5-5" class="name-decl"+          >a</span+          > = 1<br+          /><br+          />let a = 2<br+          /><br+          />in <a href="#var5-5" data-name="var5-5" class="name-use"+          >a@1</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToLetBindingWithQuotes.dhall.html view
@@ -0,0 +1,58 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToLetBindingWithQuotes.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToLetBindingWithQuotes.dhall</span></h2+      ><a data-path="/JumpToLetBindingWithQuotes.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+        >This test cases shows that the feature works with quoted variables</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />This test cases shows that the feature works with quoted variables<br+          />-}<br+          />let <span data-name="var4-5" id="var4-5" class="name-decl"+          >`quoted variable`</span+          > = 1<br+          /><br+          />let <span data-name="var6-5" id="var6-5" class="name-decl"+          >nonQuoted</span+          > = 2<br+          /><br+          />in <a href="#var4-5" data-name="var4-5" class="name-use"+          >`quoted variable`</a+          > + <a href="#var6-5" data-name="var6-5" class="name-use"+          >`nonQuoted`</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToLetBindingWithShadowing.dhall.html view
@@ -0,0 +1,63 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToLetBindingWithShadowing.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToLetBindingWithShadowing.dhall</span></h2+      ><a data-path="/JumpToLetBindingWithShadowing.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          >On this example, the first declaration of variable <code+          >a</code+          > is shadowed with the+later declaration. The jump-to-definintion on the usage of <code+          >a</code>+should not highlight the first declaration, and interacting with the first+declaration should not change the others</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />On this example, the first declaration of variable `a` is shadowed with the<br+          />later declaration. The jump-to-definintion on the usage of `a`<br+          />should not highlight the first declaration, and interacting with the first<br+          />declaration should not change the others<br+          />-}<br+          />let a = 1<br+          /><br+          />let <span data-name="var9-5" id="var9-5" class="name-decl"+          >a</span+          > = 2<br+          /><br+          />in <a href="#var9-5" data-name="var9-5" class="name-use"+          >a</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToLetbindingComplex.dhall.html view
@@ -0,0 +1,75 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToLetbindingComplex.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToLetbindingComplex.dhall</span></h2+      ><a data-path="/JumpToLetbindingComplex.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+        >A complex example of jump-to-definition on let-bindings</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />A complex example of jump-to-definition on let-bindings<br+          />-}<br+          />let <span data-name="var4-5" id="var4-5" class="name-decl"+          >f</span+          > = \(<span data-name="var4-11" id="var4-11" class="name-decl"+          >f</span+          > : Natural) -&gt;<br+          />    let <span data-name="var5-9" id="var5-9" class="name-decl"+          >a</span+          > = 1 in <a href="#var4-11" data-name="var4-11" class="name-use"+          >f</a+          > + <a href="#var5-9" data-name="var5-9" class="name-use"+          >a</a+          ><br+          /><br+          />let <span data-name="var7-5" id="var7-5" class="name-decl"+          >a</span+          > = <a href="#var4-5" data-name="var4-5" class="name-use"+          >f</a+          > 1<br+          /><br+          />let <span data-name="var9-5" id="var9-5" class="name-decl"+          >b</span+          > = <a href="#var7-5" data-name="var7-5" class="name-use"+          >a</a+          > + <a href="#var4-5" data-name="var4-5" class="name-use"+          >f</a+          > 3<br+          /><br+          />in <a href="#var9-5" data-name="var9-5" class="name-use"+          >b</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToRecordFieldWhenFieldDoesNotExist.dhall.html view
@@ -0,0 +1,67 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToRecordFieldWhenFieldDoesNotExist.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToRecordFieldWhenFieldDoesNotExist.dhall</span></h2+      ><a data-path="/JumpToRecordFieldWhenFieldDoesNotExist.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          >On this example, <code+          >dhall-docs</code+          > will detect that the variable <code+          >a</code+          > and <code+          >b</code> is of+record-type. If on a selector-expression the field is not found on the type,+no-link will be created</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />On this example, `dhall-docs` will detect that the variable `a` and `b` is of<br+          />record-type. If on a selector-expression the field is not found on the type,<br+          />no-link will be created<br+          /><br+          />-}<br+          />let <span data-name="var7-5" id="var7-5" class="name-decl"+          >a</span+          > = { x = &quot;foo&quot; }<br+          />let <span data-name="var8-5" id="var8-5" class="name-decl"+          >b</span+          > = False<br+          /><br+          />in <a href="#var7-5" data-name="var7-5" class="name-use"+          >a</a+          >.y + <a href="#var8-5" data-name="var8-5" class="name-use"+          >b</a+          >.`does not exist`<br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToRecordFieldWhenLetAnnotationPresentShouldIgnoreAnnotation.dhall.html view
@@ -0,0 +1,74 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToRecordFieldWhenLetAnnotationPresentShouldIgnoreAnnotation.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToRecordFieldWhenLetAnnotationPresentShouldIgnoreAnnotation.dhall</span></h2+      ><a data-path="/JumpToRecordFieldWhenLetAnnotationPresentShouldIgnoreAnnotation.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          >On this example, <code+          >dhall-docs</code+          > will detect that the variable <code+          >a</code+          > is annotated+with a type, but it will ignore it anyways. On let-bindings, <code+          >dhall-docs</code+          > infers+the type of the variable from the bounded expression. As a consequence, on+this example, hovering the <code+          >x</code+          > on the selector-expression will highlight the+<code+          >x</code> label on the record-literal</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />On this example, `dhall-docs` will detect that the variable `a` is annotated<br+          />with a type, but it will ignore it anyways. On let-bindings, `dhall-docs` infers<br+          />the type of the variable from the bounded expression. As a consequence, on<br+          />this example, hovering the `x` on the selector-expression will highlight the<br+          />`x` label on the record-literal<br+          />-}<br+          />let <span data-name="var8-5" id="var8-5" class="name-decl"+          >a</span+          > : Bool = { <span data-name="var8-18" id="var8-18"+                             class="name-decl"+          >x</span+          > = &quot;foo&quot; }<br+          /><br+          />in <a href="#var8-5" data-name="var8-5" class="name-use"+          >a</a+          >.<a href="#var8-18" data-name="var8-18" class="name-use"+          >x</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToRecordFieldWhenVarIsAnnotatedWithRecordType.dhall.html view
@@ -0,0 +1,79 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToRecordFieldWhenVarIsAnnotatedWithRecordType.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToRecordFieldWhenVarIsAnnotatedWithRecordType.dhall</span></h2+      ><a data-path="/JumpToRecordFieldWhenVarIsAnnotatedWithRecordType.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          >On this example, even when the variable <code+          >a</code+          > is annotated with a record-type,+<code+          >dhall-docs</code> will infer the actual type from the bounded value.</p+        >+<p+        >All interactions with fields on selector-expressions won&#39;t affect the rendered-type.</p+        >+<p+        >(The example is intended to not type-check as a Dhall expression)</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />On this example, even when the variable `a` is annotated with a record-type,<br+          />`dhall-docs` will infer the actual type from the bounded value.<br+          /><br+          />All interactions with fields on selector-expressions won&#39;t affect the rendered-type.<br+          /><br+          />(The example is intended to not type-check as a Dhall expression)<br+          />-}<br+          />let <span data-name="var9-5" id="var9-5" class="name-decl"+          >a</span+          > : { x : Text } = { <span data-name="var9-26" id="var9-26"+                                     class="name-decl"+          >x</span+          > = &quot;foo&quot;, <span data-name="var9-37" id="var9-37"+                                     class="name-decl"+          >y</span+          > = &quot;bar&quot; }<br+          /><br+          />in <a href="#var9-5" data-name="var9-5" class="name-use"+          >a</a+          >.<a href="#var9-26" data-name="var9-26" class="name-use"+          >x</a+          > ++ <a href="#var9-5" data-name="var9-5" class="name-use"+          >a</a+          >.<a href="#var9-37" data-name="var9-37" class="name-use"+          >y</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToRecordFieldWhenVarIsOfRecordType.dhall.html view
@@ -0,0 +1,72 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToRecordFieldWhenVarIsOfRecordType.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToRecordFieldWhenVarIsOfRecordType.dhall</span></h2+      ><a data-path="/JumpToRecordFieldWhenVarIsOfRecordType.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          >On this example, <code+          >dhall-docs</code+          > will detect that the variable <code+          >a</code+          > is bounded+to a record-literal. When the user clicks on the <code+          >field</code+          > in the <code+          >a.field</code+          >, it+will jump to the definition of that field in the source code i.e. to the <code+          >field</code>+key in the record literal</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />On this example, `dhall-docs` will detect that the variable `a` is bounded<br+          />to a record-literal. When the user clicks on the `field` in the `a.field`, it<br+          />will jump to the definition of that field in the source code i.e. to the `field`<br+          />key in the record literal<br+          />-}<br+          />let <span data-name="var7-5" id="var7-5" class="name-decl"+          >a</span+          > = { <span data-name="var7-11" id="var7-11" class="name-decl"+          >field</span+          > = &quot;foo&quot; }<br+          /><br+          />in Text/show <a href="#var7-5" data-name="var7-5"+                            class="name-use"+          >a</a+          >.<a href="#var7-11" data-name="var7-11" class="name-use"+          >field</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToRecordFieldWhenVarIsOfRecordTypeComplex.dhall.html view
@@ -0,0 +1,84 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToRecordFieldWhenVarIsOfRecordTypeComplex.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToRecordFieldWhenVarIsOfRecordTypeComplex.dhall</span></h2+      ><a data-path="/JumpToRecordFieldWhenVarIsOfRecordTypeComplex.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+        >A complex example of the jump-to-definition feature on record literals.</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />A complex example of the jump-to-definition feature on record literals.<br+          />-}<br+          />let <span data-name="var4-5" id="var4-5" class="name-decl"+          >a</span+          > =<br+          />    { <span data-name="var5-7" id="var5-7" class="name-decl"+          >foo</span+          > = &quot;bar&quot;, <span data-name="var5-20" id="var5-20"+                                     class="name-decl"+          >number</span+          > = +1 }<br+          /><br+          />let <span data-name="var7-5" id="var7-5" class="name-decl"+          >b</span+          > =<br+          />    { <span data-name="var8-7" id="var8-7" class="name-decl"+          >foo</span+          > = &quot;bar&quot;, <span data-name="var8-20" id="var8-20"+                                     class="name-decl"+          >number</span+          > = +1 }<br+          /><br+          />in <a href="#var4-5" data-name="var4-5" class="name-use"+          >a</a+          >.<a href="#var5-7" data-name="var5-7" class="name-use"+          >foo</a+          > ++ Integer/show <a href="#var4-5" data-name="var4-5"+                               class="name-use"+          >a</a+          >.<a href="#var5-20" data-name="var5-20" class="name-use"+          >number</a+          > ++ <a href="#var7-5" data-name="var7-5" class="name-use"+          >b</a+          >.<a href="#var8-7" data-name="var8-7" class="name-use"+          >foo</a+          > ++ Integer/show <a href="#var7-5" data-name="var7-5"+                               class="name-use"+          >b</a+          >.<a href="#var8-20" data-name="var8-20" class="name-use"+          >number</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToRecordFieldWhenVarIsOfRecordTypeDeep.dhall.html view
@@ -0,0 +1,78 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToRecordFieldWhenVarIsOfRecordTypeDeep.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToRecordFieldWhenVarIsOfRecordTypeDeep.dhall</span></h2+      ><a data-path="/JumpToRecordFieldWhenVarIsOfRecordTypeDeep.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          >On this example, <code+          >dhall-docs</code+          > will detect that the variable <code+          >a</code+          > is bounded+to a record literal. It will also detect that the <code+          >field</code+          > key from the record+literal is another record literal. When the user clicks <code+          >deep</code+          > from the+<code+          >a.field.deep</code>, it will jump to the definition of that variable in the source+code.</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />On this example, `dhall-docs` will detect that the variable `a` is bounded<br+          />to a record literal. It will also detect that the `field` key from the record<br+          />literal is another record literal. When the user clicks `deep` from the<br+          />`a.field.deep`, it will jump to the definition of that variable in the source<br+          />code.<br+          />-}<br+          />let <span data-name="var8-5" id="var8-5" class="name-decl"+          >a</span+          > = { <span data-name="var8-11" id="var8-11" class="name-decl"+          >field</span+          > = { <span data-name="var8-21" id="var8-21" class="name-decl"+          >deep</span+          > = &quot;bar&quot; } }<br+          /><br+          />in Text/show <a href="#var8-5" data-name="var8-5"+                            class="name-use"+          >a</a+          >.<a href="#var8-11" data-name="var8-11" class="name-use"+          >field</a+          >.<a href="#var8-21" data-name="var8-21" class="name-use"+          >deep</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToRecordFieldWhenVarIsOfRecordTypeFromLamBinding.dhall.html view
@@ -0,0 +1,112 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToRecordFieldWhenVarIsOfRecordTypeFromLamBinding.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToRecordFieldWhenVarIsOfRecordTypeFromLamBinding.dhall</span></h2+      ><a data-path="/JumpToRecordFieldWhenVarIsOfRecordTypeFromLamBinding.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          >On this example, <code+          >dhall-docs</code+          > will detect that the argument <code+          >a</code+          > of the only+function in this file is of record type. Therefore, any interactions on selector+expressions over the <code+          >a</code> variable will interact with the fields on the record-type.</p+        >+<p+          >Note that the treatment for <code+          >Lam</code+          > variables is different from <code+          >Let</code+          > bindings:+the annotation doesn&#39;t affect on the later case. This can be seen in the+<a href="./JumpToRecordFieldWhenLetAnnotationPresentShouldIgnoreAnnotation.dhall"+          >test case for let bindings</a></p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />On this example, `dhall-docs` will detect that the argument `a` of the only<br+          />function in this file is of record type. Therefore, any interactions on selector<br+          />expressions over the `a` variable will interact with the fields on the record-type.<br+          /><br+          />Note that the treatment for `Lam` variables is different from `Let` bindings:<br+          />the annotation doesn&#39;t affect on the later case. This can be seen in the<br+          />[test case for let bindings](./JumpToRecordFieldWhenLetAnnotationPresentShouldIgnoreAnnotation.dhall)<br+          />-}<br+          /><br+          />λ(<span data-name="var11-3" id="var11-3" class="name-decl"+          >b</span+          > : Type) →<br+          />λ(<span data-name="var12-3" id="var12-3" class="name-decl"+          >c</span+          > : Type) →<br+          />λ(<span data-name="var13-3" id="var13-3" class="name-decl"+          >a</span+          > : { <span data-name="var13-9" id="var13-9" class="name-decl"+          >list</span+          > : List <a href="#var11-3" data-name="var11-3" class="name-use"+          >b</a+          >, <span data-name="var13-24" id="var13-24" class="name-decl"+          >cons</span+          > : <a href="#var11-3" data-name="var11-3" class="name-use"+          >b</a+          > → <a href="#var12-3" data-name="var12-3" class="name-use"+          >c</a+          > → <a href="#var12-3" data-name="var12-3" class="name-use"+          >c</a+          >, <span data-name="var13-42" id="var13-42" class="name-decl"+          >nil</span+          > : <a href="#var12-3" data-name="var12-3" class="name-use"+          >c</a+          > }) →<br+          />  List/fold <a href="#var11-3" data-name="var11-3"+                           class="name-use"+          >b</a+          > <a href="#var13-3" data-name="var13-3" class="name-use"+          >a</a+          >.<a href="#var13-9" data-name="var13-9" class="name-use"+          >list</a+          > <a href="#var12-3" data-name="var12-3" class="name-use"+          >c</a+          > <a href="#var13-3" data-name="var13-3" class="name-use"+          >a</a+          >.<a href="#var13-24" data-name="var13-24" class="name-use"+          >cons</a+          > <a href="#var13-3" data-name="var13-3" class="name-use"+          >a</a+          >.<a href="#var13-42" data-name="var13-42" class="name-use"+          >nil</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToRecordFieldWhenVarIsOfRecordTypeOnPunnedEntry.dhall.html view
@@ -0,0 +1,72 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToRecordFieldWhenVarIsOfRecordTypeOnPunnedEntry.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToRecordFieldWhenVarIsOfRecordTypeOnPunnedEntry.dhall</span></h2+      ><a data-path="/JumpToRecordFieldWhenVarIsOfRecordTypeOnPunnedEntry.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          >On this example, <code+          >dhall-docs</code+          > will detect that the variable <code+          >a</code+          > is bounded+to a record literal. It will also be aware that that the attribute <code+          >x</code+          >. When+the user clicks the <code+          >x</code+          > from <code+          >a.x</code+          >, it will jump to the <code+          >x</code> punned-entry</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />On this example, `dhall-docs` will detect that the variable `a` is bounded<br+          />to a record literal. It will also be aware that that the attribute `x`. When<br+          />the user clicks the `x` from `a.x`, it will jump to the `x` punned-entry<br+          />-}<br+          />let x = 1<br+          />let <span data-name="var7-5" id="var7-5" class="name-decl"+          >a</span+          > = { <span data-name="var7-11" id="var7-11" class="name-decl"+          >x</span+          > }<br+          /><br+          />in <a href="#var7-5" data-name="var7-5" class="name-use"+          >a</a+          >.<a href="#var7-11" data-name="var7-11" class="name-use"+          >x</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToRecordFieldWhenVarIsOfRecordTypeTransitivity.dhall.html view
@@ -0,0 +1,80 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToRecordFieldWhenVarIsOfRecordTypeTransitivity.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToRecordFieldWhenVarIsOfRecordTypeTransitivity.dhall</span></h2+      ><a data-path="/JumpToRecordFieldWhenVarIsOfRecordTypeTransitivity.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          >On this example, <code+          >dhall-docs</code+          > will detect that the variable <code+          >b</code+          > is bounded+to the value of <code+          >a</code+          >, and the later is bounded to a record-literal. All selector+expressions over <code+          >b</code+          > will interact with the record-literal assigned to <code+          >a</code>, since+that is the actual definition of the fields.</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />On this example, `dhall-docs` will detect that the variable `b` is bounded<br+          />to the value of `a`, and the later is bounded to a record-literal. All selector<br+          />expressions over `b` will interact with the record-literal assigned to `a`, since<br+          />that is the actual definition of the fields.<br+          />-}<br+          />let <span data-name="var7-5" id="var7-5" class="name-decl"+          >a</span+          > = { <span data-name="var7-11" id="var7-11" class="name-decl"+          >x</span+          > = 1 }<br+          />let <span data-name="var8-5" id="var8-5" class="name-decl"+          >b</span+          > = <a href="#var7-5" data-name="var7-5" class="name-use"+          >a</a+          ><br+          /><br+          />in <a href="#var7-5" data-name="var7-5" class="name-use"+          >a</a+          >.<a href="#var7-11" data-name="var7-11" class="name-use"+          >x</a+          > + <a href="#var8-5" data-name="var8-5" class="name-use"+          >b</a+          >.<a href="#var7-11" data-name="var7-11" class="name-use"+          >x</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/JumpToRecordFieldWhenVarIsOfRecordTypeWithDotSyntax.dhall.html view
@@ -0,0 +1,113 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/JumpToRecordFieldWhenVarIsOfRecordTypeWithDotSyntax.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >JumpToRecordFieldWhenVarIsOfRecordTypeWithDotSyntax.dhall</span></h2+      ><a data-path="/JumpToRecordFieldWhenVarIsOfRecordTypeWithDotSyntax.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          >On this example, <code+          >dhall-docs</code+          > will detect that the variable <code+          >a</code> is bounded+to a record literal and it will be aware that it uses dot-syntax.</p+        >+<p+          >When the user clicks <code+          >x</code+          > from <code+          >a.x</code+          >, it will jump to the <code+          >x</code> on the record-literal.+The same applies for each other field.</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />On this example, `dhall-docs` will detect that the variable `a` is bounded<br+          />to a record literal and it will be aware that it uses dot-syntax.<br+          /><br+          />When the user clicks `x` from `a.x`, it will jump to the `x` on the record-literal.<br+          />The same applies for each other field.<br+          />-}<br+          />let <span data-name="var8-5" id="var8-5" class="name-decl"+          >a</span+          > = { <span data-name="var8-11" id="var8-11" class="name-decl"+          >x</span+          >.<span data-name="var8-13" id="var8-13" class="name-decl"+          >y</span+          >.<span data-name="var8-15" id="var8-15" class="name-decl"+          >z</span+          > = 1 }<br+          /><br+          />let <span data-name="var10-5" id="var10-5" class="name-decl"+          >ax</span+          > = <a href="#var8-5" data-name="var8-5" class="name-use"+          >a</a+          >.<a href="#var8-11" data-name="var8-11" class="name-use"+          >x</a+          ><br+          />let <span data-name="var11-5" id="var11-5" class="name-decl"+          >axy</span+          > = <a href="#var8-5" data-name="var8-5" class="name-use"+          >a</a+          >.<a href="#var8-11" data-name="var8-11" class="name-use"+          >x</a+          >.<a href="#var8-13" data-name="var8-13" class="name-use"+          >y</a+          ><br+          />let <span data-name="var12-5" id="var12-5" class="name-decl"+          >axyz</span+          > = <a href="#var8-5" data-name="var8-5" class="name-use"+          >a</a+          >.<a href="#var8-11" data-name="var8-11" class="name-use"+          >x</a+          >.<a href="#var8-13" data-name="var8-13" class="name-use"+          >y</a+          >.<a href="#var8-15" data-name="var8-15" class="name-use"+          >z</a+          ><br+          /><br+          />in <a href="#var10-5" data-name="var10-5" class="name-use"+          >ax</a+          >.<a href="#var8-13" data-name="var8-13" class="name-use"+          >y</a+          >.<a href="#var8-15" data-name="var8-15" class="name-use"+          >z</a+          > + <a href="#var11-5" data-name="var11-5" class="name-use"+          >axy</a+          >.<a href="#var8-15" data-name="var8-15" class="name-use"+          >z</a+          > + <a href="#var12-5" data-name="var12-5" class="name-use"+          >axyz</a+          ><br/></pre></div></div></body></html>
tasty/data/golden/JumpToSelf.dhall.html view
@@ -43,11 +43,15 @@           >{-|<br           />Althtough Dhall forbids cyclic imports, `dhall-docs` can handle them properly<br           />-}<br-          />let selfs =<br+          />let <span data-name="var4-5" id="var4-5" class="name-decl"+          >selfs</span+          > =<br           />    [ <a href="./JumpToSelf.dhall.html"           >./JumpToSelf.dhall</a           ><br           />    , <a href="../package/JumpToSelf.dhall.html"           >../package/JumpToSelf.dhall</a           > ]<br-          />in selfs<br/></pre></div></div></body></html>+          />in <a href="#var4-5" data-name="var4-5" class="name-use"+          >selfs</a+          ><br/></pre></div></div></body></html>
tasty/data/golden/JumpToUrls.dhall.html view
@@ -45,10 +45,20 @@           />-}<br           /><br           /><br-          />let List/generate = <a href="https://prelude.dhall-lang.org/v15.0.0/List/generate"-                                   target="_blank"+          />let <span data-name="var6-5" id="var6-5" class="name-decl"+          >List/generate</span+          > = <a href="https://prelude.dhall-lang.org/v15.0.0/List/generate"+                 target="_blank"           >https://prelude.dhall-lang.org/v15.0.0/List/generate</a           ><br           /><br-          />in List/generate 10 Text (\(n : Natural) -&gt; &quot;Result #${Natural/show n}&quot;)<br+          />in <a href="#var6-5" data-name="var6-5" class="name-use"+          >List/generate</a+          > 10 Text (\(<span data-name="var8-29" id="var8-29"+                             class="name-decl"+          >n</span+          > : Natural) -&gt; &quot;Result #${Natural/show <a href="#var8-29"+                                                             data-name="var8-29" class="name-use"+          >n</a+          >}&quot;)<br           /><br/></pre></div></div></body></html>
tasty/data/golden/Pair.dhall.html view
@@ -45,10 +45,25 @@           />Just a *Pair* right here<br           />-}<br           /><br-          />let Pair<br+          />let <span data-name="var6-5" id="var6-5" class="name-decl"+          >Pair</span+          ><br           />  : forall(A: Type) -- | Type of first position<br           />  -&gt; forall(B: Type) -- | Type of second position<br           />  -&gt; Type<br-          />  = λ(A: Type) -&gt; λ(B: Type) -&gt; {first: A, second: B}<br+          />  = λ(<span data-name="var10-7" id="var10-7" class="name-decl"+          >A</span+          >: Type) -&gt; λ(<span data-name="var10-21" id="var10-21"+                                 class="name-decl"+          >B</span+          >: Type) -&gt; {first: <a href="#var10-7" data-name="var10-7"+                                    class="name-use"+          >A</a+          >, second: <a href="#var10-21" data-name="var10-21"+                        class="name-use"+          >B</a+          >}<br           /><br-          />in Pair<br/></pre></div></div></body></html>+          />in <a href="#var6-5" data-name="var6-5" class="name-use"+          >Pair</a+          ><br/></pre></div></div></body></html>
+ tasty/data/golden/RenderTypeIndexesExample.dhall.html view
@@ -0,0 +1,57 @@+<!DOCTYPE HTML>+<html+  ><head+    ><title+    >/RenderTypeIndexesExample.dhall</title+    ><link href="index.css" type="text/css" rel="stylesheet"+    /><link href="https://fonts.googleapis.com/css2?family=Fira+Code:wght@400;500;600;700&amp;family=Lato:ital,wght@0,400;0,700;1,400&amp;display=swap"+            type="text/css" rel="stylesheet"+    /><script src="index.js" type="text/javascript"+    /><meta charset="UTF-8"/></head+  ><body+    ><div class="nav-bar"+      ><img src="dhall-icon.svg" class="dhall-icon"+      /><p class="package-title"+      >test-package</p+      ><div class="nav-bar-content-divider"+      /><a id="switch-light-dark-mode" class="nav-option"+      >Switch Light/Dark Mode</a></div+    ><div class="main-container"+      ><h2 class="doc-title"+        ><span class="crumb-divider"+        >/</span+        ><a href="index.html"+        >test-package</a+        ><span class="crumb-divider"+        >/</span+        ><span href="index.html" class="title-crumb"+        >RenderTypeIndexesExample.dhall</span></h2+      ><a data-path="/RenderTypeIndexesExample.dhall"+          class="copy-to-clipboard"+        ><i+          ><small+          >Copy path to clipboard</small></i></a+      ><br+      /><div class="doc-contents"+        ><p+          >This example shows that <code+          >dhall-docs</code> will find render the correct type on the+index respecting variable indices</p>+</div+      ><h3+      >Source</h3+      ><div class="source-code"+        ><pre+          >{-|<br+          />This example shows that `dhall-docs` will find render the correct type on the<br+          />index respecting variable indices<br+          />-}<br+          /><br+          />let <span data-name="var6-5" id="var6-5" class="name-decl"+          >x</span+          > : Bool = True<br+          />let x : Natural = 1<br+          /><br+          />in <a href="#var6-5" data-name="var6-5" class="name-use"+          >x@1</a+          ><br/></pre></div></div></body></html>
tasty/data/golden/TwoAnnotations.dhall.html view
@@ -49,8 +49,16 @@           />body of the `let` expression.  The documentation generator prefers to use the<br           />latter annotation.<br           />-}<br-          />let x = 1<br+          />let <span data-name="var6-5" id="var6-5" class="name-decl"+          >x</span+          > = 1<br           /><br-          />let y = Natural<br+          />let <span data-name="var8-5" id="var8-5" class="name-decl"+          >y</span+          > = Natural<br           /><br-          />in  x : y<br/></pre></div></div></body></html>+          />in  <a href="#var6-5" data-name="var6-5" class="name-use"+          >x</a+          > : <a href="#var8-5" data-name="var8-5" class="name-use"+          >y</a+          ><br/></pre></div></div></body></html>
tasty/data/golden/a/JumpToParent.dhall.html view
@@ -40,10 +40,14 @@       >Source</h3       ><div class="source-code"         ><pre-          >let parents =<br+          >let <span data-name="var1-5" id="var1-5" class="name-decl"+          >parents</span+          > =<br           />    [ <a href="../IndexesExample.dhall.html"           >../IndexesExample.dhall</a           ><br           />    ]<br           /><br-          />in parents<br/></pre></div></div></body></html>+          />in <a href="#var1-5" data-name="var1-5" class="name-use"+          >parents</a+          ><br/></pre></div></div></body></html>
tasty/data/golden/a/b.dhall.html view
@@ -44,4 +44,8 @@           />Hi there boys<br           />-}<br           /><br-          />let b = 1 in b<br/></pre></div></div></body></html>+          />let <span data-name="var5-5" id="var5-5" class="name-decl"+          >b</span+          > = 1 in <a href="#var5-5" data-name="var5-5" class="name-use"+          >b</a+          ><br/></pre></div></div></body></html>
tasty/data/golden/a/b/JumpToGrandfather.dhall.html view
@@ -45,10 +45,14 @@       >Source</h3       ><div class="source-code"         ><pre-          >let parents =<br+          >let <span data-name="var1-5" id="var1-5" class="name-decl"+          >parents</span+          > =<br           />    [ <a href="../../IndexesExample.dhall.html"           >../../IndexesExample.dhall</a           ><br           />    ]<br           /><br-          />in parents<br/></pre></div></div></body></html>+          />in <a href="#var1-5" data-name="var1-5" class="name-use"+          >parents</a+          ><br/></pre></div></div></body></html>
tasty/data/golden/a/b/c.dhall.html view
@@ -48,4 +48,8 @@           />Hi there boys<br           />-}<br           /><br-          />let c = 1 in c<br/></pre></div></div></body></html>+          />let <span data-name="var5-5" id="var5-5" class="name-decl"+          >c</span+          > = 1 in <a href="#var5-5" data-name="var5-5" class="name-use"+          >c</a+          ><br/></pre></div></div></body></html>
tasty/data/golden/a/b/c/a.dhall.html view
@@ -52,4 +52,8 @@           />Hi there boys<br           />-}<br           /><br-          />let a = 1 in a<br/></pre></div></div></body></html>+          />let <span data-name="var5-5" id="var5-5" class="name-decl"+          >a</span+          > = 1 in <a href="#var5-5" data-name="var5-5" class="name-use"+          >a</a+          ><br/></pre></div></div></body></html>
tasty/data/golden/deep/nested/folder/my-even.dhall.html view
@@ -59,12 +59,27 @@           >{-<br           />Check if a natural is even or not returning an union data-type<br           />-}<br-          />let my-even<br+          />let <span data-name="var4-5" id="var4-5" class="name-decl"+          >my-even</span+          ><br           />    : Natural → &lt; even | odd &gt;<br-          />    = λ(n : Natural) →<br-          />        if Natural/even n then &lt; even | odd&gt;.even else &lt; even | odd &gt;.odd<br+          />    = λ(<span data-name="var6-9" id="var6-9" class="name-decl"+          >n</span+          > : Natural) →<br+          />        if Natural/even <a href="#var6-9" data-name="var6-9"+                                       class="name-use"+          >n</a+          > then &lt; even | odd&gt;.even else &lt; even | odd &gt;.odd<br           /><br-          />let example0 = assert : my-even 1 === &lt;even | odd&gt;.odd<br-          />let example0 = assert : my-even 2 === &lt;even | odd&gt;.even<br+          />let example0 = assert : <a href="#var4-5" data-name="var4-5"+                                       class="name-use"+          >my-even</a+          > 1 === &lt;even | odd&gt;.odd<br+          />let example0 = assert : <a href="#var4-5" data-name="var4-5"+                                       class="name-use"+          >my-even</a+          > 2 === &lt;even | odd&gt;.even<br           /><br-          />in my-even<br/></pre></div></div></body></html>+          />in <a href="#var4-5" data-name="var4-5" class="name-use"+          >my-even</a+          ><br/></pre></div></div></body></html>
tasty/data/golden/index.html view
@@ -44,14 +44,6 @@               >./MarkdownExample.dhall</a               ><br/></pre></span></li         ><li-          ><a href="IndexesExample.dhall.html"-          >IndexesExample.dhall</a-          ><span class="of-type-token"-          >:</span-          ><span class="dhall-type source-code"-            ><pre-              >Bool<br/></pre></span></li-        ><li           ><a href="InvalidBlockComment.dhall.html"           >InvalidBlockComment.dhall</a></li         ><li@@ -61,9 +53,72 @@           ><a href="InvalidMarkdown.dhall.html"           >InvalidMarkdown.dhall</a></li         ><li+          ><a href="JumpToDefOnUnused.dhall.html"+          >JumpToDefOnUnused.dhall</a></li+        ><li           ><a href="JumpToHereImports.dhall.html"           >JumpToHereImports.dhall</a></li         ><li+          ><a href="JumpToLamBindingComplex.dhall.html"+          >JumpToLamBindingComplex.dhall</a></li+        ><li+          ><a href="JumpToLamBindingSimple.dhall.html"+          >JumpToLamBindingSimple.dhall</a></li+        ><li+          ><a href="JumpToLamBindingWithIndex.dhall.html"+          >JumpToLamBindingWithIndex.dhall</a></li+        ><li+          ><a href="JumpToLamBindingWithQuotes.dhall.html"+          >JumpToLamBindingWithQuotes.dhall</a></li+        ><li+          ><a href="JumpToLamBindingWithShadowing.dhall.html"+          >JumpToLamBindingWithShadowing.dhall</a></li+        ><li+          ><a href="JumpToLetBindingSimple.dhall.html"+          >JumpToLetBindingSimple.dhall</a></li+        ><li+          ><a href="JumpToLetBindingWithIndex.dhall.html"+          >JumpToLetBindingWithIndex.dhall</a></li+        ><li+          ><a href="JumpToLetBindingWithQuotes.dhall.html"+          >JumpToLetBindingWithQuotes.dhall</a></li+        ><li+          ><a href="JumpToLetBindingWithShadowing.dhall.html"+          >JumpToLetBindingWithShadowing.dhall</a></li+        ><li+          ><a href="JumpToLetbindingComplex.dhall.html"+          >JumpToLetbindingComplex.dhall</a></li+        ><li+          ><a href="JumpToRecordFieldWhenFieldDoesNotExist.dhall.html"+          >JumpToRecordFieldWhenFieldDoesNotExist.dhall</a></li+        ><li+          ><a href="JumpToRecordFieldWhenLetAnnotationPresentShouldIgnoreAnnotation.dhall.html"+          >JumpToRecordFieldWhenLetAnnotationPresentShouldIgnoreAnnotation.dhall</a></li+        ><li+          ><a href="JumpToRecordFieldWhenVarIsAnnotatedWithRecordType.dhall.html"+          >JumpToRecordFieldWhenVarIsAnnotatedWithRecordType.dhall</a></li+        ><li+          ><a href="JumpToRecordFieldWhenVarIsOfRecordType.dhall.html"+          >JumpToRecordFieldWhenVarIsOfRecordType.dhall</a></li+        ><li+          ><a href="JumpToRecordFieldWhenVarIsOfRecordTypeComplex.dhall.html"+          >JumpToRecordFieldWhenVarIsOfRecordTypeComplex.dhall</a></li+        ><li+          ><a href="JumpToRecordFieldWhenVarIsOfRecordTypeDeep.dhall.html"+          >JumpToRecordFieldWhenVarIsOfRecordTypeDeep.dhall</a></li+        ><li+          ><a href="JumpToRecordFieldWhenVarIsOfRecordTypeFromLamBinding.dhall.html"+          >JumpToRecordFieldWhenVarIsOfRecordTypeFromLamBinding.dhall</a></li+        ><li+          ><a href="JumpToRecordFieldWhenVarIsOfRecordTypeOnPunnedEntry.dhall.html"+          >JumpToRecordFieldWhenVarIsOfRecordTypeOnPunnedEntry.dhall</a></li+        ><li+          ><a href="JumpToRecordFieldWhenVarIsOfRecordTypeTransitivity.dhall.html"+          >JumpToRecordFieldWhenVarIsOfRecordTypeTransitivity.dhall</a></li+        ><li+          ><a href="JumpToRecordFieldWhenVarIsOfRecordTypeWithDotSyntax.dhall.html"+          >JumpToRecordFieldWhenVarIsOfRecordTypeWithDotSyntax.dhall</a></li+        ><li           ><a href="JumpToSelf.dhall.html"           >JumpToSelf.dhall</a></li         ><li@@ -102,6 +157,14 @@           ><span class="dhall-type source-code"             ><pre               >∀(A : Type) → ∀(B : Type) → Type<br/></pre></span></li+        ><li+          ><a href="RenderTypeIndexesExample.dhall.html"+          >RenderTypeIndexesExample.dhall</a+          ><span class="of-type-token"+          >:</span+          ><span class="dhall-type source-code"+            ><pre+              >Bool<br/></pre></span></li         ><li           ><a href="TwoAnnotations.dhall.html"           >TwoAnnotations.dhall</a
− tasty/data/package/IndexesExample.dhall
@@ -1,9 +0,0 @@-{-|-This example shows that `dhall-docs` will find render the correct type on the-index respecting variable indices--}--let x : Bool = True-let x : Natural = 1--in x@1
+ tasty/data/package/JumpToDefOnUnused.dhall view
@@ -0,0 +1,17 @@+{-|+`dhall-docs` will detect some names (record fields, let-bindings and lam-bindings)+are unused and therefore won't be highlighted+-}++let unused = 1+let used = 3++let unusedRecord = { foo = 1 }+let usedRecord = { foo = 1 }++let f =+       \(unused : Bool)+    -> \(used : Natural)+    -> \(r : { unused : Text, used : Natural}) -> used + r.used++in used + usedRecord.foo + f True 1 { unused = "foo", used = 3 }
+ tasty/data/package/JumpToLamBindingComplex.dhall view
@@ -0,0 +1,11 @@+{-|+A complex example of jump-to-definition on let-bindings+-}+let fun =+    λ(a : Text) ->+    λ(b : Text) ->+    λ(c : Text) ->+    λ(d : Text) ->+    [ a ++ b, b ++ c, c ++ d, d ++ a ]++in fun
+ tasty/data/package/JumpToLamBindingSimple.dhall view
@@ -0,0 +1,67 @@+{-|+This examples shows a demo of jumping to a let-binding definition. If you hover+the `a` paramter, the front-end will highlight all of its usages and if you+click it you will navigate to its definition.++The amount of empty lines left are intentional to show you how the browser jumps+to the declaration of a+-}+let fun = \(v : Text) ->++++++++++++++++++++++++++++++++++++++++++++++++++++++    v++++in fun
+ tasty/data/package/JumpToLamBindingWithIndex.dhall view
@@ -0,0 +1,14 @@+{-|+On this example, we introduce the `a` variable in the two parameters of the+`fun` function and the jump-to-definition engine correctly highlights the usage+when indexes are used+-}+let fun =+    λ(a : Text) ->+    λ(a : Text) ->+    [ a@1 ++ a@0 ]++let example0 = assert : fun "a" "b" === ["ab"]++in fun+
+ tasty/data/package/JumpToLamBindingWithQuotes.dhall view
@@ -0,0 +1,13 @@+{-|+This tests shows that the feature works for quoted vars on function parameters+as well+-}+let fun =+    λ(`param 1` : Text) ->+    λ(`param 2` : Text) ->+    [ `param 1` ++ `param 2` ]++let example0 = assert : fun "a" "b" === ["ab"]++in fun+
+ tasty/data/package/JumpToLamBindingWithShadowing.dhall view
@@ -0,0 +1,14 @@+{-|+On this example, the first parameter `a` is shadowed with the second declaration.+The jump-to-definintion on the usage of `a` should not highlight the first declaration,+and interacting with the first declaration should not change the others+-}+let fun =+    λ(a : Text) ->+    λ(a : Text) ->+    [ a ++ a ]++let example0 = assert : fun "a" "b" === ["bb"]++in fun+
+ tasty/data/package/JumpToLetBindingSimple.dhall view
@@ -0,0 +1,52 @@+{-|+This examples shows a demo of jumping to a let-binding definition. If you hover+the `a` variable, the front-end will highlight all of its usages and if you+click it you will navigate to its definition.++The amount of empty lines left are intentional to show you how the browser jumps+to the declaration of a+-}+let a = 1+++++++++++++++++++++++++++++++++++++++++in++a
+ tasty/data/package/JumpToLetBindingWithIndex.dhall view
@@ -0,0 +1,9 @@+{-|+Although we have a similar example on this [file](./RenderTypeIndexesExample.dhall),+this example showcases the jump-to-definition feature when indexes are used.+-}+let a = 1++let a = 2++in a@1
+ tasty/data/package/JumpToLetBindingWithQuotes.dhall view
@@ -0,0 +1,8 @@+{-|+This test cases shows that the feature works with quoted variables+-}+let `quoted variable` = 1++let nonQuoted = 2++in `quoted variable` + `nonQuoted`
+ tasty/data/package/JumpToLetBindingWithShadowing.dhall view
@@ -0,0 +1,11 @@+{-|+On this example, the first declaration of variable `a` is shadowed with the+later declaration. The jump-to-definintion on the usage of `a`+should not highlight the first declaration, and interacting with the first+declaration should not change the others+-}+let a = 1++let a = 2++in a
+ tasty/data/package/JumpToLetbindingComplex.dhall view
@@ -0,0 +1,11 @@+{-|+A complex example of jump-to-definition on let-bindings+-}+let f = \(f : Natural) ->+    let a = 1 in f + a++let a = f 1++let b = a + f 3++in b
+ tasty/data/package/JumpToRecordFieldWhenFieldDoesNotExist.dhall view
@@ -0,0 +1,10 @@+{-|+On this example, `dhall-docs` will detect that the variable `a` and `b` is of+record-type. If on a selector-expression the field is not found on the type,+no-link will be created++-}+let a = { x = "foo" }+let b = False++in a.y + b.`does not exist`
+ tasty/data/package/JumpToRecordFieldWhenLetAnnotationPresentShouldIgnoreAnnotation.dhall view
@@ -0,0 +1,10 @@+{-|+On this example, `dhall-docs` will detect that the variable `a` is annotated+with a type, but it will ignore it anyways. On let-bindings, `dhall-docs` infers+the type of the variable from the bounded expression. As a consequence, on+this example, hovering the `x` on the selector-expression will highlight the+`x` label on the record-literal+-}+let a : Bool = { x = "foo" }++in a.x
+ tasty/data/package/JumpToRecordFieldWhenVarIsAnnotatedWithRecordType.dhall view
@@ -0,0 +1,11 @@+{-|+On this example, even when the variable `a` is annotated with a record-type,+`dhall-docs` will infer the actual type from the bounded value.++All interactions with fields on selector-expressions won't affect the rendered-type.++(The example is intended to not type-check as a Dhall expression)+-}+let a : { x : Text } = { x = "foo", y = "bar" }++in a.x ++ a.y
+ tasty/data/package/JumpToRecordFieldWhenVarIsOfRecordType.dhall view
@@ -0,0 +1,9 @@+{-|+On this example, `dhall-docs` will detect that the variable `a` is bounded+to a record-literal. When the user clicks on the `field` in the `a.field`, it+will jump to the definition of that field in the source code i.e. to the `field`+key in the record literal+-}+let a = { field = "foo" }++in Text/show a.field
+ tasty/data/package/JumpToRecordFieldWhenVarIsOfRecordTypeComplex.dhall view
@@ -0,0 +1,10 @@+{-|+A complex example of the jump-to-definition feature on record literals.+-}+let a =+    { foo = "bar", number = +1 }++let b =+    { foo = "bar", number = +1 }++in a.foo ++ Integer/show a.number ++ b.foo ++ Integer/show b.number
+ tasty/data/package/JumpToRecordFieldWhenVarIsOfRecordTypeDeep.dhall view
@@ -0,0 +1,10 @@+{-|+On this example, `dhall-docs` will detect that the variable `a` is bounded+to a record literal. It will also detect that the `field` key from the record+literal is another record literal. When the user clicks `deep` from the+`a.field.deep`, it will jump to the definition of that variable in the source+code.+-}+let a = { field = { deep = "bar" } }++in Text/show a.field.deep
+ tasty/data/package/JumpToRecordFieldWhenVarIsOfRecordTypeFromLamBinding.dhall view
@@ -0,0 +1,14 @@+{-|+On this example, `dhall-docs` will detect that the argument `a` of the only+function in this file is of record type. Therefore, any interactions on selector+expressions over the `a` variable will interact with the fields on the record-type.++Note that the treatment for `Lam` variables is different from `Let` bindings:+the annotation doesn't affect on the later case. This can be seen in the+[test case for let bindings](./JumpToRecordFieldWhenLetAnnotationPresentShouldIgnoreAnnotation.dhall)+-}++λ(b : Type) →+λ(c : Type) →+λ(a : { list : List b, cons : b → c → c, nil : c }) →+  List/fold b a.list c a.cons a.nil
+ tasty/data/package/JumpToRecordFieldWhenVarIsOfRecordTypeOnPunnedEntry.dhall view
@@ -0,0 +1,9 @@+{-|+On this example, `dhall-docs` will detect that the variable `a` is bounded+to a record literal. It will also be aware that that the attribute `x`. When+the user clicks the `x` from `a.x`, it will jump to the `x` punned-entry+-}+let x = 1+let a = { x }++in a.x
+ tasty/data/package/JumpToRecordFieldWhenVarIsOfRecordTypeTransitivity.dhall view
@@ -0,0 +1,10 @@+{-|+On this example, `dhall-docs` will detect that the variable `b` is bounded+to the value of `a`, and the later is bounded to a record-literal. All selector+expressions over `b` will interact with the record-literal assigned to `a`, since+that is the actual definition of the fields.+-}+let a = { x = 1 }+let b = a++in a.x + b.x
+ tasty/data/package/JumpToRecordFieldWhenVarIsOfRecordTypeWithDotSyntax.dhall view
@@ -0,0 +1,14 @@+{-|+On this example, `dhall-docs` will detect that the variable `a` is bounded+to a record literal and it will be aware that it uses dot-syntax.++When the user clicks `x` from `a.x`, it will jump to the `x` on the record-literal.+The same applies for each other field.+-}+let a = { x.y.z = 1 }++let ax = a.x+let axy = a.x.y+let axyz = a.x.y.z++in ax.y.z + axy.z + axyz
+ tasty/data/package/RenderTypeIndexesExample.dhall view
@@ -0,0 +1,9 @@+{-|+This example shows that `dhall-docs` will find render the correct type on the+index respecting variable indices+-}++let x : Bool = True+let x : Natural = 1++in x@1