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

Unified Diff: polymer_1.2.3/bower_components/iron-image/README.md

Issue 1581713003: [third_party] add polymer 1.2.3 (Closed) Base URL: https://chromium.googlesource.com/infra/third_party/npm_modules.git@master
Patch Set: 1.2.3 Created 4 years, 11 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: polymer_1.2.3/bower_components/iron-image/README.md
diff --git a/polymer_1.2.3/bower_components/iron-image/README.md b/polymer_1.2.3/bower_components/iron-image/README.md
new file mode 100644
index 0000000000000000000000000000000000000000..6a7f9bb9bc5cdc2b4e072fa67a26b295ff3f5642
--- /dev/null
+++ b/polymer_1.2.3/bower_components/iron-image/README.md
@@ -0,0 +1,72 @@
+
+<!---
+
+This README is automatically generated from the comments in these files:
+iron-image.html
+
+Edit those files, and our readme bot will duplicate them over here!
+Edit this file, and the bot will squash your changes :)
+
+-->
+
+[![Build Status](https://travis-ci.org/PolymerElements/iron-image.svg?branch=master)](https://travis-ci.org/PolymerElements/iron-image)
+
+_[Demo and API Docs](https://elements.polymer-project.org/elements/iron-image)_
+
+
+##&lt;iron-image&gt;
+
+
+`iron-image` is an element for displaying an image that provides useful sizing and
+preloading options not found on the standard `<img>` tag.
+
+The `sizing` option allows the image to be either cropped (`cover`) or
+letterboxed (`contain`) to fill a fixed user-size placed on the element.
+
+The `preload` option prevents the browser from rendering the image until the
+image is fully loaded. In the interim, either the element's CSS `background-color`
+can be be used as the placeholder, or the `placeholder` property can be
+set to a URL (preferably a data-URI, for instant rendering) for an
+placeholder image.
+
+The `fade` option (only valid when `preload` is set) will cause the placeholder
+image/color to be faded out once the image is rendered.
+
+Examples:
+
+ Basically identical to &lt;img src="..."&gt; tag:
+
+ <iron-image src="http://lorempixel.com/400/400"></iron-image>
+
+ Will letterbox the image to fit:
+
+ <iron-image style="width:400px; height:400px;" sizing="contain"
+ src="http://lorempixel.com/600/400"></iron-image>
+
+ Will crop the image to fit:
+
+ <iron-image style="width:400px; height:400px;" sizing="cover"
+ src="http://lorempixel.com/600/400"></iron-image>
+
+ Will show light-gray background until the image loads:
+
+ <iron-image style="width:400px; height:400px; background-color: lightgray;"
+ sizing="cover" preload src="http://lorempixel.com/600/400"></iron-image>
+
+ Will show a base-64 encoded placeholder image until the image loads:
+
+ <iron-image style="width:400px; height:400px;" placeholder="data:image/gif;base64,..."
+ sizing="cover" preload src="http://lorempixel.com/600/400"></iron-image>
+
+ Will fade the light-gray background out once the image is loaded:
+
+ <iron-image style="width:400px; height:400px; background-color: lightgray;"
+ sizing="cover" preload fade src="http://lorempixel.com/600/400"></iron-image>
+
+Custom property | Description | Default
+----------------|-------------|----------
+`--iron-image-placeholder` | Mixin applied to #placeholder | `{}`
+`--iron-image-width` | Sets the width of the wrapped image | `auto`
+`--iron-image-height` | Sets the height of the wrapped image | `auto`
+
+
« no previous file with comments | « polymer_1.2.3/bower_components/iron-image/CONTRIBUTING.md ('k') | polymer_1.2.3/bower_components/iron-image/bower.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698