ICEfaces
  1. ICEfaces
  2. ICE-5481

Sparkle: create slider component using YUI3 slider

    Details

    • Type: New Feature New Feature
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0-Alpha3
    • Fix Version/s: 2.0-Beta2, 2.0.0
    • Component/s: ICE-Components
    • Labels:
      None
    • Environment:
      slider
    • Affects:
      Documentation (User Guide, Ref. Guide, etc.), Sample App./Tutorial

      Description

      Sparkle: create slider component using YUI3 slider

        Activity

        Hide
        Adnan Durrani added a comment -

        Basic slider component added

        Adding: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.slider
        Adding: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.slider\slider.js
        Modified: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.util\util.js
        Adding: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.util\yui3.js
        Adding: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider
        Adding: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\Slider.java
        Adding: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\SliderMeta.java
        Adding: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\SliderRenderer.java
        Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.slider\slider.js
        Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.util\yui3.js
        Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\Slider.java
        Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.util\util.js
        Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\SliderMeta.java
        Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\SliderRenderer.java
        Completed: At revision: 20874

        Show
        Adnan Durrani added a comment - Basic slider component added Adding: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.slider Adding: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.slider\slider.js Modified: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.util\util.js Adding: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.util\yui3.js Adding: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider Adding: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\Slider.java Adding: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\SliderMeta.java Adding: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\SliderRenderer.java Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.slider\slider.js Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.util\yui3.js Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\Slider.java Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.util\util.js Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\SliderMeta.java Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\SliderRenderer.java Completed: At revision: 20874
        Hide
        Adnan Durrani added a comment -
        • style, styleClass and thumbImage attribute added

        Modified: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.slider\slider.js
        Modified: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.util\util.js
        Modified: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\SliderMeta.java
        Modified: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\SliderRenderer.java
        Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.slider\slider.js
        Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.util\util.js
        Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\SliderMeta.java
        Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\SliderRenderer.java
        Completed: At revision: 20878

        Show
        Adnan Durrani added a comment - style, styleClass and thumbImage attribute added Modified: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.slider\slider.js Modified: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.util\util.js Modified: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\SliderMeta.java Modified: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\SliderRenderer.java Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.slider\slider.js Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\resources\org.icefaces.component.util\util.js Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\SliderMeta.java Sending content: D:\work\development\head\svn\ossrepo\icefaces\scratchpads\sparkle\component\src\org\icefaces\component\slider\SliderRenderer.java Completed: At revision: 20878
        Hide
        Ken Fyten added a comment -

        I finally found out what was the problem with the Slider CSS issues. The problem is simply that we are using YUI3 version 3.0.0, and the newest version is 3.1.1. From 3.0.0 to 3.1.0 the CSS class names and hierarchy changed substantially. If we simply use the correct CSS class names, then the styles are applied normally. You can try adding this to the slider demo pages inside a <style> element:

        .yui-skin-sam .yui-slider-rail-x

        { background-image: url(http://yui.yahooapis.com/3.1.0/build/slider/assets/skins/capsule-dark/rail-x.png); background-repeat: repeat-x; }

        .yui-skin-sam .yui-slider-rail-y

        { background-image: url(http://yui.yahooapis.com/3.1.0/build/slider/assets/skins/capsule-dark/rail-y.png); background-repeat: repeat-y; }

        So, for now I can simply adjust the skin CSS files to use version 3.0.0 class names, unless we decide to use the 3.1.0 version of slider. I suppose it would be better to wait until the YUI team comes up with something definite.

        However, this still does not fix the fact that YUI3 dynamically loads needed dependencies, including CSS files, which impedes overriding styles by using external CSS files. One option would be to enhance the outputStyle component to dynamically load any specified CSS files after YUI3 is done loading the files it requires.

        Art

        Show
        Ken Fyten added a comment - I finally found out what was the problem with the Slider CSS issues. The problem is simply that we are using YUI3 version 3.0.0, and the newest version is 3.1.1. From 3.0.0 to 3.1.0 the CSS class names and hierarchy changed substantially. If we simply use the correct CSS class names, then the styles are applied normally. You can try adding this to the slider demo pages inside a <style> element: .yui-skin-sam .yui-slider-rail-x { background-image: url(http://yui.yahooapis.com/3.1.0/build/slider/assets/skins/capsule-dark/rail-x.png); background-repeat: repeat-x; } .yui-skin-sam .yui-slider-rail-y { background-image: url(http://yui.yahooapis.com/3.1.0/build/slider/assets/skins/capsule-dark/rail-y.png); background-repeat: repeat-y; } So, for now I can simply adjust the skin CSS files to use version 3.0.0 class names, unless we decide to use the 3.1.0 version of slider. I suppose it would be better to wait until the YUI team comes up with something definite. However, this still does not fix the fact that YUI3 dynamically loads needed dependencies, including CSS files, which impedes overriding styles by using external CSS files. One option would be to enhance the outputStyle component to dynamically load any specified CSS files after YUI3 is done loading the files it requires. Art
        Hide
        Ken Fyten added a comment -

        Please port the slider to use the latest YUI 3.x release, which will also address the CSS styling issues.

        Show
        Ken Fyten added a comment - Please port the slider to use the latest YUI 3.x release, which will also address the CSS styling issues.
        Hide
        Arturo Zambrano added a comment -

        committed changes to use YUI 3.1.1 at revision 21417
        committed changes to download yui resources from local server, and not from yahoo servers, at revision 21426

        Show
        Arturo Zambrano added a comment - committed changes to use YUI 3.1.1 at revision 21417 committed changes to download yui resources from local server, and not from yahoo servers, at revision 21426
        Hide
        Mark Collette added a comment -

        Slider is an input component, so its singleSubmit/partialSubmit property should govern whether it does a singleSubmit to the server of itself, or whether it only updates a hidden input field and submits nothing, leaving it up to a submit button to submit the whole form later on. Currently, it's acting like a command component, where it's always doing a submit, but when it's true, it singleSubmits, and when it's false it does a full form submit.

        Show
        Mark Collette added a comment - Slider is an input component, so its singleSubmit/partialSubmit property should govern whether it does a singleSubmit to the server of itself, or whether it only updates a hidden input field and submits nothing, leaving it up to a submit button to submit the whole form later on. Currently, it's acting like a command component, where it's always doing a submit, but when it's true, it singleSubmits, and when it's false it does a full form submit.
        Hide
        Ken Fyten added a comment -

        Reminder that we still need a rime skin created for this component.

        Show
        Ken Fyten added a comment - Reminder that we still need a rime skin created for this component.
        Hide
        Ken Fyten added a comment - - edited

        SliderEntry component has the following noted outstanding tasks/issues:

        Component Name:

        • Rename/repackage component to "SliderEntry", incl. comp. name, tag name ("sliderEntry"), all classnames, componentFamily, etc.
        • Change componentFamily to "org.icefaces.component.SliderEntry"

        Attributes:

        • Following attribute appears to be missing:
        • disabled
        • clickableRail, "slideStart" seems like an none-useful mode (remove?).

        Documentation:

        • Component level descriptive doc all but missing from TLD/taglib doc. This can be brief summation with link to the Wiki doc page.
        • Remove references to "Pass through to YUI...":
        • axis
        • min
        • max
        • length
        • value
        • The following attributes have insufficient doc descriptions:
        • singleSubmit (use std. description)
        • immediate (inherited?)
        • valueChangeListener (should be inherited?)
        • slideInterval (needs desc. of what it actually does/affects).
        • thumbUrl
        • submitOn
        • clickableRail
        • Wiki user doc:
        • No high-level component description at all
        • Remove references to YUI and YUI attributes.

        SliderMeta:

        • @ResourceDependency "yui3.js" this file is now empty, this should be removed.

        SliderRenderer:

        • String finalScript = "ice.yui3.slider.updateProperties(" + params + ");"; (Other comps use ice.component.slider type of pattern)

        Slider:

        • broadcast: The new generated getter/setter methods will handle some of the logic done here for setting the value.
        Show
        Ken Fyten added a comment - - edited SliderEntry component has the following noted outstanding tasks/issues: Component Name: Rename/repackage component to "SliderEntry", incl. comp. name, tag name ("sliderEntry"), all classnames, componentFamily, etc. Change componentFamily to "org.icefaces.component.SliderEntry" Attributes: Following attribute appears to be missing: disabled clickableRail, "slideStart" seems like an none-useful mode (remove?). Documentation: Component level descriptive doc all but missing from TLD/taglib doc. This can be brief summation with link to the Wiki doc page. Remove references to "Pass through to YUI...": axis min max length value The following attributes have insufficient doc descriptions: singleSubmit (use std. description) immediate (inherited?) valueChangeListener (should be inherited?) slideInterval (needs desc. of what it actually does/affects). thumbUrl submitOn clickableRail Wiki user doc: No high-level component description at all Remove references to YUI and YUI attributes. SliderMeta: @ResourceDependency "yui3.js" this file is now empty, this should be removed. SliderRenderer: String finalScript = "ice.yui3.slider.updateProperties(" + params + ");"; (Other comps use ice.component.slider type of pattern) Slider: broadcast: The new generated getter/setter methods will handle some of the logic done here for setting the value.
        Hide
        yip.ng added a comment -

        Name change done.

        Revision: 22657


        Modified : /icefaces/scratchpads/sparkle/component/build.xml
        Deleted : /icefaces/scratchpads/sparkle/component/resources/org.icefaces.component.slider
        Added : /icefaces/scratchpads/sparkle/component/resources/org.icefaces.component.sliderentry (Copy from path: /icefaces/scratchpads/sparkle/component/resources/org.icefaces.component.slider, Revision, 22655)
        Deleted : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/slider
        Added : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry (Copy from path: /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/slider, Revision, 22655)
        Deleted : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/Slider.java
        Added : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntry.java
        Added : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryMeta.java
        Added : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryRenderer.java
        Deleted : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderMeta.java
        Deleted : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderRenderer.java

        Show
        yip.ng added a comment - Name change done. Revision: 22657 Modified : /icefaces/scratchpads/sparkle/component/build.xml Deleted : /icefaces/scratchpads/sparkle/component/resources/org.icefaces.component.slider Added : /icefaces/scratchpads/sparkle/component/resources/org.icefaces.component.sliderentry (Copy from path: /icefaces/scratchpads/sparkle/component/resources/org.icefaces.component.slider, Revision, 22655) Deleted : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/slider Added : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry (Copy from path: /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/slider, Revision, 22655) Deleted : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/Slider.java Added : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntry.java Added : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryMeta.java Added : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryRenderer.java Deleted : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderMeta.java Deleted : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderRenderer.java
        Hide
        yip.ng added a comment -

        @ResourceDependency "yui3.js" removed.

        Revision: 22659


        Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryMeta.java

        Show
        yip.ng added a comment - @ResourceDependency "yui3.js" removed. Revision: 22659 Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryMeta.java
        Hide
        yip.ng added a comment -

        References to "Pass through to YUI..." removed.

        Revision: 22661


        Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryMeta.java

        Show
        yip.ng added a comment - References to "Pass through to YUI..." removed. Revision: 22661 Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryMeta.java
        Hide
        yip.ng added a comment -

        ice.yui3.slider changed to ice.component.slider.

        Revision: 22662


        Modified : /icefaces/scratchpads/sparkle/component/resources/org.icefaces.component.sliderentry/slider.js
        Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryRenderer.java
        Modified : /icefaces/scratchpads/sparkle/showcase/test/web/slider.xhtml

        Show
        yip.ng added a comment - ice.yui3.slider changed to ice.component.slider. Revision: 22662 Modified : /icefaces/scratchpads/sparkle/component/resources/org.icefaces.component.sliderentry/slider.js Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryRenderer.java Modified : /icefaces/scratchpads/sparkle/showcase/test/web/slider.xhtml
        Hide
        yip.ng added a comment -

        broadcast() changed to use setValue() inherited from slider entry base class.

        Revision: 22663


        Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntry.java

        Show
        yip.ng added a comment - broadcast() changed to use setValue() inherited from slider entry base class. Revision: 22663 Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntry.java
        Hide
        yip.ng added a comment -

        disabled attribute added. However, when passed to the YUI widget, the widget seems to only add a disabled style class to the bounding box. The widget itself doesn't seem to be disabled at all.

        Revision: 22674


        Modified : /icefaces/scratchpads/sparkle/component/resources/org.icefaces.component.sliderentry/slider.js
        Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryMeta.java
        Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryRenderer.java

        Show
        yip.ng added a comment - disabled attribute added. However, when passed to the YUI widget, the widget seems to only add a disabled style class to the bounding box. The widget itself doesn't seem to be disabled at all. Revision: 22674 Modified : /icefaces/scratchpads/sparkle/component/resources/org.icefaces.component.sliderentry/slider.js Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryMeta.java Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryRenderer.java
        Hide
        yip.ng added a comment -

        Changed slideStart to be not applicable to clickableRail.

        Revision: 22676


        Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryRenderer.java

        Show
        yip.ng added a comment - Changed slideStart to be not applicable to clickableRail. Revision: 22676 Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryRenderer.java
        Hide
        yip.ng added a comment - - edited

        TLD doc updated.

        Revision: 22679


        Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryMeta.java

        Revision: 22685


        Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryMeta.java

        Show
        yip.ng added a comment - - edited TLD doc updated. Revision: 22679 Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryMeta.java Revision: 22685 Modified : /icefaces/scratchpads/sparkle/component/src/org/icefaces/component/sliderentry/SliderEntryMeta.java
        Hide
        yip.ng added a comment -

        Wiki doc updated.

        Show
        yip.ng added a comment - Wiki doc updated.

          People

          • Assignee:
            yip.ng
            Reporter:
            Adnan Durrani
          • Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: