Visual refresh on the textarea in the enanium page editor. Also fixed missing image on the Save Draft button.
authorDan Fuhry <dan@enanocms.org>
Tue, 17 Aug 2010 11:35:16 -0400
changeset 1291 a971f6efcb7b
parent 1290 27ab1b13a783
child 1293 83e0fcd008e1
Visual refresh on the textarea in the enanium page editor. Also fixed missing image on the Save Draft button.
includes/clientside/static/editor.js
includes/clientside/static/template-compiler.js
themes/enanium/css/babygrand.css
--- a/includes/clientside/static/editor.js	Mon Aug 09 19:17:52 2010 -0400
+++ b/includes/clientside/static/editor.js	Tue Aug 17 11:35:16 2010 -0400
@@ -401,6 +401,7 @@
 		button.assign_vars({
 				TITLE: $lang.get('editor_btn_savedraft'),
 				IMAGE: editor_img_path + '/savedraft.gif',
+				// SPRITE: gen_sprite_html(editor_img_path + '/sprite.png', 16, 16, 0, 80),
 				SPRITE: false,
 				FLAGS: 'href="#" onclick="ajaxPerformAutosave(); return false;" id="ajax_edit_savedraft_btn"'
 			});
--- a/includes/clientside/static/template-compiler.js	Mon Aug 09 19:17:52 2010 -0400
+++ b/includes/clientside/static/template-compiler.js	Tue Aug 17 11:35:16 2010 -0400
@@ -60,8 +60,8 @@
 	code = code.replace(/\<!-- IFSET ([A-z0-9_-]+) --\>([\s\S]*?)\<!-- BEGINELSE \1 --\>([\s\S]*?)\<!-- END \1 --\>/ig, "' + ( ( typeof(this.tpl_strings['$1']) == 'string' ) ? '$2' : '$3' ) + '");
 	code = code.replace(/\<!-- IFSET ([A-z0-9_-]+) --\>([\s\S]*?)\<!-- END \1 --\>/ig, "' + ( ( typeof(this.tpl_strings['$1']) == 'string' ) ? '$2' : '' ) + '");
 	code = code.replace(/\<!-- BEGIN ([A-z0-9_-]+) --\>([\s\S]*?)\<!-- BEGINELSE \1 --\>([\s\S]*?)\<!-- END \1 --\>/ig, "' + ( ( this.tpl_bool['$1'] == true ) ? '$2' : '$3' ) + '");
-	code = code.replace(/\<!-- BEGIN ([A-z0-9_-]+) --\>([\s\S]*?)\<!-- END \1 --\>/ig, "' + ( ( this.tpl_bool['$1'] == true ) ? '$2' : '' ) + '");
-	code = code.replace(/\<!-- BEGINNOT ([A-z0-9_-]+) --\>([\s\S]*?)\<!-- END \1 --\>/ig, "' + ( ( this.tpl_bool['$1'] == false ) ? '$2' : '' ) + '");
+	code = code.replace(/\<!-- BEGIN ([A-z0-9_-]+) --\>([\s\S]*?)\<!-- END \1 --\>/ig, "' + ( ( Boolean(this.tpl_bool['$1']) == true ) ? '$2' : '' ) + '");
+	code = code.replace(/\<!-- BEGINNOT ([A-z0-9_-]+) --\>([\s\S]*?)\<!-- END \1 --\>/ig, "' + ( ( Boolean(this.tpl_bool['$1']) == false ) ? '$2' : '' ) + '");
 	code = code.replace(/\<!-- HOOK ([A-z0-9_-]+) --\>/ig, "' + this.fetch_hook('$1') + '");
 	return code;
 }
--- a/themes/enanium/css/babygrand.css	Mon Aug 09 19:17:52 2010 -0400
+++ b/themes/enanium/css/babygrand.css	Tue Aug 17 11:35:16 2010 -0400
@@ -436,6 +436,16 @@
 	border-color: #888;
 }
 
+textarea#ajaxEditArea, textarea.writespace {
+	font-family: Lucida Grande, DejaVu Sans, arial, helvetica, sans-serif;
+	font-size: 9pt;
+	line-height: 130%;
+	color: #202020;
+	background-color: #fff;
+	padding: 4px;
+	border: 1px solid #a0a0a0;
+}
+
 /* Footer */
 div#footer {
 	margin: 7px 0 0 0;