ICEfaces
  1. ICEfaces
  2. ICE-8163

Application specific CSS classes are loaded before ICEfaces CSS when you disable automatic theme loading

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 3.0.1
    • Fix Version/s: 3.2
    • Component/s: None
    • Labels:
      None
    • Environment:
      Glassfish 3.1, Tomcat 7, Chrome, Firefox, Internet Explorer 9
    • Workaround Exists:
      Yes
    • Workaround Description:
      Hide
      A formal fix for this issue depends on a new resource ordering capability in either JSF itself, or possibly ICEfaces. In the meantime, there are two possible workarounds for this issue:

      1. Move the application-level CSS stylesheets into the top of the body region of the page, and out of the head. This will ensure that they are always loaded after the core icefaces stylesheets.

      2. Possibly you could create a custom ThemeRoller theme with essentially empty style sheets and specify that using the org.icefaces.ace.theme config. param.

      Show
      A formal fix for this issue depends on a new resource ordering capability in either JSF itself, or possibly ICEfaces. In the meantime, there are two possible workarounds for this issue: 1. Move the application-level CSS stylesheets into the top of the body region of the page, and out of the head. This will ensure that they are always loaded after the core icefaces stylesheets. 2. Possibly you could create a custom ThemeRoller theme with essentially empty style sheets and specify that using the org.icefaces.ace.theme config. param.

      Description

      Based on http://wiki.icesoft.org/display/ICE/ace.theme you need to set the following parameter to none in order to disable automatic theme loading:

      <context-param>
      <param-name>org.icefaces.ace.theme</param-name>
      <param-value>none</param-value>
      </context-param>

      When you do this, custom application style sheets are loaded first.

      If you remove this parameter custom CSS will appear at the end of the header as specified in release notes:
      http://wiki.icesoft.org/display/ICE/ICEfaces+3.0.1+Release+Notes


      See screen shots for details.
      To reproduce use attached source code.
      1. theme-none-absent.jpg
        147 kB
      2. theme-none-present.jpg
        131 kB

        Issue Links

          Activity

          Evgheni Sadovoi created issue -
          Evgheni Sadovoi made changes -
          Field Original Value New Value
          Attachment theme-none-absent.jpg [ 14462 ]
          Evgheni Sadovoi made changes -
          Attachment theme-none-present.jpg [ 14463 ]
          Evgheni Sadovoi made changes -
          Attachment Case11246Example.zip [ 14464 ]
          Evgheni Sadovoi made changes -
          Salesforce Case [5007000000MFoXr]
          Evgheni Sadovoi made changes -
          Assignee Ken Fyten [ ken.fyten ]
          Evgheni Sadovoi made changes -
          Description Based on http://wiki.icesoft.org/display/ICE/ace.theme you need to set the following parameter to none in order to disable automatic theme loading:

          <context-param>
          <param-name>org.icefaces.ace.theme</param-name>
          <param-value>none</param-value>
          </context-param>

          When you do this, custom application style sheets are loaded first.

          If you remove this parameter custom CSS will appear at the end of the header as specified in release notes:
          http://wiki.icesoft.org/display/ICE/ICEfaces+3.0.1+Release+Notes


          If an application rely on custom styling instead of the default one this regression of ICE-7761 will cause problems when the parameter is removed from web.xml

          See screen shots for details.
          To reproduce use attached source code.
          Based on http://wiki.icesoft.org/display/ICE/ace.theme you need to set the following parameter to none in order to disable automatic theme loading:

          <context-param>
          <param-name>org.icefaces.ace.theme</param-name>
          <param-value>none</param-value>
          </context-param>

          When you do this, custom application style sheets are loaded first.

          If you remove this parameter custom CSS will appear at the end of the header as specified in release notes:
          http://wiki.icesoft.org/display/ICE/ICEfaces+3.0.1+Release+Notes


          See screen shots for details.
          To reproduce use attached source code.
          Hide
          Evgheni Sadovoi added a comment -

          This JIRA is related to the changes we introduced in ICE-7761

          Show
          Evgheni Sadovoi added a comment - This JIRA is related to the changes we introduced in ICE-7761
          Ken Fyten made changes -
          Fix Version/s 3.1.0.BETA2 [ 10336 ]
          Fix Version/s 3.1 [ 10312 ]
          Assignee Priority P1
          Affects Version/s 3.0.1 [ 10282 ]
          Assignee Ken Fyten [ ken.fyten ] Arturo Zambrano [ artzambrano ]
          Ken Fyten made changes -
          Assignee Arturo Zambrano [ artzambrano ] Mircea Toma [ mircea.toma ]
          Mircea Toma made changes -
          Link This issue depends on ICE-8171 [ ICE-8171 ]
          Hide
          Mircea Toma added a comment -

          Chances are that ICE-8171 resolution will fix this issue as well.

          Show
          Mircea Toma added a comment - Chances are that ICE-8171 resolution will fix this issue as well.
          Ken Fyten made changes -
          Assignee Priority P1 P2
          Ken Fyten made changes -
          Fix Version/s 3.1.0.RC1 [ 10337 ]
          Fix Version/s 3.1.0.BETA2 [ 10336 ]
          Ken Fyten made changes -
          Workaround Description A formal fix for this issue depends on a new resource ordering capability in either JSF itself, or possibly ICEfaces. In the meantime, there are two possible workarounds for this issue:

          1. Move the application-level CSS stylesheets into the top of the body region of the page, and out of the head. This will ensure that they are always loaded after the core icefaces stylesheets.

          2. Possibly you could create a custom ThemeRoller theme with essentially empty style sheets and specify that using the org.icefaces.ace.theme config. param.

          Workaround Exists [Yes]
          Fix Version/s 3.2 [ 10338 ]
          Fix Version/s 3.1 [ 10312 ]
          Fix Version/s 3.1.0.RC1 [ 10337 ]
          Assignee Priority P2
          Repository Revision Date User Message
          ICEsoft Public SVN Repository #30402 Tue Aug 07 14:50:15 MDT 2012 mircea.toma ICE-8163 Modified HeadRenderer to add theme related CSS resources to the component tree before render phase. This way the resource ordering can be properly applied to all the resources that need to be rendered in the page. Added resource dependency metadata for the themes to make sure they get loaded after the component related CSS styles.
          Files Changed
          Commit graph MODIFY /icefaces3/trunk/icefaces/ace/component/resources/icefaces.ace/META-INCLUDE/resource-dependency.xml
          Commit graph MODIFY /icefaces3/trunk/icefaces/ace/component/src/org/icefaces/ace/renderkit/HeadRenderer.java
          Hide
          Mircea Toma added a comment - - edited

          Modified HeadRenderer to add theme related CSS resources to the component tree before render phase (modeled after h:outputStylesheet renderer). This way the resource ordering can be properly applied to all the resources that need to be rendered in the page. Added resource dependency metadata for the themes to make sure they get loaded after the component related CSS styles.

          Show
          Mircea Toma added a comment - - edited Modified HeadRenderer to add theme related CSS resources to the component tree before render phase (modeled after h:outputStylesheet renderer). This way the resource ordering can be properly applied to all the resources that need to be rendered in the page. Added resource dependency metadata for the themes to make sure they get loaded after the component related CSS styles.
          Mircea Toma made changes -
          Status Open [ 1 ] Resolved [ 5 ]
          Resolution Fixed [ 1 ]
          Hide
          Mircea Toma added a comment -

          Modified attached test case to use h:outputStylesheet tag instead of the HTML 'link' tag, this way the resource is added to the head. Later on the resource is ordered based on the resource dependency metadata saved in WEB-INF/classes/META-INF/resource-dependency.xml file.

          Show
          Mircea Toma added a comment - Modified attached test case to use h:outputStylesheet tag instead of the HTML 'link' tag, this way the resource is added to the head. Later on the resource is ordered based on the resource dependency metadata saved in WEB-INF/classes/META-INF/resource-dependency.xml file.
          Mircea Toma made changes -
          Attachment Case11246Example.fixed.zip [ 14781 ]
          Ken Fyten made changes -
          Status Resolved [ 5 ] Closed [ 6 ]

            People

            • Assignee:
              Mircea Toma
              Reporter:
              Evgheni Sadovoi
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: