@@ -38,12 +38,21 @@ It’s easy to see how Sail can directly translate to HTML:
39#### HTML code
39#### HTML code
42−<html> <head> <title>My page</title> <meta charset="utf-8" />
44+ <title>My page</title>
45+ <meta charset="utf-8" />
43−</head> <body> <h1>Welcome!</h1> <p> Hello, world! Welcome to my
49+ <p>Hello, world! Welcome to my
44−page. Here is an image: <br /> <img
50+ page. Here is an image:
45−src="https://media.urbit.org/docs/userspace/dist/wut.svg" /> </p> </body>
52+ <img src="https://media.urbit.org/docs/userspace/dist/wut.svg" />
49## Tags and Closing
58## Tags and Closing
@@ -70,8 +79,8 @@ tag name, then insert your plain text following a space. Example:
74−<h1>The title</h1>
83+<h1>The title</h1>
@@ -91,9 +100,11 @@ Example:
95−<body> <h1>Blog title</h1> <p>This is some good content.</p>
106+ <p>This is some good content.</p>
99If we want to write a string with no tag at all, then we can prepend
110If we want to write a string with no tag at all, then we can prepend
@@ -109,8 +120,11 @@ those untagged lines with `;` and then a space:
113−<body> <h1>Welcome!</h1> Hello, world. We’re on the web. </body>
126+ Hello, world. We’re on the web.
116## Attributes
130## Attributes
@@ -147,9 +161,11 @@ Tall-form attributes:
151−<div title="a tooltip" style="color:red"> <h1>Foo</h1> <p>foo bar
165+<div title="a tooltip" style="color:red">
152−baz </p> </div>
168+</div>
@@ -162,8 +178,8 @@ Add `#` after tag name to add an ID:
166−<nav id="header">Menu</nav>
182+<nav id="header">Menu</nav>
169### Classes
185### Classes
@@ -176,8 +192,8 @@ Add `.` after tag name to add a class:
180−<h1 class="text-blue">Title</h1>
196+<h1 class="text-blue">Title</h1>
183If you want a class name that contains a space, you will need to use use the
199If you want a class name that contains a space, you will need to use use the
@@ -189,8 +205,8 @@ syntax of a generic attribute:
193−<div class="logo inverse"></div>
209+<div class="logo inverse"></div>
196### Images
212### Images
@@ -203,8 +219,8 @@ Add `@` after the tag name to link your source:
207−<img src="example.png"/>
223+<img src="example.png"/>
210To add attributes to the image, like size specifications, add the desired
226To add attributes to the image, like size specifications, add the desired
@@ -225,8 +241,8 @@ Add `/` after tag name to start an `href`.
229−<a href="urbit.org">A link to Urbit.org</a>
245+<a href="urbit.org">A link to Urbit.org</a>
232## Interpolation
248## Interpolation
@@ -242,8 +258,8 @@ usual manner. For example:
246−<p>foo ~2000.1.1 baz</p>
262+<p>foo ~2000.1.1 baz</p>
@@ -259,9 +275,11 @@ Likewise:
263−<article> <b>33138</b> bananas <p>~zod ~2022.2.21..09.54.21..5b63
280+ <b>33138</b> bananas
264−0x9827.99c7.06f4.8ef9 </p> </article>
281+ <p>~zod ~2022.2.21..09.54.21..5b63 0x9827.99c7.06f4.8ef9</p>
267## A note on CSS
285## A note on CSS
@@ -391,12 +409,12 @@ tall-form hoon logic in another Sail element. For example:
392Produces one of these depending on the value of `number`:
410Produces one of these depending on the value of `number`:
395−<p><b>2 </b>is an <b>even </b>number.</p>
413+<p><b>2 </b>is an <b>even </b>number.</p>
399−<p><b>12345 </b>is an <b>odd </b>number.</p>
417+<p><b>12345 </b>is an <b>odd </b>number.</p>
402### `;/` Micfas
420### `;/` Micfas
@@ -440,10 +458,12 @@ elements inside another Sail element. For example:
444−<p> <sub>1</sub><sup>2</sup><sub>3</sub>
463+ <sub>1</sub><sup>2</sup><sub>3</sub>
445−<sup>4</sup><sub>5</sub><sup>6</sup>
464+ <sup>4</sup><sub>5</sub><sup>6</sup>
446−<sub>7</sub><sup>8</sup><sub>9</sub> </p>
465+ <sub>7</sub><sup>8</sup><sub>9</sub>
449### `;=` Mictis
469### `;=` Mictis
@@ -466,7 +486,10 @@ For example:
470−<main> <p>This is the first node.</p> <p>This is the second.</p>
491+ <p>This is the first node.</p>
492+ <p>This is the second.</p>
471−<p>Here is the last one.</p> </main>
493+ <p>Here is the last one.</p>