Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(console): remove protected app promotion #6479

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 25 additions & 16 deletions packages/console/src/assets/docs/guides/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import nativeCapacitor from './native-capacitor/index';
import nativeExpo from './native-expo/index';
import nativeFlutter from './native-flutter/index';
import nativeIosSwift from './native-ios-swift/index';
import protectedApp from './protected-app/index';
import spaAngular from './spa-angular/index';
import spaChromeExtension from './spa-chrome-extension/index';
import spaReact from './spa-react/index';
Expand Down Expand Up @@ -81,14 +82,6 @@ export const guides: Readonly<Guide[]> = Object.freeze([
Component: lazy(async () => import('./spa-react/README.mdx')),
metadata: spaReact,
},
{
order: 1.2,
id: 'm2m-general',
Logo: lazy(async () => import('./m2m-general/logo.svg?react')),
DarkLogo: lazy(async () => import('./m2m-general/logo-dark.svg?react')),
Component: lazy(async () => import('./m2m-general/README.mdx')),
metadata: m2mGeneral,
},
{
order: 1.2,
id: 'web-express',
Expand All @@ -113,6 +106,14 @@ export const guides: Readonly<Guide[]> = Object.freeze([
Component: lazy(async () => import('./web-sveltekit/README.mdx')),
metadata: webSveltekit,
},
{
order: 1.3,
id: 'spa-vue',
Logo: lazy(async () => import('./spa-vue/logo.svg?react')),
DarkLogo: undefined,
Component: lazy(async () => import('./spa-vue/README.mdx')),
metadata: spaVue,
},
{
order: 1.3,
id: 'web-go',
Expand All @@ -131,20 +132,28 @@ export const guides: Readonly<Guide[]> = Object.freeze([
},
{
order: 1.4,
id: 'protected-app',
Logo: lazy(async () => import('./protected-app/logo.svg?react')),
DarkLogo: lazy(async () => import('./protected-app/logo-dark.svg?react')),
Component: lazy(async () => import('./protected-app/README.mdx')),
metadata: protectedApp,
},
{
order: 1.5,
id: 'm2m-general',
Logo: lazy(async () => import('./m2m-general/logo.svg?react')),
DarkLogo: lazy(async () => import('./m2m-general/logo-dark.svg?react')),
Component: lazy(async () => import('./m2m-general/README.mdx')),
metadata: m2mGeneral,
},
{
order: 1.6,
id: 'web-java-spring-boot',
Logo: lazy(async () => import('./web-java-spring-boot/logo.svg?react')),
DarkLogo: undefined,
Component: lazy(async () => import('./web-java-spring-boot/README.mdx')),
metadata: webJavaSpringBoot,
},
{
order: 1.6,
id: 'spa-vue',
Logo: lazy(async () => import('./spa-vue/logo.svg?react')),
DarkLogo: undefined,
Component: lazy(async () => import('./spa-vue/README.mdx')),
metadata: spaVue,
},
{
order: 1.7,
id: 'native-ios-swift',
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"order": 1.2
"order": 1.5
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# Placeholder for protected app guide
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"order": 1.4
}
14 changes: 14 additions & 0 deletions packages/console/src/assets/docs/guides/protected-app/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import { ApplicationType } from '@logto/schemas';

import { type GuideMetadata } from '../types';

const metadata: Readonly<GuideMetadata> = Object.freeze({
name: 'Protected app',
description: 'Non-SDK integration solution powered by Cloudflare Workers',
target: ApplicationType.Protected,
isFeatured: true,
isCloud: true,
skipGuideAfterCreation: true,
});

export default metadata;
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
41 changes: 41 additions & 0 deletions packages/console/src/assets/docs/guides/protected-app/logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"order": 1.6
"order": 1.3
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@ import { type GuideMetadata } from '../types';

const metadata: Readonly<GuideMetadata> = Object.freeze({
name: 'OIDC',
description: 'Use Logto as a third-party OIDC identity provider (IdP) for your application. ',
description: 'Use Logto as a third-party OIDC identity provider (IdP) for your application.',
target: ApplicationType.Traditional,
isThirdParty: true,
skipGuideAfterCreation: true,
});

export default metadata;
9 changes: 5 additions & 4 deletions packages/console/src/assets/docs/guides/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,14 @@ export type GuideMetadata = {
};
/** Whether the guide is displayed in featured group. */
isFeatured?: boolean;

/** Indicate whether the application is for third-party use */
/** Indicate whether the application is for third-party use. */
isThirdParty?: boolean;

/** Indicate whether the application is Cloud only. E.g. Protected app */
isCloud?: boolean;
/** Indicates whether we should skip the guide after creating the application. */
skipGuideAfterCreation?: boolean;
/** The related complete guide url relative to the quick starts page (https://docs.logto.io/quick-starts). */
fullGuide?: string;

/** The related URLs to add to the further readings section. */
furtherReadings?: Array<{
title: string;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"order": 1.4
"order": 1.6
}
4 changes: 3 additions & 1 deletion packages/console/src/assets/docs/guides/web-ruby/index.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
import { ApplicationType } from '@logto/schemas';

import { isCloud } from '@/consts/env';

import { type GuideMetadata } from '../types';

const metadata: Readonly<GuideMetadata> = Object.freeze({
name: 'Ruby',
description:
'Ruby is a dynamic, open-source programming language with a focus on simplicity and productivity.',
target: ApplicationType.Traditional,
isFeatured: true,
isFeatured: !isCloud,
sample: {
repo: 'ruby',
path: 'logto-sample',
Expand Down
Loading
Loading