File tree Expand file tree Collapse file tree 6 files changed +5
-52
lines changed Expand file tree Collapse file tree 6 files changed +5
-52
lines changed Original file line number Diff line number Diff line change @@ -11,10 +11,10 @@ jobs:
11
11
- name : Check out repository code
12
12
uses : actions/checkout@v3
13
13
14
- - name : Install Node 16 .x
14
+ - name : Install Node 22 .x
15
15
uses : actions/setup-node@v3
16
16
with :
17
- node-version : 16
17
+ node-version : 22
18
18
19
19
- name : Install Dependencies
20
20
run : yarn install --frozen-lockfile
Original file line number Diff line number Diff line change 35
35
</v-list-item >
36
36
</v-list-group >
37
37
38
- <v-list-group v-if = " !isMarketplace " >
38
+ <v-list-group >
39
39
<template v-slot :activator =" { props } " >
40
40
<v-list-item v-bind =" props" >
41
41
<v-list-item-title >Payments APIs</v-list-item-title >
56
56
</v-list-item >
57
57
</v-list-group >
58
58
59
- <v-list-group v-if = " isMarketplace " >
59
+ <v-list-group >
60
60
<template v-slot :activator =" { props } " >
61
61
<v-list-item v-bind =" props" >
62
62
<v-list-item-title >Marketplace APIs</v-list-item-title >
98
98
</v-list-item >
99
99
</v-list-group >
100
100
101
- <v-list-group v-if = " !isMarketplace " >
101
+ <v-list-group >
102
102
<template v-slot :activator =" { props } " >
103
103
<v-list-item v-bind =" props" >
104
104
<v-list-item-title >Payment Intents APIs</v-list-item-title >
199
199
Do not share or record your API keys in publicly accessible mediums
200
200
such as GitHub, client-side code, etc.
201
201
</p >
202
- <v-switch
203
- v-model =" isMarketplace"
204
- label =" I am using a Circle Marketplaces API key"
205
- ></v-switch >
206
202
</v-form >
207
203
</div >
208
204
</v-navigation-drawer >
@@ -533,15 +529,6 @@ const apiKey = computed({
533
529
set : (value : string ) => store .setBearerToken (value ),
534
530
})
535
531
536
- const isMarketplace = computed ({
537
- get : () => store .isMarketplace ,
538
- set : (bool : boolean ) => {
539
- store .setIsMarketplace (bool )
540
- router .push (' /' )
541
- },
542
- })
543
-
544
- const title = ref (' Circle Sample App' )
545
532
</script >
546
533
547
534
<style scoped>
Original file line number Diff line number Diff line change 210
210
</template >
211
211
212
212
<script setup lang="ts">
213
- const store = useMainStore ()
214
-
215
- // computed
216
- const isMarketplace = computed (() => store .isMarketplace )
217
213
</script >
Original file line number Diff line number Diff line change @@ -116,15 +116,13 @@ const formData = reactive({
116
116
117
117
const verificationMethods = [' none' , ' cvv' , ' three_d_secure' ]
118
118
const sourceType = [' card' , ' ach' , ' payment_token' ]
119
- const required = [(v : string ) => !! v || ' Field is required' ]
120
119
const error = ref <any >({})
121
120
const loading = ref (false )
122
121
const showError = ref (false )
123
122
124
123
const payload = computed (() => store .getRequestPayload )
125
124
const response = computed (() => store .getRequestResponse )
126
125
const requestUrl = computed (() => store .getRequestUrl )
127
- const isMarketplace = computed (() => store .isMarketplace )
128
126
129
127
watch (
130
128
() => formData .verification ,
@@ -156,15 +154,6 @@ watch(
156
154
{ immediate: true },
157
155
)
158
156
159
- onMounted (() => {
160
- if (isMarketplace .value ) {
161
- throw createError ({
162
- statusCode: 404 ,
163
- statusMessage: ' This endpoint is not available for marketplaces' ,
164
- })
165
- }
166
- })
167
-
168
157
const onErrorSheetClosed = () => {
169
158
error .value = {}
170
159
showError .value = false
Original file line number Diff line number Diff line change 38
38
39
39
<script setup lang="ts">
40
40
const store = useMainStore ()
41
- const isMarketplace = computed (() => store .isMarketplace )
42
41
</script >
Original file line number Diff line number Diff line change 1
1
import { defineStore } from 'pinia'
2
2
3
- interface Card {
4
- id : string
5
- cvvRequired : boolean
6
- }
7
-
8
3
interface ApiRequest {
9
4
url : string
10
5
payload : any
@@ -14,8 +9,6 @@ interface ApiRequest {
14
9
interface MainState {
15
10
bearerToken : string
16
11
apiRequest : ApiRequest
17
- cards : Card [ ]
18
- isMarketplace : boolean
19
12
}
20
13
21
14
export const useMainStore = defineStore ( 'main' , {
@@ -26,16 +19,13 @@ export const useMainStore = defineStore('main', {
26
19
payload : { } ,
27
20
response : { } ,
28
21
} ,
29
- cards : [ ] ,
30
- isMarketplace : false ,
31
22
} ) ,
32
23
33
24
getters : {
34
25
getApiKey : ( state ) : string => state . bearerToken ,
35
26
getRequestPayload : ( state ) : any => state . apiRequest . payload ,
36
27
getRequestResponse : ( state ) : any => state . apiRequest . response ,
37
28
getRequestUrl : ( state ) : string => state . apiRequest . url ,
38
- getCards : ( state ) : Card [ ] => state . cards ,
39
29
} ,
40
30
41
31
actions : {
@@ -61,14 +51,6 @@ export const useMainStore = defineStore('main', {
61
51
clearRequestData ( ) {
62
52
this . apiRequest = { url : '' , payload : { } , response : { } }
63
53
} ,
64
-
65
- setCard ( card : Card ) {
66
- this . cards . push ( card )
67
- } ,
68
-
69
- setIsMarketplace ( bool : boolean ) {
70
- this . isMarketplace = bool
71
- } ,
72
54
} ,
73
55
74
56
persist : {
You can’t perform that action at this time.
0 commit comments