[richfaces-issues] [JBoss JIRA] Commented: (RF-1838) togglePanel with switchType="ajax" renders wrong <a href> stuff after request response phase
Benno Markiewicz (JIRA)
jira-events at lists.jboss.org
Tue Jan 8 12:17:44 EST 2008
[ http://jira.jboss.com/jira/browse/RF-1838?page=comments#action_12394198 ]
Benno Markiewicz commented on RF-1838:
--------------------------------------
Can confirm this issue when rerendering a commandLink with child items.
Look at the pseudocode to see what i mean.
<aj4:commandLink>
<div />
</aj4:commandLink>
will be rerendered to
<aj4:commandLink/>
<div />
> togglePanel with switchType="ajax" renders wrong <a href> stuff after request response phase
> --------------------------------------------------------------------------------------------
>
> Key: RF-1838
> URL: http://jira.jboss.com/jira/browse/RF-1838
> Project: RichFaces
> Issue Type: Bug
> Affects Versions: 3.1.3
> Environment: tomcat 6.0.14, jdk 1.5
> Reporter: Thomas Wabner
> Assigned To: Alexej Kushunin
> Fix For: 3.2.0
>
>
> I have follow simple ui component created:
> <rich:togglePanel stateOrder="closed,show" switchType="ajax">
> <f:facet name="closed">
> <h:panelGrid columns="1" width="100%">
> <rich:toggleControl switchToState="show" >
> <div style="background-color: aqua; width: 100%; cursor: pointer;"><h:outputText
> value="#{uiMessages['panel_property_header']}" /><br />
> <h:outputText value="#{property.currentProperty}"></h:outputText></div>
> </rich:toggleControl>
> </h:panelGrid>
> </f:facet>
> <f:facet name="show">
> <h:panelGrid columns="1" width="100%">
> <rich:toggleControl switchToState="closed">
> <div style="background-color: aqua; width: 100%; cursor: pointer"><h:outputText
> value="#{uiMessages['panel_property_header']}" /></div>
> </rich:toggleControl>
> </h:panelGrid>
> </f:facet>
> </rich:togglePanel>
> </ui:component>
> ##################
> Problem with this ui component is the switchType="ajax". If I set the type to "server" the component works as expected.
> The component should show initial the "closed" facet, which should render a click able div element (with text some text e.g. "show").
> After clicking the "show" text, the show facet should be rendered, which contains also a click able div element.
> This element should switch the state to "closed" after clicking on the div element.
> ------
> After looking into the rendered html output there is a <a href="...."> element is rendered which contains the div element for the close facet. The </a> comes correct after the facet output.
> Now if the closed facet is rendered, the <a href="..."/> element is closed before the div element comes. Now the div element is no more click able. This happens only for the switchType="ajax".
> I have not found any documentation or hint how to do this in another way. The toggleControl element works if I set only a value and not to include some other elements inside the toggleControl element. But if this is the only way to create a toggle control I was wondering how the simpleTogglePanel work. Because the documentation say for simpleTogglePanel "this panel is a simple solution for the togglePanel ...".
> - Thomas Wabner
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the richfaces-issues
mailing list