Changeset 22415 for trunk/wp-includes/media.php
- Timestamp:
- 11/07/2012 08:41:17 AM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/media.php
r22409 r22415 1297 1297 <script type="text/html" id="tmpl-media-modal"> 1298 1298 <div class="media-modal"> 1299 <h3 class="media-modal-title"> <%- title %></h3>1299 <h3 class="media-modal-title">{{ title }}</h3> 1300 1300 <a class="media-modal-close" href="" title="<?php esc_attr_e('Close'); ?>">×</a> 1301 1301 </div> … … 1320 1320 1321 1321 <script type="text/html" id="tmpl-attachment"> 1322 <div class="attachment-preview type- <%- type %> subtype-<%- subtype %> <%- orientation %>">1323 < % if ( uploading ) { %>1322 <div class="attachment-preview type-{{ type }} subtype-{{ subtype }} {{ orientation }}"> 1323 <# if ( uploading ) { #> 1324 1324 <div class="media-progress-bar"><div></div></div> 1325 < % } else if ( 'image' === type ) { %>1325 <# } else if ( 'image' === type ) { #> 1326 1326 <div class="thumbnail"> 1327 1327 <div class="centered"> 1328 <img src=" <%- url %>" draggable="false" />1328 <img src="{{ url }}" draggable="false" /> 1329 1329 </div> 1330 1330 </div> 1331 < % } else { %>1332 <img src=" <%- icon %>" class="icon" draggable="false" />1333 <div class="filename"> <%- filename %></div>1334 < % } %>1335 1336 < % if ( buttons.close ) { %>1331 <# } else { #> 1332 <img src="{{ icon }}" class="icon" draggable="false" /> 1333 <div class="filename">{{ filename }}</div> 1334 <# } #> 1335 1336 <# if ( buttons.close ) { #> 1337 1337 <a class="close button" href="#">×</a> 1338 < % } %>1338 <# } #> 1339 1339 </div> 1340 < % if ( describe ) { %>1341 < % if ( 'image' === type ) { %>1340 <# if ( describe ) { #> 1341 <# if ( 'image' === type ) { #> 1342 1342 <textarea class="describe" 1343 1343 placeholder="<?php esc_attr_e('Describe this image…'); ?>" 1344 > <%- caption %></textarea>1345 < % } else { %>1344 >{{ caption }}</textarea> 1345 <# } else { #> 1346 1346 <textarea class="describe" 1347 < % if ( 'video' === type ) { %>1347 <# if ( 'video' === type ) { #> 1348 1348 placeholder="<?php esc_attr_e('Describe this video…'); ?>" 1349 < % } else if ( 'audio' === type ) { %>1349 <# } else if ( 'audio' === type ) { #> 1350 1350 placeholder="<?php esc_attr_e('Describe this audio file…'); ?>" 1351 < % } else { %>1351 <# } else { #> 1352 1352 placeholder="<?php esc_attr_e('Describe this media file…'); ?>" 1353 < % } %>1354 > <%- title %></textarea>1355 < % } %>1356 < % } %>1353 <# } #> 1354 >{{ title }}</textarea> 1355 <# } #> 1356 <# } #> 1357 1357 </script> 1358 1358 1359 1359 <script type="text/html" id="tmpl-attachment-details"> 1360 1360 <h3><?php _e('Edit Attachment Details'); ?></h3> 1361 <div class="attachment-preview attachment-details-preview type- <%- type %> subtype-<%- subtype %> <%- orientation %>">1362 < % if ( uploading ) { %>1361 <div class="attachment-preview attachment-details-preview type-{{ type }} subtype-{{ subtype }} {{ orientation }}"> 1362 <# if ( uploading ) { #> 1363 1363 <div class="media-progress-bar"><div></div></div> 1364 < % } else if ( 'image' === type ) { %>1364 <# } else if ( 'image' === type ) { #> 1365 1365 <div class="thumbnail"> 1366 <img src=" <%- url %>" draggable="false" />1366 <img src="{{ url }}" draggable="false" /> 1367 1367 </div> 1368 < % } else { %>1368 <# } else { #> 1369 1369 <div class="icon-thumbnail"> 1370 <img src=" <%- icon %>" class="icon" draggable="false" />1371 <div class="filename"> <%- filename %></div>1370 <img src="{{ icon }}" class="icon" draggable="false" /> 1371 <div class="filename">{{ filename }}</div> 1372 1372 </div> 1373 < % } %>1373 <# } #> 1374 1374 </div> 1375 1375 1376 < % if ( 'image' === type ) { %>1376 <# if ( 'image' === type ) { #> 1377 1377 <textarea class="describe" 1378 1378 placeholder="<?php esc_attr_e('Describe this image…'); ?>" 1379 > <%- caption %></textarea>1380 < % } else { %>1379 >{{ caption }}</textarea> 1380 <# } else { #> 1381 1381 <textarea class="describe" 1382 < % if ( 'video' === type ) { %>1382 <# if ( 'video' === type ) { #> 1383 1383 placeholder="<?php esc_attr_e('Describe this video…'); ?>" 1384 < % } else if ( 'audio' === type ) { %>1384 <# } else if ( 'audio' === type ) { #> 1385 1385 placeholder="<?php esc_attr_e('Describe this audio file…'); ?>" 1386 < % } else { %>1386 <# } else { #> 1387 1387 placeholder="<?php esc_attr_e('Describe this media file…'); ?>" 1388 < % } %>1389 > <%- title %></textarea>1390 < % } %>1388 <# } #> 1389 >{{ title }}</textarea> 1390 <# } #> 1391 1391 </script> 1392 1392 … … 1394 1394 <div class="selection-info"> 1395 1395 <span class="count"></span> 1396 < % if ( clearable ) { %>1396 <# if ( clearable ) { #> 1397 1397 <a class="clear-selection" href="#"><?php _e('Clear'); ?></a> 1398 < % } %>1398 <# } #> 1399 1399 </div> 1400 1400 <div class="selection-view"></div> … … 1402 1402 1403 1403 <script type="text/html" id="tmpl-media-selection-preview"> 1404 <div class="selected-img selected-count- <%- count %>">1405 < % if ( thumbnail ) { %>1406 <img src=" <%- thumbnail %>" draggable="false" />1407 < % } %>1408 1409 <span class="count"> <%- count %></span>1404 <div class="selected-img selected-count-{{ count }}"> 1405 <# if ( thumbnail ) { #> 1406 <img src="{{ thumbnail }}" draggable="false" /> 1407 <# } #> 1408 1409 <span class="count">{{ count }}</span> 1410 1410 </div> 1411 < % if ( clearable ) { %>1411 <# if ( clearable ) { #> 1412 1412 <a class="clear-selection" href="#"><?php _e('Clear selection'); ?></a> 1413 < % } %>1413 <# } #> 1414 1414 </script> 1415 1415 … … 1459 1459 1460 1460 <select class="columns" name="columns" data-setting="columns"> 1461 <% _.times( 9, function( i ) { %> 1462 <option value="<%- i %>"><%- i %></option> 1463 <% }); %> 1461 <?php for( $i = 1; $i <= 9; $i++ ) : ?> 1462 <option value="<?php echo esc_attr( $i ); ?>"> 1463 <?php echo esc_html( $i ); ?> 1464 </option> 1465 <?php endfor; ?> 1464 1466 </select> 1465 1467 </script> … … 1467 1469 <script type="text/html" id="tmpl-editor-attachment"> 1468 1470 <div class="editor-attachment-preview"> 1469 < % if ( url ) { %>1470 <img src=" <%- url %>" width="<%- width %>" height="<%- height %>" draggable="false" />1471 < % } %>1472 1473 < % if ( uploading ) { %>1471 <# if ( url ) { #> 1472 <img src="{{ url }}" width="{{ width }}" height="{{ height }}" draggable="false" /> 1473 <# } #> 1474 1475 <# if ( uploading ) { #> 1474 1476 <div class="media-progress-bar"><div></div></div> 1475 < % } %>1477 <# } #> 1476 1478 <div class="overlay"> 1477 1479 <div class="button close">×</div> … … 1482 1484 1483 1485 <script type="text/html" id="tmpl-editor-gallery"> 1484 < % if ( url ) { %>1485 <img src=" <%- url %>" draggable="false" />1486 < % } %>1486 <# if ( url ) { #> 1487 <img src="{{ url }}" draggable="false" /> 1488 <# } #> 1487 1489 1488 1490 <div class="overlay"> … … 1493 1495 1494 1496 <script type="text/html" id="tmpl-attachments-css"> 1495 <style type="text/css" id=" <%- id %>-css">1496 # <%- id %>{1497 padding: 0 <%- gutter %>px;1497 <style type="text/css" id="{{ id }}-css"> 1498 #{{ id }} { 1499 padding: 0 {{ gutter }}px; 1498 1500 } 1499 1501 1500 # <%- id %>.attachment {1501 margin: <%- gutter %>px;1502 width: <%- edge %>px;1502 #{{ id }} .attachment { 1503 margin: {{ gutter }}px; 1504 width: {{ edge }}px; 1503 1505 } 1504 1506 1505 # <%- id %>.attachment-preview,1506 # <%- id %>.attachment-preview .thumbnail {1507 width: <%- edge %>px;1508 height: <%- edge %>px;1507 #{{ id }} .attachment-preview, 1508 #{{ id }} .attachment-preview .thumbnail { 1509 width: {{ edge }}px; 1510 height: {{ edge }}px; 1509 1511 } 1510 1512 1511 # <%- id %>.portrait .thumbnail img {1512 width: <%- edge %>px;1513 #{{ id }} .portrait .thumbnail img { 1514 width: {{ edge }}px; 1513 1515 height: auto; 1514 1516 } 1515 1517 1516 # <%- id %>.landscape .thumbnail img {1518 #{{ id }} .landscape .thumbnail img { 1517 1519 width: auto; 1518 height: <%- edge %>px;1520 height: {{ edge }}px; 1519 1521 } 1520 1522 </style>
Note: See TracChangeset
for help on using the changeset viewer.