Skip to content

Commit a857cd4

Browse files
committed
wip: go live -d
1 parent 9ba925c commit a857cd4

File tree

7 files changed

+21
-11
lines changed

7 files changed

+21
-11
lines changed

@fiction/admin/dashboard/DashWrap.vue

-2
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ import El404 from '@fiction/ui/page/El404.vue'
1010
import DashBar from './DashBar.vue'
1111
import DashDarkModeToggle from './DashDarkModeToggle.vue'
1212
import DashNav from './DashNav.vue'
13-
import PreLaunch from './PreLaunch.vue'
1413
1514
export type UserConfig = {
1615
layoutFormat?: 'container' | 'full'
@@ -213,7 +212,6 @@ function toggleSidebar() {
213212
</div>
214213
</div>
215214
</transition>
216-
<PreLaunch :card />
217215
</div>
218216
</template>
219217

@fiction/admin/dashboard/OnboardSurvey.vue

+5-2
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@ const { card } = defineProps<{ card: Card }>()
1616
1717
const { fictionUser } = useService<{ fictionUser: FictionUser }>()
1818
19+
const TRIAL_PRODUCT = 'pro_month'
20+
const TRIAL_PRICE = 79
21+
1922
const form = vue.ref<{
2023
fullName?: string
2124
orgName?: string
@@ -188,7 +191,7 @@ const stepConfig: StepConfig = {
188191
icon: { class: 'i-tabler-sparkles' },
189192
},
190193
title: 'Join the Best',
191-
subTitle: 'Free for one month then $39/mo. Cancel anytime.',
194+
subTitle: `Free for one month then $${TRIAL_PRICE}/mo. Cancel anytime.`,
192195
button: { label: 'Start My Trial', theme: 'primary', size: 'lg', icon: 'i-tabler-bolt', iconAfter: 'i-tabler-arrow-right' },
193196
class: 'max-w-screen-xl',
194197
noButton: true,
@@ -315,7 +318,7 @@ const stepConfig: StepConfig = {
315318
<div class="space-y-6 max-w-[500px] w-full">
316319
<ElSubscriberStart
317320
:card
318-
price-lookup-key="pro_month"
321+
:price-lookup-key="TRIAL_PRODUCT"
319322
trial-type="paid"
320323
:button="step.button || {}"
321324
class="w-full"

@fiction/admin/test/onboard.flow.test.ts

-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import { time } from 'node:console'
21
import { isCi } from '@fiction/core'
32
import { createUiTestingKit } from '@fiction/core/test-utils/kit'
43
import { afterAll, describe, expect, it } from 'vitest'

@fiction/analytics/displayMetricFactory.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,9 @@ export class MetricDisplayFactory extends FictionObject<{
7171

7272
if (!response.data) {
7373
this.log.error('No data received from analytics', { data: response })
74-
throw new Error('No data received from analytics')
74+
75+
this.error.value = 'No data received from analytics'
76+
return
7577
}
7678
else {
7779
this.log.info('Received data from analytics', { data: response })

@fiction/site/test/testUtils.ts

+13-5
Original file line numberDiff line numberDiff line change
@@ -99,8 +99,6 @@ export async function createSiteTestUtils(args: {
9999

100100
out.fictionEnv.log.info(`Site Test Utils Created (${context})`)
101101

102-
out.close = async () => testUtils.close()
103-
104102
out.createSite = async (args: { themeId?: string } = {}) => {
105103
const { themeId = 'test' } = args
106104
const service = out as SiteTestUtils
@@ -109,19 +107,29 @@ export async function createSiteTestUtils(args: {
109107
return Site.create({ siteRouter, fictionSites, themeId, isProd: false, siteId: `test-${shortId()}` })
110108
}
111109

110+
const runOnStart = async (args: { context: 'app' | 'node', isProd?: boolean }) => {
111+
const { context } = args
112+
await out.fictionAnalytics?.init()
113+
await out.fictionSites?.ensureAppDefaults({ context, defaultId: 'test' })
114+
}
115+
112116
out.init = async () => {
113117
const r = await testUtils.init()
114-
await out.fictionAnalytics?.init()
115-
await out.fictionSites?.ensureAppDefaults({ context: args.context, defaultId: 'test' })
118+
await runOnStart({ context })
116119
return r
117120
}
118121

119122
out.runApp = async (args) => {
120123
const r = await testUtils.runApp(args)
121-
await out.fictionSites?.ensureAppDefaults({ context: args.context, defaultId: 'test' })
124+
await runOnStart({ context })
122125
return r
123126
}
124127

128+
out.close = async () => {
129+
await out.fictionAnalytics?.close()
130+
await testUtils.close()
131+
}
132+
125133
return out as SiteTestUtils
126134
}
127135

icon-blue.png

38.3 KB
Loading

icon-elite.png

39.2 KB
Loading

0 commit comments

Comments
 (0)