-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.html
250 lines (243 loc) · 7.87 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
<!DOCTYPE html>
<html data-theme="light">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width" />
<meta name="color-scheme" content="light" />
<title>Mastercard Click to Pay Sample</title>
<link rel="stylesheet" type="text/css" href="styles.css" />
<link rel="stylesheet" type="text/css" href="modal.css" />
<link
rel="stylesheet"
href="https://unpkg.com/bamboo.css/dist/light.min.css"
/>
<!-- Click to Pay UI Kit -->
<link
rel="stylesheet"
href="https://src.mastercard.com/srci/integration/components/src-ui-kit/src-ui-kit.css"
/>
<script
type="module"
src="https://src.mastercard.com/srci/integration/components/src-ui-kit/src-ui-kit.esm.js"
></script>
<!-- Click to Pay SDK -->
<script src="https://sandbox.src.mastercard.com/srci/integration/2/lib.js?locale=en_US"></script>
<!-- <script src="mastercard.js"></script> -->
</head>
<body>
<main>
<div id="modal" class="modal">
<iframe id="c2p-modal" name="c2p-modal" class="modal-content"></iframe>
</div>
<h1>Payment Form</h1>
<form id="form">
<div class="row">
<div class="column">
<section id="contact_details">
<fieldset>
<legend>Contact Information</legend>
<p>
<label for="email">Email Address</label>
<input type="text" id="email" name="email" />
</p>
<p>
<label for="phone">Phone</label>
<input
type="text"
id="phone"
name="phone"
disabled
aria-disabled="true"
placeholder="disabled"
/>
</p>
</fieldset>
</section>
<section id="card_details">
<fieldset>
<legend>Card Details</legend>
<p>
<label for="card_number">Card Number</label>
<input
type="text"
id="card_number"
name="card_number"
value="5186001700008785"
/>
</p>
<p>
<label for="card_cvv">Card CVV</label>
<input
type="text"
id="card_cvv"
name="card_cvv"
value="123"
/>
</p>
<p>
<label>Expiration Month</label>
<input
type="text"
id="card_exp_month"
name="card_exp_month"
maxlength="2"
placeholder="MM"
value="01"
/>
</p>
<p>
<label>Expiration Year</label>
<input
type="text"
id="card_exp_year"
name="card_exp_year"
maxlength="4"
placeholder="YYYY"
value="2030"
/>
</p>
</fieldset>
</section>
</div>
<div class="column">
<section id="shipping_details">
<fieldset>
<legend>Shipping Address</legend>
<p>
<label for="first_name">First Name</label>
<input
type="text"
id="first_name"
name="first_name"
value="David"
/>
</p>
<p>
<label for="last_name">Last Name</label>
<input
type="text"
id="last_name"
name="last_name"
value="Johnson"
/>
</p>
<p>
<label for="address_line_1">Address Line 1</label>
<input
type="text"
id="address_line_1"
name="address_line_1"
value="618 E South St"
/>
</p>
<p>
<label for="address_line_2">Address Line 2</label>
<input
type="text"
id="address_line_2"
name="address_line_2"
value="Suite 510"
/>
</p>
<p>
<label for="address_city">City</label>
<input
type="text"
id="address_city"
name="address_city"
value="Orlando"
/>
</p>
<p>
<label for="address_state">State</label>
<input
type="text"
id="address_state"
name="address_state"
value="FL"
/>
</p>
<p>
<label for="address_zip">Zip Code</label>
<input
type="text"
id="address_zip"
name="address_zip"
value="32801"
/>
</p>
<p>
<label for="address_country">Country</label>
<input
type="text"
id="address_country"
name="address_country"
value="US"
/>
</p>
</fieldset>
</section>
</div>
<!-- <div id="c2p-container">
<src-button
id="c2p-start-button"
ref="c2p-start-button"
locale="en_US"
width="200"
height="40"
theme="dark"
card-brands="mastercard,visa,discover,amex"
></src-button>
<src-otp-channel-selection
id="c2p-otp-channel-selection"
ref="c2p-otp-channel-selection"
locale="en_US"
card-brands="mastercard,visa,discover,amex"
display-cancel-option="true"
display-header="true"
></src-otp-channel-selection>
<src-otp-input
id="c2p-otp-input"
ref="c2p-otp-input"
locale="en_US"
card-brands="mastercard,visa,discover,amex"
display-cancel-option="false"
error-reason=""
masked-identity-value="+1 (***) ***-*949"
network-id="Mastercard"
is-successful="false"
display-header="true"
auto-submit="false"
disable-elements="false"
hide-loader="false"
display-remember-me="false"
otp-resend-loading="false"
></src-otp-input>
<src-card-list
id="c2p-card-list"
ref="c2p-card-list"
locale="en_US"
card-brands="mastercard,visa,discover,amex"
display-cancel-option="false"
display-add-card="false"
display-preferred-card="false"
display-sign-out="false"
card-selection-type="gridView"
src-digital-card-id=""
display-header="true"
unaccepted-card-type=""
background="default"
></src-card-list>
</div> -->
</div>
<div style="text-align: center">
<button type="submit">Submit</button>
</div>
</form>
</main>
</body>
<script src="env.js"></script>
<script src="utils.js"></script>
<script src="modal.js"></script>
<script src="index.js"></script>
</html>