@covalent/markdown 5.1.0-beta.1 → 6.0.0-beta.2
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.
- package/README.md +8 -8
- package/_markdown-theme.scss +17 -17
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -63,18 +63,18 @@ export class MyModule {}
|
|
|
63
63
|
This module comes with its own Covalent theme which uses the material theme which is used by importing our theme scss file.
|
|
64
64
|
|
|
65
65
|
```scss
|
|
66
|
-
@
|
|
67
|
-
@
|
|
66
|
+
@use '@angular/material/theming' as mat;
|
|
67
|
+
@use '@covalent/markdown/markdown-theme' as markdown;
|
|
68
68
|
|
|
69
|
-
@include mat
|
|
69
|
+
@include mat.core();
|
|
70
70
|
|
|
71
|
-
$primary: mat-palette($mat-orange, 800);
|
|
72
|
-
$accent: mat-palette($mat-light-blue, 600, A100, A400);
|
|
73
|
-
$warn: mat-palette($mat-red, 600);
|
|
71
|
+
$primary: mat.define-palette($mat-orange, 800);
|
|
72
|
+
$accent: mat.define-palette($mat-light-blue, 600, A100, A400);
|
|
73
|
+
$warn: mat.define-palette($mat-red, 600);
|
|
74
74
|
|
|
75
|
-
$theme: mat-light-theme($primary, $accent, $warn);
|
|
75
|
+
$theme: mat.define-light-theme($primary, $accent, $warn);
|
|
76
76
|
|
|
77
|
-
@include covalent-markdown-theme($theme);
|
|
77
|
+
@include markdown.covalent-markdown-theme($theme);
|
|
78
78
|
```
|
|
79
79
|
|
|
80
80
|
## Example
|
package/_markdown-theme.scss
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
@
|
|
1
|
+
@use '@angular/material' as mat;
|
|
2
2
|
|
|
3
3
|
@mixin covalent-markdown-theme($theme) {
|
|
4
4
|
$accent: map-get($theme, accent);
|
|
@@ -7,63 +7,63 @@
|
|
|
7
7
|
|
|
8
8
|
td-markdown {
|
|
9
9
|
a {
|
|
10
|
-
color: mat-color($accent);
|
|
10
|
+
color: mat.get-color-from-palette($accent);
|
|
11
11
|
}
|
|
12
12
|
|
|
13
13
|
h1,
|
|
14
14
|
h2 {
|
|
15
|
-
border-bottom-color: mat-color($foreground, divider);
|
|
15
|
+
border-bottom-color: mat.get-color-from-palette($foreground, divider);
|
|
16
16
|
}
|
|
17
17
|
|
|
18
18
|
h3,
|
|
19
19
|
h4,
|
|
20
20
|
h5,
|
|
21
21
|
h6 {
|
|
22
|
-
color: mat-color($foreground, secondary-text);
|
|
22
|
+
color: mat.get-color-from-palette($foreground, secondary-text);
|
|
23
23
|
}
|
|
24
24
|
|
|
25
25
|
hr {
|
|
26
|
-
border-color: mat-color($foreground, divider);
|
|
26
|
+
border-color: mat.get-color-from-palette($foreground, divider);
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
blockquote {
|
|
30
|
-
color: mat-color($foreground, secondary-text);
|
|
31
|
-
border-left-color: mat-color($foreground, divider);
|
|
30
|
+
color: mat.get-color-from-palette($foreground, secondary-text);
|
|
31
|
+
border-left-color: mat.get-color-from-palette($foreground, divider);
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
table {
|
|
35
35
|
th,
|
|
36
36
|
td {
|
|
37
|
-
border-color: mat-color($foreground, dividers);
|
|
37
|
+
border-color: mat.get-color-from-palette($foreground, dividers);
|
|
38
38
|
}
|
|
39
39
|
|
|
40
40
|
tr {
|
|
41
|
-
border-top-color: mat-color($foreground, dividers);
|
|
41
|
+
border-top-color: mat.get-color-from-palette($foreground, dividers);
|
|
42
42
|
|
|
43
43
|
&:nth-child(2n) {
|
|
44
|
-
background-color: mat-color($foreground, dividers);
|
|
44
|
+
background-color: mat.get-color-from-palette($foreground, dividers);
|
|
45
45
|
}
|
|
46
46
|
}
|
|
47
47
|
}
|
|
48
48
|
|
|
49
49
|
img {
|
|
50
|
-
background-color: mat-color($background, card);
|
|
50
|
+
background-color: mat.get-color-from-palette($background, card);
|
|
51
51
|
}
|
|
52
52
|
|
|
53
53
|
code {
|
|
54
|
-
background-color: mat-color($background, hover);
|
|
54
|
+
background-color: mat.get-color-from-palette($background, hover);
|
|
55
55
|
}
|
|
56
56
|
|
|
57
57
|
.highlight pre,
|
|
58
58
|
pre {
|
|
59
|
-
background-color: mat-color($background, app-bar);
|
|
59
|
+
background-color: mat.get-color-from-palette($background, app-bar);
|
|
60
60
|
}
|
|
61
61
|
|
|
62
62
|
kbd {
|
|
63
|
-
color: mat-color($foreground, secondary-text);
|
|
64
|
-
background-color: mat-color($background, app-bar);
|
|
65
|
-
border-color: mat-color($foreground, divider);
|
|
66
|
-
border-bottom-color: mat-color($foreground, disabled);
|
|
63
|
+
color: mat.get-color-from-palette($foreground, secondary-text);
|
|
64
|
+
background-color: mat.get-color-from-palette($background, app-bar);
|
|
65
|
+
border-color: mat.get-color-from-palette($foreground, divider);
|
|
66
|
+
border-bottom-color: mat.get-color-from-palette($foreground, disabled);
|
|
67
67
|
}
|
|
68
68
|
}
|
|
69
69
|
}
|