# 细节块的不同外观

**URL:** https://meta.discourse.org/t/different-look-for-details-block/320134
**Category:** Development
**Tags:** hide-details
**Created:** [2024年八月5日 10:23 UTC](https://meta.discourse.org/t/different-look-for-details-block/320134 "2024-08-05T10:23:56Z")
**Posts on this page:** 1
**Showing post:** 6

<div class="post-metadata">

### Author: ![Jagster](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jagster/32/192154_2.png) [@Jagster](https://meta.discourse.org/u/Jagster)
#### Post date: [2024年十月8日 07:27 UTC](https://meta.discourse.org/t/different-look-for-details-block/320134/6 "2024-10-08T07:27:02Z")

</div>

首先，我大约在 20 年前用 Visual Basic 做了一个“hello world”的东西。我曾通过试错法调整过一些 WordPress 插件，并且有一次成功地更改了我 VPS 上的所有权，从 root 开始。

那个很棒的解决方案不再遵循 [details .. open]。这与 [Details block doesn’t obey open](https://meta.discourse.org/t/details-block-doesn-t-obey-open/329670) 有关，我猜。

问题是来自这部分吗？

```plaintext

cookedDetails.forEach((details) => {
            details.setAttribute("open", "");

```

为什么是这样？因为它与 Discourse 中的这个很相似 😂

```plaintext
expect(cooked_html).to match_html <<~HTML
      <details open="">
      <summary></summary>
        <p>bar</p>
      </details>

```

---

_[View the full topic](https://meta.discourse.org/t/different-look-for-details-block/320134)._
