From fd5fd1f9d5d40acac3535b61c6e052c056a88d69 Mon Sep 17 00:00:00 2001 From: zomars Date: Tue, 1 Mar 2022 13:55:49 -0700 Subject: [PATCH] Updated type info --- packages/types/App.d.ts | 31 +++++++++++++++++++++---------- 1 file changed, 21 insertions(+), 10 deletions(-) diff --git a/packages/types/App.d.ts b/packages/types/App.d.ts index b119f0c82e..a51e96f84f 100644 --- a/packages/types/App.d.ts +++ b/packages/types/App.d.ts @@ -1,32 +1,43 @@ /** - * Let define an App Integration. - * - * @type - App - * @member {boolean} installed is used to indicate if the app is installed or not. - * @member {string} type is used to indicate which type the app is. - * @member {string} title is used to add a distinctive name - * @member {string} name is the app's name. - * @member {string} description is to add information about the app. - * @member {string} imageSrc is to indicate where the app's logo is located. - * @member {string} variant is to indicate to which classification the app belongs. It can be a `calendar`, `payment` or `conferencing` integration. + * This is the definition for an app store's app metadata. + * This is used to display App info, categorize or hide certain apps in the app store. */ export interface App { + /** + * Wheter if the app is installed or not. Usually we check for api keys in env + * variables to determine if this is true or not. + * */ installed: boolean; + /** The app type */ type: `${string}_calendar` | `${string}_payment` | `${string}_video` | `${string}_web3`; + /** The display name for the app, TODO settle between this or name */ title: string; + /** The display name for the app */ name: string; + /** A brief description, usually found in the app's package.json */ description: string; + /** The icon to display in /apps/installed */ imageSrc: string; + /** TODO determine if we should use this instead of category */ variant: "calendar" | "payment" | "conferencing"; label: string; + /** The slug for the app store public page inside `/apps/[slug] */ slug: string; + /** The category to which this app belongs, currently we have `calendar`, `payment` or `video` */ category: string; + /** An abosolute url to the app logo */ logo: string; + /** Company or individual publishing this app */ publisher: string; + /** App's website */ url: string; + /** Wether if the app is verified by Cal.com or not */ verified: boolean; + /** Wether the app should appear in the trending section of the app store */ trending: boolean; + /** Rating from 0 to 5, harcoded for now. Should be fetched later on. */ rating: number; + /** Number of reviews, harcoded for now. Should be fetched later on. */ reviews: number; /** * Wheter if the app is installed globally or needs user intervention.