Move bootstrap dependencies (tagsinput) to theme redbasic (we only have it there). Comment out some most probably deprecated js includes. Some css cleanup.

This commit is contained in:
Mario Vavti 2015-03-27 11:52:59 +01:00
parent 1bf93916db
commit b59e2870ab
9 changed files with 42 additions and 30 deletions

View file

@ -11,16 +11,19 @@ code {
.jothidden input {
border: 0px;
margin: 0px;
padding: 8px;
height: 39px;
width: 70%;
margin-bottom: 5px;
width: 100%;
}
.jothidden {
display:none;
}
#jot-title-wrap input {
padding: 8px;
margin-bottom: 5px;
}
#profile-jot-text {
height: 39px;
padding: 8px;

View file

@ -25,7 +25,10 @@
.event-cats {
margin-top: 15px;
width: 100%;
}
.bootstrap-tagsinput {
width: 100%;
}
@ -47,4 +50,4 @@
#event-edit-preview-btn {
margin-right: 15px;
}
}

View file

@ -275,7 +275,7 @@ $(function() {
});
/* setup field_richtext */
setupFieldRichtext();
//setupFieldRichtext();
/* Turn elements with one of our special rel tags into popup menus */
@ -1060,9 +1060,9 @@ function fcFileBrowser (field_name, url, type, win) {
return false;
}
function setupFieldRichtext(){
return;
/*
function setupFieldRichtext(){
tinyMCE.init({
theme : "advanced",
mode : "specific_textareas",
@ -1086,9 +1086,9 @@ function setupFieldRichtext(){
theme_advanced_path : false,
file_browser_callback : "fcFileBrowser",
});
*/
}
}
*/
/**
* sprintf in javascript

View file

@ -10,9 +10,9 @@ head_add_css('view/css/conversation.css');
head_add_css('view/css/widgets.css');
head_add_css('view/css/colorbox.css');
head_add_css('library/justifiedGallery/justifiedGallery.css');
head_add_css('library/bootstrap-tagsinput/bootstrap-tagsinput.css');
head_add_js('jquery.js');
head_add_js('jquery-migrate-1.1.1.js');
//head_add_js('jquery-migrate-1.1.1.js');
head_add_js('library/justifiedGallery/jquery.justifiedGallery.js');
//head_add_js('jquery-compat.js');
@ -21,13 +21,13 @@ head_add_js('jquery.spin.js');
head_add_js('jquery.textinputs.js');
head_add_js('autocomplete.js');
head_add_js('library/jquery-textcomplete/jquery.textcomplete.js');
head_add_js('library/colorbox/jquery.colorbox.js');
//head_add_js('library/colorbox/jquery.colorbox.js');
head_add_js('library/jquery.timeago.js');
head_add_js('library/readmore.js/readmore.js');
head_add_js('library/jquery_ac/friendica.complete.js');
head_add_js('library/tiptip/jquery.tipTip.minified.js');
//head_add_js('library/jquery_ac/friendica.complete.js');
//head_add_js('library/tiptip/jquery.tipTip.minified.js');
head_add_js('library/jgrowl/jquery.jgrowl_minimized.js');
head_add_js('library/tinymce/jscripts/tiny_mce/tiny_mce.js');
//head_add_js('library/tinymce/jscripts/tiny_mce/tiny_mce.js');
head_add_js('library/cryptojs/components/core-min.js');
head_add_js('library/cryptojs/rollups/aes.js');
head_add_js('library/cryptojs/rollups/rabbit.js');
@ -38,9 +38,9 @@ head_add_js('webtoolkit.base64.js');
head_add_js('main.js');
head_add_js('crypto.js');
head_add_js('library/jRange/jquery.range.js');
head_add_js('docready.js');
//head_add_js('docready.js');
head_add_js('library/colorbox/jquery.colorbox-min.js');
head_add_js('library/bootstrap-tagsinput/bootstrap-tagsinput.js');
head_add_js('library/jquery.AreYouSure/jquery.are-you-sure.js');
head_add_js('library/tableofcontents/jquery.toc.js');

View file

@ -2214,15 +2214,19 @@ aside .nav > li > a:hover, aside .nav > li > a:focus {
}
/* Modified original CSS to match input in Redbasic */
.bootstrap-tagsinput {
.jothidden .bootstrap-tagsinput {
border-color:#fff;
background-color: #fff;
box-shadow: none;
display: inline-block;
border-radius: $radiuspx;
cursor: text;
padding: 0 6px;
width: 70% !important;
padding: 0px 8px;
width: 100%;
}
.bootstrap-tagsinput .label {
font-size: 100%;
}
.jothidden .bootstrap-tagsinput:hover, .jothidden .bootstrap-tagsinput:focus {
@ -2305,9 +2309,6 @@ aside .nav > li > a:hover, aside .nav > li > a:focus {
right: 0px;
background-color: #337AB7;
}
.label-info {
background-color: #337AB7;
}
.channels_ckbx, .pending_ckbx, .users_ckbx {
margin-top: -5px !important;

View file

@ -34,6 +34,10 @@ $(document).ready(function() {
if($('#tabs-collapse-1').length === 0) {
$('#expand-tabs').hide();
}
$("input[data-role=cat-tagsinput]").tagsinput({
tagClass: 'label label-primary'
});
});
$(document).ready(function(){
@ -48,4 +52,4 @@ $(document).ready(function(){
}
}
setInterval(function () {checkNotify();}, 10 * 1000);
});
});

View file

@ -1,7 +1,8 @@
<?php
head_add_css('library/font_awesome/css/font-awesome.min.css');
head_add_css('library/bootstrap/css/bootstrap.min.css');
head_add_css('library/bootstrap/css/bootstrap.min.css');
head_add_css('library/bootstrap-tagsinput/bootstrap-tagsinput.css');
head_add_css('view/css/bootstrap-red.css');
head_add_css('library/datetimepicker/jquery.datetimepicker.css');
//head_add_css('library/colorpicker/css/colorpicker.css');
@ -10,6 +11,7 @@ require_once('view/php/theme_init.php');
head_add_js('library/bootstrap/js/bootstrap.min.js');
head_add_js('library/bootbox/bootbox.min.js');
head_add_js('library/bootstrap-tagsinput/bootstrap-tagsinput.js');
head_add_js('library/datetimepicker/jquery.datetimepicker.js');
//head_add_js('library/colorpicker/js/colorpicker.js');
head_add_js('library/bootstrap-colorpicker/dist/js/bootstrap-colorpicker.js');

View file

@ -49,7 +49,7 @@
{{if $catsenabled}}
<div id="event-category-wrap">
<input name="category" id="event-category" type="text" placeholder="{{$placeholdercategory}}" value="{{$category}}" class="event-cats" style="display: block;" data-role="tagsinput" />
<input name="category" id="event-category" type="text" placeholder="{{$placeholdercategory}}" value="{{$category}}" class="event-cats" style="display: block;" data-role="cat-tagsinput" />
</div>
{{/if}}

View file

@ -10,8 +10,7 @@
<input type="hidden" name="coord" id="jot-coord" value="" />
<input type="hidden" name="post_id" value="{{$post_id}}" />
<input type="hidden" name="webpage" value="{{$webpage}}" />
<input type="hidden" name="preview" id="jot-preview" value="0" />
<input type="hidden" id="jot-consensus" name="consensus" value="{{if $consensus}}{{$consensus}}{{else}}0{{/if}}" />
<input type="hidden" name="preview" id="jot-preview" value="0" /> <input type="hidden" id="jot-consensus" name="consensus" value="{{if $consensus}}{{$consensus}}{{else}}0{{/if}}" />
{{if $showacl}}{{$acl}}{{/if}}
{{$mimeselect}}
{{$layoutselect}}
@ -25,7 +24,7 @@
</div>
{{if $catsenabled}}
<div id="jot-category-wrap" class="jothidden" style="display:none">
<input name="category" id="jot-category" type="text" placeholder="{{$placeholdercategory}}" value="{{$category}}" data-role="tagsinput">
<input name="category" id="jot-category" type="text" placeholder="{{$placeholdercategory}}" value="{{$category}}" data-role="cat-tagsinput">
</div>
{{/if}}
{{if $webpage}}