Repository navigation
Description
In a component that uses Vue, <c-fill fallback="..."> lets a caller's fill show the receiving component's slot fallback. Citry compiles that fallback into the caller's template. The first change for #351 (PR #430) records the component calls in that fallback in the caller's data, so a fallback can now hold components. Two kinds of content in that fallback still raise an error, because they need something only the receiving component has.
Given this caller:
<c-Receiver>
<c-fill name="body" fallback="fallback">{{ fallback }}</c-fill>
</c-Receiver>
each of these in Receiver's <c-slot name="body"> fallback raises "so that fallback cannot hold ...":
- A
<c-slot>outlet, such as<c-slot name="inner"><i>inner</i></c-slot>. It chooses its content fromReceiver's slots, but that choice (theselectedSlotsandslotKeysrecords) would still be recorded inReceiver's data, which the caller's template does not read. Let a fallback shown through<c-fill fallback=...>hold a component or a<c-slot>#351 asked for these records to move with the calls. A capturedSlotthat the fallback renders, such as{{ icon }}withicon = slots["icon"]filled by the caller, is refused the same way, as "a '' outlet", although the author wrote no<c-slot>there. - A component given fill content, such as
<c-Child>child fill</c-Child>. Citry passes that fill on through a<slot>in the caller's template, and the caller's own call does not supply it.
Vue bindings that read Vue data, and @c- event handlers, in that fallback also raise an error, on elements and components alike. That is the intended behavior and is not part of this issue: the caller's template cannot reach Receiver's Vue data or handlers.
Two forwarding chains fail with an internal message
Both fail with "direct slot result moved across unrelated receivers: current='citryOccurrence...'", which does not tell the author what to change. They fail even when the fallback holds only plain HTML, such as <i>x</i>:
Receiverputs its<c-slot name="body">inside a fill it gives to another component,Mid, and the caller shows that fallback throughfallback=.- A middle component forwards its own
<c-slot name="mid">intoReceiver's fill that usesfallback=, and the page fillsmidwithfallback=as well.
They fail the same way before the first change for #351.
Activity
fix: let a fallback shown through <c-fill fallback=...> hold components
fix: name what to change when a fallback shown through fill fallback=…
fix: name what to change when a fallback shown through fill fallback=…
JuroOravec commentedon Oct 28, 2026
Decision for 0.7.0: option B. Content inside a fallback shown through
<c-fill fallback=...>that needs the receiving component (a<c-slot>outlet, a component given fill content, a capturedSlot) keeps being refused, with the clear messages from #468. Making it work (option A: record the receiver's slot choices in the caller's data and write every branch into the caller's template) is planned after 0.7.0.