Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

`rcmail.add_element(elm, 'messagemenu')` appends `elm` to wrong element #4791

Closed
rcubetrac opened this issue Mar 11, 2015 · 3 comments

Comments

Projects
None yet
1 participant
@rcubetrac
Copy link

commented Mar 11, 2015

Reported by pavel zubkou on 11 Mar 2015 21:06 UTC as Trac ticket #1490313

Issue can be seen on larry skin.

Steps to reproduce

  • let elm be '<li>Foo</li>'
  • call rcmail.add_element(elm, 'messagemenu') on init
  • notice that elm will be appended to div#messagemenu, not the container inside <ul>

Expected result

elm is expected to be appended to <ul> which has #messagemenu-menu in larry skin.

This expected result can be received via usage of rcube_plugin_api::add_content() on server side. My expectation is that these two methods do the same, namely append element to container.

Actual result

elm is appended to div#messagemenu, thus placing it outside <ul> containing <roundcube:container name="messagemenu" id="messagemenu" />. Which is non intuitive.

Migrated-From: http://trac.roundcube.net/ticket/1490313

@rcubetrac

This comment has been minimized.

Copy link
Author

commented Mar 12, 2015

Comment by @thomascube on 12 Mar 2015 15:34 UTC

That's indeed not as intended. I guess

<roundcube:container name="messagemenu" id="messagemenu" />

should become

<roundcube:container name="messagemenu" id="messagemenu-menu" />

Basically that's the case for all the menu containers.

@rcubetrac

This comment has been minimized.

Copy link
Author

commented Mar 12, 2015

Comment by @thomascube on 12 Mar 2015 15:42 UTC

Fixed in commit [and backported in bb345b4(619891c])

@rcubetrac

This comment has been minimized.

Copy link
Author

commented Mar 12, 2015

Status changed by @thomascube on 12 Mar 2015 15:42 UTC

new => closed

@rcubetrac rcubetrac closed this Mar 12, 2015

@rcubetrac rcubetrac added this to the 1.1.1 milestone Mar 20, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.