Overview
| Comment: | Add close-head? to page header function | 
|---|---|
| Timelines: | family | ancestors | descendants | both | trunk | 
| Files: | files | file ages | folders | 
| SHA3-256: | 5fc9abc0569f09b2e19c8c0e04b2fa93 | 
| User & Date: | joel on 2019-07-04 18:19:44 | 
| Other Links: | manifest | tags | 
Context
| 2019-07-05 | ||
| 03:27 | Allow here-output-path even when no metas are available check-in: bd48c56a user: joel tags: trunk | |
| 2019-07-04 | ||
| 18:19 | Add close-head? to page header function check-in: 5fc9abc0 user: joel tags: trunk | |
| 2019-06-29 | ||
| 21:16 | Start using the SQLite cache for series metas check-in: 829c503e user: joel tags: trunk | |
Changes
Modified code-docs/snippets-html.scrbl from [bcf809dc] to [841e7710].
| ︙ | ︙ | |||
| 46 47 48 49 50 51 52 | 
    <p><b>◊|title|</b><p>
    ◊(->html body-tx)
  })
}
@section{HTML Snippet functions}
 | | | > > > > > > | 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 | 
    <p><b>◊|title|</b><p>
    ◊(->html body-tx)
  })
}
@section{HTML Snippet functions}
@defproc[(html$-page-head [title (or/c string? #f) #f] [close-head? boolean? #t]) non-empty-string?]
Returns the @tt{<head>} section of an HTML document. 
If @racket[_title] is a string it will be used inside the @tt{<title>} tag.
If you want to include additional stuff inside the @tt{<head>}, you can set @racket[_close-head?] to
@racket[#f] to prevent it from including the closing @tt{</head>} tag (you’ll have to add it
yourself).
@defproc[(html$-page-body-open [body-class string? ""]) non-empty-string?]
Returns the opening @tt{<body>} and @tt{<main>} tags and elements that immediately follow, such as
site header, logo and navigation.
If @racket[_body-class] is a non-empty string, its contents will be included in the @tt{class}
 | 
| ︙ | ︙ | 
Modified snippets-html.rkt from [2a3a4102] to [7b620fd5].
| ︙ | ︙ | |||
| 24 25 26 27 28 29 30 | 
         html$-note-title
         html$-note-contents
         html$-note-listing-full
         html$-note-in-article
         html$-notes-section
         html$-paginate-navlinks)
 | | | | 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | 
         html$-note-title
         html$-note-contents
         html$-note-listing-full
         html$-note-in-article
         html$-notes-section
         html$-paginate-navlinks)
(define (html$-page-head [title #f] [close-head? #t])
  ◊string-append{<head>
 <title>◊if[title title ""] </title>
 <meta charset="utf-8" />
 <meta name="viewport" content="width=device-width, initial-scale=1">
 <meta name="generator" content="Racket ◊(version) + Pollen ◊|pollen:version|">
 <link rel="stylesheet" type="text/css" href="/web-extra/martin.css">
 ◊if[close-head? "</head>" ""]})
(define (html$-page-body-open [class ""])
  (define body-class (if (non-empty-string? class) (format " class=\"~a\"" class) ""))
  ◊string-append{<body◊|body-class|><main>
 <a href="/"><header>
 <img src="/web-extra/mark.svg" alt="The Local Yarn" height="103" class="logo">
 <h1>The Local Yarn</h1>
 | 
| ︙ | ︙ |