Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(27)

Unified Diff: third_party/polymer/v0_8/components-chromium/iron-collapse/README.md

Issue 1162563004: Upgrade to 1.0 and switch clients to dom-repeat where needed. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix a layout import and remove the gzipped webanimation in reproduce.sh Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/polymer/v0_8/components-chromium/iron-collapse/README.md
diff --git a/third_party/polymer/v0_8/components-chromium/iron-collapse/README.md b/third_party/polymer/v0_8/components-chromium/iron-collapse/README.md
index 301c473fa64775af4146c9add633fcdaab97efb8..13a013baa459ff1465a815639f2999e4d9cfbf7b 100644
--- a/third_party/polymer/v0_8/components-chromium/iron-collapse/README.md
+++ b/third_party/polymer/v0_8/components-chromium/iron-collapse/README.md
@@ -1 +1,37 @@
# iron-collapse
+
+`iron-collapse` creates a collapsible block of content. By default, the content
+will be collapsed. Use `opened` or `toggle()` to show/hide the content.
+
+```html
+<button on-click="{{toggle}}">toggle collapse</button>
+
+<iron-collapse id="collapse">
+ <div>Content goes here...</div>
+</iron-collapse>
+```
+
+```javascript
+toggle: function() {
+ this.$.collapse.toggle();
+}
+```
+
+`iron-collapse` adjusts the height/width of the collapsible element to show/hide
+the content. So avoid putting padding/margin/border on the collapsible directly,
+and instead put a div inside and style that.
+
+```html
+<style>
+ .collapse-content {
+ padding: 15px;
+ border: 1px solid #dedede;
+ }
+</style>
+
+<iron-collapse>
+ <div class="collapse-content">
+ <div>Content goes here...</div>
+ </div>
+</iron-collapse>
+```

Powered by Google App Engine
This is Rietveld 408576698