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

Video supports to add tracks

    XMLWordPrintable

    Details

    • Type: New Feature
    • Status: Closed
    • Priority: Normal
    • Resolution: Done
    • Affects Version/s: 9.1.0
    • Fix Version/s: 9.5.0
    • Component/s: Components
    • Labels:

      Description

      Problem Description

      In order to allow application developers to meet WCAG success criteria including:

      Proposed Specification

      static usage

      Allow application developers to add HTML elements.

      static-track.zul

      <video xmlns:h="native" src="clip.mp4">
      <h:track kind="captions" srclang="en" src="a.txt"/>
      <h:track kind="captions" srclang="en" src="b.txt"/>
      </audio>
      

      dynamic usages

      Audio component provides 2 API to set Track.

      public void setTracks(List<TrackInfo>){}
      
      /**
       * This method is to deal with the HTML track element's new attributes defined in the future. Then before we add new methods in TrackInfo for the new attribute, developers can set the new attributes with a Json object.
       */
      public void setTracks(List<JSONAware>){}
      
      /**
       * A data object that contains information to render <track> element (https://developer.mozilla.org/en-US/docs/Web/HTML/Element/track)
       * It provides setter and getter for attributes e.g. setSrc(), setKind()
       * We name it TrackInfo instead of Track to avoid future name conflict. In case we will create a Track component in the future.
       */
      public class TrackInfo{
      
      }
      

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              rudyhuang rudyhuang
              Reporter:
              hawk hawk
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - 1 day Original Estimate - 1 day
                  1d
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 1 day, 4 hours
                  1d 4h