Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Details on <details>
Search
Mu-An Chiou
July 19, 2018
Technology
390
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Details on <details>
https://gist.github.com/muan/adf26249c0adf018aea828105a5846eb
Mu-An Chiou
July 19, 2018
More Decks by Mu-An Chiou
See All by Mu-An Chiou
Publishing and Hosting on GitHub pages
muan
4
170
Having no patience(Japanese)
muan
1
410
JSDC
muan
2
560
Design with Code
muan
5
580
Having no patience
muan
1
330
Design in GitHub
muan
5
390
Project Lab Squirrel #2
muan
1
680
Project Lab Squirrel #1
muan
8
910
A girl with no patience
muan
18
2k
Other Decks in Technology
See All in Technology
ゼロをイチにする仕事が終わったあと
smasato
0
250
ループエンジニアリングでE2Eテストを実践
noriyukitakei
0
230
cccccc
moznion
0
1.6k
本当の”仕事”を手放せる未来が見えた
mu7889yoon
0
220
スタートアップにおけるアジャイルの実践について #shibuyagile
murabayashi
3
2k
Terraform 101 (初心者向け) 資料
shuadachi
0
160
AWS Blocks を触ってみた/first-tach-aws-blocks
fossamagna
2
140
5分でわかる Amazon Connect_20260608
hwangbyeonghun
0
170
HookでSAST、CIでSAST、SCAでどうにかしている話 / layered-security-for-ai-written-code-with-sast-and-sca
yamaguchitk333
0
100
NDIAS CTF 2026 問題解説会資料
bata_24
0
170
技術・能力を向上する原理原則 #きのこセッションa #きのこ2026
bash0c7
0
200
デジタル・デザイン:次の50年を描く「進化する青写真」
y150saya
0
800
Featured
See All Featured
Skip the Path - Find Your Career Trail
mkilby
1
160
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3.5k
Designing Powerful Visuals for Engaging Learning
tmiket
1
430
The Illustrated Children's Guide to Kubernetes
chrisshort
51
52k
What the history of the web can teach us about the future of AI
inesmontani
PRO
1
630
Facilitating Awesome Meetings
lara
57
7k
Building Flexible Design Systems
yeseniaperezcruz
330
40k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
32
2.9k
Leo the Paperboy
mayatellez
7
1.9k
Odyssey Design
rkendrick25
PRO
2
720
Measuring Dark Social's Impact On Conversion and Attribution
stephenakadiri
2
230
Lightning Talk: Beautiful Slides for Beginners
inesmontani
PRO
2
590
Transcript
Greet(‘Brooklyn JS’)
Who this Mu-An Chiou Web Systems Engineer @ GitHub Taiwan
#1 GitHub @muan / Twitter @muanchiou
Details on <details> The best element in HTML 5. Do
@ me.
https://www.chromestatus.com/metrics/feature/timeline/popularity/480
What
What <details> <summary>Details</summary> <p>content</p> </details>
What <details> <summary>Details</summary> <p>content</p> </details>
What <details> <summary>Details</summary> <p>content</p> </details>
What <details open> <summary>Details</summary> <p>content</p> </details>
What details.open = true/false
What details.addEventListener(‘toggle’, () => {})
Why not this el.addEventListener('click', e => { const thing =
document.querySelector(‘.thing’) thing.style.display = ‘none’ })
Or this input:check + * { display: block; }
Here’s why Semantic
Here’s why Accessible
Here’s why No JavaScript
Here’s why = Interactive on load
When
When Accordions Popovers Dropdowns …
The beginning ! IE 11
Dropdown menu <div class=“dropdown js-menu-container”> <button class=“btn js-menu-target” aria-haspopup=“menu”>…</button> <ul
class=“dropdown-content js-menu-content”> <li><a href=“/muan">profile</a></li> … </ul> </div>
Dropdown menu <details class=“dropdown”> <summary class=“btn” aria-haspopup=“menu”>…</summary> <ul class=“dropdown-content”> <li><a
href=“/muan">profile</a></li> … </ul> </details>
Dropdown menu
Dropdown menu CSS: summary::before
Dropdown menu CSS: summary::before + JS: [esc] to close
Build status
Emoji reactions
Also Dialogs!
None
<details> <summary aria-haspopup=“dialog”>…</summary> <details-dialog> … </details-dialog> </details> <details-dialog>
<details-dialog> Focus management Tab trapping Accessibility enhancements Sorry <dialog>
<details> <summary aria-haspopup=“menu”>…</summary> <details-menu> … </details-menu> </details> <details-menu>
EXCITED? Let’s talk browser support —
Browser support Desktop 86% / Mobile 95% http://caniuse.com/#search=details
Polyfill javan/details-element-polyfill
CSS Helpers primer-utilities @ npm
<3 HTML
</details> GitHub @muan / Twitter @muanchiou Definitely the best element
in HTML 5.