Skip to content

Commit 51d4930

Browse files
authored
Merge pull request #2 from yourpayments/secure-fields-example
Secure fields example
2 parents 7c0397f + c92affe commit 51d4930

14 files changed

+1104
-12
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
composer.phar
22
/vendor/
3+
.idea
34

45
# Commit your application's lock file https://getcomposer.org/doc/01-basic-usage.md#commit-your-composer-lock-file-to-version-control
56
# You may choose to ignore a library lock file http://getcomposer.org/doc/02-libraries.md#lock-file

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ require vendor/autoload.php;
3030
1. [Начало работы (настройка интеграции)](src/Examples/start.php)
3131
2. [Cамый простой платёж](src/Examples/simpleGetPaymentLink.php)
3232
3. [Подробный платёж](src/Examples/getPaymentLink.php)
33-
4. [Платёж со сплитом)](src/Examples/getPaymentLinkMarketplace.php)
33+
4. [Платёж со сплитом](src/Examples/getPaymentLinkMarketplace.php)
3434
5. [Токенизация карты (чтобы запомнить карту клиента и не вводить повторно)](src/Examples/getToken.php)
3535
6. [Оплата токеном](src/Examples/paymentByToken.php)
3636
7. [Списание средств](src/Examples/paymentCapture.php)
@@ -42,6 +42,7 @@ require vendor/autoload.php;
4242
13. [Создание сессии](src/Examples/getSession.php)
4343
14. [Оплата одноразовым токеном](src/Examples/oneTimeTokenPayment.php)
4444
15. [Страница после оплаты](src/Examples/returnPage.php)
45+
16. [Безопасные поля (Secure fields)](src/Examples/secureFields.php)
4546

4647
## Ссылки
4748
- [Основной сайт НКО "Твои Платежи"](https://YPMN.ru/)

assets/css/secureFields.css

Lines changed: 142 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,142 @@
1+
body {
2+
min-width: 388px;
3+
}
4+
5+
.form {
6+
display: none;
7+
justify-content: center;
8+
margin: 25px 12px;
9+
}
10+
11+
.form form {
12+
width: 100%;
13+
max-width: 500px;
14+
min-width: 350px;
15+
}
16+
17+
.rowDateAndCVV {
18+
flex-direction: row;
19+
}
20+
21+
@media only screen and (max-width: 438px) {
22+
.rowDateAndCVV {
23+
flex-direction: column;
24+
}
25+
}
26+
27+
.form button {
28+
width: 100%;
29+
}
30+
31+
.secret-field {
32+
display: flex;
33+
align-items: center;
34+
}
35+
36+
.left-column-input {
37+
/*width: 130px;*/
38+
}
39+
40+
.right-column-input {
41+
/*width: 130px;*/
42+
}
43+
44+
.btn-primary {
45+
color: #fff;
46+
background-color: #3A9D86;
47+
border-color: #3A9D86;
48+
outline: none !important;
49+
box-shadow: none !important;
50+
}
51+
52+
.btn-primary:hover, .btn-primary:focus {
53+
color: #000;
54+
background-color: #83E8AB;
55+
border-color: #83E8AB;
56+
outline: none !important;
57+
box-shadow: none !important;
58+
}
59+
60+
.btn-primary:disabled, .btn-primary[disabled] {
61+
color: #000;
62+
background-color: #aaaaaa;
63+
border-color: #999999;
64+
outline: none !important;
65+
box-shadow: none !important;
66+
}
67+
68+
.form-control, .input-group-text {
69+
border: 1px solid #3A9D86;
70+
}
71+
72+
.result, .load {
73+
display: none;
74+
flex-direction: column;
75+
align-items: center;
76+
justify-content: center;
77+
text-align: center;
78+
margin: 25px 12px;
79+
}
80+
81+
.result .icon {
82+
margin-bottom: 15px;
83+
}
84+
85+
.result .title {
86+
font-size: 17px;
87+
font-weight: 500;
88+
margin-bottom: 8px;
89+
}
90+
91+
.result .message {
92+
font-size: 14px;
93+
font-weight: 400;
94+
margin-bottom: 25px;
95+
line-height: 1.6em;
96+
}
97+
98+
.result .message span {
99+
font-size: inherit;
100+
}
101+
102+
.json {
103+
display: block;
104+
text-align: left;
105+
margin: 5px 0;
106+
}
107+
108+
.load {
109+
display: flex;
110+
}
111+
112+
.load svg {
113+
display: block;
114+
width: 200px;
115+
height: 200px;
116+
}
117+
118+
#submitLoad {
119+
display: none;
120+
flex-direction: column;
121+
align-items: center;
122+
justify-content: center;
123+
width: 100%;
124+
background-color: #3A9D86;
125+
border-color: #3A9D86;
126+
outline: none !important;
127+
box-shadow: none !important;
128+
padding: 6px;
129+
}
130+
131+
#submitLoad svg {
132+
width: 24px;
133+
height: 24px;
134+
}
135+
136+
.reset {
137+
display: none;
138+
}
139+
140+
#simple-form {
141+
display: none;
142+
}

assets/css/text-security-disk.css

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#cvv {
2+
-webkit-text-security: disc;
3+
}

0 commit comments

Comments
 (0)