Tapestry
  1. Tapestry
  2. TAPESTRY-822

Tapestry should correctly handle url's to private assets in private-asset stylesheets

    Details

    • Type: Improvement Improvement
    • Status: Resolved
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 4.1
    • Fix Version/s: 4.1
    • Component/s: Framework
    • Labels:
      None

      Description

      CSS allows a designer to place url information into a stylesheet to, for example, specify a background image, as follows:

      background: url('someimage.gif');

      However, tapestry's asset service breaks this ability since it requires a hashed key corresponding to the asset.
      Furthermore, it does not provide any mechanism to "feed" an appropriate url into a stylesheet.

      This is particularly troubling in the case of private-assets. 3rd-party libraries may supply one or more (private-asset) stylesheets and corresponding images.
      The inability to property reference asset urls from the stylesheet results in these libraries having to inline style elements in a fashion similar to:

      <style>
      <span jwcid="@Insert" value="<" raw="yes"/>--
      .someclass

      { background: url("<span jwcid="@Insert" value="ognl:assets.someasset.buildURL(page.requestCycle)"/>"); }

      -->
      </style>

      This is clumsy, ugly, and invalid markup. Furthermore, inlining of the style element precludes the possibility of overriding values
      through an external stylesheet..

        Activity

        Robert Zeigler created issue -
        Hide
        Jesse Kuhnert added a comment -

        Fixed by the addition of a new hivemind configuration point for unprotected resources, which also allows stylesheet relative asset resolution. (To be documented in the next couple of days)

        Show
        Jesse Kuhnert added a comment - Fixed by the addition of a new hivemind configuration point for unprotected resources, which also allows stylesheet relative asset resolution. (To be documented in the next couple of days)
        Jesse Kuhnert made changes -
        Field Original Value New Value
        Fix Version/s 4.1 [ 12310632 ]
        Resolution Fixed [ 1 ]
        Status Open [ 1 ] Resolved [ 5 ]
        Mark Thomas made changes -
        Workflow jira [ 12345108 ] Default workflow, editable Closed status [ 12567607 ]
        Mark Thomas made changes -
        Workflow Default workflow, editable Closed status [ 12567607 ] jira [ 12591964 ]

          People

          • Assignee:
            Unassigned
            Reporter:
            Robert Zeigler
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development