mirror of
https://github.com/silverstripe/silverstripe-widgets
synced 2024-10-22 15:05:54 +00:00
commit
5ade9048ca
@ -21,10 +21,7 @@ class WidgetAreaEditor extends FormField {
|
|||||||
|
|
||||||
function FieldHolder($properties = array()) {
|
function FieldHolder($properties = array()) {
|
||||||
Requirements::css('widgets/css/WidgetAreaEditor.css');
|
Requirements::css('widgets/css/WidgetAreaEditor.css');
|
||||||
Requirements::javascript(THIRDPARTY_DIR . "/prototype/prototype.js");
|
|
||||||
Requirements::javascript(THIRDPARTY_DIR . '/behaviour/behaviour.js');
|
|
||||||
Requirements::javascript('widgets/javascript/WidgetAreaEditor.js');
|
Requirements::javascript('widgets/javascript/WidgetAreaEditor.js');
|
||||||
|
|
||||||
return $this->renderWith("WidgetAreaEditor");
|
return $this->renderWith("WidgetAreaEditor");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -34,7 +34,12 @@ div.availableWidgets div.Widget {
|
|||||||
width: 98%;
|
width: 98%;
|
||||||
border: 1px solid #ddd;
|
border: 1px solid #ddd;
|
||||||
border-top: none;
|
border-top: none;
|
||||||
margin-bottom: 5px;
|
margin-bottom: 10px;
|
||||||
|
background: #F0F3F4 url('../../cms/images/textures/bg_cms_main_content.png') repeat top left;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.widgetDescription{
|
||||||
|
padding: 10px 0;
|
||||||
}
|
}
|
||||||
div.widgetDescription p,
|
div.widgetDescription p,
|
||||||
div.widgetFields {
|
div.widgetFields {
|
||||||
@ -44,7 +49,7 @@ div.widgetFields {
|
|||||||
}
|
}
|
||||||
|
|
||||||
p.deleteWidget {
|
p.deleteWidget {
|
||||||
margin: 0;
|
margin: 0 0 4px;
|
||||||
height: 22px;
|
height: 22px;
|
||||||
line-height: 2.2;
|
line-height: 2.2;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
|
@ -127,7 +127,7 @@
|
|||||||
insertWidgetEditor: function(response) {
|
insertWidgetEditor: function(response) {
|
||||||
// Remove placeholder text
|
// Remove placeholder text
|
||||||
if($('#NoWidgets-'+$(this).attr('name')).length>0) {
|
if($('#NoWidgets-'+$(this).attr('name')).length>0) {
|
||||||
$('#usedWidgets-'+$(this).attr('name')).remove($('#NoWidgets-'+$(this).attr('name')));
|
$('#NoWidgets-'+$(this).attr('name')).remove();
|
||||||
}
|
}
|
||||||
|
|
||||||
var usedWidgets = $('#usedWidgets-'+$(this).attr('name')).children();
|
var usedWidgets = $('#usedWidgets-'+$(this).attr('name')).children();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user