Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

org.webjars.bowergithub.link2twenty:l2t-paper-stepper

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

org.webjars.bowergithub.link2twenty:l2t-paper-stepper

WebJar for l2t-paper-stepper

  • 0.1.3
  • Source
  • Maven
  • Socket score

Version published
Maintainers
1
Source

< l2t-paper-stepper >

Polymer element for displaying steps in a stepper progression form. Have a quick look at the Component page

Install with bower

First you need bower, see their site for details

bower install --save l2t-paper-stepper

Examples

Each step must be within a l2t-paper-step tag, but other than that you have complete control.

  <l2t-paper-stepper>
    <l2t-paper-step>#1</l2t-paper-step>
    <l2t-paper-step>#2</l2t-paper-step>
  </l2t-paper-stepper>

Styling

The following custom properties are available for styling:

Custom propertyDescriptionDefault
--step-active-label-colorColor of the label when the step is active--primary-text-color
--step-badge-colorColor of the badge when inactive--secondary-text-color
--step-badge-content-colorColor of the number and the icon inside the badge--primary-background-color
--step-badge-heightThe height of the badge (without border)30px
--step-badge-widthThe width of the badge (without border)30px
--step-button-colorColor of action buttons within step--primary-color
--step-button-text-colorText color of action buttons within step--primary-background-color
--step-connector-line-colorColor of the line that connect the steps--divider-color
--step-label-colorInitial color of the label--disabled-text-color
--step-locked-badge-colorColor of the badge if the step is locked--disabled-text-color
--step-save-badge-colorColor of the badge once the step is saved--primary-color
--step-saved-label-colorColor of the label once it's saved--primary-text-color

Attributes (l2t-paper-stepper)

Public

Attribute NameFunctionalityTypeDefault
closedIf true, start with all steps closedBooleanfalse
finishUsed to indicate if the stepper is finished or notBooleanfalse
nonLinearUsed to indicate if the stepper require users to complete one step in order to move on to the nextBooleanfalse

Private

Attribute NameFunctionalityTypeDefault
_activeStepIndexContains the index of the active stepNumberNULL
_stepsContains all the steps registeredArray[]

Attributes (l2t-paper-step)

Public

Attribute NameFunctionalityTypeDefault
activeindicating if the step is currently activeBooleanfalse
backLabellabel for back buttonString'Back'
continueLabellabel for continue buttonString'Continue'
editableindicating if the step is editableBooleanfalse
finishLabellabel for finish buttonString'Finish'
labellabel for stepString''
lockedindicating if the step is lockedBooleanfalse
optionalindicating if the step is optionalBooleanfalse
saveindicating if the step is savedBooleanfalse
skipLabellabel for skip buttonString'Skip'
updateLabellabel for update buttonString'Update'
invalidindicating if the step is invalidBooleanfalse

Private

Attribute NameFunctionalityTypeDefault
_stepIndexstores own index in _steps arrayNumberNULL

Methods (l2t-paper-stepper)

Public

Method NameAction
closeAll()Function: used to close all the steps
isFinalStep()Return: used to inicate is current step is the final step
nextStep()Function: used to open the next step, it will save and close the current step
prevStep()Function: used to open the previous step, it will close, not save, the current step
reset()Function: used to unsave all steps
setActiveByIndex(i)Function: used to set the active step by number/index
skipStep()Function: used to open the next step, it will close, not save, the current step

Private

Method NameAction
_calcNextStep()Return: provides the index closest valid step, going forwards through the array
_calcPrevStep()Return: provides the index closest valid step, going backwards through the array
_finishStep()Function: used to fire stepper-finished
_registerStep(el)Function: used by l2t-paper-step to add itself into the _steps array

Methods (l2t-paper-step)

Public

Method NameAction
activeStepObserver()Observer: setActiveByIndex to active
fireInvalidStep()Function: fire step-invalid event
ready()Function: register step with parent

Private

Method NameAction
_badgeNum(i)Return: badge number
_fireEvent(e)Function: fire clicked event for button
_getIcon()Return: icon name
_setActive()Function: makes self active step
_setValidActive()Function: checks if can be set to active, if passes call _setActive()
_showBack()Return: indicates if back button should be shown
_showContinue()Return: indicates if continue button should be shown
_showFinish()Return: indicates if finish button should be shown
_showSkip()Return: indicates if skip button should be shown
_showUpdate()Return: indicates if update button should be shown

Credit

I adapted this project from Arthur Tressol's project Caribou Stepper.

FAQs

Package last updated on 19 Apr 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc