Download free for 30 days
Sign in
Upload
Language (EN)
Support
Business
Mobile
Social Media
Marketing
Technology
Art & Photos
Career
Design
Education
Presentations & Public Speaking
Government & Nonprofit
Healthcare
Internet
Law
Leadership & Management
Automotive
Engineering
Software
Recruiting & HR
Retail
Sales
Services
Science
Small Business & Entrepreneurship
Food
Environment
Economy & Finance
Data & Analytics
Investor Relations
Sports
Spiritual
News & Politics
Travel
Self Improvement
Real Estate
Entertainment & Humor
Health & Medicine
Devices & Hardware
Lifestyle
Change Language
Language
English
Español
Português
Français
Deutsche
Cancel
Save
EN
Uploaded by
akinobu yumoto
391 views
CSSと仲良くなろう
社内勉強会用資料 BEMの基礎とCSSを組む際に気をつけたいこと
Engineering
◦
Read more
0
Save
Share
Embed
Embed presentation
Download
Download to read offline
1
/ 18
2
/ 18
3
/ 18
4
/ 18
5
/ 18
6
/ 18
7
/ 18
8
/ 18
9
/ 18
10
/ 18
11
/ 18
12
/ 18
13
/ 18
14
/ 18
15
/ 18
16
/ 18
17
/ 18
18
/ 18
More Related Content
PDF
Bem Study
by
Haraguchi Go
PDF
モダンCSS設計と BEMという開発手法
by
Kenji Karahashi
PDF
BEMについて一緒に考えてみませんか
by
KatsuhiroSaito1
PPTX
BEM記法~HTMLコーディングする際のidやclassの命名規則~
by
Younju Park
PPT
Explanation about ABEM
by
Tensho Tanaka
PDF
悩まないコーディングをしよう! OOCSS,SMACSSを用いた、読みやすくてメンテナブルなCSS設計(Sass対応)
by
Horiguchi Seito
PDF
THE BEM: Better Css Naming Conventions
by
Kotaro Kawashima
PDF
CSS の歩き方
by
Seiichiro Mishiba
Bem Study
by
Haraguchi Go
モダンCSS設計と BEMという開発手法
by
Kenji Karahashi
BEMについて一緒に考えてみませんか
by
KatsuhiroSaito1
BEM記法~HTMLコーディングする際のidやclassの命名規則~
by
Younju Park
Explanation about ABEM
by
Tensho Tanaka
悩まないコーディングをしよう! OOCSS,SMACSSを用いた、読みやすくてメンテナブルなCSS設計(Sass対応)
by
Horiguchi Seito
THE BEM: Better Css Naming Conventions
by
Kotaro Kawashima
CSS の歩き方
by
Seiichiro Mishiba
Featured
PDF
2024 Trend Updates: What Really Works In SEO & Content Marketing
by
Search Engine Journal
PDF
Storytelling For The Web: Integrate Storytelling in your Design Process
by
Chiara Aliotta
PDF
Artificial Intelligence, Data and Competition – SCHREPEL – June 2024 OECD dis...
by
OECD Directorate for Financial and Enterprise Affairs
PDF
How to Leverage AI to Boost Employee Wellness - Lydia Di Francesco - SocialHR...
by
SocialHRCamp
PDF
2024 State of Marketing Report – by Hubspot
by
Marius Sescu
PDF
Everything You Need To Know About ChatGPT
by
Expeed Software
PDF
Product Design Trends in 2024 | Teenage Engineerings
by
Pixeldarts
PDF
How Race, Age and Gender Shape Attitudes Towards Mental Health
by
ThinkNow
PDF
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
by
marketingartwork
PDF
Skeleton Culture Code
by
Skeleton Technologies
PDF
PEPSICO Presentation to CAGNY Conference Feb 2024
by
Neil Kimberley
PDF
Content Methodology: A Best Practices Report (Webinar)
by
contently
PPTX
How to Prepare For a Successful Job Search for 2024
by
Albert Qian
PDF
Social Media Marketing Trends 2024 // The Global Indie Insights
by
Kurio // The Social Media Age(ncy)
PDF
Trends In Paid Search: Navigating The Digital Landscape In 2024
by
Search Engine Journal
PDF
5 Public speaking tips from TED - Visualized summary
by
SpeakerHub
PDF
ChatGPT and the Future of Work - Clark Boyd
by
Clark Boyd
PDF
Getting into the tech field. what next
by
Tessa Mero
PDF
Google's Just Not That Into You: Understanding Core Updates & Search Intent
by
Lily Ray
PDF
How to have difficult conversations
by
Rajiv Jayarajah, MAppComm, ACC
2024 Trend Updates: What Really Works In SEO & Content Marketing
by
Search Engine Journal
Storytelling For The Web: Integrate Storytelling in your Design Process
by
Chiara Aliotta
Artificial Intelligence, Data and Competition – SCHREPEL – June 2024 OECD dis...
by
OECD Directorate for Financial and Enterprise Affairs
How to Leverage AI to Boost Employee Wellness - Lydia Di Francesco - SocialHR...
by
SocialHRCamp
2024 State of Marketing Report – by Hubspot
by
Marius Sescu
Everything You Need To Know About ChatGPT
by
Expeed Software
Product Design Trends in 2024 | Teenage Engineerings
by
Pixeldarts
How Race, Age and Gender Shape Attitudes Towards Mental Health
by
ThinkNow
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
by
marketingartwork
Skeleton Culture Code
by
Skeleton Technologies
PEPSICO Presentation to CAGNY Conference Feb 2024
by
Neil Kimberley
Content Methodology: A Best Practices Report (Webinar)
by
contently
How to Prepare For a Successful Job Search for 2024
by
Albert Qian
Social Media Marketing Trends 2024 // The Global Indie Insights
by
Kurio // The Social Media Age(ncy)
Trends In Paid Search: Navigating The Digital Landscape In 2024
by
Search Engine Journal
5 Public speaking tips from TED - Visualized summary
by
SpeakerHub
ChatGPT and the Future of Work - Clark Boyd
by
Clark Boyd
Getting into the tech field. what next
by
Tessa Mero
Google's Just Not That Into You: Understanding Core Updates & Search Intent
by
Lily Ray
How to have difficult conversations
by
Rajiv Jayarajah, MAppComm, ACC
CSSと仲良くなろう
1.
CSSと仲良くなろう
2.
⽬的 • BEMの理解を深める • BEMに沿った改修ができるようになる •
崩れにくいCSSを組めるようになる
3.
おしながき • ⽬的 • BEMの説明 •
アンチパターンと解決案 • その他、気をつけるポイント
4.
BEMってなんだ?
5.
BEMとは • CSSの命名規則のこと • Block-Element-Mofifierの略 •
基本的にシングルクラス • HTMLとCSSを疎結合にする (タグにはスタイルを当てない)
6.
Block-Element-Modifier Block:独⽴して再利⽤できるもの(⾚) Element:Blockの構成要素(⻘、紫) Modifier:B-Eの状態が変わったもの(紫) ※サンプルSP会社詳細タブ
7.
書き⽅のルール • Eはアンスコx2区切り • Mはハイフンx2区切り •
シングルクラス • タグにスタイルを当てない
8.
BEMを使うと良いこと • コンポーネントの再利⽤性が⾼い • 読みやすい •
クラス名の衝突が起こりづらい • 詳細度が上がらない • DOM構造に依存しない
9.
アンチパターンと解決策
10.
エレメントのみのコピペ 解決策 -> header-top__nav-dropdownを再定義する
11.
ブロックの外側にエレメント 解決策 -> 別ブロックにする or
ブロックを1つ親に設定
12.
ブロックの密結合 解決策 -> 同じブロックにする
13.
その他、気をつけるポイント
14.
floatの解除 解除しないと⾼さが0になり崩れの原因に🐛 floatしたら必ずclearfixしましょう
15.
可変⻑の組み⽅ ⽂字数が増えたときにも崩れないか確認したい
16.
浮かせた要素が被る 兄弟要素なのに⽚⽅が覆いかぶさっている ボタンの下にテキストが⼊ってしまったり ⽚⽅が押せなくなるため被らないようにする
17.
clickable、hoverableエリア 押せるエリアとホバーするエリアが違う 押せるエリアも注意しないと テキストしか押せないボタンなどが⽣まれてしまう ため注意が必要
18.
参考記事 • BEM を使うべき5つの理由(なぜ
BEM が G.R.E.A.T といえるのか) - Frasco • BEMという命名規則とSass 3.3の新しい記法 - アインシュタインの電話番号 • 細かすぎるけど伝わってほしい私的BEMプラクティス30
Download