fix: Alpine.data() avec x-data="wsInit" (sans parenthèses) + cache busting v2.4.6
- Changé function wsInit() → Alpine.data('wsInit', ...) avec addEventListener('alpine:init')
- x-data="wsInit()" → x-data="wsInit" (syntaxe correcte pour Alpine.data)
- Ajouté ?v=2.4.6 sur CSS et JS pour bust le cache navigateur
- Version bumpée à 2.4.6
This commit is contained in:
@@ -336,7 +336,7 @@
|
||||
.preview-leave-end{transform:translateX(100%);opacity:0;}
|
||||
</style>
|
||||
|
||||
<div class="ws-split" x-data="wsInit()"
|
||||
<div class="ws-split" x-data="wsInit"
|
||||
@dragover.prevent="onDragOver($event)"
|
||||
@dragleave="onDragLeave($event)"
|
||||
@drop.prevent="onDrop($event)"
|
||||
@@ -867,8 +867,8 @@
|
||||
</div><!-- /ws-split -->
|
||||
|
||||
<script>
|
||||
function wsInit() {
|
||||
return {
|
||||
document.addEventListener('alpine:init', () => {
|
||||
Alpine.data('wsInit', () => ({
|
||||
tree:[],
|
||||
displayTree:[],
|
||||
breadcrumb: [],
|
||||
@@ -2388,8 +2388,7 @@ function wsInit() {
|
||||
this.selectedIdsCount = Object.keys(this.selectedIds).length;
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
}
|
||||
}))
|
||||
})
|
||||
</script>
|
||||
{% endblock %}
|
||||
|
||||
Reference in New Issue
Block a user