Physlib

Physlib.Meta.Notes.HTMLNote

3 declarations

definition

HTMLNote\text{HTMLNote} of note information nini

#ofNodeInfo

Given a structure nini of type `NoteInfo` containing information about a declaration or note, this function converts it into an `HTMLNote` structure.

definition

HTML note of a formal declaration cc

#ofFormal

Given a formal declaration name cc, this function constructs an `HTMLNote` structure within the `CoreM` monad. It retrieves the line number nn, the file name, and the literal source code string associated with cc from the environment. The function generates an HTML block containing: 1. A GitHub link to the source code at line nn within the `physlib` repository. 2. The source code of the declaration cc (retrieved via `getDeclString`) enclosed in HTML `<pre><code>` tags for display. The resulting `HTMLNote` object includes this formatted HTML content along with the source file and line number metadata.

definition

HTML note of an informal declaration cc

#ofInformal

Given a declaration name cc, this function constructs an `HTMLNote` structure within the `CoreM` monad. It retrieves the line number nn, the file name, and the documentation string associated with cc from the environment. Based on whether the declaration is an `InformalDefinition` or an `InformalLemma`, the function generates an HTML block containing: 1. A GitHub link to the source code at line nn. 2. The name of the declaration cc. 3. The contents of the documentation string, where newlines are replaced by HTML line breaks. The resulting `HTMLNote` includes this formatted HTML content along with the source file metadata.