@redocly/theme 0.15.0 → 0.15.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -14,9 +14,9 @@ exports.ContainerWrapper = styled_components_1.default.section.attrs(() => ({
14
14
 
15
15
  padding: var(--md-container-padding-vertical) var(--md-container-padding-horizontal);
16
16
 
17
- & > article:first-child > h1:first-child {
18
- // disable margin top for h1 on the title heading if there is no "Last updated at" block
19
- /* margin-top: 0; */
17
+ article:first-child > h1:first-child {
18
+ // disable margin top for h1 on the title heading
19
+ margin-top: 0;
20
20
  }
21
21
 
22
22
  ${({ theme }) => theme.mediaQueries.medium} {
@@ -50,12 +50,21 @@ exports.baseTable = (0, styled_components_1.css) `
50
50
  }
51
51
 
52
52
  th {
53
+ /** th has text-align: center by default */
53
54
  text-align: left;
54
55
  font-weight: var(--md-table-head-font-weight);
55
56
  color: var(--md-table-head-text-color);
56
57
  background-color: var(--md-table-head-background-color);
57
58
  }
58
59
 
60
+ /* need to overwrite the text-align: left from above */
61
+ th[align='center'] {
62
+ text-align: center;
63
+ }
64
+ th[align='right'] {
65
+ text-align: right;
66
+ }
67
+
59
68
  tr th:first-child,
60
69
  tr td:first-child {
61
70
  border-left: 1px solid var(--md-table-border-color);
@@ -260,10 +269,6 @@ exports.MarkdownWrapper = styled_components_1.default.main.attrs(() => ({
260
269
  ${(0, theme_helpers_1.typography)('h1', 'h')};
261
270
  margin: var(--h1-margin-top) 0 var(--h1-margin-bottom) 0;
262
271
  ${headingAnchor()};
263
-
264
- &:first-child {
265
- margin-top: 0;
266
- }
267
272
  }
268
273
 
269
274
  h2.md {
package/package.json CHANGED
@@ -1,9 +1,10 @@
1
1
  {
2
2
  "name": "@redocly/theme",
3
- "version": "0.15.0",
3
+ "version": "0.15.1",
4
4
  "description": "Shared UI components library",
5
5
  "keywords": [
6
- "theme"
6
+ "theme",
7
+ "redocly"
7
8
  ],
8
9
  "author": "team@redocly.com",
9
10
  "license": "SEE LICENSE IN LICENSE",
@@ -9,9 +9,9 @@ export const ContainerWrapper = styled.section.attrs(() => ({
9
9
 
10
10
  padding: var(--md-container-padding-vertical) var(--md-container-padding-horizontal);
11
11
 
12
- & > article:first-child > h1:first-child {
13
- // disable margin top for h1 on the title heading if there is no "Last updated at" block
14
- /* margin-top: 0; */
12
+ article:first-child > h1:first-child {
13
+ // disable margin top for h1 on the title heading
14
+ margin-top: 0;
15
15
  }
16
16
 
17
17
  ${({ theme }) => theme.mediaQueries.medium} {
@@ -28,12 +28,21 @@ export const baseTable = css`
28
28
  }
29
29
 
30
30
  th {
31
+ /** th has text-align: center by default */
31
32
  text-align: left;
32
33
  font-weight: var(--md-table-head-font-weight);
33
34
  color: var(--md-table-head-text-color);
34
35
  background-color: var(--md-table-head-background-color);
35
36
  }
36
37
 
38
+ /* need to overwrite the text-align: left from above */
39
+ th[align='center'] {
40
+ text-align: center;
41
+ }
42
+ th[align='right'] {
43
+ text-align: right;
44
+ }
45
+
37
46
  tr th:first-child,
38
47
  tr td:first-child {
39
48
  border-left: 1px solid var(--md-table-border-color);
@@ -239,10 +248,6 @@ export const MarkdownWrapper = styled.main.attrs(() => ({
239
248
  ${typography('h1', 'h')};
240
249
  margin: var(--h1-margin-top) 0 var(--h1-margin-bottom) 0;
241
250
  ${headingAnchor()};
242
-
243
- &:first-child {
244
- margin-top: 0;
245
- }
246
251
  }
247
252
 
248
253
  h2.md {