Skip to content

Commit

Permalink
PoC of head additions
Browse files Browse the repository at this point in the history
  • Loading branch information
mk committed Feb 8, 2023
1 parent e299639 commit 7219298
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/nextjournal/clerk/view.clj
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,10 @@
[:script {:type "module" :src (adjust-relative-path state (get-in state [:resource->url "/js/viewer.js"]))}]
(hiccup/include-css "https://cdn.jsdelivr.net/npm/[email protected]/dist/katex.min.css")
[:link {:rel "preconnect" :href "https://fonts.bunny.net"}]
(hiccup/include-css "https://fonts.bunny.net/css?family=fira-mono:400,700%7Cfira-sans:400,400i,500,500i,700,700i%7Cfira-sans-condensed:700,700i%7Cpt-serif:400,400i,700,700i")))
(hiccup/include-css "https://fonts.bunny.net/css?family=fira-mono:400,700%7Cfira-sans:400,400i,500,500i,700,700i%7Cfira-sans-condensed:700,700i%7Cpt-serif:400,400i,700,700i")
(get-in state [:resource->url :head-additions])))

#_(swap! !resource->url assoc :head-additions (list [:style {:type "text/css"} "body { background-color: red !important; }"]))

(defn ->html [{:as state :keys [conn-ws?] :or {conn-ws? true}}]
(hiccup/html5
Expand Down
1 change: 1 addition & 0 deletions src/nextjournal/clerk/viewer.cljc
Original file line number Diff line number Diff line change
Expand Up @@ -997,6 +997,7 @@
(update :nextjournal/value (partial process-blocks viewers))
mark-presented))})


(def viewer-eval-viewer
{:pred viewer-eval?
:var-from-def? true
Expand Down

0 comments on commit 7219298

Please sign in to comment.