Skip to content

W4ngCoder/elements-examples

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Elements examples

See them in action!

This repository contains examples of stylish forms that use Stripe Elements. These examples illustrate how to handle errors in real-time and style focus states, error states, and placeholders.

Common code for handling errors and form submission lives here.

Example 1

Example 1 shows a form that uses the card Element, a custom web font, and a solid icon with a custom color.

Example 2

Example 2 shows a "floaty-label" form that uses individual cardNumber, cardExpiry, and cardCvc Elements with a custom web font.

The form also collects address (and thus postal code) outside of the payment form. It passes the postal code to Stripe on tokenization.

Example 3

Example 3 shows a form that uses individual cardNumber, cardExpiry, cardCvc, and postalCode Elements with a custom web font.

Example 4

Example 4 shows a form that uses the card Element and a custom web font.

Example 5

Example 5 shows a form that uses the card Element and a custom icon color.

Releases

No releases published

Packages

No packages published

Languages

  • HTML 43.5%
  • CSS 41.3%
  • JavaScript 15.2%