]> Untitled Git - lemmy-ui.git/commitdiff
fix: Add .accordion wrapper around sidebar to obtain negative bottom margin
authorJay Sitter <jay@jaysitter.com>
Sat, 17 Jun 2023 18:24:13 +0000 (14:24 -0400)
committerJay Sitter <jay@jaysitter.com>
Sat, 17 Jun 2023 18:24:13 +0000 (14:24 -0400)
src/shared/components/home/site-sidebar.tsx

index 283ddf83629c91d9aed5bf5a0f5b3063e99c2f7a..b09f27d20cc71e009accff2995221ed42144ac7d 100644 (file)
@@ -29,25 +29,27 @@ export class SiteSidebar extends Component<SiteSidebarProps, SiteSidebarState> {
 
   render() {
     return (
-      <section
-        id="sidebarInfo"
-        className="card border-secondary mb-3 overflow-hidden"
-      >
-        <header className="card-header" id="sidebarInfoHeader">
-          {this.siteName()}
-          {!this.state.collapsed && (
-            <BannerIconHeader banner={this.props.site.banner} />
-          )}
-        </header>
-
-        <div
-          id="sidebarInfoBody"
-          className="collapse show"
-          aria-labelledby="sidebarInfoHeader"
+      <div className="accordion">
+        <section
+          id="sidebarInfo"
+          className="card border-secondary mb-3 overflow-hidden"
         >
-          <div className="card-body">{this.siteInfo()}</div>
-        </div>
-      </section>
+          <header className="card-header" id="sidebarInfoHeader">
+            {this.siteName()}
+            {!this.state.collapsed && (
+              <BannerIconHeader banner={this.props.site.banner} />
+            )}
+          </header>
+
+          <div
+            id="sidebarInfoBody"
+            className="collapse show"
+            aria-labelledby="sidebarInfoHeader"
+          >
+            <div className="card-body">{this.siteInfo()}</div>
+          </div>
+        </section>
+      </div>
     );
   }