Home > front end >  Get a Stripe element to float with a bootstrap v5.1 floating label
Get a Stripe element to float with a bootstrap v5.1 floating label

Time:05-27

I have two fields below. An input field for my name and below it is a Stripe element for a credit card number. Based on the enter image description here

CodePudding user response:

If you are using PaymentElement, you can use the appearance API to set labels to floating .

CodePudding user response:

The less worse way I could find to achieve this is to mix the already mentioned example 2 solution with the native bootstrap classes instead of the custom css of the example. I had not the faith to do that in my own integration. If you get strength to do it, please share the repo, I'll give it a star. Good luck!

  • Related