# 如何防止视频/一个框扩展得太宽

**URL:** <https://meta.discourse.org/t/how-do-you-keep-the-video-one-box-from-expanding-too-wide/395457>\
**Category:** Development\
**Created:** [2026年二月8日 02:40 UTC](https://meta.discourse.org/t/how-do-you-keep-the-video-one-box-from-expanding-too-wide/395457 "2026-02-08T02:40:23Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![hipp0](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/hipp0/32/537433_2.png) [@hipp0](https://meta.discourse.org/u/hipp0)\
**Post date:** [2026年二月8日 02:40 UTC](https://meta.discourse.org/t/how-do-you-keep-the-video-one-box-from-expanding-too-wide/395457/1 "2026-02-08T02:40:23Z")

</div>

![image](https://global.discourse-cdn.com/meta/original/4X/8/f/c/8fcfe75ec52a0c37d58e25907d8c4fb555b37140.jpeg)

Brave 浏览器 100% 缩放

```plaintext
/* --- 7. EMBEDS & MEDIA --- */
.twitterstatus {
  max-width: 345px !important;
  width: auto !important;
}

.video-placeholder-container,
.video-placeholder-wrapper,
.lazy-video-wrapper {
  max-width: 690px !important;
  width: auto !important;
}

.allowlistedgeneric {
  max-width: 690px !important;
  width: auto !important;
  padding: 10px !important;
  margin: 0 3px 3px 3px !important;
}

```

---

<div class="post-metadata">

**Author:** ![hipp0](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/hipp0/32/537433_2.png) [@hipp0](https://meta.discourse.org/u/hipp0)\
**Post date:** [2026年二月8日 02:41 UTC](https://meta.discourse.org/t/how-do-you-keep-the-video-one-box-from-expanding-too-wide/395457/2 "2026-02-08T02:41:16Z")

</div>

与此相比，Discourse 上的显示为 100%

 ![image](https://global.discourse-cdn.com/meta/original/4X/0/9/b/09b0dd9ff9e3476e9698b7f7a47c2ea8c06bf660.jpeg)

Firefox 上为 100%

 ![image](https://global.discourse-cdn.com/meta/original/4X/f/2/d/f2d1883f2fb8cd729f6bd747038eee323aef8c0e.jpeg)

---

<div class="post-metadata">

**Author:** ![hipp0](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/hipp0/32/537433_2.png) [@hipp0](https://meta.discourse.org/u/hipp0)\
**Post date:** [2026年二月8日 03:32 UTC](https://meta.discourse.org/t/how-do-you-keep-the-video-one-box-from-expanding-too-wide/395457/3 "2026-02-08T03:32:03Z")

</div>

好吧，我想我用 Gemini 解决了这个问题：  
\*如果这有点大材小用，请告诉我。

```plaintext
/* YouTube/video player fix */
.video-placeholder-container,
.video-placeholder-wrapper,
.lazy-video-wrapper {
  /* 这是保护罩：它将播放器用户界面锁定在 690px */
  max-width: 690px !important;
  width: 100% !important; 
}

.lazy-video-wrapper iframe,
.lazy-video-wrapper video {
  /* 这会填充保护罩 */
  width: 100% !important;
  max-width: 100% !important; 
  height: auto !important;
  aspect-ratio: 16 / 9 !important;
  margin: 0 !important;

}

/* 特别针对上传的视频播放器容器 */
.video-container {
  max-width: 690px !important;
  text-align: left !important;
}

```

Brave 浏览器上 100%：

 ![image](https://global.discourse-cdn.com/meta/original/4X/9/4/7/947415a8f9aa871a939a449e8eb1b46c619be5c3.jpeg)

---

<div class="post-metadata">

**Author:** ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)\
**Post date:** [2026年三月10日 03:32 UTC](https://meta.discourse.org/t/how-do-you-keep-the-video-one-box-from-expanding-too-wide/395457/4 "2026-03-10T03:32:51Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
