Uploaded image for project: 'MyFaces Trinidad'
  1. MyFaces Trinidad
  2. TRINIDAD-1937

beef up -tr-property-ref to work in compact css properties like border

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 2.0.0-beta-1
    • Skinning
    • None

    Description

      We have compact css properties in our skin files, like

      border: red solid 2px;

      We also have a -tr-property-ref feature so you can set the property to
      another selector's property value.

      .AFDarkColor

      { color: #cccccc}

      .AFDarkBG

      {background-color: -tr-property-ref("color", ".AFDarkColor")}

      But currently -tr-property-ref does not work within a compact css property.

      We would like to do this:

      border: -tr-property-ref("color", ".AFDarkColor"); solid 2px;

      We worked around not having this feature by breaking out border: red solid
      2px into verbose styles

      border-style: solid;
      border-width: 2px;
      border-color: -tr-property-ref("color", ".AFDarkColor");

      , but this is not backward compatible; it might break a person's skin
      extension.

      If someone skinned
      border: purple solid 2px, they will overwrite the current border: red solid
      2px. The merged property is border: purple solid 2px;

      But if we changed our skin to be border-style, border-width, border-color,
      then their border override isn't overriding any more since it is a different
      property. border vs border-style, etc.
      So the properties get merged to border, border-style, border-width,
      border-color. And we currently cannot rely on the ordering of the css
      properties, so they could get border: purple solid 2px; border-style: solid;
      border-width: 2px; border-color: red.

      Attachments

        Activity

          People

            jeanne.waldman@oracle.com Jeanne Waldman
            jeanne.waldman@oracle.com Jeanne Waldman
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: