Skip to content

Commit 298494c

Browse files
authored
Fix table styling (#789)
* Fix table styling * Fix heading level
1 parent b127f03 commit 298494c

File tree

2 files changed

+28
-1
lines changed

2 files changed

+28
-1
lines changed

docs/syntax/tables.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,32 @@ A table is an arrangement of data with rows and columns. Each row consists of ce
4242
:::
4343

4444

45+
## Table without header
46+
47+
::::{tab-set}
48+
49+
:::{tab-item} Output
50+
| | |
51+
|-------------------|---------|
52+
| **Country** | Austria |
53+
| **Capital** | Vienna |
54+
| **Calling code** | +43 |
55+
| **ISO 3166 code** | AT |
56+
:::
57+
58+
:::{tab-item} Markdown
59+
```markdown
60+
| | |
61+
|-------------------|---------|
62+
| **Country** | Austria |
63+
| **Capital** | Vienna |
64+
| **Calling code** | +43 |
65+
| **ISO 3166 code** | AT |
66+
```
67+
:::
68+
69+
::::
70+
4571
## Responsive Table
4672

4773
Every table is responsive by default. The table will automatically scroll horizontally when the content is wider than the viewport.

src/Elastic.Markdown/Assets/markdown/table.css

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,12 @@
33

44
.table-wrapper {
55

6-
@apply w-full overflow-x-scroll my-4;
6+
@apply w-full overflow-x-auto my-4;
77

88
&::-webkit-scrollbar {
99
@apply h-2 bg-grey-10 border-b-1 border-grey-20;
1010
}
11+
1112
&::-webkit-scrollbar-thumb {
1213
@apply bg-grey-80 rounded-full;
1314
}

0 commit comments

Comments
 (0)