<li id="<%= id %>">

<div class="ui-grid-b">

    <div class="ui-block-a saved-records-list-synced-<%= annotation.isSynced %>"></div>
    <div class="ui-block-b saved-records-view">
        <a href="#" class="ellipsis"><%= annotation.record.name %></a>
    </div>
    <div class="ui-block-c">
        <a href="#" class="saved-records-delete" data-role="button" data-icon="delete" data-iconpos="notext" data-theme="b"></a>
    </div>

    <div class="record-extra">

        <% _.each(fields, function(field) { %>

        <%type = records.typeFromId(field.id)%>

        <% if (field.label === "Description") { %>
            <p class="ellipsis"><%=field.val%></p>
        <%}%>

        <% if (type === "image") { %>
            <img class="saved-records-view" src="<%=field.val%>" width="100%"/>
        <%}%>

        <% if (type === "audio") { %>
        <p>Audio Recording</p>
        <img id="audio-icon" src="css/images/audio.png" width="100%"/>
        <%}%>

        <% }); %>


    </div>


</div>
</li>

<li id="<%= id %>">

<div class="ui-grid-b">

    <div class="ui-block-a saved-records-list-synced-<%= annotation.isSynced %>"></div>
    <div class="ui-block-b saved-records-view">
        <a href="#" class="ellipsis"><%= annotation.record.name %></a>
    </div>
    <div class="ui-block-c">
        <a href="#" class="saved-records-delete" data-role="button" data-icon="delete" data-iconpos="notext" data-theme="b"></a>
    </div>

    <%if (layout === 'records-grid') { %>
    <div class="record-extra">

        <% _.each(fields, function(field) { %>

        <%type = records.typeFromId(field.id)%>

        <% if (field.label === "Description") { %>
            <p class="ellipsis"><%=field.val%></p>
        <%}%>

        <% if (type === "image") { %>
            <img class="saved-records-view" src="<%=field.val%>" width="100%"/>
        <%}%>

        <% if (type === "audio") { %>
        <p>Audio Recording</p>
        <img id="audio-icon" src="css/images/audio.png" width="100%"/>
        <%}%>

        <% }); %>


    </div>
    <%}%>

</div>
</li>

Check the layout before including images and sound in the DOM
Check the layout before including images and sound in the DOM

Issue edina/fieldtrip-gb#141
