freeCodeCamp/guide/russian/certifications/responsive-web-design/css-flexbox/use-the-flex-direction-prop.../index.md

17 lines
1.1 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

---
title: Use the flex-direction Property to Make a Row
localeTitle: Используйте свойство flex-direction для создания строки
---
## Используйте свойство flex-direction для создания строки
Как только у вас есть гибкий контейнер, добавив _display: flex;_ в родительский контейнер, вы можете указать, хотите ли вы, чтобы дети были сложены в ряд, добавив следующее:
```css
#box-container {
display: flex; /* This makes the flex container */
height: 500px;
flex-direction: row-reverse; /* This makes the direction be a row with reversed elements */
}
```
Вы заметите, как цвета переключают позиции по умолчанию в контейнерах гибких дисков - это строки, которые вы могли заметить из [примера твита](https://github.com/freecodecamp/guides/tree/master/src/pages/responsive-web-design/css-flexbox/add-flex-superpowers-to-the-tweet-embed/index.md) .