Class WCStories

java.lang.Object
com.vaadin.flow.component.Component
com.flowingcode.vaadin.addons.wcstories.WCStories
All Implemented Interfaces:
AttachNotifier, DetachNotifier, HasComponents, HasElement, HasEnabled, Serializable

@Tag("wc-stories") @NpmPackage(value="web-animations-js",version="2.3.2") @NpmPackage(value="@gugadev/wc-stories",version="1.0.0") @NpmPackage(value="custom-elements-native-shim",version="1.0.0") @JsModule("web-animations-js/web-animations.min.js") @JsModule("./storify/dist/index.js") public class WCStories extends Component implements HasComponents
Wrapper for web component https://github.com/gugadev/wc-stories

This component shows a group of images like Instagram stories or Whatsapp states.

Author:
Paola De Bartolo / Flowing Code
See Also:
  • Constructor Details

    • WCStories

      public WCStories(List<String> storiesPaths)
  • Method Details

    • setRadius

      public void setRadius(Integer radius)
      Sets border radius. Default radius value: 0.
      Parameters:
      radius -
    • setStartAt

      public void setStartAt(Integer startAt)
      Sets initial image index to show. Default index value: 0.
      Parameters:
      startAt -
    • setDuration

      public void setDuration(Integer duration)
      Sets visibility time of images and animation. Default value: 5000.
      Parameters:
      duration -
    • setHeight

      public void setHeight(Integer height)
      Sets stories height. Default value: 480px.
      Parameters:
      height -
    • setWidth

      public void setWidth(Integer width)
      Sets stories width. Default value: 320px.
      Parameters:
      width -
    • setWithShadow

      public void setWithShadow(Boolean withShadow)
      Enable or disable shadow in the container. Default value: disabled (false).
      Parameters:
      withShadow -
    • setStories

      public void setStories(List<WCStoriesStory> stories)
      Add the stories/images to the container.
      Parameters:
      stories -