Add event for block ejection
This commit is contained in:
parent
3ab119ebf0
commit
7bf32176a7
|
@ -2,6 +2,7 @@ export const Events = {
|
||||||
COMPONENT_CREATED: "component:created",
|
COMPONENT_CREATED: "component:created",
|
||||||
COMPONENT_UPDATED: "component:updated",
|
COMPONENT_UPDATED: "component:updated",
|
||||||
APP_VIEW_PUBLISHED: "app:view_published",
|
APP_VIEW_PUBLISHED: "app:view_published",
|
||||||
|
BLOCK_EJECTED: "block:ejected",
|
||||||
}
|
}
|
||||||
|
|
||||||
export const EventSource = {
|
export const EventSource = {
|
||||||
|
|
|
@ -1287,6 +1287,11 @@ export const getFrontendStore = () => {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Log event
|
||||||
|
analytics.captureEvent(Events.BLOCK_EJECTED, {
|
||||||
|
block: block._component,
|
||||||
|
})
|
||||||
|
|
||||||
// Attach block children back into ejected definition, using the
|
// Attach block children back into ejected definition, using the
|
||||||
// _containsSlot flag to know where to insert them
|
// _containsSlot flag to know where to insert them
|
||||||
const slotContainer = findAllMatchingComponents(
|
const slotContainer = findAllMatchingComponents(
|
||||||
|
|
Loading…
Reference in New Issue