# 嵌套的详细信息在电子邮件中未正确呈现

**URL:** <https://meta.discourse.org/t/nested-details-are-not-rendered-properly-on-emails/243370>\
**Category:** UX\
**Created:** [2022年十月31日 12:33 UTC](https://meta.discourse.org/t/nested-details-are-not-rendered-properly-on-emails/243370 "2022-10-31T12:33:03Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Nacho\_Caballero](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/nacho_caballero/32/130189_2.png) [@Nacho\_Caballero](https://meta.discourse.org/u/Nacho_Caballero)\
**Post date:** [2022年十月31日 12:33 UTC](https://meta.discourse.org/t/nested-details-are-not-rendered-properly-on-emails/243370/1 "2022-10-31T12:33:03Z")

</div>

此问题与 [discourse-details 插件](https://github.com/discourse/discourse/blob/4ad77f3382519c30d5c5cf7ef2bafbec6ece011d/plugins/discourse-details/plugin.rb#L21) @zogstrip 相关

## 复现步骤

1. 您可能需要暂时更改管理员设置 `email time window mins` 为 1 分钟，这样您就不必等待 10 分钟才能收到电子邮件。

2. 创建一个包含以下内容的新主题：

## 预期行为

电子邮件应包含顶层 `details` 文本和一个以 `details.excerpt_details` 键为内容的链接：`点击这里 (点击查看更多详情)`

## 实际行为

电子邮件包含 **所有嵌套的 `details` 文本** ，然后是链接：`点击这里 也点击这里 点击这里 (点击查看更多详情)`

这很成问题，因为如果顶层 `details` 包含许多嵌套的 `details`，输出可能会像这样：

 ![CleanShot 2022-10-31 at 13.30.11](https://global.discourse-cdn.com/meta/original/4X/8/3/d/83d85b71350418eb5af5fe5782957d76daeb9ac9.png)
