diff --git a/code/AssetAdmin.php b/code/AssetAdmin.php index 01a92f28..81491d49 100755 --- a/code/AssetAdmin.php +++ b/code/AssetAdmin.php @@ -218,7 +218,7 @@ JS echo << var url = parent.document.getElementById('sitetree').getTreeNodeByIdx( "{$folder->ID}" ).getElementsByTagName('a')[0].href; - parent.jQuery('#Form_EditForm').concrete('ss').loadForm(url); + parent.jQuery('#Form_EditForm').entwine('ss').loadForm(url); parent.statusMessage("{$statusMessage}","{$status}"); HTML; diff --git a/code/LeftAndMain.php b/code/LeftAndMain.php index 439313d0..ed0ac00c 100644 --- a/code/LeftAndMain.php +++ b/code/LeftAndMain.php @@ -221,8 +221,8 @@ class LeftAndMain extends Controller { // @todo Load separately so the CSS files can be inlined Requirements::css(SAPPHIRE_DIR . '/thirdparty/jquery-ui-themes/smoothness/ui.all.css'); - // concrete - Requirements::javascript(SAPPHIRE_DIR . '/thirdparty/jquery-concrete/dist/jquery.concrete-dist.js'); + // entwine + Requirements::javascript(SAPPHIRE_DIR . '/thirdparty/jquery-entwine/dist/jquery.entwine-dist.js'); // Required for TreeTools panel above tree Requirements::javascript(SAPPHIRE_DIR . '/javascript/TabSet.js'); @@ -737,7 +737,7 @@ JS; * Also used in the template rendered through {@link Right()} in the $EditForm placeholder. * * This is a "pseudo-abstract" methoed, usually connected to a {@link getEditForm()} - * method in a concrete subclass. This method can accept a record identifier, + * method in an entwine subclass. This method can accept a record identifier, * selected either in custom logic, or through {@link currentPageID()}. * The form usually construct itself from {@link DataObject->getCMSFields()} * for the specific managed subclass defined in {@link LeftAndMain::$tree_class}. diff --git a/code/SecurityAdmin.php b/code/SecurityAdmin.php index c1895bed..78f406e2 100644 --- a/code/SecurityAdmin.php +++ b/code/SecurityAdmin.php @@ -138,7 +138,7 @@ class SecurityAdmin extends LeftAndMain implements PermissionProvider { Requirements::css(CMS_DIR . '/css/typography.css'); Requirements::css(CMS_DIR . '/css/cms_right.css'); Requirements::javascript(SAPPHIRE_DIR . '/thirdparty/jquery/jquery.js'); - Requirements::javascript(SAPPHIRE_DIR . '/thirdparty/jquery-concrete/dist/jquery.concrete-dist.js'); + Requirements::javascript(SAPPHIRE_DIR . '/thirdparty/jquery-entwine/dist/jquery.entwine-dist.js'); Requirements::css(CMS_DIR . '/css/MemberImportForm.css'); Requirements::javascript(CMS_DIR . '/javascript/MemberImportForm.js'); @@ -169,7 +169,7 @@ class SecurityAdmin extends LeftAndMain implements PermissionProvider { Requirements::css(CMS_DIR . '/css/typography.css'); Requirements::css(CMS_DIR . '/css/cms_right.css'); Requirements::javascript(SAPPHIRE_DIR . '/thirdparty/jquery/jquery.js'); - Requirements::javascript(SAPPHIRE_DIR . '/thirdparty/jquery-concrete/dist/jquery.concrete-dist.js'); + Requirements::javascript(SAPPHIRE_DIR . '/thirdparty/jquery-entwine/dist/jquery.entwine-dist.js'); Requirements::css(CMS_DIR . '/css/MemberImportForm.css'); Requirements::javascript(CMS_DIR . '/javascript/MemberImportForm.js'); diff --git a/javascript/AssetAdmin.DragDrop.js b/javascript/AssetAdmin.DragDrop.js index 5e4f660c..dc3c59bf 100644 --- a/javascript/AssetAdmin.DragDrop.js +++ b/javascript/AssetAdmin.DragDrop.js @@ -1,7 +1,7 @@ (function($) { - $.concrete('ss', function($){ + $.entwine('ss', function($){ - $('.AssetTableField.dragdrop').concrete({ + $('.AssetTableField.dragdrop').entwine({ onmatch: function() { var self = this; $('#sitetree li').each(function() { @@ -43,7 +43,7 @@ } }); - $('.AssetTableField .dragfile').concrete({ + $('.AssetTableField .dragfile').entwine({ onmatch: function() { var self = this; var container = this.parents('.AssetTableField'); diff --git a/javascript/AssetAdmin.js b/javascript/AssetAdmin.js index b2beafb3..4e3a87f2 100755 --- a/javascript/AssetAdmin.js +++ b/javascript/AssetAdmin.js @@ -20,7 +20,7 @@ var _HANDLER_FORMS = { * Delete selected folders through "batch actions" tab. */ $(document).ready(function() { - $('#Form_BatchActionsForm').concrete('ss').register( + $('#Form_BatchActionsForm').entwine('ss').register( // TODO Hardcoding of base URL 'admin/assets/batchactions/delete', function(ids) { @@ -35,8 +35,8 @@ var _HANDLER_FORMS = { ); }); - $.concrete('ss', function($){ - $('#Form_SyncForm').concrete({ + $.entwine('ss', function($){ + $('#Form_SyncForm').entwine({ onsubmit: function(e) { var button = jQuery(this).find(':submit:first'); button.addClass('loading'); diff --git a/javascript/AssetTableField.js b/javascript/AssetTableField.js index 19c47acf..7bbf4b28 100644 --- a/javascript/AssetTableField.js +++ b/javascript/AssetTableField.js @@ -1,7 +1,7 @@ (function($) { - $.concrete('ss', function($){ + $.entwine('ss', function($){ - $('.AssetTableField').concrete({ + $('.AssetTableField').entwine({ onmatch: function() { var self = this; @@ -46,7 +46,7 @@ /** * Checkboxes used to batch delete files */ - $('.AssetTableField :checkbox').concrete({ + $('.AssetTableField :checkbox').entwine({ onchange: function() { var container = this.parents('.AssetTableField'); var input = container.find('input#deletemarked'); @@ -62,7 +62,7 @@ * Batch delete files marked by checkboxes in the table. * Refreshes the form field afterwards via ajax. */ - $('.AssetTableField input#deletemarked').concrete({ + $('.AssetTableField input#deletemarked').entwine({ onmatch: function() { this.attr('disabled', 'disabled'); this._super(); diff --git a/javascript/CMSMain.EditForm.js b/javascript/CMSMain.EditForm.js index bd685404..7f12fd99 100644 --- a/javascript/CMSMain.EditForm.js +++ b/javascript/CMSMain.EditForm.js @@ -1,11 +1,11 @@ (function($) { - $.concrete('ss', function($){ + $.entwine('ss', function($){ /** * Alert the user on change of page-type - this might have implications * on the available form fields etc. * @name ss.EditFormClassName */ - $('#Form_EditForm :input[name=ClassName]').concrete(/** @lends ss.EditFormClassName */{ + $('#Form_EditForm :input[name=ClassName]').entwine(/** @lends ss.EditFormClassName */{ onchange: function() { alert(ss.i18n._t('CMSMAIN.ALERTCLASSNAME')); } @@ -15,7 +15,7 @@ * @class Input validation on the URLSegment field * @name ss.EditForm.URLSegment */ - $('#Form_EditForm input[name=URLSegment]').concrete(/** @lends ss.EditForm.URLSegment */{ + $('#Form_EditForm input[name=URLSegment]').entwine(/** @lends ss.EditForm.URLSegment */{ FilterRegex: /[^A-Za-z0-9-]+/, ValidationMessage: ss.i18n._t('CMSMAIN.URLSEGMENTVALIDATION'), MaxLength: 50, @@ -58,7 +58,7 @@ * @class Input validation on the Title field * @name ss.EditForm.Title */ - $('#Form_EditForm input[name=Title]').concrete(/** @lends ss.EditForm.Title */{ + $('#Form_EditForm input[name=Title]').entwine(/** @lends ss.EditForm.Title */{ onmatch : function() { var self = this; @@ -76,7 +76,7 @@ // TODO language/logic coupling var isNew = this.val().indexOf("new") == 0; - var suggestion = field.concrete('ss').suggestValue(this.val()); + var suggestion = field.entwine('ss').suggestValue(this.val()); var confirmMessage = ss.i18n.sprintf( ss.i18n._t( 'UPDATEURL.CONFIRM', @@ -100,7 +100,7 @@ * the two radiobuttons and setting the hidden "ParentID" field * @name ss.EditForm.parentTypeSelector */ - $('#Form_EditForm .parentTypeSelector').concrete(/** @lends ss.EditForm.parentTypeSelector */{ + $('#Form_EditForm .parentTypeSelector').entwine(/** @lends ss.EditForm.parentTypeSelector */{ onmatch : function() { var self = this; this.find(':input[name=ParentType]').bind('click', function(e) {self._toggleSelection(e);}); @@ -123,7 +123,7 @@ * based on selection of radiobuttons. * @name ss.Form_EditForm.Access */ - $('#Form_EditForm #CanViewType, #Form_EditForm #CanEditType').concrete(/** @lends ss.Form_EditForm.Access */{ + $('#Form_EditForm #CanViewType, #Form_EditForm #CanEditType').entwine(/** @lends ss.Form_EditForm.Access */{ onmatch: function() { // TODO Decouple var dropdown; @@ -147,7 +147,7 @@ * Visible on readonly older versions of a specific page at the moment. * @name ss.Form_EditForm_action_email */ - $('#Form_EditForm .Actions #Form_EditForm_action_email').concrete(/** @lends ss.Form_EditForm_action_email */{ + $('#Form_EditForm .Actions #Form_EditForm_action_email').entwine(/** @lends ss.Form_EditForm_action_email */{ onclick: function(e) { window.open( 'mailto:?subject=' @@ -166,7 +166,7 @@ * Used for readonly older versions of a specific page. * @name ss.Form_EditForm_action_print */ - $('#Form_EditForm .Actions #Form_EditForm_action_print').concrete(/** @lends ss.Form_EditForm_action_print */{ + $('#Form_EditForm .Actions #Form_EditForm_action_print').entwine(/** @lends ss.Form_EditForm_action_print */{ onclick: function(e) { var printURL = $(this[0].form).attr('action').replace(/\?.*$/,'') + '/printable/' @@ -183,7 +183,7 @@ * @class A "rollback" to a specific version needs user confirmation. * @name ss.Form_EditForm_action_rollback */ - $('#Form_EditForm .Actions #Form_EditForm_action_rollback').concrete(/** @lends ss.Form_EditForm_action_rollback */{ + $('#Form_EditForm .Actions #Form_EditForm_action_rollback').entwine(/** @lends ss.Form_EditForm_action_rollback */{ onclick: function(e) { // @todo i18n var form = this.parents('form:first'), version = form.find(':input[name=Version]').val(), message = ''; diff --git a/javascript/CMSMain.Translatable.js b/javascript/CMSMain.Translatable.js index 3fe3c8a9..3a3f9eaa 100755 --- a/javascript/CMSMain.Translatable.js +++ b/javascript/CMSMain.Translatable.js @@ -1,11 +1,11 @@ (function($) { - $.concrete('ss', function($){ + $.entwine('ss', function($){ /** * @class Dropdown with languages above CMS tree, causing a redirect upon translation * @name ss.CMSMain.LangSelector */ - $('.CMSMain #Form_LangForm').concrete(/** @lends ss.CMSMain.LangSelector */{ + $('.CMSMain #Form_LangForm').entwine(/** @lends ss.CMSMain.LangSelector */{ onmatch: function() { var self = this; @@ -38,7 +38,7 @@ * @name ss.CMSMain.createtranslation * @requires jquery.metadata */ - $('.CMSMain .createTranslation').concrete(/** @lends ss.CMSMain.createtranslation */{ + $('.CMSMain .createTranslation').entwine(/** @lends ss.CMSMain.createtranslation */{ onmatch: function() { var self = this; diff --git a/javascript/CMSMain.Tree.js b/javascript/CMSMain.Tree.js index 824b7cb6..44569e35 100644 --- a/javascript/CMSMain.Tree.js +++ b/javascript/CMSMain.Tree.js @@ -13,11 +13,11 @@ TreeContextMenu = { }, 'Duplicate page and children' : function(treeNode) { // First save the page silently (without confirmation) and then duplicate the page. - jQuery('#Form_EditForm').concrete('ss').ajaxSubmit(null, treeNode.duplicatePageWithChildren.bind(treeNode)); + jQuery('#Form_EditForm').entwine('ss').ajaxSubmit(null, treeNode.duplicatePageWithChildren.bind(treeNode)); }, 'Duplicate just this page' : function(treeNode) { // First save the page silently (without confirmation) and then duplicate the page. - jQuery('#Form_EditForm').concrete('ss').ajaxSubmit(null, treeNode.duplicatePageWithChildren.bind(treeNode)); + jQuery('#Form_EditForm').entwine('ss').ajaxSubmit(null, treeNode.duplicatePageWithChildren.bind(treeNode)); }, 'Sort sub-pages' : function(treeNode) { var children = treeNode.treeNodeHolder().childTreeNodes(); diff --git a/javascript/CMSMain.js b/javascript/CMSMain.js index 26ebb44d..4676390e 100644 --- a/javascript/CMSMain.js +++ b/javascript/CMSMain.js @@ -1,11 +1,11 @@ (function($) { - $.concrete('ss', function($){ + $.entwine('ss', function($){ /** * @class All forms in the right content panel should have closeable jQuery UI style titles. * @name ss.contentPanel.form */ - $('#contentPanel form').concrete(/** @lends ss.contentPanel.form */{ + $('#contentPanel form').entwine(/** @lends ss.contentPanel.form */{ onmatch: function() { // Style as title bar this.find(':header:first').titlebar({ @@ -13,7 +13,7 @@ }); // The close button should close the east panel of the layout this.find(':header:first .ui-dialog-titlebar-close').bind('click', function(e) { - $('body.CMSMain').concrete('ss').getMainLayout().close('east'); + $('body.CMSMain').entwine('ss').getMainLayout().close('east'); return false; }); @@ -27,7 +27,7 @@ * similar to "Smart Search" criteria in iTunes. * @name ss.Form_SeachTreeForm */ - $('#Form_SearchTreeForm').concrete(/** @lends ss.Form_SeachTreeForm */{ + $('#Form_SearchTreeForm').entwine(/** @lends ss.Form_SeachTreeForm */{ /** * @type DOMElement */ @@ -164,7 +164,7 @@ * which creates a new page through #Form_EditForm and adds a new tree node. * @name ss.reports_holder */ - $('#Form_SideReportsForm').concrete(/** @lends ss.reports_holder */{ + $('#Form_SideReportsForm').entwine(/** @lends ss.reports_holder */{ ReportContainer: null, onmatch: function() { @@ -215,7 +215,7 @@ /** * All forms loaded via ajax from the Form_SideReports dropdown. */ - $("#SideReportsHolder form").concrete({ + $("#SideReportsHolder form").entwine({ onsubmit: function() { var self = this; @@ -243,12 +243,12 @@ /** * Register the onclick handler that loads the page into EditForm */ - $("#SideReportsHolder form ul a").concrete({ + $("#SideReportsHolder form ul a").entwine({ onclick: function(e) { if (e.button!=2) { var $link = $(this); $link.addClass('loading'); - jQuery('#Form_EditForm').concrete('ss').loadForm( + jQuery('#Form_EditForm').entwine('ss').loadForm( $(this).attr('href'), function(e) { $link.removeClass('loading'); @@ -265,7 +265,7 @@ * @name ss.Form_VersionsForm * @requires ss.i18n */ - $('#Form_VersionsForm').concrete(/** @lends ss.Form_VersionsForm */{ + $('#Form_VersionsForm').entwine(/** @lends ss.Form_VersionsForm */{ onmatch: function() { var self = this; @@ -309,7 +309,7 @@ var link = $(this).siblings('.versionlink').find('a').attr('href'); td.addClass('loading'); - jQuery('#Form_EditForm').concrete('ss').loadForm( + jQuery('#Form_EditForm').entwine('ss').loadForm( link, function(e) { td.removeClass('loading'); @@ -357,7 +357,7 @@ data.push({name:$button.attr('name'), value: $button.val()}); if(loadEditForm) { - jQuery('#Form_EditForm').concrete('ss').loadForm( + jQuery('#Form_EditForm').entwine('ss').loadForm( this.attr('action'), function(e) { $button.removeClass('loading'); diff --git a/javascript/LeftAndMain.AddForm.js b/javascript/LeftAndMain.AddForm.js index aab57e6f..46667a15 100644 --- a/javascript/LeftAndMain.AddForm.js +++ b/javascript/LeftAndMain.AddForm.js @@ -1,5 +1,5 @@ (function($) { - $.concrete('ss', function($){ + $.entwine('ss', function($){ /** * @class Simple form with a page type dropdown * which creates a new page through #Form_EditForm and adds a new tree node. @@ -7,7 +7,7 @@ * @requires ss.i18n * @requires ss.Form_EditForm */ - $('#Form_AddForm').concrete(/** @lends ss.Form_AddForm */{ + $('#Form_AddForm').entwine(/** @lends ss.Form_AddForm */{ /** * @type DOMElement */ @@ -58,7 +58,7 @@ data.push({name:'Suffix',value:newPages[parentID]++}); data.push({name:button.attr('name'),value:button.val()}); // TODO Should be set by hiddenfield already - jQuery('#Form_EditForm').concrete('ss').loadForm( + jQuery('#Form_EditForm').entwine('ss').loadForm( jQuery(this).attr('action'), function() { button.removeClass('loading'); diff --git a/javascript/LeftAndMain.BatchActions.js b/javascript/LeftAndMain.BatchActions.js index af9a63e5..57e3d8dd 100644 --- a/javascript/LeftAndMain.BatchActions.js +++ b/javascript/LeftAndMain.BatchActions.js @@ -1,5 +1,5 @@ (function($) { - $.concrete('ss', function($){ + $.entwine('ss', function($){ /** * @class Batch actions which take a bunch of selected pages, @@ -12,7 +12,7 @@ * - register: Called before an action is added. * - unregister: Called before an action is removed. */ - $('#Form_BatchActionsForm').concrete(/** @lends ss.Form_BatchActionsForm */{ + $('#Form_BatchActionsForm').entwine(/** @lends ss.Form_BatchActionsForm */{ /** * @type {DOMElement} @@ -156,10 +156,10 @@ // only if the current page was modified selectedNode.selectTreeNode(); } else if(data.deleted[selectedNode.getIdx()]) { - jQuery('#Form_EditForm').concrete('ss').removeForm(); + jQuery('#Form_EditForm').entwine('ss').removeForm(); } } else { - jQuery('#Form_EditForm').concrete('ss').removeForm(); + jQuery('#Form_EditForm').entwine('ss').removeForm(); } // close panel @@ -229,7 +229,7 @@ /** * Publish selected pages action */ - $('#Form_BatchActionsForm').concrete('ss').register('admin/batchactions/publish', function(ids) { + $('#Form_BatchActionsForm').entwine('ss').register('admin/batchactions/publish', function(ids) { var confirmed = confirm( "You have " + ids.length + " pages selected.\n\n" + "Do your really want to publish?" @@ -240,7 +240,7 @@ /** * Unpublish selected pages action */ - $('#Form_BatchActionsForm').concrete('ss').register('admin/batchactions/unpublish', function(ids) { + $('#Form_BatchActionsForm').entwine('ss').register('admin/batchactions/unpublish', function(ids) { var confirmed = confirm( "You have " + ids.length + " pages selected.\n\n" + "Do your really want to unpublish?" @@ -251,7 +251,7 @@ /** * Delete selected pages action */ - $('#Form_BatchActionsForm').concrete('ss').register('admin/batchactions/delete', function(ids) { + $('#Form_BatchActionsForm').entwine('ss').register('admin/batchactions/delete', function(ids) { var confirmed = confirm( "You have " + ids.length + " pages selected.\n\n" + "Do your really want to delete?" @@ -262,7 +262,7 @@ /** * Delete selected pages from live action */ - $('#Form_BatchActionsForm').concrete('ss').register('admin/batchactions/deletefromlive', function(ids) { + $('#Form_BatchActionsForm').entwine('ss').register('admin/batchactions/deletefromlive', function(ids) { var confirmed = confirm( "You have " + ids.length + " pages selected.\n\n" + "Do your really want to delete these pages from live?" diff --git a/javascript/LeftAndMain.EditForm.js b/javascript/LeftAndMain.EditForm.js index d549a901..69fc28d2 100644 --- a/javascript/LeftAndMain.EditForm.js +++ b/javascript/LeftAndMain.EditForm.js @@ -1,5 +1,5 @@ (function($) { - $.concrete('ss', function($){ + $.entwine('ss', function($){ /** * @class Base edit form, provides ajaxified saving @@ -14,7 +14,7 @@ * - removeform: A form is about to be removed from the DOM * - load: Form is about to be loaded through ajax */ - $('#Form_EditForm').concrete(/** @lends ss.Form_EditForm */{ + $('#Form_EditForm').entwine(/** @lends ss.Form_EditForm */{ /** * @type String HTML text to show when no form content is chosen. * Will show inside the