Skip to content

Commit

Permalink
add missing rebuild
Browse files Browse the repository at this point in the history
  • Loading branch information
tito10047 committed Sep 22, 2024
1 parent 7588448 commit 50430f4
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions src/LiveComponent/assets/dist/live_controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -1667,7 +1667,7 @@ class ElementChanges {
element.classList.remove(...this.removedClasses);
this.styleChanges.getChangedItems().forEach((change) => {
element.style.setProperty(change.name, change.value);
return;

});
this.styleChanges.getRemovedItems().forEach((styleName) => {
element.style.removeProperty(styleName);
Expand Down Expand Up @@ -2040,7 +2040,8 @@ class Component {
}
const headers = backendResponse.response.headers;
if (!headers.get('Content-Type')?.includes('application/vnd.live-component+html') &&
!headers.get('X-Live-Redirect')) {
!headers.get('X-Live-Redirect') &&
!headers.get('X-Live-Delete')) {
const controls = { displayError: true };
this.valueStore.pushPendingPropsBackToDirty();
this.hooks.triggerHook('response:error', backendResponse, controls);
Expand Down Expand Up @@ -2079,6 +2080,10 @@ class Component {
}
return;
}
if (backendResponse.response.headers.get('X-Live-Delete')) {
this.element.remove();
return;
}
this.hooks.triggerHook('loading.state:finished', this.element);
const modifiedModelValues = {};
Object.keys(this.valueStore.getDirtyProps()).forEach((modelName) => {
Expand Down Expand Up @@ -2994,7 +2999,7 @@ class LiveControllerDefault extends Controller {
});
validModifiers.set('self', () => {
if (event.target !== event.currentTarget) {
return;

}
});
validModifiers.set('debounce', (modifier) => {
Expand Down

0 comments on commit 50430f4

Please sign in to comment.