2011-01-24 21:21:09 +00:00
|
|
|
/* $This file is distributed under the terms of the license in /doc/license.txt$ */
|
|
|
|
|
|
|
|
$(document).ready(function(){
|
|
|
|
|
|
|
|
// "more"/"less" HTML truncator for showing more or less content in data property core:overview
|
2011-01-26 22:17:19 +00:00
|
|
|
$('.overview-value').truncate({max_length: 500});
|
2011-01-24 21:21:09 +00:00
|
|
|
|
2011-03-14 19:20:33 +00:00
|
|
|
// Change background color button when verbose mode is off
|
2011-03-22 03:30:45 +00:00
|
|
|
$('a#verbosePropertySwitch:contains("Turn off")').addClass('verbose-off');
|
2011-04-11 15:47:44 +00:00
|
|
|
|
2011-07-05 19:19:10 +00:00
|
|
|
// This function creates and styles the "qTip" tooltip that displays the resource uri when the user clicks the uri icon.
|
2011-04-11 15:47:44 +00:00
|
|
|
$('#uriIcon').each(function()
|
|
|
|
{
|
|
|
|
$(this).qtip(
|
|
|
|
{
|
|
|
|
content: {
|
|
|
|
title: {
|
|
|
|
text: 'URI',
|
|
|
|
},
|
|
|
|
text: '<br /><span id="uri-text">' + $("#uriIcon").attr("title") + '</span><br /><br />'
|
|
|
|
},
|
|
|
|
position: {
|
|
|
|
corner: {
|
|
|
|
target: 'leftBottom',
|
|
|
|
tooltip: 'bottomLeft'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
show: {
|
|
|
|
when: {event: 'click'}
|
|
|
|
},
|
|
|
|
hide: {
|
|
|
|
fixed: true // Make it fixed so it can be hovered over
|
|
|
|
},
|
|
|
|
style: {
|
|
|
|
title: {'backgroundColor': '#2485AE', 'color': 'white', 'fontFamily': '"Lucida Sans Unicode","Lucida Grande", Geneva, helvetica, sans-serif'},
|
|
|
|
padding: '6px 6px', // Give it some extra padding
|
|
|
|
width: 380,
|
|
|
|
textAlign: 'center',
|
|
|
|
backgroundColor: '#f1f2ee'
|
|
|
|
}
|
|
|
|
});
|
|
|
|
});
|
|
|
|
|
2011-06-24 09:50:49 +00:00
|
|
|
// Reveal vCard QR code when QR icon is clicked
|
|
|
|
$('#qrIcon, .qrCloseLink').click(function() {
|
2011-06-28 18:21:14 +00:00
|
|
|
$('#qrCodeImage').toggleClass('hidden');
|
2011-06-24 09:50:49 +00:00
|
|
|
return false;
|
|
|
|
});
|
2011-01-24 21:21:09 +00:00
|
|
|
});
|