Commit 83abf6db authored by KR Moorhouse's avatar KR Moorhouse

Removed old DOM node data. Updated jBox.css to function within the context of the builder.

parent d211a72f
......@@ -3,6 +3,7 @@
.jBox-wrapper {
text-align: left;
z-index: 100000000 !important;
}
.jBox-wrapper,
......@@ -141,6 +142,11 @@
padding: 12px 15px;
}
.ninja-forms-settings #jBox-overlay .jBox-closeButton,
.ninja-forms-app #jBox-overlay .jBox-closeButton {
display: none;
}
/* jBox Confirm */
.jBox-Confirm .jBox-content {
......@@ -474,6 +480,7 @@
height: 100%;
background: #000;
background-color: rgba(0, 0, 0, .6);
z-index: 99999999 !important;
}
/* Block scrolling */
......
......@@ -142,94 +142,6 @@ define( [], function() {
}
};
var deleteModal = new NinjaModal( modalData );
// var message, container, messageBox, deleteMsgs, buttons, confirm, cancel, lineBreak;
// container = document.createElement( 'div' );
// messageBox = document.createElement( 'p' );
//
// buttons = document.createElement( 'div' );
// buttons.style.marginTop = '10px';
// buttons.style.backgroundColor = '#f4f5f6';
//
// confirm = document.createElement( 'div' );
// confirm.style.padding = '8px';
// confirm.style.backgroundColor = '#d9534f';
// confirm.style.borderColor = '#d9534f';
// confirm.style.fontSize = '14pt';
// confirm.style.fontWeight = 'bold';
// confirm.style.color = '#ffffff';
// confirm.style.borderRadius = '4px';
//
// cancel = document.createElement( 'div' );
// cancel.style.padding = '8px';
// cancel.style.backgroundColor = '#5bc0de';
// cancel.style.borderColor = '#5bc0de';
// cancel.style.fontSize = '14pt';
// cancel.style.fontWeight = 'bold';
// cancel.style.color = '#ffffff';
// cancel.style.borderRadius = '4px';
//
// lineBreak = document.createElement( 'br' );
//
// container.classList.add( 'message' );
// messageBox.innerHTML += nfi18n.fieldDataDeleteMsg;
//
// messageBox.appendChild( lineBreak );
// container.appendChild( messageBox );
// container.appendChild( lineBreak );
//
// confirm.innerHTML = nfi18n.delete;
// confirm.classList.add( 'confirm', 'nf-button', 'primary' );
// confirm.style.float = 'left';
//
// cancel.innerHTML = nfi18n.cancel;
// cancel.classList.add( 'cancel', 'nf-button', 'secondary', 'cancel-delete-all' );
// cancel.style.float = 'right';
//
// buttons.appendChild( confirm );
// buttons.appendChild( cancel );
// buttons.classList.add( 'buttons' );
// container.appendChild( buttons );
//
// message = document.createElement( 'div' );
// message.appendChild( container );
//
// // set up delete model with all the elements created above
// var deleteFieldModal = new jBox( 'Modal', {
// width: 450,
// addClass: 'dashboard-modal',
// zIndex: 999999999,
// overlay: true,
// closeOnClick: false
// } );
//
// deleteFieldModal.setContent( message.innerHTML );
// deleteFieldModal.setTitle( 'Delete Field?' );
//
// var that = this;
// // add event listener for cancel button
// var btnCancel = deleteFieldModal.container[0].getElementsByClassName('cancel')[0];
// btnCancel.addEventListener('click', function() {
//
// // close and destroy modal
// deleteFieldModal.close();
// deleteFieldModal.destroy();
// // set deleting to false so edit can work as normal
// that.deleting = false;
//
// } );
// // add event listener for delete button
// var btnDelete = deleteFieldModal.container[0].getElementsByClassName('confirm')[0];
// btnDelete.addEventListener('click', function() {
//
// // close and destroy modal.
// deleteFieldModal.close();
// deleteFieldModal.destroy();
//
// // proceed as normal, data will be deleted in backend on publish
// that.clickDelete( e, dataModel );
// } );
//
// deleteFieldModal.open();
},
/**
......
......@@ -24,7 +24,6 @@ function NinjaModal ( data ) {
this.settings = {
width: ( 'undefined' != typeof data.width ? data.width : 400 ),
class: ( 'undefined' != typeof data.class ? data.class : 'dashboard-modal' ),
closeButton: false,
closeOnClick: ( 'undefined' != typeof data.closeOnClick ? data.closeOnClick : 'body' ),
closeOnEsc: ( 'undefined' != typeof data.closeOnEsc ? data.closeOnEsc : true )
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment