Merge pull request #18783 from nextcloud/fix/sidebar/do-not-wait-domcontentloaded-for-init
Init OCA.Files.Sidebar right away
This commit is contained in:
commit
e886ce7218
|
@ -282,5 +282,5 @@ e.exports=function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t
|
||||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
i.default.use(G.a),i.default.prototype.t=t,window.addEventListener("DOMContentLoaded",(function(){if(window.OCA.Files||(window.OCA.Files={}),Object.assign(window.OCA.Files,{Sidebar:new M}),Object.assign(window.OCA.Files.Sidebar,{Tab:$}),document.getElementById("content")&&!document.getElementById("app-sidebar")){var e=document.getElementById("content"),t=document.createElement("div");t.id="app-sidebar",e.appendChild(t)}new i.default({name:"SidebarRoot",render:function(e){return e(T)}}).$mount("#app-sidebar")}))}]);
|
i.default.use(G.a),i.default.prototype.t=t,window.OCA.Files||(window.OCA.Files={}),Object.assign(window.OCA.Files,{Sidebar:new M}),Object.assign(window.OCA.Files.Sidebar,{Tab:$}),window.addEventListener("DOMContentLoaded",(function(){if(document.getElementById("content")&&!document.getElementById("app-sidebar")){var e=document.getElementById("content"),t=document.createElement("div");t.id="app-sidebar",e.appendChild(t)}new i.default({name:"SidebarRoot",render:function(e){return e(T)}}).$mount("#app-sidebar")}))}]);
|
||||||
//# sourceMappingURL=sidebar.js.map
|
//# sourceMappingURL=sidebar.js.map
|
File diff suppressed because one or more lines are too long
|
@ -30,8 +30,6 @@ Vue.use(VueClipboard)
|
||||||
|
|
||||||
Vue.prototype.t = t
|
Vue.prototype.t = t
|
||||||
|
|
||||||
window.addEventListener('DOMContentLoaded', () => {
|
|
||||||
|
|
||||||
// Init Sidebar Service
|
// Init Sidebar Service
|
||||||
if (!window.OCA.Files) {
|
if (!window.OCA.Files) {
|
||||||
window.OCA.Files = {}
|
window.OCA.Files = {}
|
||||||
|
@ -39,6 +37,7 @@ window.addEventListener('DOMContentLoaded', () => {
|
||||||
Object.assign(window.OCA.Files, { Sidebar: new Sidebar() })
|
Object.assign(window.OCA.Files, { Sidebar: new Sidebar() })
|
||||||
Object.assign(window.OCA.Files.Sidebar, { Tab })
|
Object.assign(window.OCA.Files.Sidebar, { Tab })
|
||||||
|
|
||||||
|
window.addEventListener('DOMContentLoaded', () => {
|
||||||
// Make sure we have a proper layout
|
// Make sure we have a proper layout
|
||||||
if (document.getElementById('content')) {
|
if (document.getElementById('content')) {
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue