Fixes for testbubble

This commit is contained in:
Fabio Comuni 2011-09-26 11:48:02 +02:00
parent 5792b3d358
commit 968e7bb3b1
5 changed files with 101 additions and 49 deletions

View file

@ -437,11 +437,12 @@ function conversation(&$a, $items, $mode, $update) {
$star = false; $star = false;
if ($profile_owner == local_user() && $toplevelpost) { if ($profile_owner == local_user() && $toplevelpost) {
$isstarred = (($item['starred']) ? "starred" : "hidden"); $isstarred = (($item['starred']) ? "starred" : "unstarred");
$star = array( $star = array(
'do' => t("add star"), 'do' => t("add star"),
'undo' => t("remove star"), 'undo' => t("remove star"),
'toggle' => t("toggle star status"),
'classdo' => (($item['starred']) ? "hidden" : ""), 'classdo' => (($item['starred']) ? "hidden" : ""),
'classundo' => (($item['starred']) ? "" : "hidden"), 'classundo' => (($item['starred']) ? "" : "hidden"),
'starred' => t('starred'), 'starred' => t('starred'),

View file

@ -267,12 +267,12 @@
$.get('starred/' + ident, function(data) { $.get('starred/' + ident, function(data) {
if(data.match(/1/)) { if(data.match(/1/)) {
$('#starred-' + ident).addClass('starred'); $('#starred-' + ident).addClass('starred');
$('#starred-' + ident).removeClass('hidden'); $('#starred-' + ident).removeClass('unstarred');
$('#star-' + ident).addClass('hidden'); $('#star-' + ident).addClass('hidden');
$('#unstar-' + ident).removeClass('hidden'); $('#unstar-' + ident).removeClass('hidden');
} }
else { else {
$('#starred-' + ident).addClass('hidden'); $('#starred-' + ident).addClass('unstarred');
$('#starred-' + ident).removeClass('starred'); $('#starred-' + ident).removeClass('starred');
$('#star-' + ident).removeClass('hidden'); $('#star-' + ident).removeClass('hidden');
$('#unstar-' + ident).addClass('hidden'); $('#unstar-' + ident).addClass('hidden');

View file

@ -1,3 +1,4 @@
<nav>
$langselector $langselector
<span id="banner">$banner</span> <span id="banner">$banner</span>
@ -50,5 +51,5 @@ $langselector
{{ if $nav.apps }}<a id="nav-apps-link" class="nav-link $nav.apps.2" href="$nav.apps.0" title="$nav.apps.1">$nav.apps.1</a>{{ endif }} {{ if $nav.apps }}<a id="nav-apps-link" class="nav-link $nav.apps.2" href="$nav.apps.0" title="$nav.apps.1">$nav.apps.1</a>{{ endif }}
</nav>

View file

@ -0,0 +1,45 @@
<div class="vcard">
<div class="fn label">$profile.name</div>
{{ if $pdesc }}<div class="title">$profile.pdesc</div>{{ endif }}
<div id="profile-photo-wrapper"><img class="photo" width="175" height="175" src="$profile.photo" alt="$profile.name"></div>
{{ if $location }}
<dl class="location"><dt class="location-label">$location</dt>
<dd class="adr">
{{ if $profile.address }}<div class="street-address">$profile.address</div>{{ endif }}
<span class="city-state-zip">
<span class="locality">$profile.locality</span>{{ if $profile.locality }}, {{ endif }}
<span class="region">$profile.region</span>
<span class="postal-code">$profile.postal-code</span>
</span>
{{ if $profile.country-name }}<span class="country-name">$profile.country-name</span>{{ endif }}
</dd>
</dl>
{{ endif }}
{{ if $gender }}<dl class="mf"><dt class="gender-label">$gender</dt> <dd class="x-gender">$profile.gender</dd></dl>{{ endif }}
{{ if $profile.pubkey }}<div class="key" style="display:none;">$profile.pubkey</div>{{ endif }}
{{ if $marital }}<dl class="marital"><dt class="marital-label"><span class="heart">&hearts;</span>$marital</dt><dd class="marital-text">$profile.marital</dd></dl>{{ endif }}
{{ if $homepage }}<dl class="homepage"><dt class="homepage-label">$homepage</dt><dd class="homepage-url"><a href="$profile.homepage" target="external-link">$profile.homepage</a></dd></dl>{{ endif }}
{{ inc diaspora_vcard.tpl }}{{ endinc }}
<div id="profile-extra-links">
<ul>
{{ if $connect }}
<li><a id="dfrn-request-link" href="dfrn_request/$profile.nickname">$connect</a></li>
{{ endif }}
</ul>
</div>
</div>
$contact_block

View file

@ -27,9 +27,14 @@
<div class="wall-item-tools" id="wall-item-tools-$id"> <div class="wall-item-tools" id="wall-item-tools-$id">
$vote $vote
$plink {{ if $plink }}
<div class="wall-item-links-wrapper"><a href="$plink.href" title="$plink.title" target="external-link" class="icon remote-link"></a></div>
{{ endif }}
$edpost $edpost
$star
{{ if $star }}
<a href="#" id="starred-$id" onclick="dostar($id); return false;" class="star-item icon $isstarred" title="$star.toggle"></a>
{{ endif }}
$drop $drop
</div> </div>