Stripe offers on-site credit card payments with a JavScript client.
Stripe - Card payment gateway was added in v1.1 and uses the Stripe Payment Intents API to complete transactions.
Creating a Stripe Payment Method
See Payment Methods for the basics of creating a payment method.
Stripe requires a Secret Key and Publishable key to be configured, both of which can be found under Account Settings > API Keys in the Stripe dashboard.