kopia lustrzana https://github.com/wagtail/wagtail
Add a title attribute to the image displayed in an ImageChooserBlock.
rodzic
5ddba47cc3
commit
265d4baaf2
|
@ -10,6 +10,7 @@ Changelog
|
|||
* EmbedBlock now validates against recognised embed providers on save (Bertrand Bordage)
|
||||
* Made cache control headers on Wagtail admin consistent with Django admin (Tomasz Knapik)
|
||||
* Notification emails now include an "Auto-Submitted: auto-generated" header (Dan Braghis)
|
||||
* Image chooser panels now show alt text as title (Samir Shah)
|
||||
* Fix: Respect next param on login (Loic Teixeira)
|
||||
* Fix: InlinePanel now handles relations that specify a related_query_name (Aram Dulyan)
|
||||
* Fix: before_delete_page / after_delete_page hooks now run within the same database transaction as the page deletion (Tomasz Knapik)
|
||||
|
|
|
@ -27,6 +27,7 @@ Other features
|
|||
* EmbedBlock now validates against recognised embed providers on save (Bertrand Bordage)
|
||||
* Made cache control headers on Wagtail admin consistent with Django admin (Tomasz Knapik)
|
||||
* Notification emails now include an "Auto-Submitted: auto-generated" header (Dan Braghis)
|
||||
* Image chooser panels now show alt text as title (Samir Shah)
|
||||
|
||||
|
||||
Bug fixes
|
||||
|
|
|
@ -15,7 +15,8 @@ function createImageChooser(id) {
|
|||
src: imageData.preview.url,
|
||||
width: imageData.preview.width,
|
||||
height: imageData.preview.height,
|
||||
alt: imageData.title
|
||||
alt: imageData.title,
|
||||
title: imageData.title
|
||||
});
|
||||
chooserElement.removeClass('blank');
|
||||
editLink.attr('href', imageData.edit_link);
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
{% block chosen_state_view %}
|
||||
<div class="preview-image">
|
||||
{% if image %}
|
||||
{% image image max-165x165 class="show-transparency" %}
|
||||
{% image image max-165x165 class="show-transparency" title=image.title %}
|
||||
{% else %}
|
||||
<img>
|
||||
{% endif %}
|
||||
|
|
Ładowanie…
Reference in New Issue