Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Context Menu - data-webworks-context breaks down when your Header or Subheader has a " in it #758

Closed
bearisgaming opened this Issue · 3 comments

2 participants

@bearisgaming

When a list or other item autogenerates context menus for each item it adds a data-webworks-context item to itself that contains most of the data in the node. However because this is JSON encoded with " " surrounding the field, the text in the either the title or body of the node cannot contains a ". This breaks the field's string and it no longer parses as valid JSON and execution stops and the context menu does not appear to be correctly bound.

So for example I couldn't have the following text -

Bob said "BBui.js is fun".

Or more usefully -

<div class="some-class">some content that has custom presentation</div>
@tneil
Owner
@bearisgaming

That works for the first example. However I failed at marking my code blocks right and the second is wrapped in

<div class="some-class"></div>

Which although I forced my code to use single ' for classes here it still rendered into the DOM using " around the attributes for all my tags and as a result ends up in the data-webworks-context the same way.

@tneil tneil referenced this issue from a commit
Tim Neil fixes for context menu with quotes for issue #758 697287e
@tneil
Owner

This should now be fixed with the latest check in

@tneil tneil closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.