Definitive styles to the Grid Wizard feature for TinyMCE
This commit is contained in:
@@ -17,7 +17,7 @@ and open the template in the editor.
|
||||
body {
|
||||
position: absolute;
|
||||
top: 0px;
|
||||
left: 45%;
|
||||
left: 35%;
|
||||
margin-left: -70px;
|
||||
}
|
||||
.container {
|
||||
@@ -41,35 +41,33 @@ and open the template in the editor.
|
||||
Chose a grid
|
||||
</div>
|
||||
<div class="middle">
|
||||
<div id="gridDropdown">
|
||||
<select id="gridList">
|
||||
|
||||
</select>
|
||||
</div>
|
||||
<select id="gridList">
|
||||
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<br>
|
||||
<div class="row">
|
||||
<div class="middle">
|
||||
<div class="left">
|
||||
Prefix
|
||||
</div>
|
||||
<div class="right">
|
||||
<div id="prefixDropdown">
|
||||
<select name="prefixList" id="prefixList">
|
||||
<option value="@#">@#</option>
|
||||
<option value="@@">@@</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="middle">
|
||||
<select name="prefixList" id="prefixList">
|
||||
<option value="@#">@#</option>
|
||||
<option value="@@">@@</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<br>
|
||||
<div class="row">
|
||||
<div class="left"> </div>
|
||||
<div class="middle">
|
||||
<input type="checkbox" id="borderCheckbox"> Border
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="left"> </div>
|
||||
<div class="middle">
|
||||
<input type="checkbox" id="headersCheckbox"> Headers
|
||||
</div>
|
||||
@@ -82,10 +80,10 @@ and open the template in the editor.
|
||||
</table>
|
||||
<br>
|
||||
<div align="center">
|
||||
<button id="addButton" style="width: 100px">
|
||||
<button id="insert">
|
||||
Add
|
||||
</button>
|
||||
<button id="cancelButton" style="width: 100px">
|
||||
<button id="cancel">
|
||||
Cancel
|
||||
</button>
|
||||
</div>
|
||||
|
||||
@@ -63,7 +63,7 @@ $(document).ready(function () {
|
||||
}
|
||||
|
||||
var insertFormatedGrid = function(){
|
||||
var gridName = $("#gridList").val();
|
||||
var gridName = $("#gridList option:selected").text();
|
||||
var tableCode = "<table>"
|
||||
var gridCode = "<!--"+gridName+"@>-->";
|
||||
var headerCode = "<tr>";
|
||||
@@ -81,19 +81,19 @@ $(document).ready(function () {
|
||||
headerCode = '';
|
||||
}
|
||||
gridCode += headerCode+fieldCode+"<!--@<"+gridName+"-->";
|
||||
tableCode += gridCode+"</table>"
|
||||
updateEditorContent (tableCode);
|
||||
tableCode += gridCode+"</table>";
|
||||
updateEditorContent(tableCode);
|
||||
}
|
||||
|
||||
$('#gridList').change(function(){
|
||||
getGridFieldList($(this).val());
|
||||
});
|
||||
|
||||
$('#addButton').click(function(){
|
||||
$('#insert').click(function(){
|
||||
insertFormatedGrid();
|
||||
});
|
||||
|
||||
$('#cancelButton').click(function(){
|
||||
$('#cancel').click(function(){
|
||||
closePluginPopup();
|
||||
});
|
||||
|
||||
|
||||
@@ -192,10 +192,10 @@ class XmlForm_Field_WYSIWYG_EDITOR extends XmlForm_Field
|
||||
theme_advanced_buttons3_add : "fullpage",
|
||||
popup_css : "/js/tinymce/jscripts/tiny_mce/themes/advanced/skins/default/dialog.css",
|
||||
handle_event_callback : function(e) {
|
||||
if(this.isDirty()) {
|
||||
this.save();
|
||||
}
|
||||
return true;
|
||||
if(this.isDirty()) {
|
||||
this.save();
|
||||
}
|
||||
return true;
|
||||
}
|
||||
});
|
||||
';
|
||||
|
||||
Reference in New Issue
Block a user