# Trello card onebox

**URL:** <https://meta.discourse.org/t/trello-card-onebox/24762>\
**Category:** Feature\
**Created:** [2월 3, 2015, 5:05오전 UTC](https://meta.discourse.org/t/trello-card-onebox/24762 "2015-02-03T05:05:30Z")\
**Posts on this page:** 1\
**Showing post:** 19

<div class="post-metadata">

**Author:** ![david](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/david/32/157490_2.png) [@david](https://meta.discourse.org/u/david)\
**Post date:** [9월 28, 2017, 6:32오후 UTC](https://meta.discourse.org/t/trello-card-onebox/24762/19 "2017-09-28T18:32:19Z")

</div>

The embedding looks a lot nicer! But this bit worries me:

> Now when the page loads, the script will find that card, and replace it with a fancy embedded version.

Sounds suspiciously like Twitter’s embedding, which we can’t use on discourse because it modifies the height after the page loads… 😕 Maybe we can use the “programmatic card creation” in a `decorateCooked` method somehow…

Edit:  
Yep, their [handily un-minified javascript](https://p.trellocdn.com/embed.js) has some iframe-resizing magic going on, so I don’t think it’ll work ☹

```plaintext
var receiveMessage = function receiveMessage(event) {
      if (!isAllowedOrigin(event.origin)) {
        return;
      }

      if (event.data.command === 'resize' && event.data.secret) {
        var card = _this.activeCards[event.data.secret];
        if (!card || !card.el) {
          return;
        }
        var newHeight = event.data.options.height;
        if (newHeight !== undefined) {
          card.el.height = newHeight;
        }

```

---

_[View the full topic](https://meta.discourse.org/t/trello-card-onebox/24762)._
