forked from digital-asset/daml
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
damldocs: Backend for rendering docs to multiple pages. (digital-asse…
…t#2259) * Begin multi-page rendering * Fixed multi-file output rendering for HTML * Remove renderSimpleHtml * Remove unnecessary imports * Remove unused lang extensions * Address reviewer comments
- Loading branch information
Fran
authored
Jul 23, 2019
1 parent
d306814
commit d0dd201
Showing
9 changed files
with
227 additions
and
59 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
-- Copyright (c) 2019 Digital Asset (Switzerland) GmbH and/or its affiliates. All rights reserved. | ||
-- SPDX-License-Identifier: Apache-2.0 | ||
|
||
-- | Types common to DA.Daml.Doc.Render | ||
module DA.Daml.Doc.Render.Types | ||
( module DA.Daml.Doc.Render.Types | ||
) where | ||
|
||
import qualified Data.Text as T | ||
|
||
data DocFormat = Json | Rst | Markdown | Html | Hoogle | ||
deriving (Eq, Show, Read, Enum, Bounded) | ||
|
||
-- | Control whether to render docs as a single file, or as | ||
-- an interlinked folder of many files, one per DAML module. | ||
data RenderMode | ||
= RenderToFile FilePath -- ^ render to single file | ||
| RenderToFolder FilePath -- ^ render to folder, one file per module | ||
|
||
-- | Options that affect rendering. | ||
data RenderOptions = RenderOptions | ||
{ ro_mode :: RenderMode -- ^ control single file / multi file rendering | ||
, ro_format :: DocFormat -- ^ renderer output format | ||
, ro_title :: Maybe T.Text -- ^ title of rendered documentation | ||
, ro_template :: Maybe T.Text -- ^ renderer template | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters