| OLD | NEW |
| 1 Sky Markup: Syntax | 1 Sky Markup: Syntax |
| 2 ================== | 2 ================== |
| 3 | 3 |
| 4 A Sky file must consist of the following components: | 4 A Sky file must consist of the following components: |
| 5 | 5 |
| 6 1. If the file is intended to be a top-level Sky application, the | 6 1. If the file is intended to be a top-level Sky application, the |
| 7 string "``#!mojo mojo:sky``" followed by a U+0020, U+000A or | 7 string "``#!mojo mojo:sky``" followed by a U+0020, U+000A or |
| 8 U+000D character. | 8 U+000D character. |
| 9 | 9 |
| 10 If the file is intended to be a module, then the string "SKY", a | 10 If the file is intended to be a module, then the string "SKY", a |
| (...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 156 - Downloads and imports foo.sky in the background, using "foo" as its | 156 - Downloads and imports foo.sky in the background, using "foo" as its |
| 157 local name (see ``<script>``). | 157 local name (see ``<script>``). |
| 158 | 158 |
| 159 ``<template>`` | 159 ``<template>`` |
| 160 - The contents of the element aren't placed in the Element itself. | 160 - The contents of the element aren't placed in the Element itself. |
| 161 They are instead placed into a DocumentFragment that you can obtain | 161 They are instead placed into a DocumentFragment that you can obtain |
| 162 from the element's "content" attribute. | 162 from the element's "content" attribute. |
| 163 | 163 |
| 164 ``<script>`` | 164 ``<script>`` |
| 165 - Blocks until all previous imports have been loaded, then runs the | 165 - Blocks until all previous imports have been loaded, then runs the |
| 166 script, with either 'module' or 'application' as the first | 166 script, with 'module' as the first argument, the exports of any |
| 167 argument, the exports of any imports that have "as" attributes at | 167 imports that have "as" attributes at this time passed in as |
| 168 this time passed in as subsequent arguments, and with "this" set to | 168 subsequent arguments, and with "this" set to null. |
| 169 null. | |
| 170 | 169 |
| 171 ``<style>`` | 170 ``<style>`` |
| 172 - Adds the contents to the document's styles. | 171 - Adds the contents to the document's styles. |
| 173 | 172 |
| 174 ``<content>`` | 173 ``<content>`` |
| 175 ``<content select="...">`` | 174 ``<content select="...">`` |
| 176 - In a shadow tree, acts as an insertion point for distributed nodes. | 175 - In a shadow tree, acts as an insertion point for distributed nodes. |
| 177 The select="" attribute gives the selector to use to pick the nodes | 176 The select="" attribute gives the selector to use to pick the nodes |
| 178 to place in this insertion point; it defaults to everything. | 177 to place in this insertion point; it defaults to everything. |
| 179 | 178 |
| (...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 215 | 214 |
| 216 The following attributes are available on all elements: | 215 The following attributes are available on all elements: |
| 217 | 216 |
| 218 * ``id=""`` (any value) | 217 * ``id=""`` (any value) |
| 219 * ``class=""`` (any value, space-separated) | 218 * ``class=""`` (any value, space-separated) |
| 220 * ``style=""`` (declaration part of a Sky style rule) | 219 * ``style=""`` (declaration part of a Sky style rule) |
| 221 * ``lang=""`` (language code) | 220 * ``lang=""`` (language code) |
| 222 * ``dir=""`` (ltr or rtl only) | 221 * ``dir=""`` (ltr or rtl only) |
| 223 * ``contenteditable=""`` (subject to future developments) | 222 * ``contenteditable=""`` (subject to future developments) |
| 224 * ``tabindex=""`` (subject to future developments) | 223 * ``tabindex=""`` (subject to future developments) |
| OLD | NEW |