You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Martin Tzvetanov Grigorov (Jira)" <ji...@apache.org> on 2026/02/03 06:42:00 UTC

[jira] [Commented] (WICKET-7175) wicket:enclosure attribute - "Component with id ... was not found" when inner component hidden

    [ https://issues.apache.org/jira/browse/WICKET-7175?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18056113#comment-18056113 ] 

Martin Tzvetanov Grigorov commented on WICKET-7175:
---------------------------------------------------

About 10 years ago (or maybe more) I suggested to deprecate and remove <wicket:enclosure> in favour of EnclosureContainer because of issues like this one. There is a Jira ticket that links to several other tickets listing all known issues with this markup container.

It has been decided that <wicket:enclosure> works well for many use cases and if one faces a problem/limitation with it then (s)he has to rework his/her code to use EnclosureContainer.

> wicket:enclosure attribute - "Component with id ... was not found" when inner component hidden
> ----------------------------------------------------------------------------------------------
>
>                 Key: WICKET-7175
>                 URL: https://issues.apache.org/jira/browse/WICKET-7175
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 8.17.0
>         Environment: Wicket 8.17.0 either Linux or Windows - doesn't matter
>            Reporter: David Rain
>            Priority: Minor
>              Labels: ajax, enclosure
>         Attachments: YesNoDetailsPanel.html, YesNoDetailsPanel.java, ajax-debug.txt, ajax-response-output.png, markup-after.html, markup-before.html
>
>
> If visibility of a component inside a tag with wicket:enclosure attribute is changed from false to true (determined by isVisible) then an javascript error is reported in the Wicket Ajax Debug window (and also in the console).
> It seems that the updated component is included 2x in the AJAX re-paint response. Once alone and second surrounded by the enclosure element.
> Is this beacuse the enclosure auto-tag and the child inside are in-fact at the same hierarchy level?
> I don't know if this has been a known bug on wicket:enclosure attribute? Or if enclosures had been completely abandoned? We're still running Wicket 8 because of JDK8 compatibily.
> I can of course provide a quick start if someone is to bother with this bug.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)