You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Make minor phrasing changes to table article (#881)
* Make minor phrasing changes to table article
- Avoid passive voice
- More explicitly address the reader
- Fix grammar and wording mistakes
rdar://122293614
* Correct alignment used in spanning cells example
* More minor phrasing changes to table article:
- Typos/grammar fixes for two sentences
---------
Co-authored-by: Pat Shaughnessy <[email protected]>
Copy file name to clipboardExpand all lines: Sources/docc/DocCDocumentation.docc/adding-tables-of-data.md
+9-9Lines changed: 9 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,7 +19,7 @@ Sloth speed | Description
19
19
`supersonic` | Moves faster than the speed of sound
20
20
```
21
21
22
-
The example markup above defines the table that's shown below. Each column is automatically sized to fit its widest cell and the table is only as wide as the sum of its columns.
22
+
The example markup above defines the table that's shown below. Each column is only as wide as its widest cell and the table is only as wide as the sum of its columns.
`supersonic` | Moves faster than the speed of sound
30
30
31
-
It's not necessary to pad the cells to align the column separators (`|`). However, it may make your table _markup_ easier to read, especially for large or complex tables.
31
+
You don't need to pad the cells to align the column separators (`|`). However, it might make your table _markup_ easier to read, especially for large or complex tables.
32
32
33
-
The same table could have been defined like below. All other examples will uses padded cells for readability.
33
+
You can also define the same table with the markup that's shown below. All other examples will use padded cells for readability.
34
34
35
35
```md
36
36
Sloth speed|Description
@@ -41,7 +41,7 @@ Sloth speed|Description
41
41
`supersonic`|Moves faster than the speed of sound
42
42
```
43
43
44
-
You can add leading and/or trailing pipes (`|`) if you find that table markup easier to read. This doesn't affect the rendered table on the page. The leading and trailing pipes _can_ be applied inconsistently for each row but doing so may make it harder to discern the structure of the table.
44
+
You can add leading and/or trailing pipes (`|`) if you find that table markup easier to read. This doesn't affect the rendered table on the page. The leading and trailing pipes _can_ be applied inconsistently for each row, but doing so may make it harder to discern the structure of the table.
45
45
46
46
```md
47
47
| Sloth speed | Description |
@@ -68,7 +68,7 @@ Leading | Center | Trailing
68
68
69
69
### Spanning cells across columns
70
70
71
-
By default, each table cell is one column wide and one row tall. To span a table cell across multiple columns, place two or more column separators (`|`) next to each other after the cell's content. If the spanning cell is the last or only element of a row, you need to add the extra trailing pipe (`|`) for that row, otherwise DocC will interpret the row as having an additional empty cell at the end. For example:
71
+
By default, each table cell is one column wide and one row tall. To span a table cell across multiple columns, place two or more column separators (`|`) next to each other after the cell's content. If the spanning cell is the last or only element of a row, you need to add the extra trailing pipe (`|`) for that row, otherwise DocC interprets the row as having an additional empty cell at the end. For example:
72
72
73
73
@Row {
74
74
@Column {
@@ -89,19 +89,19 @@ By default, each table cell is one column wide and one row tall. To span a table
89
89
}
90
90
}
91
91
92
-
> Tip: You may find it easier to discern the structure of your table from its markup if you use trailing pipes consistently when spanning cells.
92
+
> Tip: You might find it easier to discern the structure of your table from its markup if you use trailing pipes consistently when spanning cells.
93
93
94
-
A spanning cells determines its horizontal alignment from the left-most column that it spans. Going from left to right in the example below:
94
+
A spanning cell determines its horizontal alignment from the left-most column that it spans. Going from left to right in the example below:
95
95
96
-
- Cells "One" and "Five" uses leading alignment because they both span the first column
96
+
- Cells "One" and "Five" use leading alignment because they both span the first column
97
97
- Cell "Four" uses center alignment because it spans the second column
98
98
- Cell "Two" uses trailing alignment because it spans the third column
0 commit comments