math-main-components 0.0.48 → 0.0.49

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,12 @@
1
+ export interface Category {
2
+ _id: string;
3
+ title: string;
4
+ isTopLevel: boolean;
5
+ hasEBooks: boolean;
6
+ hasMovies: boolean;
7
+ hasWhy: boolean;
8
+ hasCalculators: boolean;
9
+ hasPoster: boolean;
10
+ childrenCategories: Category[];
11
+ relatedCategories: Category[];
12
+ }
@@ -0,0 +1,6 @@
1
+ export interface Concept {
2
+ title: string;
3
+ subtitle: string;
4
+ description: string;
5
+ iconName: string;
6
+ }
@@ -0,0 +1,14 @@
1
+ import { PortableTextBlock } from "sanity";
2
+ export interface Content {
3
+ priority: number;
4
+ title: string;
5
+ subtitle: string;
6
+ iconName: string;
7
+ description: PortableTextBlock[];
8
+ contentBuckets: Array<ContentBucket>;
9
+ }
10
+ export interface ContentBucket {
11
+ title: string;
12
+ description: string;
13
+ bucket: string;
14
+ }
@@ -0,0 +1,15 @@
1
+ import { CourseParticipant } from "./CourseParticipant";
2
+ import { Organization } from "./Organization";
3
+ import { User } from "./User";
4
+ export interface Course {
5
+ id: string;
6
+ title: string;
7
+ content: Object;
8
+ userId: string;
9
+ user?: User;
10
+ organizationId: string;
11
+ organization: Organization;
12
+ courseParticipant: CourseParticipant[];
13
+ createdAt: string;
14
+ updatedAt: string;
15
+ }
@@ -0,0 +1,13 @@
1
+ import { Course } from "./Course";
2
+ import { CourseAnnouncementAsset } from "./CourseAnnouncementAssset";
3
+ import { User } from "./User";
4
+ export interface CourseAnnouncement {
5
+ id: string;
6
+ author: User;
7
+ authorId: string;
8
+ course: Course;
9
+ courseId: string;
10
+ message: string;
11
+ CourseAnnouncementAsset: CourseAnnouncementAsset[];
12
+ createdAt: Date;
13
+ }
@@ -0,0 +1,21 @@
1
+ export declare enum CourseAnnouncementAssetType {
2
+ file = "file",
3
+ calculator = "calculator",
4
+ video = "video",
5
+ material = "material",
6
+ ebook = "ebook",
7
+ test = "test",
8
+ link = "link"
9
+ }
10
+ export interface CourseAnnouncementAsset {
11
+ id?: string;
12
+ type: CourseAnnouncementAssetType;
13
+ link: string;
14
+ text: string;
15
+ file?: File;
16
+ fileName?: string;
17
+ fileType?: string;
18
+ fileId?: string;
19
+ fileExpire?: Date;
20
+ fileSize?: number;
21
+ }
@@ -0,0 +1,11 @@
1
+ import { Course } from "./Course";
2
+ import { User } from "./User";
3
+ export interface CourseMessage {
4
+ id: string;
5
+ author: User;
6
+ authorId: string;
7
+ course: Course;
8
+ courseId: string;
9
+ message: string;
10
+ createdAt: Date;
11
+ }
@@ -0,0 +1,9 @@
1
+ import { User } from "./User";
2
+ export interface CourseParticipant {
3
+ id: string;
4
+ role: string;
5
+ createdAt: string;
6
+ updatedAt: string;
7
+ userId: string;
8
+ user?: User;
9
+ }
@@ -0,0 +1,8 @@
1
+ export interface CoursePin {
2
+ id: string;
3
+ subscriptionPin: string;
4
+ amountOfUses: number;
5
+ maxAmountOfUses: number;
6
+ createdAt: Date;
7
+ validUntil: Date;
8
+ }
@@ -0,0 +1,13 @@
1
+ export interface S3File {
2
+ fileId: string;
3
+ updatedAt: Date;
4
+ title: string;
5
+ description: string;
6
+ category: S3FileCategory;
7
+ }
8
+ export declare enum S3FileCategory {
9
+ movies = "movies",
10
+ materials = "materials",
11
+ ebooks = "ebooks",
12
+ default = "file"
13
+ }
@@ -0,0 +1,7 @@
1
+ export interface HelpData {
2
+ id: string;
3
+ title: string;
4
+ content: any;
5
+ openButtonText: string;
6
+ closeButtonText: string;
7
+ }
@@ -0,0 +1,12 @@
1
+ import { Product } from "./Product";
2
+ export interface LicenseKey {
3
+ id: string;
4
+ product: Product;
5
+ productId: string;
6
+ pricePayedEuro: number;
7
+ valid: boolean;
8
+ quantity: boolean;
9
+ key: string;
10
+ createdAt: string;
11
+ redeemedOn: string;
12
+ }
@@ -0,0 +1,16 @@
1
+ export interface Manager {
2
+ id: string;
3
+ username: string;
4
+ firstName: string;
5
+ lastName: string;
6
+ permissions: string[];
7
+ createdAt: Date;
8
+ updateAt: Date;
9
+ }
10
+ export declare enum ManagerPermission {
11
+ content = "content",
12
+ subsription = "subscription",
13
+ manager = "manager",
14
+ license = "license",
15
+ file = "file"
16
+ }
@@ -0,0 +1,17 @@
1
+ import { Category } from "./Category";
2
+ export interface Material {
3
+ _id: string;
4
+ title: string;
5
+ fileId: string;
6
+ fileExpire?: string;
7
+ fileUrl?: string;
8
+ fileType: string;
9
+ description: string;
10
+ previewImage: {
11
+ asset: {
12
+ _ref: string;
13
+ _type: string;
14
+ };
15
+ };
16
+ categories: Category[];
17
+ }
@@ -0,0 +1,15 @@
1
+ export interface Organization {
2
+ id: string;
3
+ name: string;
4
+ website: string;
5
+ place: string;
6
+ addressLine1: string;
7
+ addressLine2: string;
8
+ postcode: string;
9
+ state: string;
10
+ country: string;
11
+ level: string;
12
+ iconId: string;
13
+ iconUrl: string;
14
+ iconExpire: Date;
15
+ }
@@ -0,0 +1,12 @@
1
+ import { Organization } from "./Organization";
2
+ import { User } from "./User";
3
+ export interface OrganizationMember {
4
+ id: string;
5
+ role: string;
6
+ createdAt: string;
7
+ updatedAt: string;
8
+ user: User;
9
+ userId: string;
10
+ organization: Organization;
11
+ organizationId: string;
12
+ }
@@ -0,0 +1,8 @@
1
+ import { PortableTextBlock } from "sanity";
2
+ export interface Page {
3
+ title: string;
4
+ slug: {
5
+ current: string;
6
+ };
7
+ content: PortableTextBlock[];
8
+ }
@@ -0,0 +1,16 @@
1
+ export interface Product {
2
+ _id: string;
3
+ title: string;
4
+ combinable: boolean;
5
+ enabled: boolean;
6
+ description: any;
7
+ unitPriceEuro: number;
8
+ recurringInterval: 'weekly' | 'monthly' | 'yearly';
9
+ trialPeriodDays: number;
10
+ minQuantity: number;
11
+ createdAt: string;
12
+ updatedAt: string;
13
+ features: any;
14
+ stripePriceId: string;
15
+ stripeProductId: string;
16
+ }
@@ -0,0 +1,7 @@
1
+ export interface ProductFeature {
2
+ _type: string;
3
+ _key: string;
4
+ type: string;
5
+ isUnlimited: boolean;
6
+ limit: number;
7
+ }
@@ -0,0 +1,7 @@
1
+ export interface PublicUser {
2
+ id: string;
3
+ email: string;
4
+ username: string;
5
+ firstName: string;
6
+ lastName: string;
7
+ }
@@ -0,0 +1,33 @@
1
+ import Stripe from "stripe";
2
+ import { Organization } from "./Organization";
3
+ import { Product } from "./Product";
4
+ import { User } from "./User";
5
+ export interface SubscriptionFeature {
6
+ limit: number;
7
+ isUnlimited: boolean;
8
+ type: string;
9
+ }
10
+ export interface Subscription {
11
+ id: string;
12
+ organization?: Organization;
13
+ organizationId: string;
14
+ product?: Product;
15
+ productId: string;
16
+ user?: User;
17
+ userId: string;
18
+ features?: SubscriptionFeature[];
19
+ currentPeriodPaid: boolean;
20
+ lastPeriodPaid: boolean;
21
+ cancelAtPeriodEnd: boolean;
22
+ currentPeriodStart: string;
23
+ currentPeriodEnd: string;
24
+ status: string;
25
+ quantity: number;
26
+ newQuantity: number;
27
+ trialEnd: string;
28
+ recurringInterval: string;
29
+ stripeSubscriptionId: string;
30
+ stripeSubscription: Stripe.Subscription;
31
+ stripePaymentMethod: Stripe.PaymentMethod;
32
+ notes: string[];
33
+ }
@@ -0,0 +1,4 @@
1
+ export interface UploadSignature {
2
+ signedUploadUrl: string;
3
+ fileId: string;
4
+ }
@@ -0,0 +1,5 @@
1
+ export interface Usage {
2
+ title: string;
3
+ subtitle: string;
4
+ ratio: number;
5
+ }
@@ -0,0 +1,25 @@
1
+ import { Course } from "./Course";
2
+ import { Organization } from "./Organization";
3
+ export interface User {
4
+ id: string;
5
+ email: string;
6
+ username: string;
7
+ firstName: string;
8
+ lastName: string;
9
+ newsletterEnabled: boolean;
10
+ initialPassword: string;
11
+ isPasswordEnabled: boolean;
12
+ emailVerified: boolean;
13
+ profileImageUrl: string;
14
+ settings: Object;
15
+ role: string;
16
+ courses: Course[];
17
+ appNotifications: Object;
18
+ emailNotifications: Object;
19
+ stripeCustomerId: string;
20
+ createdAt: string;
21
+ updatedAt: string;
22
+ organization: Organization;
23
+ organizationId: string;
24
+ organizationRole: string;
25
+ }
@@ -0,0 +1,8 @@
1
+ export interface BenefitForIndividuals {
2
+ _id: string;
3
+ priority: number;
4
+ title: string;
5
+ subtitle: string;
6
+ iconName: string;
7
+ description: string;
8
+ }
@@ -0,0 +1,8 @@
1
+ export interface BenefitForSchools {
2
+ _id: string;
3
+ priority: number;
4
+ title: string;
5
+ subtitle: string;
6
+ iconName: string;
7
+ description: string;
8
+ }
@@ -0,0 +1,8 @@
1
+ export interface Feature {
2
+ _id: string;
3
+ priority: number;
4
+ title: string;
5
+ subtitle: string;
6
+ iconName: string;
7
+ description: string;
8
+ }
@@ -0,0 +1,6 @@
1
+ export interface FooterLink {
2
+ title: string;
3
+ link: string;
4
+ priority: number;
5
+ column: string;
6
+ }
@@ -0,0 +1,13 @@
1
+ import { PortableTextBlock } from "sanity";
2
+ export interface News {
3
+ visible: boolean;
4
+ headline: string;
5
+ slug: {
6
+ current: string;
7
+ };
8
+ date: string;
9
+ image: string;
10
+ content: PortableTextBlock[];
11
+ short: PortableTextBlock[];
12
+ type: 'press' | 'update' | 'short';
13
+ }
@@ -0,0 +1,16 @@
1
+ import { Product } from "../Product";
2
+ import { ProductFeature } from "../ProductFeature";
3
+ export interface Pricing {
4
+ _id: string;
5
+ title: string;
6
+ position: PricingPosition;
7
+ limitation: string;
8
+ subtitle: string;
9
+ slogan: string;
10
+ recommended: boolean;
11
+ features: ProductFeature[];
12
+ buttonText: string;
13
+ product: Product;
14
+ }
15
+ type PricingPosition = 'personal-left' | 'personal-right' | 'schools-left' | 'schools-right';
16
+ export {};
@@ -0,0 +1,16 @@
1
+ export interface WebsiteData {
2
+ heroDescription: string;
3
+ heroTitle: string;
4
+ title: string;
5
+ copyright: string;
6
+ footerLeftColumn: string;
7
+ footerMiddleColumn: string;
8
+ footerRightColumn: string;
9
+ textBelowSchoolPricing: [];
10
+ defaultPersonalProduct: {
11
+ _ref: string;
12
+ };
13
+ defaultOrganizationProduct: {
14
+ _ref: string;
15
+ };
16
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "math-main-components",
3
- "version": "0.0.48",
3
+ "version": "0.0.49",
4
4
  "author": "Emilian Scheel",
5
5
  "files": [
6
6
  "dist/**/*"
@@ -41,5 +41,9 @@
41
41
  "build:js": "rollup -c",
42
42
  "build:types": "tsc --emitDeclarationOnly --outDir dist"
43
43
  },
44
- "dependencies": {}
44
+ "dependencies": {
45
+ "@sanity/types": "^3.20.1",
46
+ "sanity": "^3.20.1",
47
+ "stripe": "^14.5.0"
48
+ }
45
49
  }