Merge branch 'pull'

This commit is contained in:
friendica 2012-03-05 13:38:06 -08:00
commit 0d9c2ca06f
5 changed files with 67 additions and 57 deletions

2
view/contact_block.tpl Executable file → Normal file
View file

@ -1,7 +1,7 @@
<div id="contact-block"> <div id="contact-block">
<h4 class="contact-block-h4">$contacts</h4> <h4 class="contact-block-h4">$contacts</h4>
{{ if $micropro }} {{ if $micropro }}
<a class="allcontact-link" href="viewcontacts/$nickname">$viewcontacts</a> <a class="allcontact-link" href="contacts/$nickname">$viewcontacts</a>
<div class='contact-block-content'> <div class='contact-block-content'>
{{ for $micropro as $m }} {{ for $micropro as $m }}
$m $m

View file

@ -20,7 +20,8 @@
</div> </div>
<div class="contact-entry-photo-end" ></div> <div class="contact-entry-photo-end" ></div>
<div class="contact-entry-name" id="contact-entry-name-$contact.id" >$contact.name</div> <div class="contact-entry-name" id="contact-entry-name-$contact.id" >$contact.name</div>
<div class="contact-entry-details" id="contact-entry-url-$contact.id" >$contact.itemurl</div> <div class="contact-entry-details" id="contact-entry-url-$contact.id" >
<a href="$contact.itemurl" title="$contact.itemurl">Profile URL</a></div>
<div class="contact-entry-details" id="contact-entry-network-$contact.id" >$contact.network</div> <div class="contact-entry-details" id="contact-entry-network-$contact.id" >$contact.network</div>
<div class="contact-entry-end" ></div> <div class="contact-entry-end" ></div>

View file

@ -17,5 +17,7 @@
{{ endfor }} {{ endfor }}
{{ if $dropping }} {{ if $dropping }}
<div class="delete-checked">
<a href="#" onclick="deleteCheckedItems();return false;"><span class="icon delete"></span><span class="s22 text">$dropping</span></a> <a href="#" onclick="deleteCheckedItems();return false;"><span class="icon delete"></span><span class="s22 text">$dropping</span></a>
</div>
{{ endif }} {{ endif }}

View file

@ -1,7 +1,8 @@
<script type="text/javascript" src="$baseurl/library/tinymce/jscripts/tiny_mce/tiny_mce.js"></script>
<script type="text/javascript" src="$baseurl/js/ajaxupload.js"></script>
<script type="text/javascript">
<script language="javascript" type="text/javascript"> var editor = false;
var editor=false;
var textlen = 0; var textlen = 0;
var plaintext = '$editselect'; var plaintext = '$editselect';
// this is here because of the silly tinymce error. didn't help. // this is here because of the silly tinymce error. didn't help.
@ -19,15 +20,11 @@ function initEditor(cb) {
'transitionOut' : 'elastic' 'transitionOut' : 'elastic'
}); });
$(".jothidden").show(); $(".jothidden").show();
if (typeof cb!="undefined") { if (typeof cb!="undefined") cb();
cb();
}
return; return;
} }
tinyMCE.init({ tinyMCE.init({
theme : "advanced", theme : "advanced",
skin : "default",
mode : "specific_textareas", mode : "specific_textareas",
editor_selector: $editselect, editor_selector: $editselect,
auto_focus: "profile-jot-text", auto_focus: "profile-jot-text",
@ -51,9 +48,8 @@ function initEditor(cb) {
setup : function(ed) { setup : function(ed) {
cPopup = null; cPopup = null;
ed.onKeyDown.add(function(ed,e) { ed.onKeyDown.add(function(ed,e) {
if(cPopup !== null) { if(cPopup !== null)
cPopup.onkey(e); cPopup.onkey(e);
}
}); });
ed.onKeyUp.add(function(ed, e) { ed.onKeyUp.add(function(ed, e) {
@ -64,7 +60,7 @@ function initEditor(cb) {
cPopup = new ACPopup(this,baseurl+"/acl"); cPopup = new ACPopup(this,baseurl+"/acl");
} }
if(cPopup.ready && match[1]!==cPopup.searchText) cPopup.search(match[1]); if(cPopup.ready && match[1]!==cPopup.searchText) cPopup.search(match[1]);
if(! cPopup.ready) { cPopup = null; } if(! cPopup.ready) cPopup = null;
} }
else { else {
if(cPopup !== null) { cPopup.close(); cPopup = null; } if(cPopup !== null) { cPopup.close(); cPopup = null; }
@ -102,9 +98,9 @@ function initEditor(cb) {
ed.pasteAsPlainText = true; ed.pasteAsPlainText = true;
$("#profile-jot-text-loading").hide(); $("#profile-jot-text-loading").hide();
$(".jothidden").show(); $(".jothidden").show();
if (typeof cb!="undefined") cb();
if (typeof cb!="undefined") { cb(); }
}); });
} }
}); });
editor = true; editor = true;
@ -118,51 +114,21 @@ function initEditor(cb) {
} }
} }
function charCounter() {
// character count part deux
$('#profile-jot-text').keyup(function(event) {
var textlen = $(this).val().length();
var maxLen1 = 140;
var maxLen2 = 420;
$('#character-counter').removeClass('jothidden');
if(textlen <= maxLen1) {
$('#character-counter').removeClass('red');
$('#character-counter').removeClass('orange');
$('#character-counter').addClass('grey');
}
if((textlen > maxLen1) && (textlen <= maxLen2)) {
$('#character-counter').removeClass('grey');
$('#character-counter').removeClass('red');
$('#character-counter').addClass('orange');
}
if(textlen > maxLen2) {
$('#character-counter').removeClass('grey');
$('#character-counter').removeClass('orange');
$('#character-counter').addClass('red');
}
$('#character-counter').html($(this).val().length);
});
}
function enableOnUser(){ function enableOnUser(){
if (editor) return; if (editor) return;
$(this).val(""); $(this).val("");
initEditor(); initEditor();
charCounter();
} }
</script>
<script type="text/javascript" src="$baseurl/js/ajaxupload.js" ></script>
<script>
var ispublic = '$ispublic'; var ispublic = '$ispublic';
var addtitle = '$addtitle'; var addtitle = '$addtitle';
$(document).ready(function() { $(document).ready(function() {
/* enable tinymce on focus and click */ /* enable tinymce on focus and click */
$("#profile-jot-text").focus(enableOnUser); $("#profile-jot-text").focus(enableOnUser);
$("#profile-jot-text").click(enableOnUser); $("#profile-jot-text").click(enableOnUser);
$("#profile-jot-text").focus(charCounter);
$("#profile-jot-text").click(charCounter);
var uploader = new window.AjaxUpload( var uploader = new window.AjaxUpload(
'wall-image-upload', 'wall-image-upload',
@ -313,5 +279,36 @@ function enableOnUser(){
$geotag $geotag
function charCounter() {
// character count part deux
//$(this).val().length is not a function Line 282(3)
$('#profile-jot-text').keyup(function() {
var textlen = 0;
var maxLen1 = 140;
var maxLen2 = 420;
$('#character-counter').removeClass('jothidden');
textLen = $(this).val().length;
if(textLen <= maxLen1) {
$('#character-counter').removeClass('red');
$('#character-counter').removeClass('orange');
$('#character-counter').addClass('grey');
}
if((textLen > maxLen1) && (textlen <= maxLen2)) {
$('#character-counter').removeClass('grey');
$('#character-counter').removeClass('red');
$('#character-counter').addClass('orange');
}
if(textLen > maxLen2) {
$('#character-counter').removeClass('grey');
$('#character-counter').removeClass('orange');
$('#character-counter').addClass('red');
}
$('#character-counter').text( textLen );
});
$('#profile-jot-text').keyup();
}
</script> </script>

View file

@ -232,7 +232,8 @@ nav a:hover {
nav #banner { nav #banner {
display: block; display: block;
position: absolute; position: absolute;
margin-left: 20px; left: 51px;
top: 25px;
} }
nav #banner #logo-text a { nav #banner #logo-text a {
font-size: 40px; font-size: 40px;
@ -414,8 +415,8 @@ div.jGrowl div.info {
padding-left: 58px; padding-left: 58px;
} }
#nav-notifications-menu { #nav-notifications-menu {
margin-top: 30px; margin: 30px 0 0 -45px;
width: 255px; width: 300px;
max-height: 400px; max-height: 400px;
overflow: auto; overflow: auto;
font-size: 9pt; font-size: 9pt;
@ -611,8 +612,8 @@ nav #nav-notifications-linkmenu.on .icon.s22.notify, nav #nav-notifications-link
**/ **/
aside { aside {
position: absolute; position: absolute;
right: 8%; right: 15px;
width: 20.5%; width: 255px;
font-size: smaller; font-size: smaller;
} }
.vcard .fn { .vcard .fn {
@ -672,7 +673,7 @@ aside #viewcontacts {
**/ **/
#jot { #jot {
/*width: 785px;*/ /*width: 785px;*/
margin: 0px 0 20px 0px; margin: 10px 0 20px 0px;
width: 100%; width: 100%;
} }
#jot #jot-tools { #jot #jot-tools {
@ -956,7 +957,7 @@ aside #viewcontacts {
* section * section
*/ */
section { section {
margin: 20px 8% 0 6%; margin: 20px 6% 0 4%;
font-size: 0.8em; font-size: 0.8em;
padding-right: 250px; padding-right: 250px;
min-width: 475px; min-width: 475px;
@ -965,7 +966,7 @@ section {
/** tabs **/ /** tabs **/
.tabs { .tabs {
list-style: none; list-style: none;
margin: 0; margin: 10px 0 10px;
padding: 0; padding: 0;
border-bottom: 1px solid #729fcf; border-bottom: 1px solid #729fcf;
font-size: 14px; font-size: 14px;
@ -1021,6 +1022,7 @@ section {
/*border: 1px #aaa solid;*/ /*border: 1px #aaa solid;*/
/*border-radius: 5px;*/ /*border-radius: 5px;*/
padding: 0px; padding: 0px;
overflow-x: auto;
} }
.wall-item-photo-menu { .wall-item-photo-menu {
display: none; display: none;
@ -1918,7 +1920,13 @@ div[id$="wrapper"] br {
#item-delete-selected { #item-delete-selected {
margin-top: 30px; margin-top: 30px;
} }
/* was tired of having no way of moving it around, so
* here's a little 'hook' to do so */
.delete-checked {
position: absolute;
left: 35px;
margin-top: 20px;
}
#item-delete-selected-end { #item-delete-selected-end {
clear: both; clear: both;
} }
@ -2100,13 +2108,15 @@ div[id$="wrapper"] br {
} }
.field label { .field label {
float: left; float: left;
width: 200px; width: 275px;
display: block; display: block;
font-size: 1.077em; font-size: 1.077em;
/*font-weight: bold;*/
margin-bottom: 0.2em; margin-bottom: 0.2em;
margin: 0 10px 0.2em 0; margin: 0 10px 0.2em 0;
border: 1px #999 solid; border: 1px #999 solid;
padding: 5px; padding: 5px;
background: #f2eedf;
vertical-align: middle; vertical-align: middle;
} }
.field input { .field input {