Interface ICoachmark<I extends IAnyGroup>
- All Superinterfaces:
IAnyGroup<ICoachmark<I>>,IChildable<ICoachmark<I>,,I> IComponent<ICoachmark<I>>,IHtmlBasedComponent<ICoachmark<I>>,IXulElement<ICoachmark<I>>
Coachmark component
A coachmark component.
A coachmark is used to attract users' attention to the target component.
The coachmarks are suitable for guiding user operations, they should be as relevant as possible to the context.
Support @Action
| Name | Action Type |
|---|---|
| onOpen | ActionData: OpenData
Denotes that the user has opened or closed a component. |
| onTargetClick | ActionData: MouseData
Represents an event caused by a user's click on a highlighted target component. |
- Author:
- katherine
- See Also:
-
Coachmark
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic classICoachmark.Builder<I extends IAnyGroup>Builds instances of typeICoachmark.static enumSpecify a popup's position when attaching to a component.static classBuilds an updater of typeICoachmarkforUiAgent.smartUpdate(Locator, SmartUpdater). -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ICoachmark<IAnyGroup>Constant for default attributes of this immutable component. -
Method Summary
Modifier and TypeMethodDescriptiondefault StringgetId()Returns the ID.default StringReturns the position of this coachmark.Returns the target id of this coachmark.default StringReturns the client widget class.static <I extends IAnyGroup>
ICoachmark<I>Returns the instance with the given targetId and any group children.static <I extends IAnyGroup>
ICoachmark<I>Returns the instance with the given targetId and any group children.static <I extends IAnyGroup>
ICoachmark<I>Returns the instance with the given id.withPosition(String position) Returns a copy ofthisimmutable component with the specifiedposition.default ICoachmark<I>withPosition(ICoachmark.Position position) Returns a copy ofthisimmutable component with the specifiedposition.withTarget(String target) Returns a copy ofthisimmutable component with the specifiedtarget.default ICoachmarkwithTarget(IComponent target) Returns a copy ofthisimmutable component with the specifiedtarget.Methods inherited from interface org.zkoss.stateless.sul.IChildable
getChildren, withChildren, withChildrenMethods inherited from interface org.zkoss.stateless.sul.IComponent
getAction, getActions, getClientAttributes, getMold, getWidgetListeners, getWidgetOverrides, isVisible, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withActions, withActions, withClientAttribute, withClientAttributes, withId, withMold, withVisible, withWidgetClass, withWidgetListener, withWidgetListeners, withWidgetOverride, withWidgetOverridesMethods inherited from interface org.zkoss.stateless.sul.IHtmlBasedComponent
getClientAction, getDraggable, getDroppable, getHeight, getHflex, getLeft, getRenderdefer, getSclass, getSkeleton, getStyle, getTabindex, getTooltiptext, getTop, getVflex, getWidth, getZclass, getZIndex, isFocus, withClientAction, withDraggable, withDroppable, withFocus, withHeight, withHflex, withLeft, withRenderdefer, withSclass, withSkeleton, withStyle, withTabindex, withTabindex, withTooltiptext, withTop, withVflex, withWidth, withZclass, withZIndexMethods inherited from interface org.zkoss.stateless.sul.IXulElement
getContext, getCtrlKeys, getPopup, getTooltip, withContext, withCtrlKeys, withPopup, withTooltip
-
Field Details
-
DEFAULT
Constant for default attributes of this immutable component.
-
-
Method Details
-
getWidgetClass
Returns the client widget class.Default:
"zkmax.nav.Coachmark"- Specified by:
getWidgetClassin interfaceIComponent<I extends IAnyGroup>
-
getTarget
Returns the target id of this coachmark.Default:
null -
withTarget
Returns a copy ofthisimmutable component with the specifiedtarget.Sets the target component id of this coachmark
- Parameters:
target- The target component id of this coachmarkDefault:
null.- Returns:
- A modified copy of the
thisobject
-
withTarget
Returns a copy ofthisimmutable component with the specifiedtarget.Sets the target component of this coachmark
- Parameters:
target- The target component of this coachmarkDefault:
null.- Returns:
- A modified copy of the
thisobject
-
getPosition
Returns the position of this coachmark.Default:
"after_center". -
withPosition
Returns a copy ofthisimmutable component with the specifiedposition.Sets the position of this coachmark.
Valid values for the position attribute are:
- before_start
the coachmark appears above the target, aligned to the left. - before_center
the coachmark appears above the target, aligned to the center. - before_end
the coachmark appears above the target, aligned to the right. - after_start
the coachmark appears below the target, aligned to the left. - after_center
the coachmark appears below the target, aligned to the center. - after_end
the coachmark appears below the target, aligned to the right. - start_before
the coachmark appears to the left of the target, aligned to the top. - start_center
the coachmark appears to the left of the target, aligned to the middle. - start_after
the coachmark appears to the left of the target, aligned to the bottom. - end_before
the coachmark appears to the right of the target, aligned to the top. - end_center
the coachmark appears to the right of the target, aligned to the middle. - end_after
the coachmark appears to the right of the target, aligned to the bottom.
- Parameters:
position- The position of this coachmark.Default:
"after_center".- Returns:
- A modified copy of the
thisobject
- before_start
-
withPosition
Returns a copy ofthisimmutable component with the specifiedposition.Sets the position of this coachmark.
Valid values for the position attribute are:
- before_start
the coachmark appears above the target, aligned to the left. - before_center
the coachmark appears above the target, aligned to the center. - before_end
the coachmark appears above the target, aligned to the right. - after_start
the coachmark appears below the target, aligned to the left. - after_center
the coachmark appears below the target, aligned to the center. - after_end
the coachmark appears below the target, aligned to the right. - start_before
the coachmark appears to the left of the target, aligned to the top. - start_center
the coachmark appears to the left of the target, aligned to the middle. - start_after
the coachmark appears to the left of the target, aligned to the bottom. - end_before
the coachmark appears to the right of the target, aligned to the top. - end_center
the coachmark appears to the right of the target, aligned to the middle. - end_after
the coachmark appears to the right of the target, aligned to the bottom.
- Parameters:
position- The position of this coachmark.Default:
"after_center".- Returns:
- A modified copy of the
thisobject
- before_start
-
getId
Description copied from interface:IComponentReturns the ID.Default:
""(an empty string; it means no ID at all).
Note: Unlike ZK Component, there is no ID Space in Stateless Component, so theIDshould be unique within a Desktop Scope, aka a browser page.- Specified by:
getIdin interfaceIComponent<I extends IAnyGroup>
-
of
Returns the instance with the given targetId and any group children.- Parameters:
targetId- The target IDchildren- The children belong to any group- See Also:
-
of
Returns the instance with the given targetId and any group children.- Parameters:
targetId- The target IDchildren- The children belong to any group- See Also:
-
ofId
Returns the instance with the given id.- Parameters:
id- The id to identify this component
-