From 0df80d30e776ea9ecd149da61c96932a39786386 Mon Sep 17 00:00:00 2001 From: Toby Zerner Date: Fri, 17 Mar 2023 09:22:41 +1030 Subject: [PATCH] feat: add Disclosure and Accordion elements --- index.html | 44 ++++++++++++++++- src/accordion/README.md | 45 ++++++++++++++++++ src/accordion/accordion.ts | 26 ++++++++++ src/disclosure/README.md | 57 ++++++++++++++++++++++ src/disclosure/disclosure.ts | 92 ++++++++++++++++++++++++++++++++++++ src/index.ts | 2 + 6 files changed, 265 insertions(+), 1 deletion(-) create mode 100644 src/accordion/README.md create mode 100644 src/accordion/accordion.ts create mode 100644 src/disclosure/README.md create mode 100644 src/disclosure/disclosure.ts diff --git a/index.html b/index.html index ef7c81b..0cb4b3a 100644 --- a/index.html +++ b/index.html @@ -203,10 +203,29 @@ } } - ui-toolbar { + ui-toolbar, + ui-accordion { display: block; border: 2px solid #ccc; padding: 10px; + margin-top: 10px; + } + + ui-accordion h5 { + margin: 0; + } + + ui-accordion button { + width: 100%; + } + + .panel.enter-active { + transition: opacity 0.2s, transform 0.2s; + } + + .panel.enter-from { + opacity: 0; + transform: translateY(-10px); } @@ -291,6 +310,25 @@

Your dialog title

+ + +
+
+

Section A content

+

Section A content

+

Section A content

+
+
+ +
+
+

Section B content

+

Section B content

+

Section B content

+
+
+
+