Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Minor Minor
    • Resolution: Unresolved
    • Affects Version/s: 2.1
    • Fix Version/s: None
    • Component/s: Components/Renderers
    • Labels:
      None
    • Environment:

      Apache Tomcat 7.0.34 running in Windows 8

      Description

      Situation:
      A composite component has its attributes declared with the "composite-attribute" tags, one of these attributes is "theme", used to specify the css file to be used by the component.

      <composite:interface>
      <composite:attribute name="theme" required="false" default="rose" />
      ...
      </composite:interface>

      At the component's implementation I try to import the css file using the "h:outputStyleSheet" tag.

      <composite:implementation>
      <h:outputStylesheet library="components" name="calendar/#

      {theme}

      /calendar.css" />
      ...
      </composite:implementation>

      Expected behavior:
      If no attribute "theme" is specified by the page calling the component, "h:outputStylesheet" should import "calendar/rose/calendar.css". If a theme is specified it should import the specified theme.

      Actual behavior:
      "h:outputStylesheet" tries to import "calendar//calendar.css", no matter if a theme was specified or not.

      My thoughts:
      I tried to specify the theme directly inside the EL expression (name="#

      {'rose'}

      "), it worked, so it's not an expression problem. I think the cc.attrs variables are not available when "h:outputStylesheet" is processed.

      There's a similar problem described in Stack Overflow:
      http://stackoverflow.com/questions/7386344/evaluating-the-rendered-attribute-of-houtputstylesheet-inside-a-composite

        Activity

        tiagoperes created issue -
        Ed Burns made changes -
        Field Original Value New Value
        Assignee rogerk [ rogerk ]
        Ed Burns made changes -
        Priority Major [ 3 ] Trivial [ 5 ]
        Manfred Riem made changes -
        Priority Trivial [ 5 ] Minor [ 4 ]

          People

          • Assignee:
            Unassigned
            Reporter:
            tiagoperes
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated: