Skip to content

Inline styles and Content Security Policy #2423

@penartur

Description

@penartur

As of now, Chosen for JQuery does not work correctly when inline styles usage is forbidden by an appropriate Content-Security-Policy.
The problem is that, when it creates the "chosen" menu in set_up_html, it uses "style" param to specify width:

'style': "width: #{this.container_width()};"

JQuery supports specifying the width directly (not by CSS properties): http://api.jquery.com/width/ ; this one should solve the problem.

Unfortunately, writing front-end JS compatible across different browsers (and testing it) is not my strong side, so I'll only create this issue, and will not supply any pull request with it.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions