Uploaded image for project: 'ZK'
  1. ZK
  2. ZK-2944

Support Shadow element selector

    Details

    • Type: New Feature
    • Status: Closed
    • Priority: Major
    • Resolution: Done
    • Affects Version/s: 8.0.0
    • Fix Version/s: 8.0.1
    • Component/s: None
    • Labels:
      None
    • gh.sprint.customfield.default.name:
      ZK 8.0.1 S1, ZK 8.0.1 S2, ZK 8.0.1 S3

      Description

      For example,

      // zul file
      <div id="div">
          <apply id="sh1">
                <if test="true">
                      <label value="I am here"/>
                </if>
          </apply>
      </div>
      
      List<Component> applies = Selectors.find(page, "::shadow #sh1");
      
      // or
      List<Component> ifs = Selectors.find(page, ":host(#div)::shadow if");
      

      Note: we don't need to support this case. (component in shadow)
      For example,

      #div::shadow if > label
      
      // the user should use the following way instead
      #div > label
      

      The spec. referred from W3 spec.

      ::shadow pseudo element
      /deep/ combinator, which was replaced with a >>> combinator (or shadow piercing descendant combinator)
      ::content pseudo-element
      :host pseudo-class and :host() functional pseudo-class
      :host-context() functional pseudo-class
      

      Reference Link:

        Activity

        Hide
        wenninghsu wenninghsu added a comment -

        ready since 2016/01/11

        Show
        wenninghsu wenninghsu added a comment - ready since 2016/01/11

          People

          • Assignee:
            christopherszu christopherszu
            Reporter:
            jumperchen jumperchen
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Time Tracking

              Estimated:
              Original Estimate - 0 minutes
              0m
              Remaining:
              Remaining Estimate - 0 minutes
              0m
              Logged:
              Time Spent - 4 days
              4d

                Agile