Skip to content
This repository was archived by the owner on Jun 26, 2020. It is now read-only.

Commit 68d93ff

Browse files
authored
Merge pull request #67 from ckeditor/t/63
Other: Introduced consistent height and spacing among headings dropdown items. Closes #63.
2 parents e58dadc + 486e6ec commit 68d93ff

File tree

2 files changed

+13
-1
lines changed

2 files changed

+13
-1
lines changed

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,8 @@
88
"@ckeditor/ckeditor5-ui": "^0.7.1",
99
"@ckeditor/ckeditor5-utils": "^0.8.0",
1010
"@ckeditor/ckeditor5-engine": "^0.8.0",
11-
"@ckeditor/ckeditor5-paragraph": "^0.6.1"
11+
"@ckeditor/ckeditor5-paragraph": "^0.6.1",
12+
"@ckeditor/ckeditor5-theme-lark": "^0.6.1"
1213
},
1314
"devDependencies": {
1415
"@ckeditor/ckeditor5-dev-lint": "^2.0.2",

theme/theme.scss

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
// Copyright (c) 2003-2017, CKSource - Frederico Knabben. All rights reserved.
22
// For licensing, see LICENSE.md or http://ckeditor.com/license
33

4+
@import '~@ckeditor/ckeditor5-theme-lark/theme/helpers/_spacing';
5+
@import '~@ckeditor/ckeditor5-theme-lark/theme/helpers/_fonts';
6+
47
.ck-heading_heading {
58
&1 {
69
font-size: 1.5em;
@@ -15,6 +18,14 @@
1518
}
1619
}
1720

21+
// Using absolute units to make sure each element has the same height and padding.
22+
// https://github.com/ckeditor/ckeditor5-heading/issues/63
23+
[class*="ck-heading_"] {
24+
line-height: 1.8 * $ck-font-size-base;
25+
// Strip the units from $ck-def-spacing here.
26+
padding: $ck-def-spacing / ( $ck-def-spacing * 0 + 1 ) * $ck-font-size-base;
27+
}
28+
1829
[class*="ck-heading_heading"] {
1930
font-weight: bold;
2031
}

0 commit comments

Comments
 (0)