--- id: 587d78ad367417b2b2512af9 title: 在推文中使用 align-items 屬性 challengeType: 0 videoUrl: 'https://scrimba.com/p/pVaDAv/cd3PNfq' forumTopicId: 301106 dashedName: use-the-align-items-property-in-the-tweet-embed --- # --description-- 在上一個挑戰中,我們介紹了 `align-items` 屬性並給出了示例。 我們可以對推文的幾個嵌入元素使用這個屬性,以調整其中 flex 元素的對齊方式。 # --instructions-- 爲 header 中的 `.follow-btn` 元素添加 CSS 屬性 `align-items`, 並將其屬性值設爲 `center`。 # --hints-- `.follow-btn` 應在頁面上呈現。 請關閉廣告攔截器等任何擴展。 ```js assert($('.follow-btn').length > 0 && $('.follow-btn').css('display') !== 'none'); ``` `.follow-btn` 元素應有值爲 `center` 的 `align-items` 屬性。 ```js assert($('.follow-btn').css('align-items') == 'center'); ``` # --seed-- ## --seed-contents-- ```html
Quincy Larson's profile picture

Quincy Larson

@ossia

I meet so many people who are in search of that one trick that will help them work smart. Even if you work smart, you still have to work hard.

1:32 PM - 12 Jan 2018
``` # --solutions-- ```html
Quincy Larson's profile picture

Quincy Larson

@ossia

I meet so many people who are in search of that one trick that will help them work smart. Even if you work smart, you still have to work hard.

1:32 PM - 12 Jan 2018
```