|
| 1 | +-- import: fastn-community.github.io/site-doc |
| 2 | +-- import: fastn-community.github.io/code-block as cb |
| 3 | + |
| 4 | + |
| 5 | + |
| 6 | + |
| 7 | +-- site-doc.doc-home: Typography |
| 8 | +github-url: https://github.com/fastn-community/typography |
| 9 | +license-url: https://github.com/fastn-community/typography/blob/main/LICENSE |
| 10 | +current-package: fastn-community.github.io/typography |
| 11 | +show-tabs: false |
| 12 | +site-title: Typography |
| 13 | + |
| 14 | +-- site-doc.output: |
| 15 | + |
| 16 | +-- h0: This is heading hero |
| 17 | + |
| 18 | +Heading also has optional body property. |
| 19 | + |
| 20 | +-- h1: This is heading large |
| 21 | + |
| 22 | +Heading also has optional body property. |
| 23 | + |
| 24 | +-- h2: This is heading medium |
| 25 | + |
| 26 | +Heading also has optional body property. |
| 27 | + |
| 28 | +-- h3: This is heading small |
| 29 | + |
| 30 | +Heading also has optional body property. |
| 31 | + |
| 32 | +-- h4: This is heading tiny |
| 33 | + |
| 34 | +Heading also has optional body property. |
| 35 | + |
| 36 | +-- markdown: |
| 37 | + |
| 38 | +This is markdown text. You can add [link](https://fastn.com) and |
| 39 | +add **bold**, *italic* etc styles to markdown text. |
| 40 | + |
| 41 | +-- end: site-doc.output |
| 42 | + |
| 43 | +-- site-doc.header: What is a Typography |
| 44 | + |
| 45 | +Font typography involves adjusting various typographical elements such as font |
| 46 | +size, line spacing, letter spacing, and kerning to ensure that the text is easy |
| 47 | +to read and visually appealing. |
| 48 | + |
| 49 | +-- site-doc.header: How to use `typography` |
| 50 | + |
| 51 | +To use `typography` add below lines into your FASTN.ftd file: |
| 52 | + |
| 53 | +To learn more about typography |
| 54 | +[click here](https://fastn-community.github.io/typography/headings/). |
| 55 | + |
| 56 | +-- cb.code: |
| 57 | +lang: ftd |
| 58 | + |
| 59 | +\-- fastn.dependency: fastn-community.github.io/typography |
| 60 | + |
| 61 | +-- end: site-doc.doc-home |
| 62 | + |
| 63 | + |
| 64 | + |
| 65 | + |
| 66 | + |
| 67 | + |
| 68 | + |
| 69 | + |
| 70 | + |
| 71 | + |
| 72 | +-- component h0: |
| 73 | +caption title: |
| 74 | +optional body body: |
| 75 | +children inner: |
| 76 | +optional string id: |
| 77 | + |
| 78 | +-- ftd.column: |
| 79 | +width: fill-container |
| 80 | +id if { $h0.id != NULL }: $h0.id |
| 81 | + |
| 82 | +-- ftd.text: $h0.title |
| 83 | +role: $inherited.types.heading-hero |
| 84 | +color: $inherited.colors.text-strong |
| 85 | +margin-bottom.rem: 0.5 |
| 86 | +width: fill-container |
| 87 | +border-bottom-width.px: 1 |
| 88 | +border-color: $inherited.colors.border |
| 89 | +region: h1 |
| 90 | + |
| 91 | +-- markdown: |
| 92 | +if: { h0.body != NULL } |
| 93 | +body: $h0.body |
| 94 | + |
| 95 | +-- ftd.column: |
| 96 | +children: $h0.inner |
| 97 | +width: fill-container |
| 98 | + |
| 99 | +-- end: ftd.column |
| 100 | + |
| 101 | +-- end: ftd.column |
| 102 | + |
| 103 | +-- end: h0 |
| 104 | + |
| 105 | + |
| 106 | + |
| 107 | + |
| 108 | + |
| 109 | + |
| 110 | + |
| 111 | + |
| 112 | + |
| 113 | + |
| 114 | + |
| 115 | +-- component h1: |
| 116 | +caption title: |
| 117 | +optional body body: |
| 118 | +children inner: |
| 119 | +optional string id: |
| 120 | + |
| 121 | +-- ftd.column: |
| 122 | +id if { $h1.id != NULL }: $h1.id |
| 123 | +width: fill-container |
| 124 | + |
| 125 | +-- ftd.text: $h1.title |
| 126 | +role: $inherited.types.heading-large |
| 127 | +color: $inherited.colors.text-strong |
| 128 | +margin-bottom.rem: 0.5 |
| 129 | +width: fill-container |
| 130 | +border-bottom-width.px: 1 |
| 131 | +border-color: $inherited.colors.border |
| 132 | +padding-top.em: 0.5 |
| 133 | +region: h1 |
| 134 | + |
| 135 | +-- markdown: |
| 136 | +if: { h1.body != NULL } |
| 137 | +body: $h1.body |
| 138 | + |
| 139 | +-- ftd.column: |
| 140 | +children: $h1.inner |
| 141 | +width: fill-container |
| 142 | + |
| 143 | +-- end: ftd.column |
| 144 | + |
| 145 | +-- end: ftd.column |
| 146 | + |
| 147 | +-- end: h1 |
| 148 | + |
| 149 | + |
| 150 | + |
| 151 | + |
| 152 | + |
| 153 | + |
| 154 | + |
| 155 | + |
| 156 | + |
| 157 | + |
| 158 | +-- component h2: |
| 159 | +caption title: |
| 160 | +optional body body: |
| 161 | +children inner: |
| 162 | +optional string id: |
| 163 | + |
| 164 | +-- ftd.column: |
| 165 | +id if { $h2.id != NULL }: $h2.id |
| 166 | +width: fill-container |
| 167 | + |
| 168 | +-- ftd.text: $h2.title |
| 169 | +role: $inherited.types.heading-medium |
| 170 | +color: $inherited.colors.text-strong |
| 171 | +margin-bottom.rem: 0.5 |
| 172 | +width: fill-container |
| 173 | +padding-top.em: 0.3 |
| 174 | +region: h2 |
| 175 | + |
| 176 | +-- markdown: |
| 177 | +if: { h2.body != NULL } |
| 178 | +body: $h2.body |
| 179 | + |
| 180 | +-- ftd.column: |
| 181 | +children: $h2.inner |
| 182 | +width: fill-container |
| 183 | + |
| 184 | +-- end: ftd.column |
| 185 | + |
| 186 | +-- end: ftd.column |
| 187 | + |
| 188 | +-- end: h2 |
| 189 | + |
| 190 | + |
| 191 | + |
| 192 | + |
| 193 | + |
| 194 | + |
| 195 | + |
| 196 | + |
| 197 | + |
| 198 | + |
| 199 | +-- component h3: |
| 200 | +caption title: |
| 201 | +optional body body: |
| 202 | +children inner: |
| 203 | +optional string id: |
| 204 | + |
| 205 | +-- ftd.column: |
| 206 | +id if { $h3.id != NULL }: $h3.id |
| 207 | +width: fill-container |
| 208 | + |
| 209 | +-- ftd.text: $h3.title |
| 210 | +role: $inherited.types.heading-small |
| 211 | +color: $inherited.colors.text-strong |
| 212 | +margin-bottom.rem: 0.5 |
| 213 | +width: fill-container |
| 214 | +padding-top.em: 0.17 |
| 215 | +region: h3 |
| 216 | + |
| 217 | +-- markdown: |
| 218 | +if: { h3.body != NULL } |
| 219 | +body: $h3.body |
| 220 | + |
| 221 | +-- ftd.column: |
| 222 | +children: $h3.inner |
| 223 | +width: fill-container |
| 224 | + |
| 225 | +-- end: ftd.column |
| 226 | + |
| 227 | +-- end: ftd.column |
| 228 | + |
| 229 | +-- end: h3 |
| 230 | + |
| 231 | + |
| 232 | + |
| 233 | + |
| 234 | + |
| 235 | + |
| 236 | + |
| 237 | + |
| 238 | + |
| 239 | + |
| 240 | +-- component h4: |
| 241 | +caption title: |
| 242 | +optional body body: |
| 243 | +children inner: |
| 244 | +optional string id: |
| 245 | + |
| 246 | +-- ftd.column: |
| 247 | +id if { $h4.id != NULL }: $h4.id |
| 248 | +width: fill-container |
| 249 | + |
| 250 | +-- ftd.text: $h4.title |
| 251 | +role: $inherited.types.heading-tiny |
| 252 | +color: $inherited.colors.text-strong |
| 253 | +margin-bottom.rem: 0.5 |
| 254 | +width: fill-container |
| 255 | +padding-top.em: 0.08 |
| 256 | +region: h4 |
| 257 | + |
| 258 | +-- markdown: |
| 259 | +if: { h4.body != NULL } |
| 260 | +body: $h4.body |
| 261 | + |
| 262 | +-- ftd.column: |
| 263 | +children: $h4.inner |
| 264 | +width: fill-container |
| 265 | + |
| 266 | +-- end: ftd.column |
| 267 | + |
| 268 | +-- end: ftd.column |
| 269 | + |
| 270 | +-- end: h4 |
| 271 | + |
| 272 | + |
| 273 | + |
| 274 | + |
| 275 | + |
| 276 | + |
| 277 | + |
| 278 | + |
| 279 | + |
| 280 | + |
| 281 | +-- component markdown: |
| 282 | +caption or body body: |
| 283 | +optional string id: |
| 284 | + |
| 285 | +-- ftd.text: |
| 286 | +text: $markdown.body |
| 287 | +role: $inherited.types.copy-regular |
| 288 | +color: $inherited.colors.text |
| 289 | +width: fill-container |
| 290 | +id: $markdown.id |
| 291 | + |
| 292 | +-- end: markdown |
0 commit comments