Skip to content

Commit 7f467ef

Browse files
Update data (#12)
Co-authored-by: fisker <[email protected]>
1 parent 99f3024 commit 7f467ef

File tree

2 files changed

+29
-45
lines changed

2 files changed

+29
-45
lines changed

index.css

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -415,35 +415,33 @@ section {
415415
display: block;
416416
}
417417

418-
h1 {
418+
:heading {
419+
font-weight: bold;
420+
}
421+
422+
:heading(1) {
419423
margin-block: 0.67em;
420424
font-size: 2em;
421-
font-weight: bold;
422425
}
423-
h2 {
426+
:heading(2) {
424427
margin-block: 0.83em;
425428
font-size: 1.5em;
426-
font-weight: bold;
427429
}
428-
h3 {
430+
:heading(3) {
429431
margin-block: 1em;
430432
font-size: 1.17em;
431-
font-weight: bold;
432433
}
433-
h4 {
434+
:heading(4) {
434435
margin-block: 1.33em;
435436
font-size: 1em;
436-
font-weight: bold;
437437
}
438-
h5 {
438+
:heading(5) {
439439
margin-block: 1.67em;
440440
font-size: 0.83em;
441-
font-weight: bold;
442441
}
443-
h6 {
444-
margin-block: 2.33em;
442+
:heading(6, 7, 8, 9) {
445443
font-size: 0.67em;
446-
font-weight: bold;
444+
margin-block: 2.33em;
447445
}
448446

449447
dir,

index.js

Lines changed: 18 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -873,7 +873,17 @@ export default [
873873
},
874874
{
875875
type: 'Styles',
876-
selectors: ['h1'],
876+
selectors: [':heading'],
877+
styles: [
878+
{
879+
property: 'font-weight',
880+
value: 'bold',
881+
},
882+
],
883+
},
884+
{
885+
type: 'Styles',
886+
selectors: [':heading(1)'],
877887
styles: [
878888
{
879889
property: 'margin-block',
@@ -883,15 +893,11 @@ export default [
883893
property: 'font-size',
884894
value: '2.00em',
885895
},
886-
{
887-
property: 'font-weight',
888-
value: 'bold',
889-
},
890896
],
891897
},
892898
{
893899
type: 'Styles',
894-
selectors: ['h2'],
900+
selectors: [':heading(2)'],
895901
styles: [
896902
{
897903
property: 'margin-block',
@@ -901,15 +907,11 @@ export default [
901907
property: 'font-size',
902908
value: '1.50em',
903909
},
904-
{
905-
property: 'font-weight',
906-
value: 'bold',
907-
},
908910
],
909911
},
910912
{
911913
type: 'Styles',
912-
selectors: ['h3'],
914+
selectors: [':heading(3)'],
913915
styles: [
914916
{
915917
property: 'margin-block',
@@ -919,15 +921,11 @@ export default [
919921
property: 'font-size',
920922
value: '1.17em',
921923
},
922-
{
923-
property: 'font-weight',
924-
value: 'bold',
925-
},
926924
],
927925
},
928926
{
929927
type: 'Styles',
930-
selectors: ['h4'],
928+
selectors: [':heading(4)'],
931929
styles: [
932930
{
933931
property: 'margin-block',
@@ -937,15 +935,11 @@ export default [
937935
property: 'font-size',
938936
value: '1.00em',
939937
},
940-
{
941-
property: 'font-weight',
942-
value: 'bold',
943-
},
944938
],
945939
},
946940
{
947941
type: 'Styles',
948-
selectors: ['h5'],
942+
selectors: [':heading(5)'],
949943
styles: [
950944
{
951945
property: 'margin-block',
@@ -955,27 +949,19 @@ export default [
955949
property: 'font-size',
956950
value: '0.83em',
957951
},
958-
{
959-
property: 'font-weight',
960-
value: 'bold',
961-
},
962952
],
963953
},
964954
{
965955
type: 'Styles',
966-
selectors: ['h6'],
956+
selectors: [':heading(6, 7, 8, 9)'],
967957
styles: [
968-
{
969-
property: 'margin-block',
970-
value: '2.33em',
971-
},
972958
{
973959
property: 'font-size',
974960
value: '0.67em',
975961
},
976962
{
977-
property: 'font-weight',
978-
value: 'bold',
963+
property: 'margin-block',
964+
value: '2.33em',
979965
},
980966
],
981967
},

0 commit comments

Comments
 (0)