aboutsummaryrefslogtreecommitdiff
path: root/mod/profile/views
diff options
context:
space:
mode:
authorpete <pete@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-03-11 13:53:36 +0000
committerpete <pete@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-03-11 13:53:36 +0000
commite1cf670acfd8d786aec086d1bd5bb2ff96cd5870 (patch)
tree43958ce51406ef64c443bde81d4e1eb39568d9b5 /mod/profile/views
parenta8e680230b2ca66cd1d95aaac228ed0c3a0d77ad (diff)
downloadelgg-e1cf670acfd8d786aec086d1bd5bb2ff96cd5870.tar.gz
elgg-e1cf670acfd8d786aec086d1bd5bb2ff96cd5870.tar.bz2
Updated avatar user menu to generate an ordered list, reinstated the add/remove friend link, & cleaned up css.
git-svn-id: http://code.elgg.org/elgg/trunk@5361 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/profile/views')
-rw-r--r--mod/profile/views/default/profile/css.php37
-rw-r--r--mod/profile/views/default/profile/hoverover.php6
-rw-r--r--mod/profile/views/default/profile/icon.php8
-rw-r--r--mod/profile/views/default/profile/menu/actions.php6
-rw-r--r--mod/profile/views/default/profile/menu/adminwrapper.php2
-rw-r--r--mod/profile/views/default/profile/menu/links.php16
-rw-r--r--mod/profile/views/default/profile/menu/linksownpage.php12
7 files changed, 40 insertions, 47 deletions
diff --git a/mod/profile/views/default/profile/css.php b/mod/profile/views/default/profile/css.php
index dea780ceb..cde028f12 100644
--- a/mod/profile/views/default/profile/css.php
+++ b/mod/profile/views/default/profile/css.php
@@ -349,7 +349,7 @@ p.visit_twitter a {
height:15px;
}
/* user avatar submenu options */
-.usericon div.sub_menu {
+.usericon .sub_menu {
display:none;
position:absolute;
padding:0;
@@ -367,44 +367,37 @@ p.visit_twitter a {
div.usericon a.icon img {
z-index:10;
}
-.usericon div.sub_menu a:link,
-.usericon div.sub_menu a:visited,
-.usericon div.sub_menu a:hover {
+.usericon .sub_menu a:link,
+.usericon .sub_menu a:visited,
+.usericon .sub_menu a:hover {
display:block;
}
-.usericon div.sub_menu a:hover {
+.usericon .sub_menu a:hover {
background:#cccccc;
text-decoration:none;
}
-.usericon div.sub_menu h3 {
+.usericon .sub_menu h3 {
font-size:1.3em;
line-height: 1.1em;
padding:0;
+ margin:0;
border-bottom:solid 1px #dddddd;
color: #4690d6;
- margin:0 !important;
-}
-.usericon div.sub_menu h3 a {
- padding:3px 3px 3px 6px !important;
}
-.usericon div.sub_menu p {
- margin:0 !important;
- padding:0 !important;
- height:auto !important;
- line-height:1.2em !important;
- font-size:12px !important;
+.usericon .sub_menu h3 a {
+ padding:3px 3px 3px 8px;
}
-.usericon div.sub_menu p a {
- padding:3px 3px 3px 6px !important;
+.usericon .sub_menu a {
+ padding:2px 3px 2px 8px;
}
/* admin menu options in avatar submenu */
.user_menu_admin {
border-top:solid 1px #dddddd;
}
-.user_menu_admin a {
+.usericon .sub_menu li.user_menu_admin a {
color:red;
}
-.user_menu_admin a:hover {
- color:white !important;
- background:red !important;
+.usericon .sub_menu li.user_menu_admin a:hover {
+ color:white;
+ background:red;
}
diff --git a/mod/profile/views/default/profile/hoverover.php b/mod/profile/views/default/profile/hoverover.php
index 571585311..5250377a1 100644
--- a/mod/profile/views/default/profile/hoverover.php
+++ b/mod/profile/views/default/profile/hoverover.php
@@ -11,9 +11,9 @@
* @uses $vars['entity'] The user entity. If none specified, the current user is assumed.
*/
?>
-<p class="user_menu_name">
- <b><?php echo $vars['entity']->name; ?></b>
-</p>
+<li class="user_menu_name">
+ <?php echo $vars['entity']->name; ?>
+</li>
<?php
echo elgg_view('profile/hoverover/actions', $vars);
echo elgg_view('profile/hoverover/links', $vars);
diff --git a/mod/profile/views/default/profile/icon.php b/mod/profile/views/default/profile/icon.php
index 59b16cdac..83015766a 100644
--- a/mod/profile/views/default/profile/icon.php
+++ b/mod/profile/views/default/profile/icon.php
@@ -54,12 +54,11 @@ if ($vars['entity'] instanceof ElggUser) {
<div class="sub_menu">
<h3><a href="<?php echo $vars['entity']->getURL(); ?>"><?php echo $vars['entity']->name; ?></a></h3>
<?php
+ echo "<ul class='sub_menu_list'>";
if (isloggedin()) {
$actions = elgg_view('profile/menu/actions',$vars);
if (!empty($actions)) {
-
- echo "<div class=\"item_line\">{$actions}</div>";
-
+ echo "<li class='user_menu_addremovefriend'>{$actions}</li>";
}
if ($vars['entity']->getGUID() == $vars['user']->getGUID()) {
echo elgg_view('profile/menu/linksownpage',$vars);
@@ -69,11 +68,12 @@ if ($vars['entity'] instanceof ElggUser) {
} else {
echo elgg_view('profile/menu/links',$vars);
}
+ echo "</ul>";
?>
</div>
<?php
if ((isadminloggedin()) || (!$vars['entity']->isBanned())) {
- ?><a href="<?php echo $vars['entity']->getURL(); ?>" class="icon" ><?php
+ ?><a href="<?php echo $vars['entity']->getURL(); ?>" class="icon" ><?php
}
}
diff --git a/mod/profile/views/default/profile/menu/actions.php b/mod/profile/views/default/profile/menu/actions.php
index 4ce7c89b6..f200ec379 100644
--- a/mod/profile/views/default/profile/menu/actions.php
+++ b/mod/profile/views/default/profile/menu/actions.php
@@ -16,16 +16,16 @@ if (isloggedin()) {
$ts = time();
$token = generate_action_token($ts);
if ($vars['entity']->isFriend()) {
- echo elgg_view('output/confirm_link', array(
+ echo elgg_view('output/confirmlink', array(
'href' => "{$vars['url']}action/friends/remove?friend={$vars['entity']->getGUID()}",
'text' => elgg_echo('friend:remove'),
'class' => 'user_menu_removefriend'
));
} else {
- echo elgg_view('output/confirm_link', array(
+ echo elgg_view('output/confirmlink', array(
'href' => "{$vars['url']}action/friends/add?friend={$vars['entity']->getGUID()}",
'text' => elgg_echo('friend:add'),
- 'class' => 'user_menu_removefriend'
+ 'class' => 'user_menu_addfriend'
));
}
}
diff --git a/mod/profile/views/default/profile/menu/adminwrapper.php b/mod/profile/views/default/profile/menu/adminwrapper.php
index b60eec462..eec5a6d3f 100644
--- a/mod/profile/views/default/profile/menu/adminwrapper.php
+++ b/mod/profile/views/default/profile/menu/adminwrapper.php
@@ -13,5 +13,5 @@
$adminlinks = elgg_view('profile/menu/adminlinks', $vars);
if (!empty($adminlinks)) {
- echo "<p class=\"user_menu_admin\">{$adminlinks}</p>";
+ echo "<li class='user_menu_admin'>{$adminlinks}</li>";
} \ No newline at end of file
diff --git a/mod/profile/views/default/profile/menu/links.php b/mod/profile/views/default/profile/menu/links.php
index ce82df10a..fd04e2e99 100644
--- a/mod/profile/views/default/profile/menu/links.php
+++ b/mod/profile/views/default/profile/menu/links.php
@@ -12,21 +12,21 @@
*/
?>
-<p class="user_menu_profile">
+<li class="user_menu_profile">
<a href="<?php echo $vars['entity']->getURL(); ?>"><?php echo elgg_echo("profile"); ?></a>
-</p>
+</li>
<?php
if ($vars['entity']->canEdit()){
?>
- <p class="user_menu_profile">
+ <li class="user_menu_profile">
<a href="<?php echo $vars['url']?>pg/profile/<?php echo $vars['entity']->username; ?>/edit/icon"><?php echo elgg_echo("profile:editicon"); ?></a>
- </p>
+ </li>
<?php
}
?>
-<p class="user_menu_friends">
+<li class="user_menu_friends">
<a href="<?php echo $vars['url']; ?>pg/friends/<?php echo $vars['entity']->username; ?>/"><?php echo elgg_echo("friends"); ?></a>
-</p>
-<p class="user_menu_friends_of">
+</li>
+<li class="user_menu_friends_of">
<a href="<?php echo $vars['url']; ?>pg/friendsof/<?php echo $vars['entity']->username; ?>/"><?php echo elgg_echo("friends:of"); ?></a>
-</p>
+</li>
diff --git a/mod/profile/views/default/profile/menu/linksownpage.php b/mod/profile/views/default/profile/menu/linksownpage.php
index 58eb3e1a0..2d41c6c31 100644
--- a/mod/profile/views/default/profile/menu/linksownpage.php
+++ b/mod/profile/views/default/profile/menu/linksownpage.php
@@ -14,16 +14,16 @@
<?php
if ($vars['entity']->canEdit()){
?>
- <p class="user_menu_profile">
+ <li class="user_menu_profile">
<a href="<?php echo $vars['url']?>pg/profile/<?php echo $vars['entity']->username; ?>/edit/icon"><?php echo elgg_echo("profile:editicon"); ?></a>
- </p>
+ </li>
<?php
}
?>
-<p class="user_menu_friends">
+<li class="user_menu_friends">
<a href="<?php echo $vars['url']; ?>pg/friends/<?php echo $vars['entity']->username; ?>/"><?php echo elgg_echo("friends"); ?></a>
-</p>
-<p class="user_menu_friends_of">
+</li>
+<li class="user_menu_friends_of">
<a href="<?php echo $vars['url']; ?>pg/friendsof/<?php echo $vars['entity']->username; ?>/"><?php echo elgg_echo("friends:of"); ?></a>
-</p>
+</li>