Vlad Kurkin (b_vladi) wrote in changelog,
Vlad Kurkin
b_vladi
changelog

[livejournal] r19791: LJSUP-9515: Incorrect behavior for repos...

Committer: vkurkin
LJSUP-9515: Incorrect behavior for reposting
U   trunk/htdocs/js/ck/plugins/livejournal/plugin.js
Modified: trunk/htdocs/js/ck/plugins/livejournal/plugin.js
===================================================================
--- trunk/htdocs/js/ck/plugins/livejournal/plugin.js	2011-08-19 09:59:51 UTC (rev 19790)
+++ trunk/htdocs/js/ck/plugins/livejournal/plugin.js	2011-08-19 10:01:49 UTC (rev 19791)
@@ -726,7 +726,7 @@
 				+ 'background-repeat: no-repeat;'
 				+ 'background-color: #CCCCCC;'
 				+ 'border: 1px dotted #000000;'
-				+ 'height: 80px;'
+				+ 'min-height: 80px;'
 			+ '}');
 
 			function doEmbed(content) {
@@ -1229,10 +1229,6 @@
 								}
 								newElement.children = element.children;
 							break;
-							case 'lj-repost':
-								newElement = new CKEDITOR.htmlParser.element('lj-repost');
-								newElement.isOptionalClose = newElement.isEmpty = true;
-							break;
 							default:
 								if (!element.children.length) {
 									newElement = false;
@@ -1255,6 +1251,13 @@
 							ljUserNode.isOptionalClose = ljUserNode.isEmpty = true;
 							return ljUserNode;
 						}
+					},
+					input: function(element){
+						if(element.attributes['class'] == 'lj-repost'){
+							var newElement = new CKEDITOR.htmlParser.element('lj-repost');
+							newElement.isOptionalClose = newElement.isEmpty = true;
+							return newElement;
+						}
 					}
 				},
 				attributes: {

Tags: b_vladi, js, livejournal
Subscribe
  • Post a new comment

    Error

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 0 comments