Skip to content

Commit 48d096c

Browse files
committed
Merge branch 'main' of https://github.com/civitai/civitai into main
2 parents 9247672 + a15a5c0 commit 48d096c

File tree

7 files changed

+28
-14
lines changed

7 files changed

+28
-14
lines changed

next.config.mjs

+7-5
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import packageJson from './package.json' assert { type: 'json' };
66
const isProd = process.env.NODE_ENV === 'production';
77
const isDev = process.env.NODE_ENV === 'development';
88
const analyze = process.env.ANALYZE === 'true';
9-
const shouldOptimizeImports = (isDev && analyze) || isProd
9+
const shouldOptimizeImports = (isDev && analyze) || isProd;
1010

1111
const withBundleAnalyzer = bundlAnalyzer({
1212
enabled: analyze,
@@ -68,10 +68,7 @@ export default defineNextConfig(
6868
experimental: {
6969
// scrollRestoration: true,
7070
largePageDataBytes: 512 * 100000,
71-
optimizePackageImports: [
72-
'@civitai/client',
73-
'./srs/libs/form'
74-
],
71+
optimizePackageImports: ['@civitai/client', './srs/libs/form'],
7572
},
7673
headers: async () => {
7774
// Add X-Robots-Tag header to all pages matching /sitemap.xml and /sitemap-models.xml /sitemap-articles.xml, etc
@@ -231,6 +228,11 @@ export default defineNextConfig(
231228
destination: '/events/holiday2023',
232229
permanent: true,
233230
},
231+
{
232+
source: '/air/confirm',
233+
destination: '/studio/confirm',
234+
permanent: true,
235+
},
234236
{
235237
source: '/blocked-by-octoml',
236238
destination: '/articles/3307',

package-lock.json

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "model-share",
3-
"version": "5.0.518",
3+
"version": "5.0.519",
44
"private": true,
55
"scripts": {
66
"start": "next start",

src/components/LoginRedirect/LoginRedirect.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ export function LoginRedirect({ children, reason, returnUrl }: Props) {
2525
}
2626

2727
function handleClick(e: React.MouseEvent) {
28-
if (running) closeTour({ reset: true });
28+
if (running) closeTour();
2929
requireLogin({
3030
uiEvent: e,
3131
reason,

src/components/Tours/ToursProvider.tsx

+11
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,17 @@ export function ToursProvider({ children }: { children: React.ReactNode }) {
166166
// Set initial step based on user settings
167167
const currentStep = currentTourData?.currentStep ?? 0;
168168
setState((old) => ({ ...old, currentStep, returnUrl: path }));
169+
170+
// handle initialization of the active tour
171+
switch (tourKey) {
172+
case 'content-generation':
173+
case 'remix-content-generation':
174+
generationPanel.setView('generate');
175+
generationPanel.open();
176+
break;
177+
default:
178+
break;
179+
}
169180
}, [isInitialLoading, tourKey]);
170181

171182
const completed = currentTourData?.completed;

src/pages/air/confirm.tsx renamed to src/pages/studio/confirm.tsx

+5-5
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ export default function Confirm() {
5454
const confirmEmail = (
5555
<Container size="xs">
5656
<Stack>
57-
<Text size="xl" weight={500} ta="center">{`Thanks for being a Civitai Supporter ❤️`}</Text>
57+
<Text size="xl" weight={500} ta="center">{`Thanks for being a Civitai Member ❤️`}</Text>
5858
<Text>{`To complete your application, please enter the email that you used when you applied for the Artist in Residence program`}</Text>
5959
<Stack spacing={5}>
6060
<TextInput
@@ -93,11 +93,11 @@ export default function Confirm() {
9393
</Alert>
9494
<Button
9595
component="a"
96-
href="https://air.civitai.com/application-success"
96+
href="https://studio.civitai.com/cohort-application/success"
9797
rightIcon={<IconArrowRight />}
9898
size="lg"
9999
>
100-
Return to AiR Application
100+
Return to Studio Cohort Application
101101
</Button>
102102
</Stack>
103103
</Container>
@@ -106,7 +106,7 @@ export default function Confirm() {
106106
const subscriptionsLoading = subscriptionLoading || productsLoading;
107107
const notMember = (
108108
<Stack>
109-
<Text size="xl" weight={500} ta="center">{`Become a Supporter today!`}</Text>
109+
<Text size="xl" weight={500} ta="center">{`Become a Member today!`}</Text>
110110
{subscriptionsLoading ? (
111111
<Loader />
112112
) : (
@@ -127,7 +127,7 @@ export default function Confirm() {
127127
return (
128128
<Container>
129129
<Title order={1} align="center" mb="lg">
130-
AiR Supporter Confirmation
130+
Studio Member Confirmation
131131
</Title>
132132
{!isMember ? notMember : isConfirmed ? confirmed : confirmEmail}
133133
</Container>

src/server/redis/caches.ts

+1
Original file line numberDiff line numberDiff line change
@@ -303,6 +303,7 @@ export const modelVersionAccessCache = createCachedObject<ModelVersionAccessCach
303303
key: REDIS_KEYS.CACHES.ENTITY_AVAILABILITY.MODEL_VERSIONS,
304304
idKey: 'entityId',
305305
ttl: CacheTTL.day,
306+
cacheNotFound: false,
306307
dontCacheFn: (data) => {
307308
// We only wanna cache public models. Otherwise, we better confirm every time. It's a safer bet.
308309
// Also, only cache it if it's been published for more than an hour.

0 commit comments

Comments
 (0)