Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
CSS Flexbox (WebElement #35)
Search
Vladimír Kriška
October 08, 2015
Programming
220
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
CSS Flexbox (WebElement #35)
Vladimír Kriška
October 08, 2015
More Decks by Vladimír Kriška
See All by Vladimír Kriška
Twelve-Factor app with Docker
ujovlado
0
200
Design a REST API you will love to work with
ujovlado
0
830
Docker for PHP developers - Tips, Tricks & Lessons learned
ujovlado
3
540
Docker ‐ from development to production in minutes (PoSobota #91)
ujovlado
0
450
Non-traditional use of Docker (Nette Camp #3)
ujovlado
0
210
Contributions [lightning talk] (PyconCZ 2015)
ujovlado
0
160
Simplify your dev life with Docker (WebElement Banská Bystrica)
ujovlado
0
220
Don't underestimate CSS (WebElement #30)
ujovlado
0
660
Database Migrations in PHP (Posobota #66)
ujovlado
0
180
Other Decks in Programming
See All in Programming
우리의 Nitro Modules는 당신의 Turbo Modules보다 아름답다
l2hyunwoo
0
260
Materialが消えた日 〜真っ白なFlutterキャンバスにRenderObjectで絵を描く〜
umigishiaoi
0
150
SODA - FACT BOOK(EN)
sodainc
1
210
私なりのハーネスエンジニアリング ~独自の言語処理系の開発を通して~
seosoft
0
180
Kotlinize Is Not Just Converting to Kotlin
chigichan24
1
220
LLM 101
dalinaum
0
470
あなたの await、OS まで届いてる? strace で覗く JavaScript の非同期
hasutosasaki
1
2.2k
Engineering Biometric UX Across Android Versions | DroidKnights 2026
ryunen344
1
190
Enforcing Your Architecture with Unit Tests in the AI Era (Swift Connection X)
steliosf
PRO
1
150
クラウドゲーミングのパフォーマンス最適化に挑む / Cloud Gaming Performance Tuning
vivion
0
330
Augmenting AI with the Power of Jakarta EE
ivargrimstad
0
160
Будущее локальных LLM – Алексей Голобурдин, PythoNN
sobolevn
0
110
Featured
See All Featured
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
Building a A Zero-Code AI SEO Workflow
portentint
PRO
0
820
How to Build an AI Search Optimization Roadmap - Criteria and Steps to Take #SEOIRL
aleyda
1
2.2k
Marketing Yourself as an Engineer | Alaka | Gurzu
gurzu
0
360
How Fast Is Fast Enough? [PerfNow 2025]
tammyeverts
3
970
Facilitating Awesome Meetings
lara
57
7.2k
Designing Dashboards & Data Visualisations in Web Apps
destraynor
232
55k
How Software Deployment tools have changed in the past 20 years
geshan
3
35k
The browser strikes back
jonoalderson
0
1.9k
Faster Mobile Websites
deanohume
310
32k
Testing 201, or: Great Expectations
jmmastey
46
8.4k
B2B Lead Gen: Tactics, Traps & Triumph
marketingsoph
1
300
Transcript
CSS FLEXBOX Vladimír Kriška (@ujovlado) WebElement #35
None
None
Classic “floats”
None
Flexbox applied* *and minor improvements: styled button, changed image position
None
Container, items, … source: http://www.w3.org/TR/css-flexbox-1/
flex-flow (shorthand) flex-direction • row, row-reverse, column, column-reverse • initial
value: row flex-wrap • nowrap, wrap, wrap-reverse • initial value: nowrap • flex-direction || flex-wrap
order • <int> • initial value: 0 • affects only
visual media (not speech) • use it for visual, not logical ordering
Single-line & multi-line Once content is broken into lines, each
line is independent
The “flex” property (shorthand) • none, [flex-grow && flex-shrink ||
flex-basis] • flex: none • 0 0 auto • flex: initial (this is an initial value) • 0 1 auto • flex: auto • 1 1 auto • flex: <int> • <int> 1 0% (e.g. flex: 10 => flex: 10 1 0%)
flex-grow & flex-shrink & flex-basis flex-grow how much the flex
item will grow relative to the rest of the flex items flex-shrink how much the flex item will shrink relative to the rest of the flex items flex-basis initial main size of the flex item, before free space is distributed according to the flex factors
flex: 1 0 20%* *with min-width applied and disabled max-width
min-width: 200px;
Different flex for each box* min-width: 200px; *with min-width applied
and disabled max-width
None
justify-content • flex-start, flex-end, center, space-between, space-around • initial value:
flex-start source: http://www.w3.org/TR/css-flexbox-1/
justify-content: center
None
align-items, align-self align-items • flex-start, flex-end, center, baseline, stretch •
initial value: stretch • applies to: containers align-self • auto, flex-start, flex-end, center, baseline, stretch • initial value: auto • applies to: items
align-items, align-self source: http://www.w3.org/TR/css-flexbox-1/
So, how to center div vertically?
None
Questions? No? Thank you!