UNPKG

19.8 kBHTMLView Raw
1<!DOCTYPE html>
2<html lang="en">
3 <head>
4 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
5 <meta name="viewport" content="width=device-width, initial-scale=1">
6 <meta http-equiv="X-UA-Compatible" content="IE=edge">
7 <meta name="msapplication-tap-highlight" content="no">
8 <meta name="description" content="Materialize is a modern responsive CSS framework based on Material Design by Google. ">
9 <title>Media - Materialize</title>
10 <!-- Favicons-->
11 <link rel="apple-touch-icon-precomposed" href="images/favicon/apple-touch-icon-152x152.png">
12 <meta name="msapplication-TileColor" content="#FFFFFF">
13 <meta name="msapplication-TileImage" content="images/favicon/mstile-144x144.png">
14 <link rel="icon" href="images/favicon/favicon-32x32.png" sizes="32x32">
15 <!-- Android 5 Chrome Color-->
16 <meta name="theme-color" content="#EE6E73">
17 <!-- CSS-->
18 <link href="css/prism.css" rel="stylesheet">
19 <link href="css/ghpages-materialize.css" type="text/css" rel="stylesheet" media="screen,projection">
20 <link href="http://fonts.googleapis.com/css?family=Inconsolata" rel="stylesheet" type="text/css">
21 <link href="http://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
22 <script>
23 window.liveSettings = {
24 api_key: "a0b49b34b93844c38eaee15690d86413",
25 picker: "bottom-right",
26 detectlang: true,
27 dynamic: true,
28 autocollect: true
29 };
30 </script>
31 <script src="//cdn.transifex.com/live.js"></script>
32 </head>
33 <body>
34 <header>
35 <nav class="top-nav">
36 <div class="container">
37 <div class="nav-wrapper"><a class="page-title">Media</a></div>
38 </div>
39 </nav>
40 <div class="container"><a href="#" data-activates="nav-mobile" class="button-collapse top-nav full hide-on-large-only"><i class="mdi-navigation-menu"></i></a></div>
41 <ul id="nav-mobile" class="side-nav fixed">
42 <li class="logo"><a id="logo-container" href="http://materializecss.com/" class="brand-logo">
43 <object id="front-page-logo" type="image/svg+xml" data="res/materialize.svg">Your browser does not support SVG</object></a></li>
44 <li class="search">
45 <div class="search-wrapper card">
46 <input id="search"><i class="material-icons">search</i>
47 <div class="search-results"></div>
48 </div>
49 </li>
50 <li class="bold"><a href="about.html" class="waves-effect waves-teal">About</a></li>
51 <li class="bold"><a href="getting-started.html" class="waves-effect waves-teal">Getting Started</a></li>
52 <li class="no-padding">
53 <ul class="collapsible collapsible-accordion">
54 <li class="bold"><a class="collapsible-header waves-effect waves-teal">CSS</a>
55 <div class="collapsible-body">
56 <ul>
57 <li><a href="color.html">Color</a></li>
58 <li><a href="grid.html">Grid</a></li>
59 <li><a href="helpers.html">Helpers</a></li>
60 <li><a href="media-css.html">Media</a></li>
61 <li><a href="sass.html">Sass</a></li>
62 <li><a href="shadow.html">Shadow</a></li>
63 <li><a href="table.html">Table</a></li>
64 <li><a href="typography.html">Typography</a></li>
65 </ul>
66 </div>
67 </li>
68 <li class="bold"><a class="collapsible-header waves-effect waves-teal">Components</a>
69 <div class="collapsible-body">
70 <ul>
71 <li><a href="badges.html">Badges</a></li>
72 <li><a href="buttons.html">Buttons</a></li>
73 <li><a href="breadcrumbs.html">Breadcrumbs</a></li>
74 <li><a href="cards.html">Cards</a></li>
75 <li><a href="chips.html">Chips</a></li>
76 <li><a href="collections.html">Collections</a></li>
77 <li><a href="footer.html">Footer</a></li>
78 <li><a href="forms.html">Forms</a></li>
79 <li><a href="icons.html">Icons</a></li>
80 <li><a href="navbar.html">Navbar</a></li>
81 <li><a href="pagination.html">Pagination</a></li>
82 <li><a href="preloader.html">Preloader</a></li>
83 </ul>
84 </div>
85 </li>
86 <li class="bold"><a class="collapsible-header active waves-effect waves-teal">JavaScript</a>
87 <div class="collapsible-body">
88 <ul>
89 <li><a href="collapsible.html">Collapsible</a></li>
90 <li><a href="dialogs.html">Dialogs</a></li>
91 <li><a href="dropdown.html">Dropdown</a></li>
92 <li class="active"><a href="media.html">Media</a></li>
93 <li><a href="modals.html">Modals</a></li>
94 <li><a href="parallax.html">Parallax</a></li>
95 <li><a href="pushpin.html">Pushpin</a></li>
96 <li><a href="scrollfire.html">ScrollFire</a></li>
97 <li><a href="scrollspy.html">Scrollspy</a></li>
98 <li><a href="side-nav.html">SideNav</a></li>
99 <li><a href="tabs.html">Tabs</a></li>
100 <li><a href="transitions.html">Transitions</a></li>
101 <li><a href="waves.html">Waves</a></li>
102 </ul>
103 </div>
104 </li>
105 </ul>
106 </li>
107 <li class="bold"><a href="http://materializecss.com/mobile.html" class="waves-effect waves-teal">Mobile</a></li>
108 <li class="bold"><a href="showcase.html" class="waves-effect waves-teal">Showcase</a></li>
109 </ul>
110 </header>
111 <main><div class="container">
112 <div class="row">
113 <div class="col s12 m9 l10">
114 <p class="caption">Media components include things that have to do with large media objects like Images, Video, Audio, etc.</p>
115
116 <div id="materialbox" class="scrollspy section">
117 <h2 class="header">Material Box</h2>
118 <p class="caption">Material box is a material design implementation of the Lightbox plugin. When a user clicks on an image that can be enlarged. Material box centers the image and enlarges it in a smooth, non-jarring manner. To dismiss the image, the user can either click on the image again, scroll away, or press the ESC key.</p>
119 <img class="materialboxed responsive-img" width="650" src="images/sample-1.jpg">
120
121 <p>Creating the above image with the effect is as simple as adding a <code class="language-markup">materialboxed</code> class to the image tag.</p>
122 <pre><code class="language-markup">
123 &lt;img class="materialboxed" width="650" src="images/sample-1.jpg">
124 </code></pre>
125
126
127 <h4>Initialization</h4>
128 <p>Materialbox is intialized automatically. However, if you add images dynamically, you will have to add this initialization code.</p>
129 <pre><code class="language-javascript">
130 $(document).ready(function(){
131 $('.materialboxed').materialbox();
132 });
133 </code></pre>
134
135 <h4>Captions</h4>
136 <p>It is very easy to add a short caption to your photo. Just add the caption as a <code class="language-markup">data-caption</code> attribute.</p>
137 <img class="materialboxed" data-caption="A picture of some deer and tons of trees" width="250" src="http://th01.deviantart.net/fs70/PRE/i/2013/126/1/e/nature_portrait_by_pw_fotografie-d63tx0n.jpg">
138 <pre><code class="language-markup">
139 &lt;img class="materialboxed" data-caption="A picture of some deer and tons of trees" width="250" src="http://th01.deviantart.net/fs70/PRE/i/2013/126/1/e/nature_portrait_by_pw_fotografie-d63tx0n.jpg">
140 </code></pre>
141 </div>
142
143 <br>
144
145
146 <!-- Slider Section -->
147 <div id="slider" class="scrollspy section">
148 <h3 class="header">Slider</h3>
149 <p class="caption">Our slider is a simple and elegant image carousel. You can also have captions that will be transitioned on their own depending on their alignment. You can also have indicators that show up on the bottom of the slider. </p>
150 <p>Note: This is also Hammer.js compatible! Try swiping with your finger to scroll through the slider.</p><br>
151
152 <div class="slider">
153 <ul class="slides">
154 <li>
155 <img src="http://lorempixel.com/580/250/nature/1"> <!-- random image -->
156 <div class="caption center-align">
157 <h3>This is our big Tagline!</h3>
158 <h5 class="light grey-text text-lighten-3">Here's our small slogan.</h5>
159 </div>
160 </li>
161 <li>
162 <img src="http://lorempixel.com/580/250/nature/2"> <!-- random image -->
163 <div class="caption left-align">
164 <h3>Left Aligned Caption</h3>
165 <h5 class="light grey-text text-lighten-3">Here's our small slogan.</h5>
166 </div>
167 </li>
168 <li>
169 <img src="http://lorempixel.com/580/250/nature/3"> <!-- random image -->
170 <div class="caption right-align">
171 <h3>Right Aligned Caption</h3>
172 <h5 class="light grey-text text-lighten-3">Here's our small slogan.</h5>
173 </div>
174 </li>
175 <li>
176 <img src="http://lorempixel.com/580/250/nature/4"> <!-- random image -->
177 <div class="caption center-align">
178 <h3>This is our big Tagline!</h3>
179 <h5 class="light grey-text text-lighten-3">Here's our small slogan.</h5>
180 </div>
181 </li>
182 </ul>
183 </div><br>
184
185 <pre><code class="language-markup">
186 &lt;div class="slider">
187 &lt;ul class="slides">
188 &lt;li>
189 &lt;img src="http://lorempixel.com/580/250/nature/1"> &lt;!-- random image -->
190 &lt;div class="caption center-align">
191 &lt;h3>This is our big Tagline!&lt;/h3>
192 &lt;h5 class="light grey-text text-lighten-3">Here's our small slogan.&lt;/h5>
193 &lt;/div>
194 &lt;/li>
195 &lt;li>
196 &lt;img src="http://lorempixel.com/580/250/nature/2"> &lt;!-- random image -->
197 &lt;div class="caption left-align">
198 &lt;h3>Left Aligned Caption&lt;/h3>
199 &lt;h5 class="light grey-text text-lighten-3">Here's our small slogan.&lt;/h5>
200 &lt;/div>
201 &lt;/li>
202 &lt;li>
203 &lt;img src="http://lorempixel.com/580/250/nature/3"> &lt;!-- random image -->
204 &lt;div class="caption right-align">
205 &lt;h3>Right Aligned Caption&lt;/h3>
206 &lt;h5 class="light grey-text text-lighten-3">Here's our small slogan.&lt;/h5>
207 &lt;/div>
208 &lt;/li>
209 &lt;li>
210 &lt;img src="http://lorempixel.com/580/250/nature/4"> &lt;!-- random image -->
211 &lt;div class="caption center-align">
212 &lt;h3>This is our big Tagline!&lt;/h3>
213 &lt;h5 class="light grey-text text-lighten-3">Here's our small slogan.&lt;/h5>
214 &lt;/div>
215 &lt;/li>
216 &lt;/ul>
217 &lt;/div>
218 </code></pre>
219
220 <br>
221 <h4>Fullscreen Slider</h4>
222 <p>You can easliy make this slider a fullscreen slider by adding the class <code class="language-markup">fullscreen</code> to the slider div. Here's a quick demo.</p>
223 <a href="fullscreen-slider-demo.html" target="_blank" class="btn-large waves-effect waves-light">Open Demo</a>
224
225 <br>
226 <h4>jQuery Initialization</h4>
227 <pre><code class="language-javascript">
228 $(document).ready(function(){
229 $('.slider').slider({full_width: true});
230 });
231 </code></pre>
232 <br>
233
234 <h4>jQuery Plugin Options</h4>
235 <table class="hoverable">
236 <thead>
237 <tr>
238 <th>Option Name</th>
239 <th>Description</th>
240 </tr>
241 </thead>
242
243 <tbody>
244 <tr>
245 <td>Indicators</td>
246 <td>Set to false to hide slide indicators. (Default: True)</td>
247 </tr>
248 <tr>
249 <td>Height</td>
250 <td>Set height of slider. (Default: 400)</td>
251 </tr>
252 <tr>
253 <td>Transition</td>
254 <td>Set the duration of the transition animation in ms. (Default: 500)</td>
255 </tr>
256 <tr>
257 <td>Interval</td>
258 <td>Set the duration between transitions in ms. (Default: 6000)</td>
259 </tr>
260 </tbody>
261 </table>
262 <br>
263
264 <h4>jQuery Plugin Methods</h4>
265 <p>We have methods to pause, start, move to next and move to previous slide.</p>
266 <pre><code class="language-javascript col s12">
267// Pause slider
268$('.slider').slider('pause');
269// Start slider
270$('.slider').slider('start');
271// Next slide
272$('.slider').slider('next');
273// Previous slide
274$('.slider').slider('prev');
275 </code></pre>
276 </div>
277
278 </div>
279
280
281 <!-- Table of Contents -->
282 <div class="col hide-on-small-only m3 l2">
283 <div class="toc-wrapper">
284 <div class="buysellads hide-on-small-only">
285 <!-- CarbonAds Zone Code -->
286 <script async type="text/javascript" src="//cdn.carbonads.com/carbon.js?zoneid=1673&serve=C6AILKT&placement=materializecss" id="_carbonads_js"></script>
287 </div>
288 <div style="height: 1px;">
289 <ul class="section table-of-contents">
290 <li><a href="#materialbox">Material Box</a></li>
291 <li><a href="#slider">Slider</a></li>
292 </ul>
293 </div>
294 </div>
295 </div>
296
297 </div>
298</div>
299
300
301 </main> <footer class="page-footer">
302 <div class="container">
303 <div class="row">
304 <div class="col l4 s12">
305 <h5 class="white-text">Help Materialize Grow</h5>
306 <p class="grey-text text-lighten-4">We are a team of college students working on this project like it's our full time job. Any amount would help support and continue development on this project and is greatly appreciated.</p>
307 <form id="paypal-donate" action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_top">
308<input type="hidden" name="cmd" value="_s-xclick">
309<input type="hidden" name="encrypted" value="-----BEGIN PKCS7-----MIIHLwYJKoZIhvcNAQcEoIIHIDCCBxwCAQExggEwMIIBLAIBADCBlDCBjjELMAkGA1UEBhMCVVMxCzAJBgNVBAgTAkNBMRYwFAYDVQQHEw1Nb3VudGFpbiBWaWV3MRQwEgYDVQQKEwtQYXlQYWwgSW5jLjETMBEGA1UECxQKbGl2ZV9jZXJ0czERMA8GA1UEAxQIbGl2ZV9hcGkxHDAaBgkqhkiG9w0BCQEWDXJlQHBheXBhbC5jb20CAQAwDQYJKoZIhvcNAQEBBQAEgYC2O5rnsmP26R+2wNew3Jc3rCzBzw8LpJh1TTRZyMIFMYv/voKC1TMEvxU0ct4gdsZ29zARE96gRsCPVtVpY1hGr0NivLXeiHyw3xoW9UfzjcI9g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wgBSWn3y7xm8XvVk/UtcKG+wQ1mSUa6GBlKSBkTCBjjELMAkGA1UEBhMCVVMxCzAJBgNVBAgTAkNBMRYwFAYDVQQHEw1Nb3VudGFpbiBWaWV3MRQwEgYDVQQKEwtQYXlQYWwgSW5jLjETMBEGA1UECxQKbGl2ZV9jZXJ0czERMA8GA1UEAxQIbGl2ZV9hcGkxHDAaBgkqhkiG9w0BCQEWDXJlQHBheXBhbC5jb22CAQAwDAYDVR0TBAUwAwEB/zANBgkqhkiG9w0BAQUFAAOBgQCBXzpWmoBa5e9fo6ujionW1hUhPkOBakTr3YCDjbYfvJEiv/2P+IobhOGJr85+XHhN0v4gUkEDI8r2/rNk1m0GA8HKddvTjyGw/XqXa+LSTlDYkqI8OwR8GEYj4efEtcRpRYBxV8KxAW93YDWzFGvruKnnLbDAF6VR5w/cCMn5hzGCAZowggGWAgEBMIGUMIGOMQswCQYDVQQGEwJVUzELMAkGA1UECBMCQ0ExFjAUBgNVBAcTDU1vdW50YWluIFZpZXcxFDASBgNVBAoTC1BheVBhbCBJbmMuMRMwEQYDVQQLFApsaXZlX2NlcnRzMREwDwYDVQQDFAhsaXZlX2FwaTEcMBoGCSqGSIb3DQEJARYNcmVAcGF5cGFsLmNvbQIBADAJBgUrDgMCGgUAoF0wGAYJKoZIhvcNAQkDMQsGCSqGSIb3DQEHATAcBgkqhkiG9w0BCQUxDxcNMTQxMjE1MDcwNTI3WjAjBgkqhkiG9w0BCQQxFgQUTOnEae05+jEbHsz0um3L3/Cl/zgwDQYJKoZIhvcNAQEBBQAEgYAGuieIpSk7XCxyo4RieZQ/SO0EHUYEW9B7KFJB9qZ1+yCKpUm7prwsGGOJAAdqKOw59I7qjLQI5cFJz/O8Ivb14TclAZiKTnOCB/wO1QHp+9s+hF00D6v0TDetLm0GLnk/7ljWvNq1pTyiMTLVg4yw1dAzQE1tC6bYTtLuDhLl0Q==-----END PKCS7-----
310">
311<button class="btn waves-effect waves-light red lighten-3" type="submit" name="action" alt="PayPal - The safer, easier way to pay online!">Donate Now
312</button>
313</form>
314
315 </div>
316 <div class="col l4 s12">
317 <h5 class="white-text">Join the Discussion</h5>
318 <p class="grey-text text-lighten-4">We have a Gitter chat room set up where you can talk directly with us. Come in and discuss new features, future goals, general problems or questions, or anything else you can think of.</p>
319 <a class="btn waves-effect waves-light red lighten-3" target="_blank" href="https://gitter.im/Dogfalo/materialize">Chat</a>
320 </div>
321 <div class="col l4 s12" style="overflow: hidden;">
322 <h5 class="white-text">Connect</h5>
323 <iframe src="http://ghbtns.com/github-btn.html?user=dogfalo&repo=materialize&type=watch&count=true&size=large" allowtransparency="true" frameborder="0" scrolling="0" width="170" height="30"></iframe>
324 <br>
325 <a href="https://twitter.com/MaterializeCSS" class="twitter-follow-button" data-show-count="true" data-size="large" data-dnt="true">Follow @MaterializeCSS</a>
326 <br>
327 <div class="g-follow" data-annotation="bubble" data-height="24" data-href="https://plus.google.com/108619793845925798422" data-rel="publisher"></div>
328 </div>
329 </div>
330 </div>
331 <div class="footer-copyright">
332 <div class="container">
333 © 2014-2015 Materialize, All rights reserved.
334 <a class="grey-text text-lighten-4 right" href="https://github.com/Dogfalo/materialize/blob/master/LICENSE">MIT License</a>
335 </div>
336 </div>
337 </footer>
338 <!-- Scripts-->
339 <script src="https://code.jquery.com/jquery-2.1.1.min.js"></script>
340 <script>if (!window.jQuery) { document.write('<script src="bin/jquery-2.1.1.min.js"><\/script>'); }
341 </script>
342 <script src="js/jquery.timeago.min.js"></script>
343 <script src="js/prism.js"></script>
344 <script src="jade/lunr.min.js"></script>
345 <script src="jade/search.js"></script>
346 <script src="bin/materialize.js"></script>
347 <script src="js/init.js"></script>
348 <!-- Twitter Button -->
349 <script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0],p=/^http:/.test(d.location)?'http':'https';if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src=p+'://platform.twitter.com/widgets.js';fjs.parentNode.insertBefore(js,fjs);}}(document, 'script', 'twitter-wjs');</script>
350
351 <!-- Google Plus Button-->
352 <script src="https://apis.google.com/js/platform.js" async defer></script>
353
354 <!-- Google Analytics -->
355 <script>
356 (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
357 (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
358 m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
359 })(window,document,'script','//www.google-analytics.com/analytics.js','ga');
360
361 ga('create', 'UA-56218128-1', 'auto');
362 ga('require', 'displayfeatures');
363 ga('send', 'pageview');
364 </script>
365 </body>
366</html>
\No newline at end of file