2014-12-16 20:43:22 +01:00
|
|
|
window.wp = window.wp || {};
|
2015-09-25 23:01:46 +02:00
|
|
|
window.wp.customize = window.wp.customize || { get: function() {} };
|
2014-12-16 20:43:22 +01:00
|
|
|
|
|
|
|
var customizerRootElement;
|
|
|
|
customizerRootElement = jQuery( '<div id="customize-theme-controls"><ul></ul></div>' );
|
2015-09-25 23:01:46 +02:00
|
|
|
customizerRootElement.css( { position: 'absolute', left: -10000, top: -10000 } ); // Remove from view.
|
2014-12-16 20:43:22 +01:00
|
|
|
jQuery( document.body ).append( customizerRootElement );
|
|
|
|
|
|
|
|
window._wpCustomizeSettings = {
|
|
|
|
'autofocus': {},
|
|
|
|
'browser': {
|
|
|
|
'ios': false,
|
|
|
|
'mobile': false
|
|
|
|
},
|
|
|
|
'controls': {
|
|
|
|
'fixture-control': {
|
|
|
|
'active': true,
|
2015-05-30 02:02:13 +02:00
|
|
|
'content': '<li id="accordion-section-fixture-section" class="accordion-section control-section control-section-default"> <h3 class="accordion-section-title" tabindex="0"> Section Fixture <span class="screen-reader-text">Press return or enter to open</span> </h3> <ul class="accordion-section-content"> <li class="customize-section-description-container"> <div class="customize-section-title"> <button class="customize-section-back" tabindex="-1"> <span class="screen-reader-text">Back</span> </button> <h3> <span class="customize-action">Customizing ▸ Fixture Panel</span> Section Fixture </h3> </div> </li> </ul> </li>',
|
2014-12-16 20:43:22 +01:00
|
|
|
'description': '',
|
|
|
|
'instanceNumber': 8,
|
|
|
|
'label': 'Fixture Control',
|
|
|
|
'priority': 10,
|
|
|
|
'section': 'fixture-section',
|
|
|
|
'settings': {
|
|
|
|
'default': 'fixture-setting'
|
|
|
|
},
|
|
|
|
'type': 'text'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
'documentTitleTmpl': 'Customize: %s',
|
|
|
|
'nonce': {
|
|
|
|
'preview': '',
|
|
|
|
'save': ''
|
|
|
|
},
|
|
|
|
'panels': {
|
|
|
|
'fixture-panel': {
|
|
|
|
'active': true,
|
2015-05-30 02:02:13 +02:00
|
|
|
'content': '<li id="accordion-panel-fixture-panel" class="accordion-section control-section control-panel control-panel-default"> <h3 class="accordion-section-title" tabindex="0"> Fixture Panel <span class="screen-reader-text">Press return or enter to open this panel</span> </h3> <ul class="accordion-sub-container control-panel-content"> <li class="panel-meta customize-info accordion-section cannot-expand"> <button class="customize-panel-back" tabindex="-1"><span class="screen-reader-text">Back</span></button> <div class="accordion-section-title"> <span class="preview-notice">You are customizing <strong class="panel-title">Fixture Panel</strong></span> <button class="customize-help-toggle dashicons dashicons-editor-help" tabindex="0" aria-expanded="false"><span class="screen-reader-text">Help</span></button> </div> </li> </ul> </li>',
|
2014-12-16 20:43:22 +01:00
|
|
|
'description': 'Lorem ipsum',
|
|
|
|
'instanceNumber': 1,
|
|
|
|
'priority': 110,
|
2015-05-30 02:02:13 +02:00
|
|
|
'title': 'Fixture panel with content',
|
2014-12-16 20:43:22 +01:00
|
|
|
'type': 'default'
|
2015-05-30 02:02:13 +02:00
|
|
|
},
|
|
|
|
'fixture-panel-default-templated': {
|
|
|
|
'active': true,
|
|
|
|
'description': 'Lorem ipsum',
|
|
|
|
'instanceNumber': 2,
|
|
|
|
'priority': 110,
|
|
|
|
'title': 'Fixture default panel using template',
|
|
|
|
'type': 'default'
|
|
|
|
},
|
|
|
|
'fixture-panel-titleless-templated': {
|
|
|
|
'active': true,
|
|
|
|
'description': 'Lorem ipsum',
|
|
|
|
'instanceNumber': 3,
|
|
|
|
'priority': 110,
|
|
|
|
'title': 'Fixture titleless panel using template',
|
|
|
|
'type': 'titleless'
|
2015-06-02 00:46:56 +02:00
|
|
|
},
|
|
|
|
'fixture-panel-reusing-default-template': {
|
|
|
|
'active': true,
|
|
|
|
'description': 'Lorem ipsum',
|
|
|
|
'instanceNumber': 3,
|
|
|
|
'priority': 110,
|
|
|
|
'title': 'Fixture panel of custom type re-using default template',
|
|
|
|
'type': 'reusing-default-template'
|
|
|
|
},
|
|
|
|
'fixture-panel-without-params': {}
|
2014-12-16 20:43:22 +01:00
|
|
|
},
|
|
|
|
'sections': {
|
|
|
|
'fixture-section': {
|
|
|
|
'active': true,
|
2015-05-30 02:02:13 +02:00
|
|
|
'content': '<li id="accordion-section-fixture-section" class="accordion-section control-section control-section-default"> <h3 class="accordion-section-title" tabindex="0"> Section Fixture <span class="screen-reader-text">Press return or enter to open</span> </h3> <ul class="accordion-section-content"> <li class="customize-section-description-container"> <div class="customize-section-title"> <button class="customize-section-back" tabindex="-1"> <span class="screen-reader-text">Back</span> </button> <h3> <span class="customize-action">Customizing ▸ Fixture Panel</span> Section Fixture </h3> </div> </li> </ul> </li>',
|
2014-12-16 20:43:22 +01:00
|
|
|
'description': '',
|
|
|
|
'instanceNumber': 2,
|
|
|
|
'panel': 'fixture-panel',
|
|
|
|
'priority': 20,
|
|
|
|
'title': 'Fixture Section',
|
|
|
|
'type': 'default'
|
2015-05-30 02:02:13 +02:00
|
|
|
},
|
|
|
|
'fixture-section-default-templated': {
|
|
|
|
'active': true,
|
|
|
|
'description': '',
|
|
|
|
'instanceNumber': 3,
|
|
|
|
'panel': 'fixture-panel',
|
|
|
|
'priority': 20,
|
|
|
|
'title': 'Fixture default section using template',
|
|
|
|
'type': 'default'
|
|
|
|
},
|
|
|
|
'fixture-section-titleless-templated': {
|
|
|
|
'active': true,
|
|
|
|
'description': '',
|
|
|
|
'instanceNumber': 4,
|
|
|
|
'panel': 'fixture-panel',
|
|
|
|
'priority': 20,
|
|
|
|
'title': 'Fixture titleless section using template',
|
|
|
|
'type': 'titleless'
|
2015-06-02 00:46:56 +02:00
|
|
|
},
|
|
|
|
'fixture-section-reusing-default-template': {
|
|
|
|
'active': true,
|
|
|
|
'description': '',
|
|
|
|
'instanceNumber': 4,
|
|
|
|
'panel': 'fixture-panel',
|
|
|
|
'priority': 20,
|
|
|
|
'title': 'Fixture section of custom type re-using default template',
|
|
|
|
'type': 'reusing-default-template'
|
|
|
|
},
|
|
|
|
'fixture-section-without-params': {}
|
2014-12-16 20:43:22 +01:00
|
|
|
},
|
|
|
|
'settings': {
|
|
|
|
'fixture-setting': {
|
|
|
|
'transport': 'postMessage',
|
|
|
|
'value': 'Lorem Ipsum'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
'theme': {
|
|
|
|
'active': true,
|
|
|
|
'stylesheet': 'twentyfifteen'
|
|
|
|
},
|
|
|
|
'url': {
|
|
|
|
'activated': 'http://example.org/wp-admin/themes.php?activated=true&previewed',
|
|
|
|
'ajax': '/wp-admin/admin-ajax.php',
|
|
|
|
'allowed': [
|
|
|
|
'http://example.org/'
|
|
|
|
],
|
|
|
|
'fallback': 'http://example.org/?preview=1&template=twentyfifteen&stylesheet=twentyfifteen&preview_iframe=1&TB_iframe=true',
|
|
|
|
'home': 'http://example.org/',
|
|
|
|
'isCrossDomain': false,
|
|
|
|
'login': 'http://example.org/wp-login.php?interim-login=1&customize-login=1',
|
|
|
|
'parent': 'http://example.org/wp-admin/',
|
|
|
|
'preview': 'http://example.org/'
|
|
|
|
}
|
|
|
|
};
|
|
|
|
window._wpCustomizeControlsL10n = {};
|
2015-07-08 07:37:37 +02:00
|
|
|
|
|
|
|
jQuery.ajaxSetup( {
|
|
|
|
beforeSend: function( e, data ) {
|
2015-08-03 21:27:27 +02:00
|
|
|
if ( data.url.indexOf( '//example.org' ) !== -1 ) {
|
2015-07-08 07:37:37 +02:00
|
|
|
return false;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
} );
|