Mathching markup to user profilelist (entities)

This commit is contained in:
sarven 2009-01-22 16:50:35 +00:00
parent e6211c4c22
commit 93925b8505
2 changed files with 18 additions and 16 deletions

View File

@ -66,7 +66,7 @@ class GroupList extends Widget
function show() function show()
{ {
$this->out->elementStart('ul', 'groups'); $this->out->elementStart('ul', 'profiles groups xoxo');
$cnt = 0; $cnt = 0;
@ -85,19 +85,19 @@ class GroupList extends Widget
function showGroup() function showGroup()
{ {
$this->out->elementStart('li', array('class' => 'group', $this->out->elementStart('li', array('class' => 'profile',
'id' => 'group-' . $this->group->id)); 'id' => 'group-' . $this->group->id));
$user = common_current_user(); $user = common_current_user();
$this->out->elementStart('div', array('id' => 'group_group', $this->out->elementStart('div', 'entity_profile vcard');
'class' => 'vcard'));
$logo = ($this->group->stream_logo) ? $logo = ($this->group->stream_logo) ?
$this->group->stream_logo : User_group::defaultLogo(AVATAR_STREAM_SIZE); $this->group->stream_logo : User_group::defaultLogo(AVATAR_STREAM_SIZE);
$this->out->elementStart('a', array('href' => $this->group->homeUrl(), $this->out->elementStart('a', array('href' => $this->group->homeUrl(),
'class' => 'url')); 'class' => 'url',
'rel' => 'group'));
$this->out->element('img', array('src' => $logo, $this->out->element('img', array('src' => $logo,
'class' => 'photo avatar', 'class' => 'photo avatar',
'width' => AVATAR_STREAM_SIZE, 'width' => AVATAR_STREAM_SIZE,
@ -105,24 +105,24 @@ class GroupList extends Widget
'alt' => 'alt' =>
($this->group->fullname) ? $this->group->fullname : ($this->group->fullname) ? $this->group->fullname :
$this->group->nickname)); $this->group->nickname));
$hasFN = ($this->group->fullname) ? 'nickname' : 'fn nickname'; $hasFN = ($this->group->fullname) ? 'nickname url uid' : 'fn org nickname url uid';
$this->out->elementStart('span', $hasFN); $this->out->elementStart('span', $hasFN);
$this->out->raw($this->highlight($this->group->nickname)); $this->out->raw($this->highlight($this->group->nickname));
$this->out->elementEnd('span'); $this->out->elementEnd('span');
$this->out->elementEnd('a'); $this->out->elementEnd('a');
if ($this->group->fullname) { if ($this->group->fullname) {
$this->out->elementStart('dl', 'group_fn'); $this->out->elementStart('dl', 'entity_fn');
$this->out->element('dt', null, 'Full name'); $this->out->element('dt', null, 'Full name');
$this->out->elementStart('dd'); $this->out->elementStart('dd');
$this->out->elementStart('span', 'fn'); $this->out->elementStart('span', 'fn org');
$this->out->raw($this->highlight($this->group->fullname)); $this->out->raw($this->highlight($this->group->fullname));
$this->out->elementEnd('span'); $this->out->elementEnd('span');
$this->out->elementEnd('dd'); $this->out->elementEnd('dd');
$this->out->elementEnd('dl'); $this->out->elementEnd('dl');
} }
if ($this->group->location) { if ($this->group->location) {
$this->out->elementStart('dl', 'group_location'); $this->out->elementStart('dl', 'entity_location');
$this->out->element('dt', null, _('Location')); $this->out->element('dt', null, _('Location'));
$this->out->elementStart('dd', 'location'); $this->out->elementStart('dd', 'location');
$this->out->raw($this->highlight($this->group->location)); $this->out->raw($this->highlight($this->group->location));
@ -130,7 +130,7 @@ class GroupList extends Widget
$this->out->elementEnd('dl'); $this->out->elementEnd('dl');
} }
if ($this->group->homepage) { if ($this->group->homepage) {
$this->out->elementStart('dl', 'group_url'); $this->out->elementStart('dl', 'entity_url');
$this->out->element('dt', null, _('URL')); $this->out->element('dt', null, _('URL'));
$this->out->elementStart('dd'); $this->out->elementStart('dd');
$this->out->elementStart('a', array('href' => $this->group->homepage, $this->out->elementStart('a', array('href' => $this->group->homepage,
@ -141,7 +141,7 @@ class GroupList extends Widget
$this->out->elementEnd('dl'); $this->out->elementEnd('dl');
} }
if ($this->group->description) { if ($this->group->description) {
$this->out->elementStart('dl', 'group_note'); $this->out->elementStart('dl', 'entity_note');
$this->out->element('dt', null, _('Note')); $this->out->element('dt', null, _('Note'));
$this->out->elementStart('dd', 'note'); $this->out->elementStart('dd', 'note');
$this->out->raw($this->highlight($this->group->description)); $this->out->raw($this->highlight($this->group->description));

View File

@ -655,10 +655,15 @@ margin-bottom:0;
min-height:60px; min-height:60px;
} }
.profile .form_group_join,
.profile .form_group_leave,
.profile .form_user_subscribe, .profile .form_user_subscribe,
.profile .form_user_unsubscribe { .profile .form_user_unsubscribe {
float:right; float:right;
} }
.profile .form_group_join legend,
.profile .form_group_leave legend,
.profile .form_user_subscribe legend, .profile .form_user_subscribe legend,
.profile .form_user_unsubscribe legend { .profile .form_user_unsubscribe legend {
display:none; display:none;
@ -678,7 +683,8 @@ display:inline;
float:none; float:none;
} }
.profile .entity_profile .entity_note, .profile .entity_profile .entity_note,
.profile .entity_profile .entity_url { .profile .entity_profile .entity_url,
.profile .entity_profile .entity_tags {
margin-left:59px; margin-left:59px;
clear:none; clear:none;
display:block; display:block;
@ -1195,7 +1201,3 @@ text-align:center;
#testimonials { #testimonials {
clear:both; clear:both;
} }
.entity_tags dt {
display:block;
}