Skip to content

Commit

Permalink
feat: add styles for the details block (#2165)
Browse files Browse the repository at this point in the history
  • Loading branch information
laurelfulford authored Jul 25, 2023
1 parent 81c52f5 commit 25832c3
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 0 deletions.
22 changes: 22 additions & 0 deletions newspack-theme/sass/blocks/_blocks.scss
Original file line number Diff line number Diff line change
Expand Up @@ -1162,6 +1162,28 @@ hr {
}
}

//! Details block
.wp-block-details {
border: solid var( --newspack-theme-color-border );
border-width: 1px 0;
padding: 0.5rem 1.5rem;

> :not(summary) {
margin-bottom: 16px;
margin-top: 16px;
}

summary {
font-family: var( --newspack-theme-font-heading );
margin-left: -1rem;
}

+ .wp-block-details {
border-top: 0;
margin-top: -32px;
}
}

//! Navigtation block
.wp-block-navigation a {
text-decoration: none;
Expand Down
21 changes: 21 additions & 0 deletions newspack-theme/sass/style-editor-base.scss
Original file line number Diff line number Diff line change
Expand Up @@ -998,6 +998,27 @@ ul.wp-block-archives,
}
}

/** === Details block === */
.wp-block-details {
border: solid var( --newspack-theme-color-border );
border-width: 1px 0;
padding: 0.5rem 1.5rem;

> :not(summary) {
margin-bottom: 16px;
margin-top: 16px;
}

summary {
font-family: var( --newspack-theme-font-heading );
}

+ .wp-block-details {
border-top: 0;
margin-top: -28px;
}
}

/** === Organic Profile Block === */
.wp-block-organic-profile-block {
box-shadow: none;
Expand Down

0 comments on commit 25832c3

Please sign in to comment.