# 如何控制侧边栏菜单部分的顺序？

**URL:** <https://meta.discourse.org/t/how-to-control-the-order-of-menu-sections-in-the-sidebar/383384>\
**Category:** Support\
**Tags:** sidebar\
**Created:** [2025年九月20日 14:18 UTC](https://meta.discourse.org/t/how-to-control-the-order-of-menu-sections-in-the-sidebar/383384 "2025-09-20T14:18:41Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![chapoi](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/chapoi/32/537252_2.png) [@chapoi](https://meta.discourse.org/u/chapoi)\
**Post date:** [2025年九月21日 19:28 UTC](https://meta.discourse.org/t/how-to-control-the-order-of-menu-sections-in-the-sidebar/383384/7 "2025-09-21T19:28:48Z")

</div>

移动设备上的 `sidebar-wrapper` 类被 `sidebar-hamburger-dropdown` 取代了，我认为。因此，添加它也应该能在移动设备上正常工作：

```plaintext
.sidebar-wrapper, 
.sidebar-hamburger-dropdown { 
  .sidebar-custom-sections {
    display: contents;
  } 
  [data-section-name="community"] {
    order: -4;
  }
  [data-section-name="categories"] {
    order: -3;
  }
  [data-section-name="tags"] {
    order: -2;
  }
  [data-section-name="custom-section-name"] {
    order: -1;
  }
}

```

---

_[View the full topic](https://meta.discourse.org/t/how-to-control-the-order-of-menu-sections-in-the-sidebar/383384)._
