mirror of
https://github.com/LemmyNet/joinlemmy-site.git
synced 2024-11-25 13:51:17 +00:00
Add a warning alert for closed source apps.
This commit is contained in:
parent
baa2f9c960
commit
2fafb18134
5 changed files with 32 additions and 3 deletions
|
@ -1 +1 @@
|
|||
Subproject commit 229a9319ba1130723928e58fcbdbfccad45a4e81
|
||||
Subproject commit 0738d1326a788c648c29f1808e7274873f7985ac
|
|
@ -1 +1 @@
|
|||
Subproject commit bc063f46eb15fa09391639a4777b0cabb0cdcef5
|
||||
Subproject commit fe95bd00c3e9b08c8fb86e0f930452a1f4a2119b
|
|
@ -1 +1 @@
|
|||
Subproject commit d0f3548379e446d2c333e582734bc68f8d684f4d
|
||||
Subproject commit 848fc0d3b4128f262b605d6a6f81cd3f49dbbdbc
|
|
@ -4,6 +4,11 @@ export interface ApiLibrary {
|
|||
description: string;
|
||||
}
|
||||
|
||||
export enum SourceType {
|
||||
Closed,
|
||||
Open,
|
||||
}
|
||||
|
||||
export interface AppDetails {
|
||||
name: string;
|
||||
description: string;
|
||||
|
@ -11,6 +16,7 @@ export interface AppDetails {
|
|||
icon?: string;
|
||||
banner?: string;
|
||||
links: AppLink[];
|
||||
sourceType: SourceType;
|
||||
}
|
||||
|
||||
export interface AppLink {
|
||||
|
@ -57,6 +63,7 @@ const voyagerApp: AppDetails = {
|
|||
icon: "github",
|
||||
},
|
||||
],
|
||||
sourceType: SourceType.Open,
|
||||
};
|
||||
|
||||
const thunderApp: AppDetails = {
|
||||
|
@ -84,6 +91,7 @@ const thunderApp: AppDetails = {
|
|||
icon: "github",
|
||||
},
|
||||
],
|
||||
sourceType: SourceType.Open,
|
||||
};
|
||||
|
||||
export const ANDROID_APPS: AppDetails[] = [
|
||||
|
@ -107,6 +115,7 @@ export const ANDROID_APPS: AppDetails[] = [
|
|||
icon: "github",
|
||||
},
|
||||
],
|
||||
sourceType: SourceType.Open,
|
||||
},
|
||||
{
|
||||
name: "Eternity",
|
||||
|
@ -128,6 +137,7 @@ export const ANDROID_APPS: AppDetails[] = [
|
|||
icon: "github",
|
||||
},
|
||||
],
|
||||
sourceType: SourceType.Open,
|
||||
},
|
||||
{
|
||||
name: "Combustible",
|
||||
|
@ -145,6 +155,7 @@ export const ANDROID_APPS: AppDetails[] = [
|
|||
icon: "github",
|
||||
},
|
||||
],
|
||||
sourceType: SourceType.Open,
|
||||
},
|
||||
{
|
||||
name: "LiftOff!",
|
||||
|
@ -166,6 +177,7 @@ export const ANDROID_APPS: AppDetails[] = [
|
|||
icon: "github",
|
||||
},
|
||||
],
|
||||
sourceType: SourceType.Open,
|
||||
},
|
||||
voyagerApp,
|
||||
thunderApp,
|
||||
|
@ -181,6 +193,7 @@ export const ANDROID_APPS: AppDetails[] = [
|
|||
icon: "googleplay",
|
||||
},
|
||||
],
|
||||
sourceType: SourceType.Closed,
|
||||
},
|
||||
{
|
||||
name: "Sync for Lemmy",
|
||||
|
@ -194,6 +207,7 @@ export const ANDROID_APPS: AppDetails[] = [
|
|||
icon: "googleplay",
|
||||
},
|
||||
],
|
||||
sourceType: SourceType.Closed,
|
||||
},
|
||||
];
|
||||
|
||||
|
@ -214,6 +228,7 @@ export const IOS_APPS: AppDetails[] = [
|
|||
icon: "github",
|
||||
},
|
||||
],
|
||||
sourceType: SourceType.Open,
|
||||
},
|
||||
{
|
||||
name: "Lunar",
|
||||
|
@ -231,6 +246,7 @@ export const IOS_APPS: AppDetails[] = [
|
|||
icon: "github",
|
||||
},
|
||||
],
|
||||
sourceType: SourceType.Open,
|
||||
},
|
||||
voyagerApp,
|
||||
thunderApp,
|
||||
|
@ -251,6 +267,7 @@ export const IOS_APPS: AppDetails[] = [
|
|||
icon: "github",
|
||||
},
|
||||
],
|
||||
sourceType: SourceType.Open,
|
||||
},
|
||||
];
|
||||
|
||||
|
@ -266,6 +283,7 @@ export const WEB_APPS: AppDetails[] = [
|
|||
icon: "github",
|
||||
},
|
||||
],
|
||||
sourceType: SourceType.Open,
|
||||
},
|
||||
{
|
||||
name: "Photon",
|
||||
|
@ -279,6 +297,7 @@ export const WEB_APPS: AppDetails[] = [
|
|||
icon: "github",
|
||||
},
|
||||
],
|
||||
sourceType: SourceType.Open,
|
||||
},
|
||||
{
|
||||
name: "Alexandrite",
|
||||
|
@ -293,6 +312,7 @@ export const WEB_APPS: AppDetails[] = [
|
|||
icon: "github",
|
||||
},
|
||||
],
|
||||
sourceType: SourceType.Open,
|
||||
},
|
||||
{
|
||||
name: "lemmyBB",
|
||||
|
@ -305,6 +325,7 @@ export const WEB_APPS: AppDetails[] = [
|
|||
icon: "github",
|
||||
},
|
||||
],
|
||||
sourceType: SourceType.Open,
|
||||
},
|
||||
];
|
||||
|
||||
|
@ -320,5 +341,6 @@ export const CLI_APPS: AppDetails[] = [
|
|||
icon: "github",
|
||||
},
|
||||
],
|
||||
sourceType: SourceType.Open,
|
||||
},
|
||||
];
|
||||
|
|
|
@ -10,6 +10,7 @@ import {
|
|||
AppLink,
|
||||
CLI_APPS,
|
||||
IOS_APPS,
|
||||
SourceType,
|
||||
WEB_APPS,
|
||||
} from "./app-definitions";
|
||||
import { Icon } from "./icon";
|
||||
|
@ -67,6 +68,12 @@ const AppDetailsCard = ({ app }: AppDetailsCardProps) => (
|
|||
className="rounded-xl max-h-96 mb-2"
|
||||
/>
|
||||
<p className="text-sm text-gray-300 mb-2">{app.description}</p>
|
||||
{app.sourceType == SourceType.Closed && (
|
||||
<div className="alert alert-warning">
|
||||
<Icon icon="alert-octagon" />
|
||||
<span>{i18n.t("closed_source_warning")}</span>
|
||||
</div>
|
||||
)}
|
||||
<AppDetailsButtons links={app.links} />
|
||||
</div>
|
||||
</div>
|
||||
|
|
Loading…
Reference in a new issue