Skip to content

Commit ae67da6

Browse files
cleanup store, update github workflow to use node 22
1 parent ff94b1e commit ae67da6

File tree

6 files changed

+5
-52
lines changed

6 files changed

+5
-52
lines changed

.github/workflows/pipeline.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ jobs:
1111
- name: Check out repository code
1212
uses: actions/checkout@v3
1313

14-
- name: Install Node 16.x
14+
- name: Install Node 22.x
1515
uses: actions/setup-node@v3
1616
with:
17-
node-version: 16
17+
node-version: 22
1818

1919
- name: Install Dependencies
2020
run: yarn install --frozen-lockfile

layouts/default.vue

Lines changed: 3 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
</v-list-item>
3636
</v-list-group>
3737

38-
<v-list-group v-if="!isMarketplace">
38+
<v-list-group>
3939
<template v-slot:activator="{ props }">
4040
<v-list-item v-bind="props">
4141
<v-list-item-title>Payments APIs</v-list-item-title>
@@ -56,7 +56,7 @@
5656
</v-list-item>
5757
</v-list-group>
5858

59-
<v-list-group v-if="isMarketplace">
59+
<v-list-group>
6060
<template v-slot:activator="{ props }">
6161
<v-list-item v-bind="props">
6262
<v-list-item-title>Marketplace APIs</v-list-item-title>
@@ -98,7 +98,7 @@
9898
</v-list-item>
9999
</v-list-group>
100100

101-
<v-list-group v-if="!isMarketplace">
101+
<v-list-group>
102102
<template v-slot:activator="{ props }">
103103
<v-list-item v-bind="props">
104104
<v-list-item-title>Payment Intents APIs</v-list-item-title>
@@ -199,10 +199,6 @@
199199
Do not share or record your API keys in publicly accessible mediums
200200
such as GitHub, client-side code, etc.
201201
</p>
202-
<v-switch
203-
v-model="isMarketplace"
204-
label="I am using a Circle Marketplaces API key"
205-
></v-switch>
206202
</v-form>
207203
</div>
208204
</v-navigation-drawer>
@@ -533,15 +529,6 @@ const apiKey = computed({
533529
set: (value: string) => store.setBearerToken(value),
534530
})
535531
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')
545532
</script>
546533

547534
<style scoped>

pages/debug/businessAccount/index.vue

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -210,8 +210,4 @@
210210
</template>
211211

212212
<script setup lang="ts">
213-
const store = useMainStore()
214-
215-
// computed
216-
const isMarketplace = computed(() => store.isMarketplace)
217213
</script>

pages/debug/payments/create.vue

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -116,15 +116,13 @@ const formData = reactive({
116116
117117
const verificationMethods = ['none', 'cvv', 'three_d_secure']
118118
const sourceType = ['card', 'ach', 'payment_token']
119-
const required = [(v: string) => !!v || 'Field is required']
120119
const error = ref<any>({})
121120
const loading = ref(false)
122121
const showError = ref(false)
123122
124123
const payload = computed(() => store.getRequestPayload)
125124
const response = computed(() => store.getRequestResponse)
126125
const requestUrl = computed(() => store.getRequestUrl)
127-
const isMarketplace = computed(() => store.isMarketplace)
128126
129127
watch(
130128
() => formData.verification,
@@ -156,15 +154,6 @@ watch(
156154
{ immediate: true },
157155
)
158156
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-
168157
const onErrorSheetClosed = () => {
169158
error.value = {}
170159
showError.value = false

pages/debug/payouts/index.vue

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,5 +38,4 @@
3838

3939
<script setup lang="ts">
4040
const store = useMainStore()
41-
const isMarketplace = computed(() => store.isMarketplace)
4241
</script>

stores/main.ts

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,5 @@
11
import { defineStore } from 'pinia'
22

3-
interface Card {
4-
id: string
5-
cvvRequired: boolean
6-
}
7-
83
interface ApiRequest {
94
url: string
105
payload: any
@@ -14,8 +9,6 @@ interface ApiRequest {
149
interface MainState {
1510
bearerToken: string
1611
apiRequest: ApiRequest
17-
cards: Card[]
18-
isMarketplace: boolean
1912
}
2013

2114
export const useMainStore = defineStore('main', {
@@ -26,16 +19,13 @@ export const useMainStore = defineStore('main', {
2619
payload: {},
2720
response: {},
2821
},
29-
cards: [],
30-
isMarketplace: false,
3122
}),
3223

3324
getters: {
3425
getApiKey: (state): string => state.bearerToken,
3526
getRequestPayload: (state): any => state.apiRequest.payload,
3627
getRequestResponse: (state): any => state.apiRequest.response,
3728
getRequestUrl: (state): string => state.apiRequest.url,
38-
getCards: (state): Card[] => state.cards,
3929
},
4030

4131
actions: {
@@ -61,14 +51,6 @@ export const useMainStore = defineStore('main', {
6151
clearRequestData() {
6252
this.apiRequest = { url: '', payload: {}, response: {} }
6353
},
64-
65-
setCard(card: Card) {
66-
this.cards.push(card)
67-
},
68-
69-
setIsMarketplace(bool: boolean) {
70-
this.isMarketplace = bool
71-
},
7254
},
7355

7456
persist: {

0 commit comments

Comments
 (0)