@dotted-labs/ngx-supabase-stripe 0.2.2 → 0.2.3
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.
|
@@ -1466,11 +1466,11 @@ class ProductListComponent {
|
|
|
1466
1466
|
this.priceSelected.emit(price);
|
|
1467
1467
|
}
|
|
1468
1468
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.5", ngImport: i0, type: ProductListComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1469
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.5", type: ProductListComponent, isStandalone: true, selector: "stripe-product-list", inputs: { products: { classPropertyName: "products", publicName: "products", isSignal: true, isRequired: false, transformFunction: null }, currency: { classPropertyName: "currency", publicName: "currency", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { productSelected: "productSelected", priceSelected: "priceSelected" }, ngImport: i0, template: "@if (productsStore.isStatusLoading()) {\n <div class=\"flex justify-start gap-8\">\n @for (item of [1,2,3]; track item) {\n <lib-product-item-skeleton></lib-product-item-skeleton>\n }\n </div>\n}\n\n@if (productsStore.isStatusError() && !productsStore.isStatusLoading()) {\n <div class=\"alert alert-error\">\n <span>{{ productsStore.error() }}</span>\n </div>\n}\n\n@if (!productsStore.hasProducts()) {\n <div class=\"alert alert-info\">\n <span>No products available</span>\n </div>\n}\n\n@if (productsStore.hasProducts()) {\n <div class=\"flex justify-start gap-8\">\n @for (product of products(); track product.id) {\n <lib-product-item\n [product]=\"product\"\n [currency]=\"currency()\"\n (productSelected)=\"onProductSelect($event)\"\n (priceSelected)=\"onPriceSelect($event)\">\n </lib-product-item>\n }\n </div>\n} \n\n\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "component", type: ProductItemComponent, selector: "lib-product-item", inputs: ["product", "currency"], outputs: ["productSelected", "priceSelected"] }, { kind: "component", type: ProductItemSkeletonComponent, selector: "lib-product-item-skeleton" }] });
|
|
1469
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.5", type: ProductListComponent, isStandalone: true, selector: "stripe-product-list", inputs: { products: { classPropertyName: "products", publicName: "products", isSignal: true, isRequired: false, transformFunction: null }, currency: { classPropertyName: "currency", publicName: "currency", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { productSelected: "productSelected", priceSelected: "priceSelected" }, ngImport: i0, template: "@if (productsStore.isStatusLoading()) {\n <div class=\"flex justify-start gap-8\">\n @for (item of [1,2,3]; track item) {\n <lib-product-item-skeleton></lib-product-item-skeleton>\n }\n </div>\n}\n\n@if (productsStore.isStatusError() && !productsStore.isStatusLoading()) {\n <div class=\"alert alert-error\">\n <span>{{ productsStore.error() }}</span>\n </div>\n}\n\n@if (!productsStore.hasProducts() && !productsStore.isStatusLoading()) {\n <div class=\"alert alert-info\">\n <span>No products available</span>\n </div>\n}\n\n@if (productsStore.hasProducts()) {\n <div class=\"flex justify-start gap-8\">\n @for (product of products(); track product.id) {\n <lib-product-item\n [product]=\"product\"\n [currency]=\"currency()\"\n (productSelected)=\"onProductSelect($event)\"\n (priceSelected)=\"onPriceSelect($event)\">\n </lib-product-item>\n }\n </div>\n} \n\n\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "component", type: ProductItemComponent, selector: "lib-product-item", inputs: ["product", "currency"], outputs: ["productSelected", "priceSelected"] }, { kind: "component", type: ProductItemSkeletonComponent, selector: "lib-product-item-skeleton" }] });
|
|
1470
1470
|
}
|
|
1471
1471
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.5", ngImport: i0, type: ProductListComponent, decorators: [{
|
|
1472
1472
|
type: Component,
|
|
1473
|
-
args: [{ selector: 'stripe-product-list', standalone: true, imports: [CommonModule, ProductItemComponent, ProductItemSkeletonComponent], template: "@if (productsStore.isStatusLoading()) {\n <div class=\"flex justify-start gap-8\">\n @for (item of [1,2,3]; track item) {\n <lib-product-item-skeleton></lib-product-item-skeleton>\n }\n </div>\n}\n\n@if (productsStore.isStatusError() && !productsStore.isStatusLoading()) {\n <div class=\"alert alert-error\">\n <span>{{ productsStore.error() }}</span>\n </div>\n}\n\n@if (!productsStore.hasProducts()) {\n <div class=\"alert alert-info\">\n <span>No products available</span>\n </div>\n}\n\n@if (productsStore.hasProducts()) {\n <div class=\"flex justify-start gap-8\">\n @for (product of products(); track product.id) {\n <lib-product-item\n [product]=\"product\"\n [currency]=\"currency()\"\n (productSelected)=\"onProductSelect($event)\"\n (priceSelected)=\"onPriceSelect($event)\">\n </lib-product-item>\n }\n </div>\n} \n\n\n" }]
|
|
1473
|
+
args: [{ selector: 'stripe-product-list', standalone: true, imports: [CommonModule, ProductItemComponent, ProductItemSkeletonComponent], template: "@if (productsStore.isStatusLoading()) {\n <div class=\"flex justify-start gap-8\">\n @for (item of [1,2,3]; track item) {\n <lib-product-item-skeleton></lib-product-item-skeleton>\n }\n </div>\n}\n\n@if (productsStore.isStatusError() && !productsStore.isStatusLoading()) {\n <div class=\"alert alert-error\">\n <span>{{ productsStore.error() }}</span>\n </div>\n}\n\n@if (!productsStore.hasProducts() && !productsStore.isStatusLoading()) {\n <div class=\"alert alert-info\">\n <span>No products available</span>\n </div>\n}\n\n@if (productsStore.hasProducts()) {\n <div class=\"flex justify-start gap-8\">\n @for (product of products(); track product.id) {\n <lib-product-item\n [product]=\"product\"\n [currency]=\"currency()\"\n (productSelected)=\"onProductSelect($event)\"\n (priceSelected)=\"onPriceSelect($event)\">\n </lib-product-item>\n }\n </div>\n} \n\n\n" }]
|
|
1474
1474
|
}] });
|
|
1475
1475
|
|
|
1476
1476
|
class EmbeddedSubscriptionComponent {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dotted-labs-ngx-supabase-stripe.mjs","sources":["../../../projects/ngx-supabase-stripe/src/lib/config/stripe.config.ts","../../../projects/ngx-supabase-stripe/src/lib/config/supabase.config.ts","../../../projects/ngx-supabase-stripe/src/lib/config/ngx-supabase-stripe.config.ts","../../../projects/ngx-supabase-stripe/src/lib/services/supabase-client.service.ts","../../../projects/ngx-supabase-stripe/src/lib/services/stripe-client.service.ts","../../../projects/ngx-supabase-stripe/src/lib/models/currency.model.ts","../../../projects/ngx-supabase-stripe/src/lib/store/products.store.ts","../../../projects/ngx-supabase-stripe/src/lib/store/subscriptions.store.ts","../../../projects/ngx-supabase-stripe/src/lib/store/customer.store.ts","../../../projects/ngx-supabase-stripe/src/lib/store/checkout.store.ts","../../../projects/ngx-supabase-stripe/src/lib/store/portal-account.store.ts","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-skeleton/embedded-skeleton.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-skeleton/embedded-skeleton.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-checkout/embedded-checkout.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-checkout/embedded-checkout.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-checkout/return-page/return-page.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-checkout/return-page/return-page.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/product-list/product-item-skeleton/product-item-skeleton.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/product-list/product-item-skeleton/product-item-skeleton.component.html","../../../projects/ngx-supabase-stripe/src/lib/services/utils.service.ts","../../../projects/ngx-supabase-stripe/src/lib/components/product-list/product-item/product-item.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/product-list/product-item/product-item.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/product-list/product-list.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/product-list/product-list.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-subscription/embedded-subscription.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-subscription/embedded-subscription.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-subscription/return-page/subscription-return-page.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-subscription/return-page/subscription-return-page.component.html","../../../projects/ngx-supabase-stripe/src/lib/directives/brand-icon.directive.ts","../../../projects/ngx-supabase-stripe/src/lib/directives/brand-name.directive.ts","../../../projects/ngx-supabase-stripe/src/lib/directives/payment-method-type.directive.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-method/payment-method.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-method/payment-method.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-dialog/payment-intents-dialog.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-dialog/payment-intents-dialog.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-table/payment-intents-table.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-table/payment-intents-table.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscriptions-list/subscription-item-skeleton/subscription-item-skeleton.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscriptions-list/subscription-item-skeleton/subscription-item-skeleton.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscriptions-list/subscription-item/subscription-item.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscriptions-list/subscription-item/subscription-item.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscriptions-list/subscriptions-list.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscriptions-list/subscriptions-list.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscription-card/subscription-card-skeleton/subscription-card-skeleton.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscription-card/subscription-card-skeleton/subscription-card-skeleton.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscription-card/subscription-card.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscription-card/subscription-card.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-list/payment-intents-item-skeleton/payment-intent-item-skeleton.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-list/payment-intents-item-skeleton/payment-intent-item-skeleton.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-list/payment-intents-item/payment-intent-item.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-list/payment-intents-item/payment-intent-item.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-list/payment-intents-list.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-list/payment-intents-list.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscriptions.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscriptions.component.html","../../../projects/ngx-supabase-stripe/src/lib/pages/customer/customer.component.ts","../../../projects/ngx-supabase-stripe/src/lib/pages/customer/customer.component.html","../../../projects/ngx-supabase-stripe/src/public-api.ts","../../../projects/ngx-supabase-stripe/src/dotted-labs-ngx-supabase-stripe.ts"],"sourcesContent":["import { InjectionToken, Provider } from '@angular/core';\n\n/**\n * Stripe configuration interface\n */\nexport interface StripeConfig {\n /**\n * Stripe client secret\n */\n publishableKey: string;\n}\n\nexport const STRIPE_CONFIG = new InjectionToken<StripeConfig>('STRIPE_CONFIG');\n\n/**\n * Provides the Stripe configuration\n * @param config The Stripe configuration\n * @returns An array of providers\n */\nexport function provideStripeConfig(config: StripeConfig): Provider[] {\n return [\n {\n provide: STRIPE_CONFIG,\n useValue: config\n }\n ];\n}","import { InjectionToken, Provider } from '@angular/core';\n\n/**\n * Supabase configuration interface\n */\nexport interface SupabaseConfig {\n /**\n * Supabase project URL\n */\n supabaseUrl: string;\n\n /**\n * Supabase API key\n */\n supabaseKey: string;\n\n /**\n * Supabase schema\n */\n supabaseSchema: 'public' | 'stripe';\n}\n\nexport const SUPABASE_CONFIG = new InjectionToken<SupabaseConfig>('SUPABASE_CONFIG');\n\n/**\n * Provides the Supabase configuration\n * @param config The Supabase configuration\n * @returns An array of providers\n */\nexport function provideSupabaseConfig(config: SupabaseConfig): Provider[] {\n return [\n {\n provide: SUPABASE_CONFIG,\n useValue: config\n }\n ];\n}\n\n","import { EnvironmentProviders, Provider } from '@angular/core';\nimport { STRIPE_CONFIG, StripeConfig } from './stripe.config';\nimport { SUPABASE_CONFIG, SupabaseConfig } from './supabase.config';\n\nexport interface NgxSupabaseStripeConfig {\n supabaseConfig: SupabaseConfig;\n stripeConfig: StripeConfig;\n}\n\n/**\n * Provides the NgxSupabaseStripeConfig object\n * @param config The NgxSupabaseStripeConfig object\n * @returns The NgxSupabaseStripeConfig object\n */\nexport function provideNgxSupabaseStripeConfig(\n config: NgxSupabaseStripeConfig\n): (Provider | EnvironmentProviders)[] {\n const providers: (Provider | EnvironmentProviders)[] = [\n {\n provide: SUPABASE_CONFIG,\n useValue: config.supabaseConfig\n },\n {\n provide: STRIPE_CONFIG,\n useValue: config.stripeConfig\n }\n ];\n\n return providers;\n}\n\n","import { inject, Injectable } from '@angular/core';\nimport { createClient, SupabaseClient } from '@supabase/supabase-js';\nimport { Database } from '../../database.types';\nimport { SUPABASE_CONFIG } from '../config/supabase.config';\nimport { StripeCheckoutSession, StripePaymentIntent, StripeProduct, StripeTables, StripeUpdateType } from '../models/database.model';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class SupabaseClientService {\n private readonly config = inject(SUPABASE_CONFIG);\n private readonly client: SupabaseClient<Database>;\n\n constructor() {\n this.client = createClient<Database>(\n this.config.supabaseUrl,\n this.config.supabaseKey,\n );\n\n console.log('🚀 [SupabaseClientService]: this.client', this.client);\n } \n\n /**\n * Get the Supabase client instance\n */\n public getClient(): SupabaseClient<Database> {\n return this.client;\n }\n\n /**\n * Select payment intents\n * @param query Optional query parameters\n */\n public async selectPaymentIntents(\n query?: {\n columns?: string;\n eq?: Partial<Record<keyof StripePaymentIntent, unknown>>;\n order?: { column: keyof StripePaymentIntent | string; ascending?: boolean };\n limit?: number;\n }\n ): Promise<{ data: StripePaymentIntent[] | null; error: Error | null }> {\n return this.select<StripePaymentIntent>('payment_intents', query);\n }\n\n /**\n * STRIPE CHECKOUT SESSIONS\n */\n\n /**\n * Select checkout sessions\n * @param sessionId The checkout session ID\n */\n public async selectCheckoutSession(\n sessionId: string\n ): Promise<{ data: StripeCheckoutSession | null; error: Error | null }> {\n return this.client\n .schema(this.config.supabaseSchema)\n .rpc('get_stripe_checkout_session', { session_id: sessionId })\n .select('*')\n .single();\n }\n\n /**\n * STRIPE SUBSCRIPTIONS\n */\n\n /**\n * Get all Stripe subscriptions\n */\n public getStripeSubscriptions() {\n return this.client\n .schema(this.config.supabaseSchema)\n .rpc('get_stripe_subscriptions')\n .select('*');\n }\n\n /**\n * Select a Stripe subscription\n * @param subscriptionId The subscription ID\n */\n public selectStripeSubscription(subscriptionId: string) {\n return this.client\n .schema(this.config.supabaseSchema)\n .rpc('get_stripe_subscription', { subscription_id: subscriptionId })\n .select('*');\n }\n\n /**\n * STRIPE PRICES\n */\n\n /**\n * Select Stripe prices\n * @param query Optional query parameters\n */\n public async selectStripePrices() {\n return this.client\n .schema(this.config.supabaseSchema)\n .rpc('get_stripe_prices')\n .select('*');\n }\n\n /**\n * STRIPE PRODUCTS\n */\n\n /**\n * Select Stripe products\n * @param query Optional query parameters\n */\n public async selectStripeProducts() {\n return this.client\n .schema(this.config.supabaseSchema)\n .rpc('get_stripe_products')\n .select('*');\n }\n\n /**\n * Select a Stripe product\n * @param productId The product ID\n */\n public async selectStripeProduct(productId: string) {\n return this.client\n .schema(this.config.supabaseSchema)\n .rpc('get_stripe_product', { product_id: productId })\n .select('*');\n }\n\n /**\n * Update a product\n * @param id The product ID\n * @param data The product data to update\n */\n public async updateProduct(\n id: string,\n data: StripeUpdateType<'products'>\n ): Promise<{ data: StripeProduct | null; error: Error | null }> {\n return this.update<StripeProduct>(\n 'products',\n data,\n { id }\n );\n }\n\n /**\n * Delete a product\n * @param id The product ID\n */\n public async deleteProduct(\n id: string\n ): Promise<{ data: StripeProduct | null; error: Error | null }> {\n return this.delete<StripeProduct>('products', { id });\n }\n\n /**\n * CUSTOMER FUNCTIONS\n */\n\n /**\n * Get customer by email\n * @param email The customer email\n */\n public async getCustomerByEmail(email: string) {\n return this.client.schema(this.config.supabaseSchema).rpc('get_stripe_customer', { customer_email: email });\n }\n\n /**\n * Get customer payment intents\n * @param customerId The customer ID\n */\n public async getCustomerPaymentIntents(customerId: string) {\n return this.client\n .schema(this.config.supabaseSchema)\n .rpc('get_stripe_customer_payment_intents', { customer_id: customerId })\n .select('*');\n }\n\n /**\n * Get customer subscriptions\n * @param customerId The customer ID\n */\n public async getCustomerSubscriptions(customerId: string) {\n return this.client\n .schema(this.config.supabaseSchema)\n .rpc('get_stripe_customer_subscriptions', { customer_id: customerId })\n .select('*');\n }\n\n\n /**\n * CLIENT GENERIC FUNCTIONS\n */\n\n /**\n * Select data from a table\n * @param table The table name\n * @param query Optional query parameters\n */\n public async select<T>(\n table: StripeTables,\n query?: {\n columns?: string;\n eq?: Record<string, any>;\n order?: { column: string; ascending?: boolean };\n limit?: number;\n }\n ): Promise<{ data: T[] | null; error: Error | null }> {\n try {\n let queryBuilder = this.client\n .schema('stripe')\n .from(table)\n .select(query?.columns ?? '*');\n\n if (query?.eq) {\n Object.entries(query.eq).forEach(([key, value]) => {\n queryBuilder = queryBuilder.eq(key, value);\n });\n }\n\n if (query?.order) {\n queryBuilder = queryBuilder.order(\n query.order.column,\n { ascending: query.order.ascending ?? true }\n );\n }\n\n if (query?.limit) {\n queryBuilder = queryBuilder.limit(query.limit);\n }\n\n const { data, error } = await queryBuilder;\n\n if (error) {\n throw error;\n }\n\n return { data: data as T[], error: null };\n } catch (error) {\n return { data: null, error: error as Error };\n }\n }\n\n /**\n * Insert data into a table\n * @param table The table name\n * @param data The data to insert\n */\n public async insert<T>(\n table: StripeTables,\n data: Partial<T>\n ): Promise<{ data: T | null; error: Error | null }> {\n try {\n const { data: result, error } = await (this.client\n .schema('stripe')\n .from(table)\n .insert(data)\n .select()\n .single());\n\n if (error) {\n throw error;\n }\n\n return { data: result as T, error: null };\n } catch (error) {\n return { data: null, error: error as Error };\n }\n }\n\n /**\n * Update data in a table\n * @param table The table name\n * @param data The data to update\n * @param eq The equality conditions\n */\n public async update<T>(\n table: StripeTables,\n data: Partial<T>,\n eq: Record<string, any>\n ): Promise<{ data: T | null; error: Error | null }> {\n try {\n let queryBuilder = this.client\n .schema('stripe')\n .from(table)\n .update(data);\n\n Object.entries(eq).forEach(([key, value]) => {\n queryBuilder = queryBuilder.eq(key, value);\n });\n\n const { data: result, error } = await queryBuilder\n .select()\n .single();\n\n if (error) {\n throw error;\n }\n\n return { data: result as T, error: null };\n } catch (error) {\n return { data: null, error: error as Error };\n }\n }\n\n\n /**\n * Delete data from a table\n * @param table The table name\n * @param eq The equality conditions\n */\n public async delete<T>(\n table: StripeTables,\n eq: Record<string, any>\n ): Promise<{ data: T | null; error: Error | null }> {\n try {\n let queryBuilder = this.client\n .schema('stripe')\n .from(table)\n .delete();\n\n Object.entries(eq).forEach(([key, value]) => {\n queryBuilder = queryBuilder.eq(key, value);\n });\n\n const { data: result, error } = await queryBuilder\n .select()\n .single();\n\n if (error) {\n throw error;\n }\n\n return { data: result as T, error: null };\n } catch (error) {\n return { data: null, error: error as Error };\n }\n }\n}\n","import { inject, Injectable } from '@angular/core';\nimport { loadStripe, Stripe, StripeEmbeddedCheckout } from '@stripe/stripe-js';\nimport type { Stripe as StripeTypes } from 'stripe';\nimport { STRIPE_CONFIG } from '../config/stripe.config';\nimport { StripeCustomerPublic } from '../store/customer.store';\nimport { SupabaseClientService } from './supabase-client.service';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class StripeClientService {\n private readonly config = inject(STRIPE_CONFIG);\n private readonly supabase = inject(SupabaseClientService);\n stripe: Promise<Stripe | null>;\n embeddedCheckout: StripeEmbeddedCheckout | null = null;\n\n constructor() {\n this.stripe = loadStripe(this.config.publishableKey);\n console.log('🔌 [StripeClientService]: Loaded Stripe Client from @stripe/stripe-js');\n }\n\n /**\n * Get the Stripe instance\n */\n public async getStripe(): Promise<Stripe | null> {\n return this.stripe;\n }\n\n /**\n * Initialize the embedded checkout\n * @param clientSecret The client secret for the checkout session\n */\n public async initEmbeddedCheckout(clientSecret: string) {\n const stripe = await this.getStripe();\n this.embeddedCheckout = await stripe?.initEmbeddedCheckout({ \n clientSecret\n }) ?? null;\n }\n\n /**\n * Mount the embedded checkout\n * @param elementId The ID of the element to mount the checkout on\n */\n public mountEmbeddedCheckout(elementId: string = '#embedded-checkout') {\n this.embeddedCheckout?.mount(elementId);\n }\n\n /**\n * Destroy the embedded checkout\n */\n public destroyEmbeddedCheckout() {\n console.log('🧹 [StripeClientService] destroying embedded checkout');\n this.embeddedCheckout?.destroy();\n this.embeddedCheckout = null;\n console.log('🧹 [StripeClientService] destroyed embedded checkout');\n }\n\n /**\n * Create a checkout session\n * @param priceId The price ID for the subscription\n * @param successUrl The URL to redirect to on success\n * @param cancelUrl The URL to redirect to on cancel\n */\n public async createCheckoutSession(\n priceId: string,\n resultPagePath: string,\n customer: StripeCustomerPublic | null\n ): Promise<{ clientSecret: string | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Checkout.Session>('checkout_session', {\n body: {\n priceId,\n resultPagePath,\n customer\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { \n clientSecret: data?.client_secret ?? null, \n error: null \n };\n } catch (error) {\n return { clientSecret: null, error: error as Error };\n }\n }\n\n /**\n * Create a subscription\n * @param priceId The price ID for the subscription\n */\n public async createSubscription(priceId: string, returnPath: string, customer: StripeCustomerPublic | null): Promise<{ clientSecret: string | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Checkout.Session>('create_subscription', {\n body: {\n priceId,\n resultPagePath: returnPath,\n customer\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { clientSecret: data?.client_secret ?? null, error: null };\n } catch (error) {\n return { clientSecret: null, error: error as Error };\n }\n }\n\n /**\n * Update a subscription\n * @param subscriptionId The subscription ID \n * @param params The parameters to update\n */\n public async updateSubscription(\n subscriptionId: string, \n params: any\n ): Promise<{ subscription: StripeTypes.Subscription | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Subscription>('update_subscription', {\n body: {\n subscriptionId,\n params\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { subscription: data, error: null };\n } catch (error) {\n return { subscription: null, error: error as Error };\n }\n }\n\n /**\n * Get a subscription\n * @param subscriptionId The subscription ID\n */\n public async getSubscription(\n subscriptionId: string\n ): Promise<{ subscription: StripeTypes.Subscription | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Subscription>('get_subscription', {\n body: {\n subscriptionId\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { subscription: data, error: null };\n } catch (error) {\n return { subscription: null, error: error as Error };\n }\n }\n\n /**\n * List customer subscriptions\n */\n public async listSubscriptions(): Promise<{ subscriptions: StripeTypes.Subscription[] | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Subscription[]>('list_subscriptions');\n\n if (error) {\n throw error;\n }\n\n return { subscriptions: data, error: null };\n } catch (error) {\n return { subscriptions: null, error: error as Error };\n }\n }\n\n /**\n * Cancel a subscription\n * @param subscriptionId The subscription ID\n */\n public async cancelSubscription(\n subscriptionId: string\n ): Promise<{ subscription: StripeTypes.Subscription | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Subscription>('cancel_subscription', {\n body: {\n subscriptionId\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { subscription: data, error: null };\n } catch (error) {\n return { subscription: null, error: error as Error };\n }\n }\n\n /**\n * Resume a paused subscription\n * @param subscriptionId The subscription ID\n * @param params Optional parameters for resumption\n */\n public async resumeSubscription(\n subscriptionId: string,\n params?: any\n ): Promise<{ subscription: StripeTypes.Subscription | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Subscription>('resume_subscription', {\n body: {\n subscriptionId,\n params\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { subscription: data, error: null };\n } catch (error) {\n return { subscription: null, error: error as Error };\n }\n }\n\n /**\n * Retrieve the payment intent status\n * @param sessionId The session ID of the checkout session\n */\n public async getCheckoutSessionStatus(sessionId: string): Promise<{ \n sessionStatus: StripeTypes.Checkout.Session | null; \n error: Error | null \n }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Checkout.Session>('session_status', {\n body: {\n sessionId\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { sessionStatus: data, error: null };\n } catch (error) {\n console.error('❌ [StripeClientService]: Error retrieving payment intent:', error);\n return { sessionStatus: null, error: error as Error };\n }\n }\n\n /**\n * Create a portal session\n * @param customerId The customer ID\n * @param returnUrl The URL to redirect to after the portal session\n */\n public async createPortalSession(customerId: string, returnUrl: string): Promise<{ url: string | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.BillingPortal.Session>('create_portal_session', {\n body: {\n customerId,\n returnUrl\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { url: data?.url ?? null, error: null };\n } catch (error) {\n return { url: null, error: error as Error };\n }\n }\n\n /**\n * Create a customer\n * @param customerEmail The email of the customer\n */\n public async createCustomer(customerEmail: string): Promise<{ customer: StripeTypes.Customer | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Customer>('create_customer', {\n body: {\n customerEmail\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { customer: data, error: null };\n } catch (error) {\n return { customer: null, error: error as Error };\n }\n }\n\n public async getCustomerPaymentMethods(customerId: string): Promise<{ paymentMethods: StripeTypes.PaymentMethod[] | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.PaymentMethod[]>('customer_payment_methods', {\n body: { customerId }\n });\n\n if (error) {\n throw error;\n }\n\n return { paymentMethods: data, error: null };\n } catch (error) {\n return { paymentMethods: null, error: error as Error };\n }\n }\n\n public async getCustomerPaymentMethod(customerId: string, paymentMethodId: string): Promise<{ paymentMethod: StripeTypes.PaymentMethod | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.PaymentMethod>('customer_payment_method', {\n body: { customerId, paymentMethodId }\n });\n\n if (error) {\n throw error;\n }\n\n return { paymentMethod: data, error: null };\n } catch (error) {\n return { paymentMethod: null, error: error as Error };\n }\n }\n}\n","export enum Currency {\n EUR = 'eur',\n USD = 'usd',\n GBP = 'gbp',\n JPY = 'jpy',\n KRW = 'krw',\n CNY = 'cny',\n INR = 'inr',\n}","import { computed, inject } from '@angular/core';\nimport { patchState, signalStore, withComputed, withHooks, withMethods, withState } from '@ngrx/signals';\nimport { StripePrice, StripeProduct } from '../models/database.model';\nimport { SupabaseClientService } from '../services/supabase-client.service';\nimport { Currency } from '../models/currency.model';\n\nexport type StripeProductPublic = Omit<StripeProduct, 'attrs'> & {\n images: string[];\n prices: {\n details: StripePricePublic;\n recurringInterval: string;\n }[];\n}\n\nexport type StripePricePublic = Omit<StripePrice, 'attrs'>;\n\nexport type ProductsStatus = 'idle' | 'loading' | 'success' | 'error';\n\ntype ProductsState = {\n products: StripeProductPublic[] | null;\n prices: StripePricePublic[] | null;\n status: ProductsStatus;\n error: string | null;\n currency: Currency;\n}\n\nconst initialProductsState: ProductsState = {\n products: null,\n prices: null,\n status: 'idle',\n error: null,\n currency: Currency.EUR,\n};\n\nexport const ProductsStore = signalStore(\n { providedIn: 'root' },\n withState(initialProductsState),\n withComputed((state) => ({\n isStatusLoading: computed(() => state.status() === 'loading'),\n isStatusSuccess: computed(() => state.status() === 'success'),\n isStatusError: computed(() => state.status() === 'error'),\n oneTimeproductsByCurrency: computed(() => state.products()?.filter(product => \n product.prices.some(price => (price.details.type === 'one_time' && price.details.currency === state.currency()))\n ) || []),\n recurringProductsByCurrency: computed(() => state.products()?.filter(product => \n product.prices.some(price => (price.details.type === 'recurring' && price.details.currency === state.currency()))\n ) || []),\n productsByCurrency: computed(() => state.products()?.filter(product => \n product.prices.some(price => (price.details.currency === state.currency()))\n ) || []),\n hasProducts: computed(() => state.products() !== null && state.products()!.length > 0),\n isError: computed(() => state.error())\n })),\n withMethods((store, supabaseService = inject(SupabaseClientService)) => ({\n /**\n * Get products by IDs from the current loaded products\n */\n getProductsByIds(ids: string[]): StripeProductPublic[] {\n console.log('🎮 [ProductsStore] Loading products by ids: ', ids);\n return store.products()?.filter(product => product.id && ids.includes(product.id)) || [];\n },\n\n /**\n * Set the currency filter for products\n */\n setCurrency(currency: Currency): void {\n patchState(store, { currency });\n },\n\n /**\n * Load product by id\n */\n async loadProductById(id: string) {\n patchState(store, { status: 'loading', error: null });\n\n try {\n const { data: product, error: productError } = await supabaseService.selectStripeProduct(id);\n \n if (productError) {\n console.error('🎮 [ProductsStore]: Error loading product', productError);\n patchState(store, { status: 'error', error: (productError as Error).message });\n }\n\n const products: StripeProductPublic[] = [];\n \n if (product && product.length > 0) {\n const productParsed = parseProduct(product[0], store.prices() as StripePrice[]);\n products.push(productParsed);\n }\n\n patchState(store, { status: 'success', products });\n \n } catch (error) {\n patchState(store, { status: 'error', error: (error as Error).message });\n }\n },\n\n /**\n * Load products from Stripe\n */\n async loadProducts() {\n patchState(store, { status: 'loading', error: null });\n\n try {\n const { data: prices, error: pricesError } = await supabaseService.selectStripePrices();\n\n if (pricesError) {\n console.error('🎮 [ProductsStore]: Error loading prices', pricesError);\n patchState(store, { status: 'error', error: (pricesError as Error).message });\n }\n \n patchState(store, { prices: prices || [] });\n\n const { data: stripeProducts, error: productsError } = await supabaseService.selectStripeProducts();\n\n if (productsError) {\n console.error('🎮 [ProductsStore]: Error loading products', productsError);\n patchState(store, {\n status: 'error',\n error: (productsError as Error).message,\n });\n }\n\n if (stripeProducts) {\n {\n const products: StripeProductPublic[] = [];\n\n stripeProducts.forEach(product => {\n products.push(parseProduct(product, store.prices() as StripePrice[]));\n });\n\n console.log('🎮 [ProductsStore] products: ', products);\n\n patchState(store, {\n status: 'success',\n products: products\n });\n }\n }\n\n } catch (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n }\n },\n\n /**\n * Reset the store to initial state\n */\n reset() {\n patchState(store, initialProductsState);\n }\n })),\n withHooks((store) => ({\n async onInit() {\n console.log('🎮 [ProductsStore] onInit');\n\n const products = store.products();\n console.log('🎮 [ProductsStore] products: ', products);\n\n if (!products) {\n console.log('🎮 [ProductsStore] loading products...');\n await store.loadProducts();\n }\n }\n }))\n)\n\nexport function parseProduct(product: StripeProduct, prices: StripePrice[] = []): StripeProductPublic {\n const { attrs, ...mainProperties } = product;\n return {\n ...mainProperties,\n images: (attrs as any)?.images || [],\n prices: prices.filter(price => price.product === product.id).map(price => ({\n details: price,\n recurringInterval: (price?.attrs as any)?.recurring?.interval || 'no-recurring'\n }))\n };\n}\n\n","import { computed, inject } from '@angular/core';\nimport { patchState, signalStore, withComputed, withHooks, withMethods, withState } from '@ngrx/signals';\nimport { StripeSubscription } from '../models/database.model';\nimport { StripeClientService } from '../services/stripe-client.service';\nimport { SupabaseClientService } from '../services/supabase-client.service';\nimport { ProductsStore, StripeProductPublic } from './products.store';\nimport { CustomerStore, StripeCustomerPublic } from './customer.store';\n\nexport type StripeSubscriptionCancellationDetails = {\n cancel_at_period_end: boolean;\n cancel_at: number;\n canceled_at: number;\n cancellation_details: {\n comment: string;\n feedback: string;\n reason: string;\n }\n}\n\nexport type StripeSubscriptionPlan = {\n amount: number;\n active: boolean;\n interval: string;\n productId: string;\n}\n\nexport type StripeSubscriptionPublic = Omit<StripeSubscription, 'attrs'> & {\n status: string;\n plan: StripeSubscriptionPlan;\n cancel: StripeSubscriptionCancellationDetails;\n product?: StripeProductPublic | null;\n};\n\nexport type SubscriptionStatus = 'idle' | 'loading' | 'success' | 'error';\n\nexport interface SubscriptionState {\n subscriptions: StripeSubscriptionPublic[] | null;\n currentSubscription: StripeSubscriptionPublic | null;\n status: SubscriptionStatus;\n error: string | null;\n sessionStatus: any | null;\n}\n\nconst initialSubscriptionState: SubscriptionState = {\n subscriptions: null,\n currentSubscription: null,\n status: 'idle',\n error: null,\n sessionStatus: null,\n};\n\nexport const SubscriptionsStore = signalStore(\n { providedIn: 'root' },\n withState(initialSubscriptionState),\n withComputed((state) => ({\n isStatusLoading: computed(() => state.status() === 'loading'),\n isStatusSuccess: computed(() => state.status() === 'success'),\n isStatusError: computed(() => state.status() === 'error'),\n hasSubscriptions: computed(() => state.subscriptions() !== null && state.subscriptions()!.length > 0),\n isError: computed(() => state.error()),\n })),\n withMethods((store, stripeService = inject(StripeClientService), \n supabaseService = inject(SupabaseClientService), \n productsStore = inject(ProductsStore),\n customerStore = inject(CustomerStore)) => ({\n /**\n * Create a subscription\n * @param priceId The price ID for the subscription\n */\n async createSubscription(priceId: string, returnPath: string, customer: StripeCustomerPublic | null) {\n patchState(store, { status: 'loading', error: null });\n\n try {\n const { clientSecret, error } = await stripeService.createSubscription(priceId, returnPath, customer);\n console.log('🔍 [SubscriptionsStore] created subscription', clientSecret, error);\n \n if (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n } else {\n const stripe = await stripeService.getStripe();\n\n if (!stripe) {\n patchState(store, {\n status: 'error',\n error: 'No Stripe instance returned',\n });\n } else {\n await stripeService.initEmbeddedCheckout(clientSecret as string);\n stripeService.mountEmbeddedCheckout();\n\n patchState(store, {\n status: 'success',\n });\n }\n }\n } catch (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n }\n },\n\n /**\n * Load all subscriptions for the current customer\n */\n async loadSubscriptions() {\n patchState(store, { status: 'loading', error: null });\n\n try {\n const { data: subscriptions, error } = await supabaseService.getStripeSubscriptions();\n console.log('🔍 [SubscriptionsStore] loaded subscriptions', subscriptions);\n\n const parsedSubscriptions = subscriptions?.map((subscription) => {\n const parsedSubscription = parseSubscription(subscription as StripeSubscription);\n \n // Get the product associated with this subscription\n const productId = parsedSubscription.plan.productId;\n if (productId && productsStore.products()) {\n const product = productsStore.products()?.find(p => p.id === productId);\n if (product) {\n parsedSubscription.product = product;\n }\n }\n \n return parsedSubscription;\n });\n\n if (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n } else {\n patchState(store, {\n status: 'success',\n subscriptions: parsedSubscriptions\n });\n }\n } catch (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n }\n },\n\n /**\n * Get a specific subscription\n * @param subscriptionId The subscription ID\n */\n async getSubscription(subscriptionId: string) {\n patchState(store, { status: 'loading', error: null });\n\n try {\n const { data, error } = await supabaseService.selectStripeSubscription(subscriptionId);\n const [subscription] = data || [];\n console.log('🔍 [SubscriptionsStore] got subscription', subscription, error);\n\n const parsedSubscription = parseSubscription(subscription as StripeSubscription);\n\n // Get the product associated with this subscription\n const productId = parsedSubscription.plan.productId;\n if (productId && productsStore.products()) {\n const product = productsStore.products()?.find(p => p.id === productId);\n if (product) {\n parsedSubscription.product = product;\n }\n }\n\n if (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n } else {\n patchState(store, {\n status: 'success',\n currentSubscription: parsedSubscription\n });\n }\n } catch (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n }\n },\n\n /**\n * Get the status of a checkout subcription session\n * @param sessionId The ID of the checkout subcription session\n */\n async getSessionStatus({sessionId}: {sessionId: string}) {\n patchState(store, { status: 'loading', error: null });\n\n try {\n const { sessionStatus, error } = await stripeService.getCheckoutSessionStatus(sessionId);\n \n if (error) {\n patchState(store, { status: 'error', error: (error as Error).message });\n } else {\n patchState(store, { status: 'success', sessionStatus });\n }\n\n } catch (error) {\n patchState(store, { status: 'error', error: (error as Error).message });\n }\n },\n\n /**\n * Destroy the embedded subscription\n */\n destroyEmbeddedSubscription() {\n stripeService.destroyEmbeddedCheckout();\n },\n\n /**\n * Reset the store to initial state\n */\n reset() {\n patchState(store, initialSubscriptionState);\n }\n })),\n withHooks(() => {\n const productsStore = inject(ProductsStore);\n\n if (!productsStore.hasProducts()) {\n productsStore.loadProducts();\n console.log('🔍 [SubscriptionsStore] loading products');\n }\n\n return {\n onInit() {\n console.log('🔍 [SubscriptionsStore] initialized');\n },\n onDestroy() {\n console.log('🧹 [SubscriptionsStore] destroyed');\n }\n }\n })\n);\n\nexport function parseSubscription(subscription: StripeSubscription): StripeSubscriptionPublic {\n const subscriptionAttrs = subscription.attrs as any;\n \n return {\n ...subscription,\n status: subscriptionAttrs.status,\n plan: {\n amount: subscriptionAttrs.plan.amount,\n active: subscriptionAttrs.plan.active,\n interval: subscriptionAttrs.plan.interval,\n productId: subscriptionAttrs.plan.product,\n },\n cancel: {\n cancel_at_period_end: subscriptionAttrs.cancel_at_period_end ?? false,\n cancel_at: subscriptionAttrs.cancel_at ?? null,\n canceled_at: subscriptionAttrs.canceled_at ?? null,\n cancellation_details: subscriptionAttrs.cancellation_details ?? {\n comment: null,\n feedback: null,\n reason: null\n }\n },\n product: subscriptionAttrs.product ? subscriptionAttrs.product as StripeProductPublic : undefined\n };\n}","import { computed, inject } from '@angular/core';\nimport { patchState, signalStore, withComputed, withHooks, withMethods, withState } from '@ngrx/signals';\nimport { addEntity, removeEntity, setAllEntities, setEntity, updateEntity, upsertEntity, withEntities } from '@ngrx/signals/entities';\nimport type { Stripe as StripeTypes } from 'stripe';\nimport { StripeCustomer, StripePaymentIntent } from '../models/database.model';\nimport { StripeClientService } from '../services/stripe-client.service';\nimport { SupabaseClientService } from '../services/supabase-client.service';\nimport { ProductsStore } from './products.store';\nimport { parseSubscription, StripeSubscriptionPublic } from './subscriptions.store';\n\nexport type CustomerStatus = 'idle' | 'loading' | 'success' | 'error';\n\nexport type StripePaymentIntentsPublic = Omit<StripePaymentIntent, 'attrs'> & {\n status: string;\n invoiceId: string;\n liveMode: boolean;\n confirmationMethod: string;\n paymentMethodId: string;\n paymentMethod?: PaymentMethodEntity;\n};\n\nexport type StripeCustomerPublic = Omit<StripeCustomer, 'attrs'>;\n\nexport type PaymentMethodEntity = StripeTypes.PaymentMethod;\n\nexport interface CustomerState {\n customer: {\n data: StripeCustomerPublic | null;\n status: CustomerStatus;\n error: string | null;\n };\n paymentIntents: {\n data: StripePaymentIntentsPublic[];\n status: CustomerStatus;\n error: string | null;\n };\n subscriptions: {\n data: StripeSubscriptionPublic[];\n status: CustomerStatus;\n error: string | null;\n };\n paymentMethodsStatus: CustomerStatus;\n paymentMethodsError: string | null;\n}\n\nconst initialCustomerState: CustomerState = {\n customer: { \n status: 'idle', \n data: null,\n error: null \n },\n paymentIntents: {\n data: [],\n status: 'idle',\n error: null,\n },\n subscriptions: {\n data: [], \n status: 'idle',\n error: null,\n },\n paymentMethodsStatus: 'idle',\n paymentMethodsError: null,\n};\n\n\nexport const CustomerStore = signalStore(\n { providedIn: 'root' },\n withState(initialCustomerState),\n withEntities<PaymentMethodEntity>(),\n withComputed((state) => ({\n isPaymentIntentsStatusLoading: computed(() => state.paymentIntents.status() === 'loading'),\n isPaymentIntentsStatusSuccess: computed(() => state.paymentIntents.status() === 'success'),\n isPaymentIntentsStatusError: computed(() => state.paymentIntents.status() === 'error'),\n isSubscriptionsStatusLoading: computed(() => state.subscriptions.status() === 'loading'),\n isSubscriptionsStatusSuccess: computed(() => state.subscriptions.status() === 'success'),\n isSubscriptionsStatusError: computed(() => state.subscriptions.status() === 'error'),\n hasSubscriptions: computed(() => state.subscriptions.data() !== null && state.subscriptions.data()!.length > 0),\n hasPaymentIntents: computed(() => state.paymentIntents.data() !== null && state.paymentIntents.data()!.length > 0),\n firstSubscription: computed(() => state.subscriptions.data()?.[0]),\n restSubscriptions: computed(() => state.subscriptions.data()?.slice(1)),\n isError: computed(() => state.paymentIntents.error()),\n isPaymentMethodsStatusLoading: computed(() => state.paymentMethodsStatus() === 'loading'),\n isPaymentMethodsStatusSuccess: computed(() => state.paymentMethodsStatus() === 'success'),\n isPaymentMethodsStatusError: computed(() => state.paymentMethodsStatus() === 'error'),\n hasPaymentMethods: computed(() => state.entities().length > 0),\n paymentMethods: computed(() => state.entities()),\n })),\n withMethods((state, supabaseService = inject(SupabaseClientService), stripeService = inject(StripeClientService), productsStore = inject(ProductsStore)) => ({\n /**\n * Load customer\n * @param customerEmail The customer email\n */\n async loadCustomer(customerEmail: string) {\n patchState(state, { customer: { status: 'loading', data: null, error: null } });\n\n const { data, error } = await supabaseService.getCustomerByEmail(customerEmail);\n const [customer] = data as StripeCustomerPublic[];\n\n if (error) {\n patchState(state, { customer: { error: error.message, status: 'error', data: null } });\n } else {\n \n if (customer) {\n this.loadPaymentIntents(customer.id as string);\n this.loadSubscriptions(customer.id as string);\n this.loadPaymentMethods(customer.id as string);\n\n patchState(state, { customer: { data: customer, status: 'success', error: null } });\n } else {\n this.createCustomer(customerEmail);\n }\n\n }\n },\n\n /**\n * Create a customer\n * @param customerEmail The customer email\n */\n async createCustomer(customerEmail: string) {\n const { customer, error } = await stripeService.createCustomer(customerEmail);\n\n if (error) {\n patchState(state, { customer: { error: error.message, status: 'error', data: null } });\n } else {\n patchState(state, { customer: { data: customer as StripeCustomerPublic, status: 'success', error: null } });\n }\n },\n\n /**\n * Load payment intents\n * @param customerId The customer ID\n */\n async loadPaymentIntents(customerId: string) {\n patchState(state, { paymentIntents: { status: 'loading', data: [], error: null } });\n\n const { data, error } = await supabaseService.getCustomerPaymentIntents(customerId);\n const paymentIntents = data?.map((paymentIntent) => parsePaymentIntent(paymentIntent, state.entityMap()));\n\n if (error) {\n patchState(state, { paymentIntents: { error: error.message, status: 'error', data: [] } });\n } else {\n patchState(state, { paymentIntents: { data: paymentIntents ?? [], status: 'success', error: null } });\n }\n }, \n\n /**\n * Load subscriptions\n * @param customerId The customer ID\n */\n async loadSubscriptions(customerId: string) {\n patchState(state, { subscriptions: { data: [], status: 'loading', error: null } });\n\n const { data, error } = await supabaseService.getCustomerSubscriptions(customerId);\n \n if (error) {\n patchState(state, { subscriptions: { error: error.message, status: 'error', data: [] } });\n } else {\n const subscriptions = data.map((subscription) => {\n const parsedSubscription = parseSubscription(subscription);\n \n // Get the product associated with this subscription\n const productId = parsedSubscription.plan.productId;\n if (productId && productsStore.products()) {\n const product = productsStore.products()?.find(p => p.id === productId);\n if (product) {\n parsedSubscription.product = product;\n }\n }\n \n return parsedSubscription;\n });\n\n console.log('🔍 [CustomerStore] subscriptions: ', subscriptions);\n \n patchState(state, { subscriptions: { data: subscriptions ?? [], status: 'success', error: null } });\n }\n },\n\n /**\n * Load payment methods for a customer\n * @param customerId The customer ID\n */\n async loadPaymentMethods(customerId: string) {\n patchState(state, { \n paymentMethodsStatus: 'loading', \n paymentMethodsError: null \n });\n\n const { paymentMethods, error } = await stripeService.getCustomerPaymentMethods(customerId);\n\n if (error) {\n patchState(state, { \n paymentMethodsStatus: 'error', \n paymentMethodsError: error.message \n });\n } else {\n patchState(state, \n setAllEntities(paymentMethods ?? []),\n { \n paymentMethodsStatus: 'success', \n paymentMethodsError: null \n }\n );\n }\n },\n\n /**\n * Load a single payment method and add/update it in the entity collection\n * @param customerId The customer ID\n * @param paymentMethodId The payment method ID\n */\n async loadPaymentMethod(customerId: string, paymentMethodId: string) {\n patchState(state, { \n paymentMethodsStatus: 'loading', \n paymentMethodsError: null \n });\n\n const { paymentMethod, error } = await stripeService.getCustomerPaymentMethod(customerId, paymentMethodId);\n\n if (error) {\n patchState(state, { \n paymentMethodsStatus: 'error', \n paymentMethodsError: error.message \n });\n } else if (paymentMethod) {\n }\n\n if (paymentMethod) {\n patchState(state, \n upsertEntity(paymentMethod),\n { \n paymentMethodsStatus: 'success', \n paymentMethodsError: null \n }\n );\n } else {\n patchState(state, { \n paymentMethodsStatus: 'error', \n paymentMethodsError: 'Payment method not found' \n });\n }\n },\n })),\n withHooks(() => {\n return {\n onInit() {\n const productsStore = inject(ProductsStore);\n\n if (!productsStore.hasProducts()) {\n console.log('🔍 [CustomerStore] loading products...');\n productsStore.loadProducts();\n }\n console.log('🔍 [CustomerStore] initialized');\n },\n onDestroy() {\n console.log('🧹 [CustomerStore] destroyed');\n }\n }\n })\n);\n\nexport function parsePaymentIntent(\n paymentIntent: StripePaymentIntent, \n paymentMethodsMap: Record<string, PaymentMethodEntity> = {}\n): StripePaymentIntentsPublic {\n console.log('🔍 [CustomerStore] paymentIntent: ', paymentIntent);\n\n const paymentIntentAttrs = paymentIntent.attrs as any;\n const paymentMethodId = paymentIntentAttrs.payment_method;\n \n return {\n ...paymentIntent,\n status: paymentIntentAttrs.status,\n invoiceId: paymentIntentAttrs.invoice as string,\n liveMode: paymentIntentAttrs.livemode as boolean,\n confirmationMethod: paymentIntentAttrs.confirmation_method,\n paymentMethodId,\n paymentMethod: paymentMethodId ? paymentMethodsMap[paymentMethodId] : undefined,\n };\n}","import { computed, inject } from '@angular/core';\nimport { patchState, signalStore, withComputed, withHooks, withMethods, withState } from '@ngrx/signals';\nimport { StripeClientService } from '../services/stripe-client.service';\nimport { CustomerStore, StripeCustomerPublic } from './customer.store';\nimport type { Stripe as StripeTypes } from 'stripe';\n\nexport type ICheckoutSessionStatus = StripeTypes.Checkout.Session;\n\nexport type CheckoutStatus = 'idle' | 'loading' | 'success' | 'error';\n\ntype CheckoutState = {\n status: CheckoutStatus;\n sessionId: string | null;\n returnPagePath: string;\n error: string | null;\n sessionStatus: ICheckoutSessionStatus | null;\n}\n\nconst initialCheckoutState: CheckoutState = {\n status: 'idle',\n sessionId: null,\n returnPagePath: '/return',\n error: null,\n sessionStatus: null\n};\n\nexport const CheckoutStore = signalStore(\n { providedIn: 'root' },\n withState(initialCheckoutState),\n withComputed((state) => ({\n isStatusLoading: computed(() => state.status() === 'loading'),\n isStatusSuccess: computed(() => state.status() === 'success'),\n isStatusError: computed(() => state.status() === 'error'),\n paymentStatus: computed(() => state.sessionStatus()?.status),\n isPaymentComplete: computed(() => state.sessionStatus()?.status === 'complete'),\n isPaymentProcessing: computed(() => state.sessionStatus()?.status === 'open'),\n isError: computed(() => state.error())\n })),\n withMethods((store, stripeService = inject(StripeClientService), customerStore = inject(CustomerStore)) => ({\n /**\n * Create a checkout session\n * @param priceId The price ID to checkout\n * @param returnPagePath The return page path after checkout\n */\n async createCheckoutSession({priceId, returnPagePath, customerEmail}: {priceId: string, returnPagePath: string, customerEmail: string | null}) {\n patchState(store, { status: 'loading', error: null });\n\n try {\n let customer: StripeCustomerPublic | null = null;\n \n if (customerEmail) {\n customer = customerStore.customer().data;\n }\n\n const { clientSecret, error } = await stripeService.createCheckoutSession(priceId, returnPagePath, customer);\n\n if (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n } else {\n const stripe = await stripeService.getStripe();\n\n if (!stripe) {\n patchState(store, {\n status: 'error',\n error: 'No Stripe instance returned',\n });\n } else {\n await stripeService.initEmbeddedCheckout(clientSecret as string);\n stripeService.mountEmbeddedCheckout();\n\n patchState(store, {\n status: 'success',\n });\n }\n }\n\n } catch (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n }\n },\n\n /**\n * Get the status of a checkout session\n * @param sessionId The ID of the checkout session\n */\n async getSessionStatus({sessionId}: {sessionId: string}) {\n patchState(store, { status: 'loading', error: null });\n\n try {\n const { sessionStatus, error } = await stripeService.getCheckoutSessionStatus(sessionId);\n \n if (error) {\n patchState(store, { status: 'error', error: (error as Error).message });\n } else {\n patchState(store, { status: 'success', sessionStatus });\n }\n\n } catch (error) {\n patchState(store, { status: 'error', error: (error as Error).message });\n }\n },\n\n\n /**\n * Destroy the embedded checkout\n */\n destroyEmbeddedCheckout() {\n stripeService.destroyEmbeddedCheckout();\n },\n \n /**\n * Reset the store to initial state\n */\n reset() {\n patchState(store, initialCheckoutState);\n }\n })),\n withHooks({\n onInit() {\n console.log('🔍 [CheckoutStore] initialized');\n },\n onDestroy() {\n console.log('🧹 [CheckoutStore] destroyed');\n }\n })\n) ","import { computed, inject } from '@angular/core';\nimport { patchState, signalStore, withComputed, withMethods, withState } from '@ngrx/signals';\nimport { StripeClientService } from '../services/stripe-client.service';\n\nexport interface PortalSessionResponse {\n url: string;\n}\n\nexport type PortalStatus = 'idle' | 'loading' | 'success' | 'error';\n\nexport interface PortalState {\n status: PortalStatus;\n error: string | null;\n portalUrl: string | null;\n}\n\nconst initialPortalState: PortalState = {\n status: 'idle',\n error: null,\n portalUrl: null\n};\n\nexport const PortalAccountStore = signalStore(\n { providedIn: 'root' },\n withState(initialPortalState),\n withComputed((state) => ({\n isStatusIdle: computed(() => state.status() === 'idle'),\n isStatusLoading: computed(() => state.status() === 'loading'),\n isStatusSuccess: computed(() => state.status() === 'success'),\n isStatusError: computed(() => state.status() === 'error'),\n })),\n withMethods((store, stripeService = inject(StripeClientService)) => ({\n /**\n * Creates a customer portal session and redirects to the URL\n * @param customerId Stripe customer ID\n * @param returnUrl URL to redirect to after the portal session\n */\n async createPortalSession(customerId: string, returnUrl: string): Promise<void> {\n patchState(store, { status: 'loading', error: null, portalUrl: null });\n\n try {\n const { url, error } = await stripeService.createPortalSession(customerId, returnUrl);\n\n if (error) {\n throw new Error(error.message);\n }\n\n if (!url) {\n throw new Error('No se pudo crear la sesión del portal');\n }\n\n patchState(store, {\n status: 'success',\n portalUrl: url\n });\n\n window.location.href = url;\n } catch (error) {\n console.error('🚨 [PortalAccountStore]', error);\n \n const errorMessage = error instanceof Error ? error.message : 'Error desconocido';\n \n patchState(store, {\n status: 'error',\n error: errorMessage\n });\n }\n },\n\n /**\n * Resets the store to initial state\n */\n reset(): void {\n patchState(store, initialPortalState);\n }\n }))\n); ","import { Component } from '@angular/core';\n\n@Component({\n selector: 'lib-embedded-skeleton',\n templateUrl: './embedded-skeleton.component.html',\n standalone: true\n})\nexport class EmbeddedSkeletonComponent {} ","<div class=\"w-full max-w-md mx-auto p-4\">\n <!-- Header skeleton -->\n <div class=\"flex items-center gap-4 mb-6\">\n <div class=\"skeleton w-16 h-16 rounded-lg\"></div>\n <div class=\"skeleton h-6 w-48\"></div>\n </div>\n\n <!-- Price skeleton -->\n <div class=\"mb-8\">\n <div class=\"skeleton h-10 w-32 mb-2\"></div>\n <div class=\"skeleton h-4 w-24\"></div>\n </div>\n\n <!-- Payment form skeleton -->\n <div class=\"space-y-4\">\n <!-- Email field -->\n <div class=\"skeleton h-12 w-full\"></div>\n \n <!-- Card info field -->\n <div class=\"skeleton h-12 w-full\"></div>\n \n <!-- Name field -->\n <div class=\"skeleton h-12 w-full\"></div>\n \n <!-- Country selector -->\n <div class=\"skeleton h-12 w-full\"></div>\n \n <!-- Submit button -->\n <div class=\"skeleton h-12 w-full mt-6\"></div>\n </div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, computed, inject, input, OnInit } from '@angular/core';\nimport { CheckoutStore } from '../../store/checkout.store';\nimport { CustomerStore } from '../../store/customer.store';\nimport { EmbeddedSkeletonComponent } from '../embedded-skeleton/embedded-skeleton.component';\n\n@Component({\n selector: 'lib-embedded-checkout',\n templateUrl: './embedded-checkout.component.html',\n standalone: true,\n imports: [CommonModule, EmbeddedSkeletonComponent],\n})\nexport class EmbeddedCheckoutComponent implements OnInit {\n public readonly checkoutStore = inject(CheckoutStore);\n public readonly customerStore = inject(CustomerStore);\n \n public readonly priceId = input.required<string>();\n public readonly returnPagePath = input<string>('/return');\n \n public readonly customer = computed(() => this.customerStore.customer().data);\n\n async ngOnInit() {\n this.createCheckoutSession();\n }\n\n private createCheckoutSession() {\n const baseUrl = window.location.origin;\n const returnPath = `${baseUrl}${this.returnPagePath()}`;\n\n // Create the checkout session\n this.checkoutStore.createCheckoutSession({\n priceId: this.priceId(),\n returnPagePath: returnPath,\n customerEmail: this.customer()?.email ?? ''\n });\n }\n\n ngOnDestroy() {\n this.checkoutStore.destroyEmbeddedCheckout();\n }\n} ","<div class=\"checkout-container\">\n @if (checkoutStore.isStatusLoading()) {\n <lib-embedded-skeleton />\n }\n \n @if (checkoutStore.isStatusError()) {\n <div class=\"error\">\n <p>Error: {{ checkoutStore.error() }}</p>\n </div>\n }\n <div id=\"embedded-checkout\"></div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, OnInit, inject, input } from '@angular/core';\nimport { ActivatedRoute, Router } from '@angular/router';\nimport { CheckoutStore } from '../../../store/checkout.store';\n\n@Component({\n selector: 'lib-checkout-return-page',\n templateUrl: './return-page.component.html',\n standalone: true,\n imports: [CommonModule],\n})\nexport class ReturnPageComponent implements OnInit {\n private readonly route = inject(ActivatedRoute);\n private readonly router = inject(Router);\n \n public readonly checkoutStore = inject(CheckoutStore);\n \n public readonly returnUrl = input<string>('/');\n \n async ngOnInit() {\n this.route.queryParams.subscribe(async params => {\n const sessionId = params['session_id'];\n this.getSessionStatus(sessionId);\n });\n }\n\n private async getSessionStatus(sessionId: string) {\n if (sessionId) {\n await this.checkoutStore.getSessionStatus({ sessionId });\n } else {\n console.error('Missing session_id parameter in URL');\n }\n }\n \n public navigate(): void {\n this.router.navigateByUrl(this.returnUrl());\n }\n} ","<div class=\"return-page-container\">\n @if (checkoutStore.isStatusLoading()) {\n <div class=\"loading-state\">\n <div class=\"spinner\"></div>\n <p>Verifying your payment status...</p>\n </div>\n }\n\n @if (checkoutStore.isStatusSuccess() && checkoutStore.isPaymentComplete()) {\n <div class=\"alert alert-success alert-soft flex flex-col items-center gap-4\">\n <div class=\"flex items-center gap-4\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" fill=\"none\" viewBox=\"0 0 24 24\" stroke-width=\"1.5\" stroke=\"currentColor\" class=\"w-12 h-12\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 12.75L11.25 15 15 9.75M21 12a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n <h2 class=\"status-title\">¡Payment completed successfully!</h2>\n </div>\n </div>\n }\n\n @if (checkoutStore.isStatusSuccess() && checkoutStore.isPaymentProcessing()) {\n <div class=\"alert alert-info alert-soft flex flex-col items-center gap-4\">\n <div class=\"flex items-center gap-4\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" fill=\"none\" viewBox=\"0 0 24 24\" stroke-width=\"1.5\" stroke=\"currentColor\" class=\"w-12 h-12\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M12 6v6h4.5m4.5 0a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n <h2 class=\"status-title\">Payment in processing</h2>\n </div>\n <p class=\"status-message\">Your payment is being processed. You will receive an email confirmation when it is complete.</p>\n </div>\n }\n\n @if (checkoutStore.isStatusError()) {\n <div class=\"alert alert-error alert-soft flex flex-col items-center gap-4\">\n <div class=\"flex items-center gap-4\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" fill=\"none\" viewBox=\"0 0 24 24\" stroke-width=\"1.5\" stroke=\"currentColor\" class=\"w-12 h-12\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M12 9v3.75m-9.303 3.376c-.866 1.5.217 3.374 1.948 3.374h14.71c1.73 0 2.813-1.874 1.948-3.374L13.949 3.378c-.866-1.5-3.032-1.5-3.898 0L2.697 16.126zM12 15.75h.007v.008H12v-.008z\" />\n </svg>\n <h2 class=\"status-title\">An error occurred</h2>\n </div>\n @if (checkoutStore.error()) {\n <p class=\"status-message\">{{ checkoutStore.error() }}</p>\n } @else {\n <p class=\"status-message\">The payment could not be processed. Please try again or contact support.</p>\n }\n </div>\n }\n\n <div class=\"flex justify-end w-full pt-4\">\n <button class=\"btn btn-outline\" (click)=\"navigate()\">Back</button>\n </div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component } from '@angular/core';\n\n@Component({\n selector: 'lib-product-item-skeleton',\n standalone: true,\n imports: [CommonModule],\n templateUrl: './product-item-skeleton.component.html'\n})\nexport class ProductItemSkeletonComponent {} ","<div class=\"card bg-base-100 shadow-xl w-[350px]\">\n <figure>\n <div class=\"skeleton h-48 w-full\"></div>\n </figure>\n <div class=\"card-body\">\n <div class=\"skeleton h-8 w-32\"></div>\n <div class=\"skeleton h-6 w-48\"></div>\n <div class=\"skeleton h-4 w-full\"></div>\n <div class=\"skeleton h-4 w-3/4\"></div>\n <div class=\"card-actions justify-end mt-4\">\n <div class=\"skeleton h-10 w-24\"></div>\n </div>\n </div>\n</div> ","import { Injectable } from '@angular/core';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class UtilsService {\n\n public formatAmount(amount: number, currency = 'EUR'): string {\n if (!amount) return 'N/A';\n\n const formatter = new Intl.NumberFormat(currency.toLocaleUpperCase() === 'EUR' ? 'es-ES' : 'en-US', {\n style: 'currency',\n currency: currency || 'USD',\n });\n \n return formatter.format(amount / 100);\n }\n \n public formatDate(timestamp: number | string): string {\n if (!timestamp) return 'N/A';\n \n const date = typeof timestamp === 'number'\n ? new Date(timestamp * 1000)\n : new Date(timestamp);\n \n return date.toLocaleDateString('es-ES', {\n year: 'numeric',\n month: 'short',\n day: 'numeric'\n });\n }\n \n public getStatusBadgeClass(status: string): string {\n switch (status) {\n case 'active':\n case 'succeeded':\n case 'paid':\n return 'badge-success';\n case 'failed':\n case 'canceled':\n case 'unpaid':\n return 'badge-error';\n case 'pending':\n case 'processing':\n case 'trialing':\n return 'badge-warning';\n default:\n return 'badge-ghost';\n }\n }\n}\n","import { CommonModule } from '@angular/common';\nimport { Component, computed, inject, input, output } from '@angular/core';\nimport { DomSanitizer } from '@angular/platform-browser';\nimport { UtilsService } from '../../../services/utils.service';\nimport { StripePricePublic, StripeProductPublic } from '../../../store/products.store';\nimport { Currency } from '../../../models/currency.model';\n\n@Component({\n selector: 'lib-product-item',\n standalone: true,\n imports: [CommonModule],\n templateUrl: './product-item.component.html'\n})\nexport class ProductItemComponent {\n public readonly product = input.required<StripeProductPublic>();\n public readonly currency = input<Currency>(Currency.EUR);\n\n public readonly productSelected = output<StripeProductPublic>();\n public readonly priceSelected = output<StripePricePublic>();\n\n public readonly utils = inject(UtilsService);\n private readonly sanitizer = inject(DomSanitizer);\n\n public price = computed(() => this.product().prices.find(price => price.details.currency === this.currency()));\n\n public sanitizedImage = computed(() => {\n const imageUrl = this.product().images?.[0];\n return imageUrl ? this.sanitizer.bypassSecurityTrustUrl(imageUrl) : null;\n });\n\n onSelect() {\n this.productSelected.emit(this.product());\n this.priceSelected.emit(this.price()?.details as StripePricePublic);\n }\n} ","<div class=\"card bg-base-100 shadow-xl max-w-sm mx-auto rounded-3xl w-[350px]\">\n <!-- Header with image and favorite icon -->\n <div class=\"relative\">\n @if (sanitizedImage()) {\n <figure class=\"bg-gradient-to-br from-base-200 to-base-300\">\n <img \n [src]=\"sanitizedImage()\" \n alt=\"{{ product().name }}\" \n class=\"h-64 w-full object-cover p-8 rounded-t-3xl\" />\n </figure>\n } @else {\n <div class=\"h-64 bg-gradient-to-br from-base-200 to-base-300 flex items-center justify-center\">\n <div class=\"text-base-content/50 text-6xl\">📦</div>\n </div>\n }\n </div>\n\n <div class=\"card-body p-6 flex flex-col h-full\">\n <!-- Product title -->\n <h2 class=\"card-title text-xl font-bold text-base-content\">\n {{ product().name }}\n </h2>\n\n <!-- Description (moved under title) -->\n @if (product().description) {\n <p class=\"text-base-content/70 text-sm mb-4 line-clamp-3\">\n {{ product().description }}\n </p>\n }\n\n <!-- Price options as text -->\n <div class=\"flex justify-between gap-2\">\n <span class=\"text-xl font-bold text-base-content\">\n @if (price()?.details?.type === 'recurring') {\n {{ utils.formatAmount(price()?.details?.unit_amount ?? 0, price()?.details?.currency ?? 'EUR') }}/{{ price()?.recurringInterval === 'month' ? 'mo' : 'yr' }}\n } @else {\n {{ utils.formatAmount(price()?.details?.unit_amount ?? 0, price()?.details?.currency ?? 'EUR') }}\n }\n </span>\n\n <!-- Status badge (only show if inactive) -->\n @if (!product().active) {\n <div class=\"mt-4\">\n <div class=\"badge badge-warning badge-sm\">Inactive</div>\n </div>\n } @else {\n <button \n class=\"btn btn-primary\"\n (click)=\"onSelect()\">\n Buy now\n </button>\n }\n </div>\n </div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, inject, input, output } from '@angular/core';\nimport { ProductsStore, StripePricePublic, StripeProductPublic } from '../../store/products.store';\nimport { ProductItemSkeletonComponent } from './product-item-skeleton/product-item-skeleton.component';\nimport { ProductItemComponent } from './product-item/product-item.component';\nimport { Currency } from '../../models/currency.model';\n\n@Component({\n selector: 'stripe-product-list',\n standalone: true,\n imports: [CommonModule, ProductItemComponent, ProductItemSkeletonComponent],\n templateUrl: './product-list.component.html'\n})\nexport class ProductListComponent {\n public readonly productsStore = inject(ProductsStore);\n\n public readonly products = input<StripeProductPublic[]>([]);\n public readonly currency = input<Currency>(Currency.EUR);\n\n public readonly productSelected = output<StripeProductPublic>();\n public readonly priceSelected = output<StripePricePublic>();\n\n onProductSelect(product: StripeProductPublic) {\n this.productSelected.emit(product);\n }\n\n onPriceSelect(price: StripePricePublic) {\n this.priceSelected.emit(price);\n }\n} ","@if (productsStore.isStatusLoading()) {\n <div class=\"flex justify-start gap-8\">\n @for (item of [1,2,3]; track item) {\n <lib-product-item-skeleton></lib-product-item-skeleton>\n }\n </div>\n}\n\n@if (productsStore.isStatusError() && !productsStore.isStatusLoading()) {\n <div class=\"alert alert-error\">\n <span>{{ productsStore.error() }}</span>\n </div>\n}\n\n@if (!productsStore.hasProducts()) {\n <div class=\"alert alert-info\">\n <span>No products available</span>\n </div>\n}\n\n@if (productsStore.hasProducts()) {\n <div class=\"flex justify-start gap-8\">\n @for (product of products(); track product.id) {\n <lib-product-item\n [product]=\"product\"\n [currency]=\"currency()\"\n (productSelected)=\"onProductSelect($event)\"\n (priceSelected)=\"onPriceSelect($event)\">\n </lib-product-item>\n }\n </div>\n} \n\n\n","import { CommonModule } from '@angular/common';\nimport { Component, computed, inject, input, OnInit } from '@angular/core';\nimport { CustomerStore } from '../../store/customer.store';\nimport { SubscriptionsStore } from '../../store/subscriptions.store';\nimport { EmbeddedSkeletonComponent } from '../embedded-skeleton/embedded-skeleton.component';\n\n@Component({\n selector: 'lib-embedded-subscription',\n templateUrl: './embedded-subscription.component.html',\n standalone: true,\n imports: [CommonModule, EmbeddedSkeletonComponent]\n})\nexport class EmbeddedSubscriptionComponent implements OnInit {\n public readonly subscriptionsStore = inject(SubscriptionsStore);\n public readonly customerStore = inject(CustomerStore);\n\n public readonly priceId = input.required<string>();\n public readonly returnPagePath = input<string>('/subscription-return');\n \n public readonly customer = computed(() => this.customerStore.customer().data);\n\n async ngOnInit() {\n this.createSubscription();\n }\n\n private createSubscription() {\n const baseUrl = window.location.origin;\n const returnPath = `${baseUrl}${this.returnPagePath()}`;\n this.subscriptionsStore.createSubscription(this.priceId(), returnPath, this.customer());\n }\n\n ngOnDestroy() {\n this.subscriptionsStore.destroyEmbeddedSubscription();\n }\n} ","<div class=\"subscription-container\">\n <div class=\"info-panel p-4 bg-primary-100 rounded-lg mb-4\">\n <div class=\"flex items-center\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-6 w-6 text-primary mr-2\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n <p class=\"text-primary-700\">Plan de suscripción: <span class=\"font-semibold\">{{ priceId() }}</span></p>\n </div>\n </div>\n \n @if (subscriptionsStore.isStatusLoading()) {\n <lib-embedded-skeleton />\n }\n \n @if (subscriptionsStore.isStatusError()) {\n <div class=\"error\">\n <p>Error: {{ subscriptionsStore.error() }}</p>\n </div>\n }\n \n <div id=\"embedded-checkout\" class=\"mt-4\"></div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, OnInit, computed, inject, input } from '@angular/core';\nimport { ActivatedRoute, Router } from '@angular/router';\nimport { CheckoutStore } from '../../../store/checkout.store';\nimport { SubscriptionsStore } from '../../../store/subscriptions.store';\n\n@Component({\n selector: 'lib-subscription-return-page',\n templateUrl: './subscription-return-page.component.html',\n standalone: true,\n imports: [CommonModule],\n})\nexport class SubscriptionReturnPageComponent implements OnInit {\n private readonly route = inject(ActivatedRoute);\n private readonly router = inject(Router);\n\n public readonly checkoutStore = inject(CheckoutStore);\n public readonly subscriptionsStore = inject(SubscriptionsStore);\n\n public readonly sessionStatus = computed(() => this.checkoutStore.sessionStatus());\n \n public readonly returnUrl = input<string>('/');\n \n async ngOnInit() {\n this.route.queryParams.subscribe(async params => {\n const sessionId = params['session_id'];\n this.getSessionStatus(sessionId);\n });\n }\n\n private async getSessionStatus(sessionId: string) {\n if (sessionId) {\n await this.checkoutStore.getSessionStatus({ sessionId });\n } else {\n console.error('Missing session_id parameter in URL');\n }\n }\n \n public navigate(): void {\n this.router.navigateByUrl(this.returnUrl());\n }\n} ","<div class=\"flex justify-center min-h-screen bg-gradient-to-br from-blue-50 to-indigo-100 p-4\">\n <div class=\"hero-content text-center max-w-md\">\n <div class=\"card w-full bg-base-100 shadow-2xl\">\n <div class=\"card-body items-center text-center\">\n <!-- Success Icon -->\n <div class=\"mb-6\">\n <div class=\"avatar\">\n <div class=\"w-24 h-24 rounded-full bg-success/10 flex items-center justify-center\">\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n class=\"h-full w-full text-success\"\n fill=\"none\"\n viewBox=\"0 0 24 24\"\n stroke=\"currentColor\"\n >\n <path\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n stroke-width=\"2\"\n d=\"M9 12l2 2 4-4m6 2a9 9 0 11-18 0 9 9 0 0118 0z\"\n />\n </svg>\n </div>\n </div>\n </div>\n\n <!-- Status Content -->\n @if (checkoutStore.isStatusLoading()) {\n <div class=\"flex flex-col items-center gap-4 mb-6\">\n <span class=\"loading loading-spinner loading-lg text-primary\"></span>\n <div class=\"alert alert-info\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" fill=\"none\" viewBox=\"0 0 24 24\" class=\"stroke-current shrink-0 w-6 h-6\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z\"></path>\n </svg>\n <span>Cargando detalles de la suscripción...</span>\n </div>\n </div>\n } @else if (checkoutStore.isStatusError()) {\n <div class=\"alert alert-error mb-6\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"stroke-current shrink-0 h-6 w-6\" fill=\"none\" viewBox=\"0 0 24 24\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M10 14l2-2m0 0l2-2m-2 2l-2-2m2 2l2 2m7-2a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n <span>{{ subscriptionsStore.error() }}</span>\n </div>\n } @else if (checkoutStore.isPaymentComplete()) {\n\n <!-- Title and Description -->\n <h2 class=\"card-title text-3xl font-bold text-base-content mb-2\">{{ sessionStatus()?.amount_total }}</h2>\n\n <div class=\"alert alert-success mb-6\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"stroke-current shrink-0 h-6 w-6\" fill=\"none\" viewBox=\"0 0 24 24\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M9 12l2 2 4-4m6 2a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n <span class=\"font-medium\">Tu suscripción está activa y lista para usar.</span>\n </div>\n\n <div class=\"bg-base-200 rounded-lg p-4 mb-6 w-full\">\n <h3 class=\"font-semibold text-sm text-base-content/80 mb-3\">Beneficios incluidos:</h3>\n <ul class=\"space-y-2\">\n <li class=\"flex items-center text-sm\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 text-success mr-2\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M5 13l4 4L19 7\" />\n </svg>\n Acceso completo a todas las funciones\n </li>\n <li class=\"flex items-center text-sm\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 text-success mr-2\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M5 13l4 4L19 7\" />\n </svg>\n Soporte prioritario 24/7\n </li>\n <li class=\"flex items-center text-sm\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 text-success mr-2\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M5 13l4 4L19 7\" />\n </svg>\n Actualizaciones automáticas\n </li>\n </ul>\n </div>\n }\n\n <!-- Action Buttons -->\n <div class=\"card-actions justify-center w-full\">\n <button class=\"btn btn-primary btn-wide\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-5 w-5 mr-2\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n stroke-width=\"2\"\n d=\"M3 12l2-2m0 0l7-7 7 7M5 10v10a1 1 0 001 1h3m10-11l2 2m-2-2v10a1 1 0 01-1 1h-3m-6 0a1 1 0 001-1v-4a1 1 0 011-1h2a1 1 0 011 1v4a1 1 0 001 1m-6 0h6\"\n />\n </svg>\n Ir al Panel Principal\n </button>\n </div>\n\n <!-- Additional Help -->\n <div class=\"text-center mt-4\">\n <p class=\"text-xs text-base-content/50\">\n ¿Necesitas ayuda?\n <a href=\"#\" class=\"link link-primary\">Contacta soporte</a>\n </p>\n </div>\n </div>\n </div>\n </div>\n</div>","import { Directive, ElementRef, input, effect } from '@angular/core';\nimport type { Stripe as StripeTypes } from 'stripe';\n\n@Directive({\n selector: '[ngxBrandIcon]',\n standalone: true\n})\nexport class BrandIconDirective {\n public readonly paymentMethod = input.required<StripeTypes.PaymentMethod>({ alias: 'ngxBrandIcon' });\n\n constructor(private readonly el: ElementRef<HTMLElement>) {\n\n effect(() => {\n const icon = this.getBrandIcon();\n this.el.nativeElement.textContent = icon;\n });\n }\n\n private getBrandIcon(): string {\n const brand = this.paymentMethod().card?.brand;\n const brandIcons: Record<string, string> = {\n 'visa': '💳',\n 'mastercard': '💳', \n 'amex': '💳',\n 'discover': '💳',\n 'diners': '💳',\n 'jcb': '💳',\n 'unionpay': '💳',\n 'unknown': '💳'\n };\n return brandIcons[brand || 'unknown'] || '💳';\n }\n}\n","import { Directive, ElementRef, input, effect } from '@angular/core';\nimport type { Stripe as StripeTypes } from 'stripe';\n\n@Directive({\n selector: '[ngxBrandName]',\n standalone: true\n})\nexport class BrandNameDirective {\n public readonly paymentMethod = input.required<StripeTypes.PaymentMethod>({ alias: 'ngxBrandName' });\n\n constructor(private readonly el: ElementRef<HTMLElement>) {\n\n effect(() => {\n const name = this.getBrandName();\n this.el.nativeElement.textContent = name;\n });\n }\n\n private getBrandName(): string {\n const brand = this.paymentMethod().card?.brand;\n const brandNames: Record<string, string> = {\n 'visa': 'Visa',\n 'mastercard': 'Mastercard',\n 'amex': 'American Express',\n 'discover': 'Discover',\n 'diners': 'Diners Club',\n 'jcb': 'JCB',\n 'unionpay': 'UnionPay',\n 'unknown': 'Tarjeta'\n };\n return brandNames[brand || 'unknown'] || 'Tarjeta';\n }\n}\n","import { Directive, ElementRef, input, effect } from '@angular/core';\nimport type { Stripe as StripeTypes } from 'stripe';\n\n@Directive({\n selector: '[ngxPaymentMethodType]',\n standalone: true\n})\nexport class PaymentMethodTypeDirective {\n public readonly paymentMethod = input.required<StripeTypes.PaymentMethod>({ alias: 'ngxPaymentMethodType' });\n\n constructor(private readonly el: ElementRef<HTMLElement>) {\n\n effect(() => {\n const type = this.getPaymentMethodType();\n this.el.nativeElement.textContent = type;\n });\n }\n\n private getPaymentMethodType(): string {\n const typeNames: Record<string, string> = {\n 'card': 'Tarjeta',\n 'paypal': 'PayPal',\n 'klarna': 'Klarna',\n 'afterpay_clearpay': 'Afterpay',\n 'alipay': 'Alipay',\n 'bancontact': 'Bancontact',\n 'eps': 'EPS',\n 'giropay': 'Giropay',\n 'ideal': 'iDEAL',\n 'p24': 'Przelewy24',\n 'sepa_debit': 'SEPA Direct Debit',\n 'sofort': 'Sofort',\n 'wechat_pay': 'WeChat Pay'\n };\n return typeNames[this.paymentMethod().type] || 'Método de pago';\n }\n}\n","import { Component, input } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport type { Stripe as StripeTypes } from 'stripe';\nimport { BrandIconDirective } from '../../../directives/brand-icon.directive';\nimport { BrandNameDirective } from '../../../directives/brand-name.directive';\nimport { PaymentMethodTypeDirective } from '../../../directives/payment-method-type.directive';\n\nexport type PaymentMethodDisplayMode = 'detailed' | 'compact';\n\n@Component({\n selector: 'ngx-payment-method',\n standalone: true,\n imports: [CommonModule, BrandIconDirective, BrandNameDirective, PaymentMethodTypeDirective],\n templateUrl: './payment-method.component.html'\n})\nexport class PaymentMethodComponent {\n public readonly paymentMethod = input.required<StripeTypes.PaymentMethod>();\n public readonly mode = input<PaymentMethodDisplayMode>('detailed');\n\n public get last4(): string {\n return this.paymentMethod().card?.last4 || '****';\n }\n\n public get expirationDate(): string {\n const card = this.paymentMethod().card;\n if (!card?.exp_month || !card?.exp_year) return '';\n return `${card.exp_month.toString().padStart(2, '0')}/${card.exp_year.toString().slice(-2)}`;\n }\n\n public get holderName(): string {\n return this.paymentMethod().billing_details?.name || 'N/A';\n }\n\n public get isExpired(): boolean {\n const card = this.paymentMethod().card;\n if (!card?.exp_month || !card?.exp_year) return false;\n \n const now = new Date();\n const expDate = new Date(card.exp_year, card.exp_month - 1);\n return expDate < now;\n }\n\n public get cardFunding(): string | undefined {\n return this.paymentMethod().card?.funding;\n }\n\n public get cardCountry(): string | undefined {\n return this.paymentMethod().card?.country || undefined;\n }\n\n public get billingEmail(): string | undefined {\n return this.paymentMethod().billing_details?.email || undefined;\n }\n\n public get billingPhone(): string | undefined {\n return this.paymentMethod().billing_details?.phone || undefined;\n }\n\n public get billingAddress() {\n return this.paymentMethod().billing_details?.address;\n }\n}\n","<!-- Detailed Version -->\n@if (mode() === 'detailed') {\n <div class=\"w-full max-w-md mx-auto\">\n <!-- Stack of Credit Cards -->\n <div class=\"stack w-full h-56\">\n <div class=\"bg-gradient-to-br from-primary to-accent text-neutral-content relative place-content-center rounded-box\">\n <div class=\"card-body p-6 relative z-10\">\n <!-- Card Header -->\n <div class=\"flex justify-between items-start mb-6\">\n <div class=\"flex items-center gap-2\">\n <!--<span class=\"text-3xl filter drop-shadow-lg\" [ngxBrandIcon]=\"paymentMethod()\"></span>-->\n <div class=\"font-bold text-lg text-primary-content\" [ngxBrandName]=\"paymentMethod()\"></div>\n @if (cardCountry) {\n <div class=\"text-xs text-primary-content/60 uppercase\">{{ cardCountry }}</div>\n }\n @if (isExpired) {\n <div class=\"badge badge-error badge-sm animate-pulse\">Expirada</div>\n }\n </div>\n </div>\n\n <!-- Card Number -->\n <div class=\"mb-6\">\n <div class=\"font-mono text-xl tracking-wider text-primary-content\">\n **** **** **** {{ last4 }}\n </div>\n </div>\n\n <!-- Card Bottom Info -->\n <div class=\"flex justify-start items-end\">\n <div class=\"flex-1\">\n <div class=\"text-xs text-primary-content/60 mb-1\">TITULAR</div>\n <div class=\"font-medium text-sm text-primary-content truncate max-w-32\">{{ holderName }}</div>\n </div>\n \n @if (expirationDate) {\n <div class=\"flex-1\">\n <div class=\"text-xs text-primary-content/60 mb-1\">VÁLIDA HASTA</div>\n <div class=\"font-mono text-sm text-primary-content\">{{ expirationDate }}</div>\n </div>\n }\n </div>\n </div>\n\n <!-- Card Background Pattern -->\n <div class=\"absolute inset-0 opacity-20\">\n <div class=\"absolute top-4 right-4 w-20 h-20 rounded-full bg-primary-content/30\"></div>\n <div class=\"absolute bottom-4 left-4 w-16 h-16 rounded-full bg-primary-content/20\"></div>\n <div class=\"absolute top-1/2 left-1/2 transform -translate-x-1/2 -translate-y-1/2 w-32 h-32 rounded-full bg-primary-content/10\"></div>\n </div>\n </div>\n <div class=\"bg-secondary grid place-content-center rounded-box\"></div>\n <div class=\"bg-accent grid place-content-center rounded-box\"></div>\n </div>\n\n <!-- Additional Information Below Cards -->\n <div class=\"mt-6 space-y-4\">\n <!-- Billing Information -->\n @if (billingEmail || billingPhone) {\n <div class=\"card bg-base-100 shadow-sm border border-base-200\">\n <div class=\"card-body p-4\">\n <h4 class=\"card-title text-sm mb-3 flex items-center gap-2\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M16 7a4 4 0 11-8 0 4 4 0 018 0zM12 14a7 7 0 00-7 7h14a7 7 0 00-7-7z\" />\n </svg>\n Información de Contacto\n </h4>\n \n <div class=\"space-y-2\">\n @if (billingEmail) {\n <div class=\"flex items-center gap-2 text-sm\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 text-base-content/60\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M16 12a4 4 0 10-8 0 4 4 0 008 0zm0 0v1.5a2.5 2.5 0 005 0V12a9 9 0 10-9 9m4.5-1.206a8.959 8.959 0 01-4.5 1.207\" />\n </svg>\n <span class=\"text-base-content/70\">{{ billingEmail }}</span>\n </div>\n }\n \n @if (billingPhone) {\n <div class=\"flex items-center gap-2 text-sm\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 text-base-content/60\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M3 5a2 2 0 012-2h3.28a1 1 0 01.948.684l1.498 4.493a1 1 0 01-.502 1.21l-2.257 1.13a11.042 11.042 0 005.516 5.516l1.13-2.257a1 1 0 011.21-.502l4.493 1.498a1 1 0 01.684.949V19a2 2 0 01-2 2h-1C9.716 21 3 14.284 3 6V5z\" />\n </svg>\n <span class=\"text-base-content/70\">{{ billingPhone }}</span>\n </div>\n }\n </div>\n </div>\n </div>\n }\n\n <!-- Billing Address -->\n @if (billingAddress && (billingAddress.line1 || billingAddress.city)) {\n <div class=\"card bg-base-100 shadow-sm border border-base-200\">\n <div class=\"card-body p-4\">\n <h4 class=\"card-title text-sm mb-3 flex items-center gap-2\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M17.657 16.657L13.414 20.9a1.998 1.998 0 01-2.827 0l-4.244-4.243a8 8 0 1111.314 0z\" />\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M15 11a3 3 0 11-6 0 3 3 0 016 0z\" />\n </svg>\n Dirección de Facturación\n </h4>\n \n <div class=\"text-sm text-base-content/70 space-y-1\">\n @if (billingAddress.line1) {\n <div>{{ billingAddress.line1 }}</div>\n @if (billingAddress.line2) {\n <div>{{ billingAddress.line2 }}</div>\n }\n }\n \n <div class=\"flex gap-2 flex-wrap\">\n @if (billingAddress.city) {\n <span>{{ billingAddress.city }}</span>\n }\n @if (billingAddress.postal_code) {\n <span>{{ billingAddress.postal_code }}</span>\n }\n @if (billingAddress.country) {\n <span class=\"uppercase\">{{ billingAddress.country }}</span>\n }\n </div>\n </div>\n </div>\n </div>\n }\n\n <!-- Card Creation Date -->\n <div class=\"flex items-center justify-between text-sm text-base-content/60 px-2\">\n <span>Método agregado:</span>\n <span>{{ paymentMethod().created * 1000 | date:'short' }}</span>\n </div>\n </div>\n </div>\n}\n\n<!-- Compact Version -->\n@if (mode() === 'compact') {\n <div class=\"flex items-center gap-2\">\n <!--<span class=\"text-xl filter drop-shadow-sm\" [ngxBrandIcon]=\"paymentMethod()\"></span>-->\n \n <div class=\"flex-1 min-w-0\">\n <div class=\"flex items-center gap-2\">\n <span class=\"font-medium\" [ngxBrandName]=\"paymentMethod()\"></span>\n <span class=\"text-base-content/70\">•••• {{ last4 }}</span>\n @if (paymentMethod().type === 'card' && expirationDate) {\n <span class=\"text-base-content/70 text-sm\">{{ expirationDate }}</span>\n }\n </div>\n </div>\n\n @if (isExpired) {\n <div class=\"badge badge-error badge-sm animate-pulse\">Expirada</div>\n } @else {\n <div class=\"badge badge-success badge-sm\">Activa</div>\n }\n </div>\n}\n","import { Component, input } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { StripePaymentIntentsPublic } from '../../../../store/customer.store';\nimport { UtilsService } from '../../../../services/utils.service';\nimport { PaymentMethodComponent } from '../../payment-method/payment-method.component';\n\n@Component({\n selector: 'lib-payment-intents-dialog',\n standalone: true,\n imports: [CommonModule, PaymentMethodComponent],\n templateUrl: './payment-intents-dialog.component.html'\n})\nexport class PaymentIntentsDialogComponent {\n public readonly paymentIntent = input.required<StripePaymentIntentsPublic>();\n public readonly dialogId = input.required<string>();\n \n public readonly utils = new UtilsService();\n}\n","<dialog [id]=\"dialogId()\" class=\"modal\">\n <div class=\"modal-box max-w-2xl\">\n <h3 class=\"font-bold text-lg mb-4\">Detalles del Payment Intent</h3>\n \n <!-- Header with Amount and Status -->\n <div class=\"flex items-center gap-3 mb-6 p-4 bg-base-200 rounded-lg\">\n <div class=\"flex-1\">\n <div class=\"text-3xl font-bold text-primary\">\n {{ utils.formatAmount(paymentIntent().amount ?? 0, paymentIntent().currency ?? 'EUR') }}\n </div>\n <div class=\"text-sm text-base-content/70\">\n {{ (paymentIntent().currency ?? 'EUR').toUpperCase() }}\n </div>\n </div>\n <div class=\"flex gap-2\">\n <div class=\"badge {{ utils.getStatusBadgeClass(paymentIntent().status) }}\">\n {{ paymentIntent().status }}\n </div>\n @if (!paymentIntent().liveMode) {\n <div class=\"badge badge-warning\">TEST</div>\n }\n </div>\n </div>\n\n <div class=\"space-y-6\">\n <!-- Transaction Details -->\n <div>\n <h4 class=\"text-sm font-semibold text-base-content/80 mb-3 flex items-center gap-2\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n Detalles de la Transacción\n </h4>\n \n <div class=\"grid grid-cols-1 sm:grid-cols-2 gap-3\">\n <div class=\"stat bg-base-200 rounded-lg p-3\">\n <div class=\"stat-title text-xs\">Estado</div>\n <div class=\"stat-value text-sm capitalize\">{{ paymentIntent().status }}</div>\n <div class=\"stat-desc\">{{ paymentIntent().liveMode ? 'Producción' : 'Pruebas' }}</div>\n </div>\n \n <div class=\"stat bg-base-200 rounded-lg p-3\">\n <div class=\"stat-title text-xs\">Monto</div>\n <div class=\"stat-value text-sm\">{{ utils.formatAmount(paymentIntent().amount ?? 0, paymentIntent().currency ?? 'EUR') }}</div>\n <div class=\"stat-desc\">{{ (paymentIntent().currency ?? 'EUR').toUpperCase() }}</div>\n </div>\n </div>\n\n <!-- Confirmation Method -->\n <div class=\"mt-3 flex items-center gap-2 text-sm p-2 bg-base-200 rounded\">\n <div class=\"w-2 h-2 bg-success rounded-full\"></div>\n <span class=\"text-base-content/70\">Confirmación:</span>\n <span class=\"capitalize font-medium\">{{ paymentIntent().confirmationMethod.replace('_', ' ') }}</span>\n </div>\n </div>\n\n <!-- Payment Information -->\n @if (paymentIntent().paymentMethod) {\n <div>\n <h4 class=\"text-sm font-semibold text-base-content/80 mb-3 flex items-center gap-2\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M3 10h18M7 15h1m4 0h1m-7 4h12a3 3 0 003-3V8a3 3 0 00-3-3H6a3 3 0 00-3 3v8a3 3 0 003 3z\" />\n </svg>\n Información del Pago\n </h4>\n \n <ngx-payment-method \n [paymentMethod]=\"paymentIntent().paymentMethod!\" \n mode=\"detailed\">\n </ngx-payment-method>\n </div>\n }\n\n <!-- Additional Information -->\n <div>\n <h4 class=\"text-sm font-semibold text-base-content/80 mb-3 flex items-center gap-2\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z\" />\n </svg>\n Información Adicional\n </h4>\n \n <div class=\"space-y-2\">\n @if (paymentIntent().invoiceId) {\n <div class=\"flex items-center justify-between p-2 bg-base-200 rounded\">\n <span class=\"text-sm text-base-content/70\">Factura</span>\n <span class=\"text-sm font-mono\">{{ paymentIntent().invoiceId.slice(-8) }}</span>\n </div>\n }\n \n <div class=\"flex items-center justify-between p-2 bg-base-200 rounded\">\n <span class=\"text-sm text-base-content/70\">Entorno</span>\n <span class=\"text-sm\">\n @if (paymentIntent().liveMode) {\n <span class=\"text-success\">Producción</span>\n } @else {\n <span class=\"text-warning\">Pruebas</span>\n }\n </span>\n </div>\n \n <div class=\"flex items-center justify-between p-2 bg-base-200 rounded\">\n <span class=\"text-sm text-base-content/70\">Referencia</span>\n <span class=\"text-sm font-mono\">•••{{ paymentIntent().id?.slice(-6) || 'N/A' }}</span>\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"modal-action\">\n <form method=\"dialog\">\n <button class=\"btn btn-primary\">Cerrar</button>\n </form>\n </div>\n </div>\n</dialog>\n","import { CommonModule } from '@angular/common';\nimport { Component, computed, inject, input, output } from '@angular/core';\nimport { UtilsService } from '../../../../services/utils.service';\nimport { StripePaymentIntentsPublic } from '../../../../store/customer.store';\nimport { PaymentMethodComponent } from '../../payment-method/payment-method.component';\nimport { PaymentIntentsDialogComponent } from '../payment-intents-dialog/payment-intents-dialog.component';\n\n@Component({\n selector: 'lib-payment-intents-table',\n templateUrl: './payment-intents-table.component.html',\n standalone: true,\n imports: [\n CommonModule,\n PaymentMethodComponent,\n PaymentIntentsDialogComponent\n ]\n})\nexport class PaymentIntentsTableComponent {\n public readonly paymentIntents = input.required<StripePaymentIntentsPublic[]>();\n\n public paymentIntentsTable = computed(() => {\n return this.paymentIntents().map(paymentIntent => ({\n ...paymentIntent,\n selected: false\n }));\n });\n\n public readonly loading = input<boolean>(false);\n public readonly error = input<string | null>(null);\n public readonly withControls = input<boolean>(true);\n \n public readonly exportSelected = output<StripePaymentIntentsPublic[]>();\n public readonly onRefresh = output<void>();\n \n public readonly utils = inject(UtilsService);\n \n public readonly hasPaymentIntents = computed(() => \n this.paymentIntents() && this.paymentIntents().length > 0\n );\n \n protected readonly trackByPaymentIntentId = (index: number, item: StripePaymentIntentsPublic) => item.id;\n \n public refreshPaymentIntents(): void {\n this.onRefresh.emit();\n }\n\n public allPaymentIntentsSelected(): boolean {\n return this.paymentIntentsTable().every(paymentIntent => paymentIntent.selected);\n }\n\n public somePaymentIntentsSelected(): boolean {\n return this.paymentIntentsTable().some(paymentIntent => paymentIntent.selected);\n }\n\n public toggleAllPaymentIntents(event: Event): void {\n const checkbox = event.target as HTMLInputElement;\n const isChecked = checkbox.checked;\n this.paymentIntentsTable().forEach(paymentIntent => {\n paymentIntent.selected = isChecked;\n });\n }\n\n public togglePaymentIntent(event: Event, id: string): void {\n const checkbox = event.target as HTMLInputElement;\n const isChecked = checkbox.checked;\n const paymentIntent = this.paymentIntentsTable().find(paymentIntent => paymentIntent.id === id);\n if (paymentIntent) {\n paymentIntent.selected = isChecked;\n }\n }\n\n public showDetails(id: string): void {\n const modalElement = document.getElementById(`modal-${id}`) as HTMLDialogElement;\n if (modalElement) {\n modalElement.showModal();\n }\n } \n\n public exportSelectedPaymentIntents(): void {\n this.exportSelected.emit(this.paymentIntentsTable().filter(paymentIntent => paymentIntent.selected));\n }\n} ","<div class=\"payment-intents-container\">\n @if (withControls()) {\n <div class=\"controls mb-4 flex justify-between items-center\">\n <div class=\"stats\">\n @if (hasPaymentIntents()) {\n <span class=\"badge badge-soft badge-info\">{{ paymentIntentsTable().length }} payment intents</span>\n }\n </div>\n <div class=\"flex justify-end items-center gap-2\">\n <button class=\"btn btn-sm btn-outline\" (click)=\"refreshPaymentIntents()\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 mr-1\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M4 4v5h.582m15.356 2A8.001 8.001 0 004.582 9m0 0H9m11 11v-5h-.581m0 0a8.003 8.003 0 01-15.357-2m15.357 2H15\" />\n </svg>\n Actualizar\n </button>\n <button class=\"btn btn-sm btn-primary\" [disabled]=\"!somePaymentIntentsSelected()\" (click)=\"exportSelectedPaymentIntents()\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"1em\" height=\"1em\" viewBox=\"0 0 24 24\"><path fill=\"currentColor\" d=\"M8.71 7.71L11 5.41V15a1 1 0 0 0 2 0V5.41l2.29 2.3a1 1 0 0 0 1.42 0a1 1 0 0 0 0-1.42l-4-4a1 1 0 0 0-.33-.21a1 1 0 0 0-.76 0a1 1 0 0 0-.33.21l-4 4a1 1 0 1 0 1.42 1.42M21 14a1 1 0 0 0-1 1v4a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1v-4a1 1 0 0 0-2 0v4a3 3 0 0 0 3 3h14a3 3 0 0 0 3-3v-4a1 1 0 0 0-1-1\"/></svg>\n Export Selected\n </button>\n </div>\n </div>\n }\n\n @if (loading()) {\n <div class=\"overflow-x-auto\">\n <div class=\"skeleton h-32 w-full\"></div>\n </div>\n } @else if (error()) {\n <div class=\"error-container\">\n <div class=\"alert alert-error\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"stroke-current shrink-0 h-6 w-6\" fill=\"none\" viewBox=\"0 0 24 24\"><path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M10 14l2-2m0 0l2-2m-2 2l-2-2m2 2l2 2m7-2a9 9 0 11-18 0 9 9 0 0118 0z\" /></svg>\n <span>{{ error() }}</span>\n </div>\n </div>\n } @else if (hasPaymentIntents()) {\n <div class=\"overflow-x-auto rounded-box bg-base-100\">\n <table class=\"table table-zebra\">\n <!-- head -->\n <thead>\n <tr>\n <th>\n <label>\n <input type=\"checkbox\" class=\"checkbox\" (change)=\"toggleAllPaymentIntents($event)\" [checked]=\"allPaymentIntentsSelected()\" />\n </label>\n </th>\n <th>Amount</th>\n <th>Payment Method</th>\n <th>Status</th>\n <th>Mode</th>\n <th></th>\n </tr>\n </thead>\n <tbody>\n @for (paymentIntent of paymentIntentsTable(); track trackByPaymentIntentId(0, paymentIntent)) {\n <tr>\n <th>\n <label>\n <input type=\"checkbox\" class=\"checkbox\" (change)=\"togglePaymentIntent($event, paymentIntent.id ?? '')\" [checked]=\"paymentIntent.selected\" />\n </label>\n </th>\n <td>{{ utils.formatAmount(paymentIntent.amount ?? 0, paymentIntent.currency ?? 'EUR') }}</td>\n <td>\n @if (paymentIntent.paymentMethod) {\n <ngx-payment-method \n [paymentMethod]=\"paymentIntent.paymentMethod!\" \n mode=\"compact\">\n </ngx-payment-method>\n } @else {\n <span class=\"badge badge-outline\">\n {{ paymentIntent.paymentMethodId }}\n </span>\n }\n </td>\n <td>\n <span class=\"badge badge-soft {{ utils.getStatusBadgeClass(paymentIntent.status) }}\">\n {{ paymentIntent.status}}\n </span>\n </td>\n <td>{{ paymentIntent.liveMode ? 'Live' : 'Test' }}</td>\n <td>\n <button class=\"btn btn-xs btn-ghost\" (click)=\"showDetails(paymentIntent.id ?? '')\">\n Details\n </button>\n <lib-payment-intents-dialog \n [paymentIntent]=\"paymentIntent\" \n [dialogId]=\"'modal-' + paymentIntent.id\">\n </lib-payment-intents-dialog>\n </td>\n </tr>\n }\n </tbody>\n </table>\n </div>\n } @else {\n <div class=\"empty-state\">\n <div class=\"card bg-base-100 shadow-sm\">\n <div class=\"card-body items-center text-center\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-12 w-12 text-gray-400 mb-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M3 10h18M7 15h1m4 0h1m-7 4h12a3 3 0 003-3V8a3 3 0 00-3-3H6a3 3 0 00-3 3v8a3 3 0 003 3z\" />\n </svg>\n <h2 class=\"card-title text-xl\">No recent payment intents</h2>\n <p class=\"text-gray-600\">No payment intents found in your history.</p>\n </div>\n </div>\n </div>\n }\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component } from '@angular/core';\n\n@Component({\n selector: 'lib-subscription-item-skeleton',\n standalone: true,\n imports: [CommonModule],\n templateUrl: './subscription-item-skeleton.component.html',\n})\nexport class SubscriptionItemSkeletonComponent {}","<div class=\"card bg-base-100 shadow-sm\">\n <div class=\"card-body p-4\">\n <div class=\"flex justify-between\">\n <div>\n <div class=\"flex items-center gap-2\">\n <div class=\"skeleton h-6 w-32\"></div>\n <div class=\"skeleton h-5 w-20\"></div>\n </div>\n <div class=\"skeleton h-4 w-48 mt-2\"></div>\n </div>\n \n <div class=\"flex gap-2\">\n <div class=\"skeleton h-8 w-20\"></div>\n </div>\n </div>\n\n <div class=\"mt-2\">\n <div class=\"flex justify-between text-sm\">\n <div class=\"skeleton h-4 w-32\"></div>\n <div class=\"skeleton h-4 w-32\"></div>\n </div>\n </div>\n\n <!--<div class=\"mt-4 border-t pt-4\">\n <div class=\"grid grid-cols-1 md:grid-cols-2 gap-4\">\n <div>\n <div class=\"skeleton h-5 w-24 mb-2\"></div>\n <div class=\"space-y-1\">\n <div class=\"skeleton h-4 w-full\"></div>\n <div class=\"skeleton h-4 w-full\"></div>\n <div class=\"skeleton h-4 w-3/4\"></div>\n </div>\n </div>\n \n <div>\n <div class=\"skeleton h-5 w-24 mb-2\"></div>\n <div class=\"space-y-1\">\n <div class=\"skeleton h-4 w-full\"></div>\n <div class=\"skeleton h-4 w-3/4\"></div>\n </div>\n </div>\n </div>\n \n <div class=\"card-actions mt-4 justify-end\">\n <div class=\"skeleton h-8 w-32\"></div>\n </div>\n </div>-->\n </div>\n</div>","import { CommonModule } from '@angular/common';\nimport { Component, computed, inject, input, output } from '@angular/core';\nimport { DomSanitizer, SafeUrl } from '@angular/platform-browser';\nimport { UtilsService } from '../../../../../services/utils.service';\nimport { PortalAccountStore } from '../../../../../store/portal-account.store';\nimport { StripeSubscriptionPublic, SubscriptionsStore } from '../../../../../store/subscriptions.store';\n\n@Component({\n selector: 'lib-subscription-item',\n templateUrl: './subscription-item.component.html',\n standalone: true,\n imports: [CommonModule],\n})\nexport class SubscriptionItemComponent {\n public readonly subscriptionsStore = inject(SubscriptionsStore);\n public readonly portalAccountStore = inject(PortalAccountStore);\n public readonly utils = inject(UtilsService);\n private readonly sanitizer = inject(DomSanitizer);\n \n public readonly subscription = input.required<StripeSubscriptionPublic>();\n public readonly onManageSubscription = output<string>();\n\n public readonly isStatusLoading = computed(() => this.portalAccountStore.isStatusLoading());\n\n public readonly productImage = computed(() => {\n return this.subscription().product?.images?.[0] || 'https://img.daisyui.com/images/profile/demo/yellingcat@192.webp';\n });\n \n public isExpanded = false;\n \n public toggleExpand(): void {\n this.isExpanded = !this.isExpanded;\n }\n \n public manageSubscription(): void {\n this.onManageSubscription.emit(this.subscription().customer ?? '');\n }\n\n public sanitizeImageUrl(imageUrl: string): SafeUrl {\n return this.sanitizer.bypassSecurityTrustUrl(imageUrl);\n }\n} ","<div class=\"card bg-gradient-to-br from-primary/10 to-secondary/10 shadow-lg hover:shadow-xl transition-all duration-300 border border-base-300\">\n <div class=\"card-body p-6\">\n <!-- Header con título y precio -->\n <div class=\"flex justify-between items-start mb-4\">\n <div class=\"flex items-center gap-3\">\n <!-- Imagen de la suscripción -->\n <div class=\"avatar\">\n <div class=\"w-24 rounded\">\n <img [src]=\"sanitizeImageUrl(productImage())\" \n [alt]=\"subscription().product?.name || 'Subscription product'\"\n class=\"w-full h-full object-cover rounded-lg\" />\n </div>\n </div> \n \n <div>\n <h3 class=\"text-2xl font-bold text-base-content\">\n {{ subscription().product?.name || 'Subscription Plan' }}\n </h3>\n <div class=\"flex items-center gap-2 mt-1\">\n <span class=\"badge {{ utils.getStatusBadgeClass(subscription().status) }} badge-lg\">\n {{ subscription().status }}\n </span>\n @if (subscription().cancel.cancel_at_period_end) {\n <span class=\"badge badge-warning badge-lg\">Cancelada</span>\n }\n </div>\n </div>\n </div>\n \n <!-- Precio principal -->\n <div class=\"text-right\">\n <div class=\"text-4xl font-bold text-primary\">\n {{ utils.formatAmount(subscription().plan.amount, subscription().currency ?? 'EUR') }}\n </div>\n <div class=\"text-base-content/70 text-lg capitalize\">\n {{ subscription().plan.interval }}ly\n </div>\n </div>\n </div>\n\n <!-- Fechas de período -->\n <div class=\"flex justify-between items-center py-4 border-t border-base-300\">\n <div class=\"text-left\">\n <div class=\"text-base-content/70 text-sm font-medium\">Start:</div>\n <div class=\"text-base-content font-semibold\">\n {{ utils.formatDate(subscription().current_period_start ?? '') }}\n </div>\n </div>\n \n <div class=\"text-right\">\n <div class=\"text-base-content/70 text-sm font-medium\">End:</div>\n <div class=\"text-base-content font-semibold\">\n {{ utils.formatDate(subscription().current_period_end ?? '') }}\n </div>\n </div>\n </div>\n <div class=\"flex justify-end w-full\">\n <button class=\"btn btn-primary\" [disabled]=\"isStatusLoading()\" (click)=\"manageSubscription()\">\n @if (isStatusLoading()) {\n <span class=\"loading loading-spinner loading-sm\"></span>\n Cargando...\n } @else {\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-5 w-5\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M10.325 4.317c.426-1.756 2.924-1.756 3.35 0a1.724 1.724 0 002.573 1.066c1.543-.94 3.31.826 2.37 2.37a1.724 1.724 0 001.065 2.572c1.756.426 1.756 2.924 0 3.35a1.724 1.724 0 00-1.066 2.573c.94 1.543-.826 3.31-2.37 2.37a1.724 1.724 0 00-2.572 1.065c-.426 1.756-2.924 1.756-3.35 0a1.724 1.724 0 00-2.573-1.066c-1.543.94-3.31-.826-2.37-2.37a1.724 1.724 0 00-1.065-2.572c-1.756-.426-1.756-2.924 0-3.35a1.724 1.724 0 001.066-2.573c-.94-1.543.826-3.31 2.37-2.37.996.608 2.296.07 2.572-1.065z\" />\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M15 12a3 3 0 11-6 0 3 3 0 016 0z\" />\n </svg>\n Gestionar Suscripción\n }\n </button>\n </div>\n </div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, input, output } from '@angular/core';\nimport { StripeSubscriptionPublic } from '../../../../store/subscriptions.store';\nimport { SubscriptionItemSkeletonComponent } from './subscription-item-skeleton/subscription-item-skeleton.component';\nimport { SubscriptionItemComponent } from './subscription-item/subscription-item.component';\n\n@Component({\n selector: 'lib-subscriptions-list',\n templateUrl: './subscriptions-list.component.html',\n standalone: true,\n imports: [CommonModule, SubscriptionItemComponent, SubscriptionItemSkeletonComponent],\n})\nexport class SubscriptionsListComponent {\n public readonly subscriptions = input.required<StripeSubscriptionPublic[]>();\n public readonly loading = input<boolean>(false);\n public readonly error = input<string | null>(null);\n public readonly withEmptyState = input<boolean>(true);\n\n public readonly onManageSubscription = output<string>();\n\n public manageSubscription(customerId: string): void {\n this.onManageSubscription.emit(customerId);\n }\n} ","<div class=\"subscriptions-container\">\n @if (loading()) {\n <div class=\"flex flex-col gap-4\">\n @for (item of [1,2,3]; track item) {\n <lib-subscription-item-skeleton></lib-subscription-item-skeleton>\n }\n </div>\n } @else if (error()) {\n <div class=\"error-container\">\n <div class=\"alert alert-error\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"stroke-current shrink-0 h-6 w-6\" fill=\"none\" viewBox=\"0 0 24 24\"><path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M10 14l2-2m0 0l2-2m-2 2l-2-2m2 2l2 2m7-2a9 9 0 11-18 0 9 9 0 0118 0z\" /></svg>\n <span>{{ error() }}</span>\n </div>\n </div>\n } @else if (subscriptions().length > 0) {\n <div class=\"subscriptions-list flex flex-col gap-4\">\n @for (subscription of subscriptions(); track subscription.id) {\n <lib-subscription-item \n [subscription]=\"subscription\"\n (onManageSubscription)=\"manageSubscription($event)\">\n </lib-subscription-item>\n }\n </div>\n } @else if (withEmptyState() && subscriptions().length === 0 && !loading()) {\n <div class=\"empty-state\">\n <div class=\"card bg-base-100 shadow-sm\">\n <div class=\"card-body items-center text-center\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-12 w-12 text-gray-400 mb-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n <h2 class=\"card-title text-xl\">No tienes suscripciones activas</h2>\n <p class=\"text-gray-600\">Consulta nuestros planes para comenzar una suscripción.</p>\n </div>\n </div>\n </div>\n }\n</div> ","import { Component } from '@angular/core';\n\n@Component({\n selector: 'lib-subscription-card-skeleton',\n templateUrl: './subscription-card-skeleton.component.html',\n standalone: true\n})\nexport class SubscriptionCardSkeletonComponent {}\n","<div class=\"card bg-base-100 w-96 shadow-sm\">\n <figure class=\"flex items-center justify-center\">\n <div class=\"skeleton h-48 w-full\"></div>\n </figure>\n <div class=\"card-body\">\n <div class=\"flex justify-between items-center\">\n <div class=\"skeleton h-8 w-2/3\"></div>\n <div class=\"skeleton h-6 w-24 rounded-full\"></div>\n </div>\n \n <div class=\"mt-3\">\n <div class=\"skeleton h-4 w-full\"></div>\n <div class=\"skeleton h-4 w-5/6 mt-2\"></div>\n </div>\n \n <div class=\"card-actions justify-end mt-4\">\n <div class=\"skeleton h-10 w-40 rounded-lg\"></div>\n </div>\n </div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, inject, input, output } from '@angular/core';\nimport { StripeSubscriptionPublic } from '../../../../store/subscriptions.store';\nimport { SubscriptionCardSkeletonComponent } from './subscription-card-skeleton/subscription-card-skeleton.component';\nimport { UtilsService } from '../../../../services/utils.service';\n\n@Component({\n selector: 'lib-subscription-card',\n templateUrl: './subscription-card.component.html',\n standalone: true,\n imports: [CommonModule, SubscriptionCardSkeletonComponent],\n})\nexport class SubscriptionCardComponent {\n public readonly subscription = input.required<StripeSubscriptionPublic>();\n public readonly loading = input<boolean>(false);\n public readonly error = input<string | null>(null);\n\n public readonly utils = inject(UtilsService);\n \n public readonly onManageSubscription = output<string>();\n \n public hasValidProductImages(): boolean {\n const subscription = this.subscription();\n return !!subscription?.product && Array.isArray(subscription.product.images) && subscription.product.images.length > 0;\n }\n\n public getProductImage(): string {\n return this.subscription()?.product?.images?.[0] || '';\n }\n\n public getProductName(): string {\n return this.subscription()?.product?.name || '';\n }\n \n /**\n * Emit the customer ID to manage subscription\n */\n public manageSubscription(): void {\n this.onManageSubscription.emit(this.subscription().customer as string);\n }\n} ","@if (loading()) {\n <lib-subscription-card-skeleton></lib-subscription-card-skeleton>\n} @else if (error()) {\n <div class=\"alert alert-error\">{{ error() }}</div>\n} @else if (subscription()) {\n <div class=\"card bg-base-100 w-96 shadow-sm \">\n @if (hasValidProductImages()) {\n <figure class=\"flex items-center justify-center\">\n <img [src]=\"getProductImage()\" [alt]=\"getProductName()\" class=\"h-48 w-full object-cover\" />\n </figure>\n }\n <div class=\"card-body\">\n <div class=\"flex justify-between items-center\">\n <h2 class=\"card-title\">{{ getProductName() }}</h2>\n <span class=\"badge badge-soft {{ utils.getStatusBadgeClass(subscription().status) }} subscription-status\">\n {{ subscription().status }}\n </span>\n </div>\n \n <div class=\"mt-3\">\n <p class=\"opacity-75\">{{ subscription().product?.description }}</p>\n </div>\n \n <div class=\"card-actions justify-end\">\n <button class=\"btn btn-primary\" (click)=\"manageSubscription()\">\n Manage Subscription\n </button>\n </div>\n </div>\n </div>\n}\n","import { CommonModule } from '@angular/common';\nimport { Component } from '@angular/core';\n\n@Component({\n selector: 'lib-payment-intent-item-skeleton',\n templateUrl: './payment-intent-item-skeleton.component.html',\n standalone: true,\n imports: [CommonModule]\n})\nexport class PaymentIntentItemSkeletonComponent {} ","<div class=\"card bg-base-100 shadow-sm card-skeleton\">\n <div class=\"card-body p-4\">\n <!-- Header with status and expand button -->\n <div class=\"flex justify-between\">\n <div class=\"w-full\">\n <div class=\"flex items-center\">\n <!-- Title/Status placeholder -->\n <div class=\"skeleton w-32 h-6 rounded-md\"></div>\n <!-- Badge placeholder -->\n <div class=\"skeleton w-24 h-6 ml-2 rounded-full\"></div>\n </div>\n <!-- Customer ID placeholder -->\n <div class=\"skeleton w-48 h-4 mt-2 rounded-md\"></div>\n </div>\n \n <!-- Details button placeholder -->\n <div class=\"skeleton w-20 h-8 rounded-md\"></div>\n </div>\n\n <!-- Payment details summary -->\n <div class=\"flex justify-between mt-3\">\n <div>\n <!-- Amount placeholder -->\n <div class=\"skeleton w-32 h-8 rounded-md\"></div>\n </div>\n <div>\n <!-- Date placeholder -->\n <div class=\"skeleton w-28 h-6 rounded-md\"></div>\n </div>\n </div>\n \n <!-- Optional expanded details placeholder -->\n <div class=\"mt-4 border-t pt-4\">\n <div class=\"grid grid-cols-1 md:grid-cols-2 gap-4\">\n <div>\n <!-- Details heading placeholder -->\n <div class=\"skeleton w-36 h-5 mb-3 rounded-md\"></div>\n \n <!-- List items placeholders -->\n <div class=\"space-y-2\">\n <div class=\"skeleton w-full h-4 rounded-md\"></div>\n <div class=\"skeleton w-full h-4 rounded-md\"></div>\n <div class=\"skeleton w-3/4 h-4 rounded-md\"></div>\n </div>\n </div>\n \n <div>\n <!-- Second column heading placeholder -->\n <div class=\"skeleton w-36 h-5 mb-3 rounded-md\"></div>\n \n <!-- List items placeholders -->\n <div class=\"space-y-2\">\n <div class=\"skeleton w-full h-4 rounded-md\"></div>\n <div class=\"skeleton w-2/3 h-4 rounded-md\"></div>\n </div>\n </div>\n </div>\n \n <!-- Action button placeholder -->\n <div class=\"flex justify-end mt-4\">\n <div class=\"skeleton w-36 h-10 rounded-md\"></div>\n </div>\n </div>\n </div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, inject, input, signal } from '@angular/core';\nimport { StripePaymentIntentsPublic } from '../../../../../store/customer.store';\nimport { UtilsService } from '../../../../../services/utils.service';\nimport { PaymentMethodComponent } from '../../../payment-method/payment-method.component';\n\n@Component({\n selector: 'lib-payment-intent-item',\n templateUrl: './payment-intent-item.component.html',\n standalone: true,\n imports: [CommonModule, PaymentMethodComponent]\n})\nexport class PaymentIntentItemComponent {\n public readonly paymentIntent = input.required<StripePaymentIntentsPublic>();\n \n public readonly utils = inject(UtilsService);\n \n public readonly isExpanded = signal(false);\n \n public toggleExpand(): void {\n this.isExpanded.update(value => !value);\n }\n} ","<div class=\"card bg-base-100 shadow-sm hover:shadow-md transition-all duration-200 border border-base-200\">\n <div class=\"card-body p-4\">\n \n <!-- Header Section -->\n <div class=\"flex justify-between items-start mb-3\">\n <div class=\"flex-1\">\n <div class=\"flex items-center gap-2 mb-1\">\n <div class=\"text-2xl font-bold text-primary\">\n {{ utils.formatAmount(paymentIntent().amount ?? 0, paymentIntent().currency ?? 'EUR') }}\n </div>\n <div class=\"badge {{ utils.getStatusBadgeClass(paymentIntent().status) }} badge-sm\">\n {{ paymentIntent().status }}\n </div>\n @if (!paymentIntent().liveMode) {\n <div class=\"badge badge-warning badge-sm\">TEST</div>\n }\n </div>\n </div>\n \n <button \n class=\"btn btn-sm btn-ghost btn-circle\" \n (click)=\"toggleExpand()\"\n [class.rotate-180]=\"isExpanded()\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 transition-transform duration-200\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M19 9l-7 7-7-7\" />\n </svg>\n </button>\n </div>\n\n <!-- Main Info Section -->\n <div class=\"space-y-2\">\n <!-- Payment Method -->\n @if (paymentIntent().paymentMethod) {\n <ngx-payment-method \n [paymentMethod]=\"paymentIntent().paymentMethod!\" \n mode=\"compact\">\n </ngx-payment-method>\n } @else {\n <div class=\"flex items-center gap-2 p-2 bg-base-200 rounded-lg\">\n <div class=\"w-8 h-8 bg-base-300 rounded-full flex items-center justify-center\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M3 10h18M7 15h1m4 0h1m-7 4h12a3 3 0 003-3V8a3 3 0 00-3-3H6a3 3 0 00-3 3v8a3 3 0 003 3z\" />\n </svg>\n </div>\n <div>\n <div class=\"font-medium text-sm\">Método de pago</div>\n <div class=\"text-xs text-base-content/70\">•••• {{ paymentIntent().paymentMethodId.slice(-4) }}</div>\n </div>\n </div>\n }\n\n <!-- Confirmation Method -->\n <div class=\"flex items-center gap-2 text-sm\">\n <div class=\"w-2 h-2 bg-success rounded-full\"></div>\n <span class=\"text-base-content/70\">Confirmación:</span>\n <span class=\"capitalize font-medium\">{{ paymentIntent().confirmationMethod.replace('_', ' ') }}</span>\n </div>\n </div>\n\n <!-- Expanded Details -->\n @if (isExpanded()) {\n <div class=\"divider my-4\"></div>\n \n <div class=\"space-y-4\">\n <!-- Transaction Details -->\n <div>\n <h4 class=\"text-sm font-semibold text-base-content/80 mb-3 flex items-center gap-2\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n Detalles de la Transacción\n </h4>\n \n <div class=\"grid grid-cols-1 sm:grid-cols-2 gap-3\">\n <div class=\"stat bg-base-200 rounded-lg p-3\">\n <div class=\"stat-title text-xs\">Estado</div>\n <div class=\"stat-value text-sm capitalize\">{{ paymentIntent().status }}</div>\n <div class=\"stat-desc\">{{ paymentIntent().liveMode ? 'Producción' : 'Pruebas' }}</div>\n </div>\n \n <div class=\"stat bg-base-200 rounded-lg p-3\">\n <div class=\"stat-title text-xs\">Monto</div>\n <div class=\"stat-value text-sm\">{{ utils.formatAmount(paymentIntent().amount ?? 0, paymentIntent().currency ?? 'EUR') }}</div>\n <div class=\"stat-desc\">{{ (paymentIntent().currency ?? 'EUR').toUpperCase() }}</div>\n </div>\n </div>\n </div>\n\n <!-- Payment Information -->\n @if (paymentIntent().paymentMethod) {\n <div>\n <h4 class=\"text-sm font-semibold text-base-content/80 mb-3 flex items-center gap-2\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M3 10h18M7 15h1m4 0h1m-7 4h12a3 3 0 003-3V8a3 3 0 00-3-3H6a3 3 0 00-3 3v8a3 3 0 003 3z\" />\n </svg>\n Información del Pago\n </h4>\n \n <ngx-payment-method \n [paymentMethod]=\"paymentIntent().paymentMethod!\" \n mode=\"detailed\">\n </ngx-payment-method>\n </div>\n }\n\n <!-- Additional Information -->\n <div>\n <h4 class=\"text-sm font-semibold text-base-content/80 mb-3 flex items-center gap-2\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z\" />\n </svg>\n Información Adicional\n </h4>\n \n <div class=\"space-y-2\">\n @if (paymentIntent().invoiceId) {\n <div class=\"flex items-center justify-between p-2 bg-base-200 rounded\">\n <span class=\"text-sm text-base-content/70\">Factura</span>\n <span class=\"text-sm font-mono\">{{ paymentIntent().invoiceId.slice(-8) }}</span>\n </div>\n }\n \n <div class=\"flex items-center justify-between p-2 bg-base-200 rounded\">\n <span class=\"text-sm text-base-content/70\">Entorno</span>\n <span class=\"text-sm\">\n @if (paymentIntent().liveMode) {\n <span class=\"text-success\">Producción</span>\n } @else {\n <span class=\"text-warning\">Pruebas</span>\n }\n </span>\n </div>\n \n <div class=\"flex items-center justify-between p-2 bg-base-200 rounded\">\n <span class=\"text-sm text-base-content/70\">Referencia</span>\n <span class=\"text-sm font-mono\">•••{{ paymentIntent().id?.slice(-6) || 'N/A' }}</span>\n </div>\n </div>\n </div>\n </div>\n }\n </div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, input, output } from '@angular/core';\nimport { StripePaymentIntentsPublic } from '../../../../store/customer.store';\nimport { PaymentIntentItemSkeletonComponent } from './payment-intents-item-skeleton/payment-intent-item-skeleton.component';\nimport { PaymentIntentItemComponent } from './payment-intents-item/payment-intent-item.component';\n\n@Component({\n selector: 'lib-payment-intents-list',\n templateUrl: './payment-intents-list.component.html',\n standalone: true,\n imports: [\n CommonModule,\n PaymentIntentItemSkeletonComponent,\n PaymentIntentItemComponent\n ]\n})\nexport class PaymentIntentsListComponent {\n public readonly paymentIntents = input.required<StripePaymentIntentsPublic[]>();\n public readonly loading = input<boolean>(false);\n public readonly error = input<string | null>(null);\n public readonly withControls = input<boolean>(true);\n \n public readonly onRefresh = output<void>();\n \n protected readonly trackByPaymentIntentId = (index: number, item: StripePaymentIntentsPublic) => item.id;\n \n public refreshPaymentIntents(): void {\n this.onRefresh.emit();\n }\n} ","<div class=\"payment-intents-container\">\n @if (withControls()) {\n <div class=\"controls mb-4 flex justify-between items-center\">\n <div class=\"stats\">\n @if (paymentIntents().length > 0) {\n <span class=\"badge badge-soft badge-info\">{{ paymentIntents().length }} payment intents</span>\n }\n </div>\n <button class=\"btn btn-sm btn-outline\" (click)=\"refreshPaymentIntents()\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 mr-1\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M4 4v5h.582m15.356 2A8.001 8.001 0 004.582 9m0 0H9m11 11v-5h-.581m0 0a8.003 8.003 0 01-15.357-2m15.357 2H15\" />\n </svg>\n Actualizar\n </button>\n </div>\n }\n\n @if (loading()) {\n <div class=\"flex flex-col gap-4\">\n @for (item of [1,2,3]; track item) {\n <lib-payment-intent-item-skeleton></lib-payment-intent-item-skeleton>\n }\n </div>\n } @else if (error()) {\n <div class=\"error-container\">\n <div class=\"alert alert-error\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"stroke-current shrink-0 h-6 w-6\" fill=\"none\" viewBox=\"0 0 24 24\"><path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M10 14l2-2m0 0l2-2m-2 2l-2-2m2 2l2 2m7-2a9 9 0 11-18 0 9 9 0 0118 0z\" /></svg>\n <span>{{ error() }}</span>\n </div>\n </div>\n } @else if (paymentIntents().length > 0) {\n <div class=\"flex flex-col gap-4\">\n @for (paymentIntent of paymentIntents(); track paymentIntent.id) {\n <lib-payment-intent-item [paymentIntent]=\"paymentIntent\"></lib-payment-intent-item>\n }\n </div>\n } @else {\n <div class=\"empty-state\">\n <div class=\"card bg-base-100 shadow-sm\">\n <div class=\"card-body items-center text-center\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-12 w-12 text-gray-400 mb-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M3 10h18M7 15h1m4 0h1m-7 4h12a3 3 0 003-3V8a3 3 0 00-3-3H6a3 3 0 00-3 3v8a3 3 0 003 3z\" />\n </svg>\n <h2 class=\"card-title text-xl\">No hay payment intents recientes</h2>\n <p class=\"text-gray-600\">No se encontraron payment intents en tu historial.</p>\n </div>\n </div>\n </div>\n }\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, inject, input } from '@angular/core';\nimport { CustomerStore } from '../../../store/customer.store';\nimport { PortalAccountStore } from '../../../store/portal-account.store';\nimport { SubscriptionCardComponent } from './subscription-card/subscription-card.component';\nimport { SubscriptionsListComponent } from './subscriptions-list/subscriptions-list.component';\n\n@Component({\n selector: 'lib-subscriptions',\n templateUrl: './subscriptions.component.html',\n standalone: true,\n imports: [CommonModule, SubscriptionCardComponent, SubscriptionsListComponent],\n})\nexport class SubscriptionsComponent {\n public readonly customerStore = inject(CustomerStore);\n public readonly portalAccountStore = inject(PortalAccountStore);\n\n public readonly returnUrl = input<string>(window.location.origin + '/account');\n\n public manageSubscription(customerId: string): void {\n this.portalAccountStore.createPortalSession(customerId, this.returnUrl());\n }\n\n public refreshSubscriptions(): void {\n if (this.customerStore.customer().data?.id) {\n this.customerStore.loadSubscriptions(this.customerStore.customer().data?.id as string);\n }\n }\n}\n\n","<div class=\"mb-4 flex flex-col justify-between items-center\">\n <div class=\"mb-6 w-full\">\n <h2 class=\"text-2xl font-bold text-gray-800\">Subscriptions</h2>\n <p class=\"text-gray-600\">Manage your subscriptions and payments in one place</p>\n </div>\n <div class=\"controls mb-4 flex justify-between items-center w-full\">\n <div class=\"stats\">\n @if (customerStore.subscriptions.data().length > 0) {\n <span class=\"badge badge-soft badge-info\">{{ customerStore.subscriptions.data().length}} subscriptions</span>\n }\n </div>\n <button class=\"btn btn-sm btn-outline\" (click)=\"refreshSubscriptions()\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 mr-1\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M4 4v5h.582m15.356 2A8.001 8.001 0 004.582 9m0 0H9m11 11v-5h-.581m0 0a8.003 8.003 0 01-15.357-2m15.357 2H15\" />\n </svg>\n Updated\n </button>\n </div>\n</div>\n\n<div class=\"flex flex-col gap-4\">\n <lib-subscription-card\n [subscription]=\"customerStore.firstSubscription()\"\n [loading]=\"customerStore.isSubscriptionsStatusLoading()\"\n [error]=\"customerStore.subscriptions.error()\"\n (onManageSubscription)=\"manageSubscription($event)\">\n </lib-subscription-card>\n <lib-subscriptions-list\n [subscriptions]=\"customerStore.restSubscriptions()\"\n [loading]=\"customerStore.isSubscriptionsStatusLoading()\"\n [error]=\"customerStore.subscriptions.error()\"\n [withEmptyState]=\"false\"\n (onManageSubscription)=\"manageSubscription($event)\">\n </lib-subscriptions-list>\n</div>","import { CommonModule } from '@angular/common';\nimport { Component, computed, inject, input, signal } from '@angular/core';\nimport { PaymentIntentsListComponent } from '../../components/customer/payment-intents/payment-intents-list/payment-intents-list.component';\nimport { PaymentIntentsTableComponent } from '../../components/customer/payment-intents/payment-intents-table/payment-intents-table.component';\nimport { SubscriptionsComponent } from '../../components/customer/subscriptions/subscriptions.component';\nimport { CustomerStore, StripePaymentIntentsPublic } from '../../store/customer.store';\n\n@Component({\n selector: 'lib-customer-dashboard',\n templateUrl: './customer.component.html',\n standalone: true,\n imports: [\n CommonModule,\n PaymentIntentsListComponent,\n PaymentIntentsTableComponent,\n SubscriptionsComponent\n ]\n}) \nexport class CustomerDashboardComponent {\n public readonly customerStore = inject(CustomerStore);\n\n public readonly returnUrl = input<string>(window.location.origin + '/account');\n \n public readonly customer = computed(() => this.customerStore.customer().data);\n \n public readonly activeTab = signal<'list' | 'table'>('list');\n\n public refreshPaymentIntents(): void {\n this.customerStore.loadPaymentIntents(this.customerStore.customer().data?.id as string);\n }\n \n public setActiveTab(tab: 'list' | 'table'): void {\n this.activeTab.set(tab);\n }\n\n public exportSelectedPaymentIntents(paymentIntents: StripePaymentIntentsPublic[]): void {\n console.log('[💰 CustomerDashboardComponent] exportSelectedPaymentIntents: ', paymentIntents);\n }\n}\n","<div class=\"container flex flex-col gap-6 mx-auto\">\n <!-- Subscriptions Section -->\n <section class=\"flex flex-col\">\n <lib-subscriptions [returnUrl]=\"returnUrl()\"></lib-subscriptions>\n </section>\n\n <!-- Payment Intents Section with Tabs -->\n <section class=\"flex flex-col\">\n <header class=\"mb-4\">\n <h2 class=\"text-2xl font-bold text-gray-800\">Payment Intents</h2>\n <p class=\"text-gray-600\">Payment intents history. Select a tab to see the list or table view.</p>\n </header>\n\n <div role=\"tablist\" class=\"tabs tabs-box w-fit mb-4\">\n <a role=\"tab\" class=\"tab\" [class.tab-active]=\"activeTab() === 'list'\" (click)=\"setActiveTab('list')\">Lista</a>\n <a role=\"tab\" class=\"tab\" [class.tab-active]=\"activeTab() === 'table'\" (click)=\"setActiveTab('table')\">Tabla</a>\n </div>\n\n @if (activeTab() === 'list') {\n <lib-payment-intents-list\n [paymentIntents]=\"customerStore.paymentIntents.data()\"\n [loading]=\"customerStore.isPaymentIntentsStatusLoading()\"\n [error]=\"customerStore.paymentIntents.error()\"\n (onRefresh)=\"refreshPaymentIntents()\">\n </lib-payment-intents-list>\n } @else {\n <lib-payment-intents-table\n [paymentIntents]=\"customerStore.paymentIntents.data()\"\n [loading]=\"customerStore.isPaymentIntentsStatusLoading()\"\n [error]=\"customerStore.paymentIntents.error()\"\n (exportSelected)=\"exportSelectedPaymentIntents($event)\"\n (onRefresh)=\"refreshPaymentIntents()\">\n </lib-payment-intents-table>\n }\n </section>\n</div>\n","/*\n * Public API Surface of ngx-supabase-stripe\n */\n\n// Export configurations\nexport * from './lib/config/ngx-supabase-stripe.config';\nexport * from './lib/config/stripe.config';\nexport * from './lib/config/supabase.config';\n\n// Export store\nexport * from './lib/store/checkout.store';\nexport * from './lib/store/products.store';\nexport * from './lib/store/subscriptions.store';\nexport * from './lib/store/customer.store';\nexport * from './lib/store/portal-account.store';\n\n// Export services\nexport * from './lib/services/stripe-client.service';\nexport * from './lib/services/supabase-client.service';\n\n// Export components\nexport * from './lib/components/embedded-checkout/embedded-checkout.component';\nexport * from './lib/components/embedded-checkout/return-page/return-page.component';\nexport * from './lib/components/product-list/product-list.component';\nexport * from './lib/components/embedded-subscription/embedded-subscription.component';\nexport * from './lib/components/embedded-subscription/return-page/subscription-return-page.component';\nexport * from './lib/components/customer/payment-intents/payment-intents-table/payment-intents-table.component';\nexport * from './lib/components/customer/subscriptions/subscriptions-list/subscriptions-list.component';\nexport * from './lib/components/customer/subscriptions/subscription-card/subscription-card.component';\nexport * from './lib/components/customer/subscriptions/subscriptions-list/subscriptions-list.component';\nexport * from './lib/components/customer/payment-intents/payment-intents-list/payment-intents-list.component';\nexport * from './lib/pages/customer/customer.component';\n\n// Export models\nexport * from './lib/models/currency.model';\n\n// Export types\nexport * from './database.types';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;MAYa,aAAa,GAAG,IAAI,cAAc,CAAe,eAAe;AAE7E;;;;AAIG;AACG,SAAU,mBAAmB,CAAC,MAAoB,EAAA;IACtD,OAAO;AACL,QAAA;AACE,YAAA,OAAO,EAAE,aAAa;AACtB,YAAA,QAAQ,EAAE;AACX;KACF;AACH;;MCJa,eAAe,GAAG,IAAI,cAAc,CAAiB,iBAAiB;AAEnF;;;;AAIG;AACG,SAAU,qBAAqB,CAAC,MAAsB,EAAA;IAC1D,OAAO;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AA,EAAA,8lDAAA,EAAA;;;AEhBH;;AAEG;AAEH;;ACJA;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"dotted-labs-ngx-supabase-stripe.mjs","sources":["../../../projects/ngx-supabase-stripe/src/lib/config/stripe.config.ts","../../../projects/ngx-supabase-stripe/src/lib/config/supabase.config.ts","../../../projects/ngx-supabase-stripe/src/lib/config/ngx-supabase-stripe.config.ts","../../../projects/ngx-supabase-stripe/src/lib/services/supabase-client.service.ts","../../../projects/ngx-supabase-stripe/src/lib/services/stripe-client.service.ts","../../../projects/ngx-supabase-stripe/src/lib/models/currency.model.ts","../../../projects/ngx-supabase-stripe/src/lib/store/products.store.ts","../../../projects/ngx-supabase-stripe/src/lib/store/subscriptions.store.ts","../../../projects/ngx-supabase-stripe/src/lib/store/customer.store.ts","../../../projects/ngx-supabase-stripe/src/lib/store/checkout.store.ts","../../../projects/ngx-supabase-stripe/src/lib/store/portal-account.store.ts","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-skeleton/embedded-skeleton.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-skeleton/embedded-skeleton.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-checkout/embedded-checkout.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-checkout/embedded-checkout.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-checkout/return-page/return-page.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-checkout/return-page/return-page.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/product-list/product-item-skeleton/product-item-skeleton.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/product-list/product-item-skeleton/product-item-skeleton.component.html","../../../projects/ngx-supabase-stripe/src/lib/services/utils.service.ts","../../../projects/ngx-supabase-stripe/src/lib/components/product-list/product-item/product-item.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/product-list/product-item/product-item.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/product-list/product-list.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/product-list/product-list.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-subscription/embedded-subscription.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-subscription/embedded-subscription.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-subscription/return-page/subscription-return-page.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/embedded-subscription/return-page/subscription-return-page.component.html","../../../projects/ngx-supabase-stripe/src/lib/directives/brand-icon.directive.ts","../../../projects/ngx-supabase-stripe/src/lib/directives/brand-name.directive.ts","../../../projects/ngx-supabase-stripe/src/lib/directives/payment-method-type.directive.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-method/payment-method.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-method/payment-method.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-dialog/payment-intents-dialog.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-dialog/payment-intents-dialog.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-table/payment-intents-table.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-table/payment-intents-table.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscriptions-list/subscription-item-skeleton/subscription-item-skeleton.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscriptions-list/subscription-item-skeleton/subscription-item-skeleton.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscriptions-list/subscription-item/subscription-item.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscriptions-list/subscription-item/subscription-item.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscriptions-list/subscriptions-list.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscriptions-list/subscriptions-list.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscription-card/subscription-card-skeleton/subscription-card-skeleton.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscription-card/subscription-card-skeleton/subscription-card-skeleton.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscription-card/subscription-card.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscription-card/subscription-card.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-list/payment-intents-item-skeleton/payment-intent-item-skeleton.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-list/payment-intents-item-skeleton/payment-intent-item-skeleton.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-list/payment-intents-item/payment-intent-item.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-list/payment-intents-item/payment-intent-item.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-list/payment-intents-list.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/payment-intents/payment-intents-list/payment-intents-list.component.html","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscriptions.component.ts","../../../projects/ngx-supabase-stripe/src/lib/components/customer/subscriptions/subscriptions.component.html","../../../projects/ngx-supabase-stripe/src/lib/pages/customer/customer.component.ts","../../../projects/ngx-supabase-stripe/src/lib/pages/customer/customer.component.html","../../../projects/ngx-supabase-stripe/src/public-api.ts","../../../projects/ngx-supabase-stripe/src/dotted-labs-ngx-supabase-stripe.ts"],"sourcesContent":["import { InjectionToken, Provider } from '@angular/core';\n\n/**\n * Stripe configuration interface\n */\nexport interface StripeConfig {\n /**\n * Stripe client secret\n */\n publishableKey: string;\n}\n\nexport const STRIPE_CONFIG = new InjectionToken<StripeConfig>('STRIPE_CONFIG');\n\n/**\n * Provides the Stripe configuration\n * @param config The Stripe configuration\n * @returns An array of providers\n */\nexport function provideStripeConfig(config: StripeConfig): Provider[] {\n return [\n {\n provide: STRIPE_CONFIG,\n useValue: config\n }\n ];\n}","import { InjectionToken, Provider } from '@angular/core';\n\n/**\n * Supabase configuration interface\n */\nexport interface SupabaseConfig {\n /**\n * Supabase project URL\n */\n supabaseUrl: string;\n\n /**\n * Supabase API key\n */\n supabaseKey: string;\n\n /**\n * Supabase schema\n */\n supabaseSchema: 'public' | 'stripe';\n}\n\nexport const SUPABASE_CONFIG = new InjectionToken<SupabaseConfig>('SUPABASE_CONFIG');\n\n/**\n * Provides the Supabase configuration\n * @param config The Supabase configuration\n * @returns An array of providers\n */\nexport function provideSupabaseConfig(config: SupabaseConfig): Provider[] {\n return [\n {\n provide: SUPABASE_CONFIG,\n useValue: config\n }\n ];\n}\n\n","import { EnvironmentProviders, Provider } from '@angular/core';\nimport { STRIPE_CONFIG, StripeConfig } from './stripe.config';\nimport { SUPABASE_CONFIG, SupabaseConfig } from './supabase.config';\n\nexport interface NgxSupabaseStripeConfig {\n supabaseConfig: SupabaseConfig;\n stripeConfig: StripeConfig;\n}\n\n/**\n * Provides the NgxSupabaseStripeConfig object\n * @param config The NgxSupabaseStripeConfig object\n * @returns The NgxSupabaseStripeConfig object\n */\nexport function provideNgxSupabaseStripeConfig(\n config: NgxSupabaseStripeConfig\n): (Provider | EnvironmentProviders)[] {\n const providers: (Provider | EnvironmentProviders)[] = [\n {\n provide: SUPABASE_CONFIG,\n useValue: config.supabaseConfig\n },\n {\n provide: STRIPE_CONFIG,\n useValue: config.stripeConfig\n }\n ];\n\n return providers;\n}\n\n","import { inject, Injectable } from '@angular/core';\nimport { createClient, SupabaseClient } from '@supabase/supabase-js';\nimport { Database } from '../../database.types';\nimport { SUPABASE_CONFIG } from '../config/supabase.config';\nimport { StripeCheckoutSession, StripePaymentIntent, StripeProduct, StripeTables, StripeUpdateType } from '../models/database.model';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class SupabaseClientService {\n private readonly config = inject(SUPABASE_CONFIG);\n private readonly client: SupabaseClient<Database>;\n\n constructor() {\n this.client = createClient<Database>(\n this.config.supabaseUrl,\n this.config.supabaseKey,\n );\n\n console.log('🚀 [SupabaseClientService]: this.client', this.client);\n } \n\n /**\n * Get the Supabase client instance\n */\n public getClient(): SupabaseClient<Database> {\n return this.client;\n }\n\n /**\n * Select payment intents\n * @param query Optional query parameters\n */\n public async selectPaymentIntents(\n query?: {\n columns?: string;\n eq?: Partial<Record<keyof StripePaymentIntent, unknown>>;\n order?: { column: keyof StripePaymentIntent | string; ascending?: boolean };\n limit?: number;\n }\n ): Promise<{ data: StripePaymentIntent[] | null; error: Error | null }> {\n return this.select<StripePaymentIntent>('payment_intents', query);\n }\n\n /**\n * STRIPE CHECKOUT SESSIONS\n */\n\n /**\n * Select checkout sessions\n * @param sessionId The checkout session ID\n */\n public async selectCheckoutSession(\n sessionId: string\n ): Promise<{ data: StripeCheckoutSession | null; error: Error | null }> {\n return this.client\n .schema(this.config.supabaseSchema)\n .rpc('get_stripe_checkout_session', { session_id: sessionId })\n .select('*')\n .single();\n }\n\n /**\n * STRIPE SUBSCRIPTIONS\n */\n\n /**\n * Get all Stripe subscriptions\n */\n public getStripeSubscriptions() {\n return this.client\n .schema(this.config.supabaseSchema)\n .rpc('get_stripe_subscriptions')\n .select('*');\n }\n\n /**\n * Select a Stripe subscription\n * @param subscriptionId The subscription ID\n */\n public selectStripeSubscription(subscriptionId: string) {\n return this.client\n .schema(this.config.supabaseSchema)\n .rpc('get_stripe_subscription', { subscription_id: subscriptionId })\n .select('*');\n }\n\n /**\n * STRIPE PRICES\n */\n\n /**\n * Select Stripe prices\n * @param query Optional query parameters\n */\n public async selectStripePrices() {\n return this.client\n .schema(this.config.supabaseSchema)\n .rpc('get_stripe_prices')\n .select('*');\n }\n\n /**\n * STRIPE PRODUCTS\n */\n\n /**\n * Select Stripe products\n * @param query Optional query parameters\n */\n public async selectStripeProducts() {\n return this.client\n .schema(this.config.supabaseSchema)\n .rpc('get_stripe_products')\n .select('*');\n }\n\n /**\n * Select a Stripe product\n * @param productId The product ID\n */\n public async selectStripeProduct(productId: string) {\n return this.client\n .schema(this.config.supabaseSchema)\n .rpc('get_stripe_product', { product_id: productId })\n .select('*');\n }\n\n /**\n * Update a product\n * @param id The product ID\n * @param data The product data to update\n */\n public async updateProduct(\n id: string,\n data: StripeUpdateType<'products'>\n ): Promise<{ data: StripeProduct | null; error: Error | null }> {\n return this.update<StripeProduct>(\n 'products',\n data,\n { id }\n );\n }\n\n /**\n * Delete a product\n * @param id The product ID\n */\n public async deleteProduct(\n id: string\n ): Promise<{ data: StripeProduct | null; error: Error | null }> {\n return this.delete<StripeProduct>('products', { id });\n }\n\n /**\n * CUSTOMER FUNCTIONS\n */\n\n /**\n * Get customer by email\n * @param email The customer email\n */\n public async getCustomerByEmail(email: string) {\n return this.client.schema(this.config.supabaseSchema).rpc('get_stripe_customer', { customer_email: email });\n }\n\n /**\n * Get customer payment intents\n * @param customerId The customer ID\n */\n public async getCustomerPaymentIntents(customerId: string) {\n return this.client\n .schema(this.config.supabaseSchema)\n .rpc('get_stripe_customer_payment_intents', { customer_id: customerId })\n .select('*');\n }\n\n /**\n * Get customer subscriptions\n * @param customerId The customer ID\n */\n public async getCustomerSubscriptions(customerId: string) {\n return this.client\n .schema(this.config.supabaseSchema)\n .rpc('get_stripe_customer_subscriptions', { customer_id: customerId })\n .select('*');\n }\n\n\n /**\n * CLIENT GENERIC FUNCTIONS\n */\n\n /**\n * Select data from a table\n * @param table The table name\n * @param query Optional query parameters\n */\n public async select<T>(\n table: StripeTables,\n query?: {\n columns?: string;\n eq?: Record<string, any>;\n order?: { column: string; ascending?: boolean };\n limit?: number;\n }\n ): Promise<{ data: T[] | null; error: Error | null }> {\n try {\n let queryBuilder = this.client\n .schema('stripe')\n .from(table)\n .select(query?.columns ?? '*');\n\n if (query?.eq) {\n Object.entries(query.eq).forEach(([key, value]) => {\n queryBuilder = queryBuilder.eq(key, value);\n });\n }\n\n if (query?.order) {\n queryBuilder = queryBuilder.order(\n query.order.column,\n { ascending: query.order.ascending ?? true }\n );\n }\n\n if (query?.limit) {\n queryBuilder = queryBuilder.limit(query.limit);\n }\n\n const { data, error } = await queryBuilder;\n\n if (error) {\n throw error;\n }\n\n return { data: data as T[], error: null };\n } catch (error) {\n return { data: null, error: error as Error };\n }\n }\n\n /**\n * Insert data into a table\n * @param table The table name\n * @param data The data to insert\n */\n public async insert<T>(\n table: StripeTables,\n data: Partial<T>\n ): Promise<{ data: T | null; error: Error | null }> {\n try {\n const { data: result, error } = await (this.client\n .schema('stripe')\n .from(table)\n .insert(data)\n .select()\n .single());\n\n if (error) {\n throw error;\n }\n\n return { data: result as T, error: null };\n } catch (error) {\n return { data: null, error: error as Error };\n }\n }\n\n /**\n * Update data in a table\n * @param table The table name\n * @param data The data to update\n * @param eq The equality conditions\n */\n public async update<T>(\n table: StripeTables,\n data: Partial<T>,\n eq: Record<string, any>\n ): Promise<{ data: T | null; error: Error | null }> {\n try {\n let queryBuilder = this.client\n .schema('stripe')\n .from(table)\n .update(data);\n\n Object.entries(eq).forEach(([key, value]) => {\n queryBuilder = queryBuilder.eq(key, value);\n });\n\n const { data: result, error } = await queryBuilder\n .select()\n .single();\n\n if (error) {\n throw error;\n }\n\n return { data: result as T, error: null };\n } catch (error) {\n return { data: null, error: error as Error };\n }\n }\n\n\n /**\n * Delete data from a table\n * @param table The table name\n * @param eq The equality conditions\n */\n public async delete<T>(\n table: StripeTables,\n eq: Record<string, any>\n ): Promise<{ data: T | null; error: Error | null }> {\n try {\n let queryBuilder = this.client\n .schema('stripe')\n .from(table)\n .delete();\n\n Object.entries(eq).forEach(([key, value]) => {\n queryBuilder = queryBuilder.eq(key, value);\n });\n\n const { data: result, error } = await queryBuilder\n .select()\n .single();\n\n if (error) {\n throw error;\n }\n\n return { data: result as T, error: null };\n } catch (error) {\n return { data: null, error: error as Error };\n }\n }\n}\n","import { inject, Injectable } from '@angular/core';\nimport { loadStripe, Stripe, StripeEmbeddedCheckout } from '@stripe/stripe-js';\nimport type { Stripe as StripeTypes } from 'stripe';\nimport { STRIPE_CONFIG } from '../config/stripe.config';\nimport { StripeCustomerPublic } from '../store/customer.store';\nimport { SupabaseClientService } from './supabase-client.service';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class StripeClientService {\n private readonly config = inject(STRIPE_CONFIG);\n private readonly supabase = inject(SupabaseClientService);\n stripe: Promise<Stripe | null>;\n embeddedCheckout: StripeEmbeddedCheckout | null = null;\n\n constructor() {\n this.stripe = loadStripe(this.config.publishableKey);\n console.log('🔌 [StripeClientService]: Loaded Stripe Client from @stripe/stripe-js');\n }\n\n /**\n * Get the Stripe instance\n */\n public async getStripe(): Promise<Stripe | null> {\n return this.stripe;\n }\n\n /**\n * Initialize the embedded checkout\n * @param clientSecret The client secret for the checkout session\n */\n public async initEmbeddedCheckout(clientSecret: string) {\n const stripe = await this.getStripe();\n this.embeddedCheckout = await stripe?.initEmbeddedCheckout({ \n clientSecret\n }) ?? null;\n }\n\n /**\n * Mount the embedded checkout\n * @param elementId The ID of the element to mount the checkout on\n */\n public mountEmbeddedCheckout(elementId: string = '#embedded-checkout') {\n this.embeddedCheckout?.mount(elementId);\n }\n\n /**\n * Destroy the embedded checkout\n */\n public destroyEmbeddedCheckout() {\n console.log('🧹 [StripeClientService] destroying embedded checkout');\n this.embeddedCheckout?.destroy();\n this.embeddedCheckout = null;\n console.log('🧹 [StripeClientService] destroyed embedded checkout');\n }\n\n /**\n * Create a checkout session\n * @param priceId The price ID for the subscription\n * @param successUrl The URL to redirect to on success\n * @param cancelUrl The URL to redirect to on cancel\n */\n public async createCheckoutSession(\n priceId: string,\n resultPagePath: string,\n customer: StripeCustomerPublic | null\n ): Promise<{ clientSecret: string | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Checkout.Session>('checkout_session', {\n body: {\n priceId,\n resultPagePath,\n customer\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { \n clientSecret: data?.client_secret ?? null, \n error: null \n };\n } catch (error) {\n return { clientSecret: null, error: error as Error };\n }\n }\n\n /**\n * Create a subscription\n * @param priceId The price ID for the subscription\n */\n public async createSubscription(priceId: string, returnPath: string, customer: StripeCustomerPublic | null): Promise<{ clientSecret: string | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Checkout.Session>('create_subscription', {\n body: {\n priceId,\n resultPagePath: returnPath,\n customer\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { clientSecret: data?.client_secret ?? null, error: null };\n } catch (error) {\n return { clientSecret: null, error: error as Error };\n }\n }\n\n /**\n * Update a subscription\n * @param subscriptionId The subscription ID \n * @param params The parameters to update\n */\n public async updateSubscription(\n subscriptionId: string, \n params: any\n ): Promise<{ subscription: StripeTypes.Subscription | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Subscription>('update_subscription', {\n body: {\n subscriptionId,\n params\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { subscription: data, error: null };\n } catch (error) {\n return { subscription: null, error: error as Error };\n }\n }\n\n /**\n * Get a subscription\n * @param subscriptionId The subscription ID\n */\n public async getSubscription(\n subscriptionId: string\n ): Promise<{ subscription: StripeTypes.Subscription | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Subscription>('get_subscription', {\n body: {\n subscriptionId\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { subscription: data, error: null };\n } catch (error) {\n return { subscription: null, error: error as Error };\n }\n }\n\n /**\n * List customer subscriptions\n */\n public async listSubscriptions(): Promise<{ subscriptions: StripeTypes.Subscription[] | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Subscription[]>('list_subscriptions');\n\n if (error) {\n throw error;\n }\n\n return { subscriptions: data, error: null };\n } catch (error) {\n return { subscriptions: null, error: error as Error };\n }\n }\n\n /**\n * Cancel a subscription\n * @param subscriptionId The subscription ID\n */\n public async cancelSubscription(\n subscriptionId: string\n ): Promise<{ subscription: StripeTypes.Subscription | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Subscription>('cancel_subscription', {\n body: {\n subscriptionId\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { subscription: data, error: null };\n } catch (error) {\n return { subscription: null, error: error as Error };\n }\n }\n\n /**\n * Resume a paused subscription\n * @param subscriptionId The subscription ID\n * @param params Optional parameters for resumption\n */\n public async resumeSubscription(\n subscriptionId: string,\n params?: any\n ): Promise<{ subscription: StripeTypes.Subscription | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Subscription>('resume_subscription', {\n body: {\n subscriptionId,\n params\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { subscription: data, error: null };\n } catch (error) {\n return { subscription: null, error: error as Error };\n }\n }\n\n /**\n * Retrieve the payment intent status\n * @param sessionId The session ID of the checkout session\n */\n public async getCheckoutSessionStatus(sessionId: string): Promise<{ \n sessionStatus: StripeTypes.Checkout.Session | null; \n error: Error | null \n }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Checkout.Session>('session_status', {\n body: {\n sessionId\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { sessionStatus: data, error: null };\n } catch (error) {\n console.error('❌ [StripeClientService]: Error retrieving payment intent:', error);\n return { sessionStatus: null, error: error as Error };\n }\n }\n\n /**\n * Create a portal session\n * @param customerId The customer ID\n * @param returnUrl The URL to redirect to after the portal session\n */\n public async createPortalSession(customerId: string, returnUrl: string): Promise<{ url: string | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.BillingPortal.Session>('create_portal_session', {\n body: {\n customerId,\n returnUrl\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { url: data?.url ?? null, error: null };\n } catch (error) {\n return { url: null, error: error as Error };\n }\n }\n\n /**\n * Create a customer\n * @param customerEmail The email of the customer\n */\n public async createCustomer(customerEmail: string): Promise<{ customer: StripeTypes.Customer | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.Customer>('create_customer', {\n body: {\n customerEmail\n }\n });\n\n if (error) {\n throw error;\n }\n\n return { customer: data, error: null };\n } catch (error) {\n return { customer: null, error: error as Error };\n }\n }\n\n public async getCustomerPaymentMethods(customerId: string): Promise<{ paymentMethods: StripeTypes.PaymentMethod[] | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.PaymentMethod[]>('customer_payment_methods', {\n body: { customerId }\n });\n\n if (error) {\n throw error;\n }\n\n return { paymentMethods: data, error: null };\n } catch (error) {\n return { paymentMethods: null, error: error as Error };\n }\n }\n\n public async getCustomerPaymentMethod(customerId: string, paymentMethodId: string): Promise<{ paymentMethod: StripeTypes.PaymentMethod | null; error: Error | null }> {\n try {\n const { data, error } = await this.supabase.getClient()\n .functions.invoke<StripeTypes.PaymentMethod>('customer_payment_method', {\n body: { customerId, paymentMethodId }\n });\n\n if (error) {\n throw error;\n }\n\n return { paymentMethod: data, error: null };\n } catch (error) {\n return { paymentMethod: null, error: error as Error };\n }\n }\n}\n","export enum Currency {\n EUR = 'eur',\n USD = 'usd',\n GBP = 'gbp',\n JPY = 'jpy',\n KRW = 'krw',\n CNY = 'cny',\n INR = 'inr',\n}","import { computed, inject } from '@angular/core';\nimport { patchState, signalStore, withComputed, withHooks, withMethods, withState } from '@ngrx/signals';\nimport { StripePrice, StripeProduct } from '../models/database.model';\nimport { SupabaseClientService } from '../services/supabase-client.service';\nimport { Currency } from '../models/currency.model';\n\nexport type StripeProductPublic = Omit<StripeProduct, 'attrs'> & {\n images: string[];\n prices: {\n details: StripePricePublic;\n recurringInterval: string;\n }[];\n}\n\nexport type StripePricePublic = Omit<StripePrice, 'attrs'>;\n\nexport type ProductsStatus = 'idle' | 'loading' | 'success' | 'error';\n\ntype ProductsState = {\n products: StripeProductPublic[] | null;\n prices: StripePricePublic[] | null;\n status: ProductsStatus;\n error: string | null;\n currency: Currency;\n}\n\nconst initialProductsState: ProductsState = {\n products: null,\n prices: null,\n status: 'idle',\n error: null,\n currency: Currency.EUR,\n};\n\nexport const ProductsStore = signalStore(\n { providedIn: 'root' },\n withState(initialProductsState),\n withComputed((state) => ({\n isStatusLoading: computed(() => state.status() === 'loading'),\n isStatusSuccess: computed(() => state.status() === 'success'),\n isStatusError: computed(() => state.status() === 'error'),\n oneTimeproductsByCurrency: computed(() => state.products()?.filter(product => \n product.prices.some(price => (price.details.type === 'one_time' && price.details.currency === state.currency()))\n ) || []),\n recurringProductsByCurrency: computed(() => state.products()?.filter(product => \n product.prices.some(price => (price.details.type === 'recurring' && price.details.currency === state.currency()))\n ) || []),\n productsByCurrency: computed(() => state.products()?.filter(product => \n product.prices.some(price => (price.details.currency === state.currency()))\n ) || []),\n hasProducts: computed(() => state.products() !== null && state.products()!.length > 0),\n isError: computed(() => state.error())\n })),\n withMethods((store, supabaseService = inject(SupabaseClientService)) => ({\n /**\n * Get products by IDs from the current loaded products\n */\n getProductsByIds(ids: string[]): StripeProductPublic[] {\n console.log('🎮 [ProductsStore] Loading products by ids: ', ids);\n return store.products()?.filter(product => product.id && ids.includes(product.id)) || [];\n },\n\n /**\n * Set the currency filter for products\n */\n setCurrency(currency: Currency): void {\n patchState(store, { currency });\n },\n\n /**\n * Load product by id\n */\n async loadProductById(id: string) {\n patchState(store, { status: 'loading', error: null });\n\n try {\n const { data: product, error: productError } = await supabaseService.selectStripeProduct(id);\n \n if (productError) {\n console.error('🎮 [ProductsStore]: Error loading product', productError);\n patchState(store, { status: 'error', error: (productError as Error).message });\n }\n\n const products: StripeProductPublic[] = [];\n \n if (product && product.length > 0) {\n const productParsed = parseProduct(product[0], store.prices() as StripePrice[]);\n products.push(productParsed);\n }\n\n patchState(store, { status: 'success', products });\n \n } catch (error) {\n patchState(store, { status: 'error', error: (error as Error).message });\n }\n },\n\n /**\n * Load products from Stripe\n */\n async loadProducts() {\n patchState(store, { status: 'loading', error: null });\n\n try {\n const { data: prices, error: pricesError } = await supabaseService.selectStripePrices();\n\n if (pricesError) {\n console.error('🎮 [ProductsStore]: Error loading prices', pricesError);\n patchState(store, { status: 'error', error: (pricesError as Error).message });\n }\n \n patchState(store, { prices: prices || [] });\n\n const { data: stripeProducts, error: productsError } = await supabaseService.selectStripeProducts();\n\n if (productsError) {\n console.error('🎮 [ProductsStore]: Error loading products', productsError);\n patchState(store, {\n status: 'error',\n error: (productsError as Error).message,\n });\n }\n\n if (stripeProducts) {\n {\n const products: StripeProductPublic[] = [];\n\n stripeProducts.forEach(product => {\n products.push(parseProduct(product, store.prices() as StripePrice[]));\n });\n\n console.log('🎮 [ProductsStore] products: ', products);\n\n patchState(store, {\n status: 'success',\n products: products\n });\n }\n }\n\n } catch (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n }\n },\n\n /**\n * Reset the store to initial state\n */\n reset() {\n patchState(store, initialProductsState);\n }\n })),\n withHooks((store) => ({\n async onInit() {\n console.log('🎮 [ProductsStore] onInit');\n\n const products = store.products();\n console.log('🎮 [ProductsStore] products: ', products);\n\n if (!products) {\n console.log('🎮 [ProductsStore] loading products...');\n await store.loadProducts();\n }\n }\n }))\n)\n\nexport function parseProduct(product: StripeProduct, prices: StripePrice[] = []): StripeProductPublic {\n const { attrs, ...mainProperties } = product;\n return {\n ...mainProperties,\n images: (attrs as any)?.images || [],\n prices: prices.filter(price => price.product === product.id).map(price => ({\n details: price,\n recurringInterval: (price?.attrs as any)?.recurring?.interval || 'no-recurring'\n }))\n };\n}\n\n","import { computed, inject } from '@angular/core';\nimport { patchState, signalStore, withComputed, withHooks, withMethods, withState } from '@ngrx/signals';\nimport { StripeSubscription } from '../models/database.model';\nimport { StripeClientService } from '../services/stripe-client.service';\nimport { SupabaseClientService } from '../services/supabase-client.service';\nimport { ProductsStore, StripeProductPublic } from './products.store';\nimport { CustomerStore, StripeCustomerPublic } from './customer.store';\n\nexport type StripeSubscriptionCancellationDetails = {\n cancel_at_period_end: boolean;\n cancel_at: number;\n canceled_at: number;\n cancellation_details: {\n comment: string;\n feedback: string;\n reason: string;\n }\n}\n\nexport type StripeSubscriptionPlan = {\n amount: number;\n active: boolean;\n interval: string;\n productId: string;\n}\n\nexport type StripeSubscriptionPublic = Omit<StripeSubscription, 'attrs'> & {\n status: string;\n plan: StripeSubscriptionPlan;\n cancel: StripeSubscriptionCancellationDetails;\n product?: StripeProductPublic | null;\n};\n\nexport type SubscriptionStatus = 'idle' | 'loading' | 'success' | 'error';\n\nexport interface SubscriptionState {\n subscriptions: StripeSubscriptionPublic[] | null;\n currentSubscription: StripeSubscriptionPublic | null;\n status: SubscriptionStatus;\n error: string | null;\n sessionStatus: any | null;\n}\n\nconst initialSubscriptionState: SubscriptionState = {\n subscriptions: null,\n currentSubscription: null,\n status: 'idle',\n error: null,\n sessionStatus: null,\n};\n\nexport const SubscriptionsStore = signalStore(\n { providedIn: 'root' },\n withState(initialSubscriptionState),\n withComputed((state) => ({\n isStatusLoading: computed(() => state.status() === 'loading'),\n isStatusSuccess: computed(() => state.status() === 'success'),\n isStatusError: computed(() => state.status() === 'error'),\n hasSubscriptions: computed(() => state.subscriptions() !== null && state.subscriptions()!.length > 0),\n isError: computed(() => state.error()),\n })),\n withMethods((store, stripeService = inject(StripeClientService), \n supabaseService = inject(SupabaseClientService), \n productsStore = inject(ProductsStore),\n customerStore = inject(CustomerStore)) => ({\n /**\n * Create a subscription\n * @param priceId The price ID for the subscription\n */\n async createSubscription(priceId: string, returnPath: string, customer: StripeCustomerPublic | null) {\n patchState(store, { status: 'loading', error: null });\n\n try {\n const { clientSecret, error } = await stripeService.createSubscription(priceId, returnPath, customer);\n console.log('🔍 [SubscriptionsStore] created subscription', clientSecret, error);\n \n if (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n } else {\n const stripe = await stripeService.getStripe();\n\n if (!stripe) {\n patchState(store, {\n status: 'error',\n error: 'No Stripe instance returned',\n });\n } else {\n await stripeService.initEmbeddedCheckout(clientSecret as string);\n stripeService.mountEmbeddedCheckout();\n\n patchState(store, {\n status: 'success',\n });\n }\n }\n } catch (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n }\n },\n\n /**\n * Load all subscriptions for the current customer\n */\n async loadSubscriptions() {\n patchState(store, { status: 'loading', error: null });\n\n try {\n const { data: subscriptions, error } = await supabaseService.getStripeSubscriptions();\n console.log('🔍 [SubscriptionsStore] loaded subscriptions', subscriptions);\n\n const parsedSubscriptions = subscriptions?.map((subscription) => {\n const parsedSubscription = parseSubscription(subscription as StripeSubscription);\n \n // Get the product associated with this subscription\n const productId = parsedSubscription.plan.productId;\n if (productId && productsStore.products()) {\n const product = productsStore.products()?.find(p => p.id === productId);\n if (product) {\n parsedSubscription.product = product;\n }\n }\n \n return parsedSubscription;\n });\n\n if (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n } else {\n patchState(store, {\n status: 'success',\n subscriptions: parsedSubscriptions\n });\n }\n } catch (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n }\n },\n\n /**\n * Get a specific subscription\n * @param subscriptionId The subscription ID\n */\n async getSubscription(subscriptionId: string) {\n patchState(store, { status: 'loading', error: null });\n\n try {\n const { data, error } = await supabaseService.selectStripeSubscription(subscriptionId);\n const [subscription] = data || [];\n console.log('🔍 [SubscriptionsStore] got subscription', subscription, error);\n\n const parsedSubscription = parseSubscription(subscription as StripeSubscription);\n\n // Get the product associated with this subscription\n const productId = parsedSubscription.plan.productId;\n if (productId && productsStore.products()) {\n const product = productsStore.products()?.find(p => p.id === productId);\n if (product) {\n parsedSubscription.product = product;\n }\n }\n\n if (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n } else {\n patchState(store, {\n status: 'success',\n currentSubscription: parsedSubscription\n });\n }\n } catch (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n }\n },\n\n /**\n * Get the status of a checkout subcription session\n * @param sessionId The ID of the checkout subcription session\n */\n async getSessionStatus({sessionId}: {sessionId: string}) {\n patchState(store, { status: 'loading', error: null });\n\n try {\n const { sessionStatus, error } = await stripeService.getCheckoutSessionStatus(sessionId);\n \n if (error) {\n patchState(store, { status: 'error', error: (error as Error).message });\n } else {\n patchState(store, { status: 'success', sessionStatus });\n }\n\n } catch (error) {\n patchState(store, { status: 'error', error: (error as Error).message });\n }\n },\n\n /**\n * Destroy the embedded subscription\n */\n destroyEmbeddedSubscription() {\n stripeService.destroyEmbeddedCheckout();\n },\n\n /**\n * Reset the store to initial state\n */\n reset() {\n patchState(store, initialSubscriptionState);\n }\n })),\n withHooks(() => {\n const productsStore = inject(ProductsStore);\n\n if (!productsStore.hasProducts()) {\n productsStore.loadProducts();\n console.log('🔍 [SubscriptionsStore] loading products');\n }\n\n return {\n onInit() {\n console.log('🔍 [SubscriptionsStore] initialized');\n },\n onDestroy() {\n console.log('🧹 [SubscriptionsStore] destroyed');\n }\n }\n })\n);\n\nexport function parseSubscription(subscription: StripeSubscription): StripeSubscriptionPublic {\n const subscriptionAttrs = subscription.attrs as any;\n \n return {\n ...subscription,\n status: subscriptionAttrs.status,\n plan: {\n amount: subscriptionAttrs.plan.amount,\n active: subscriptionAttrs.plan.active,\n interval: subscriptionAttrs.plan.interval,\n productId: subscriptionAttrs.plan.product,\n },\n cancel: {\n cancel_at_period_end: subscriptionAttrs.cancel_at_period_end ?? false,\n cancel_at: subscriptionAttrs.cancel_at ?? null,\n canceled_at: subscriptionAttrs.canceled_at ?? null,\n cancellation_details: subscriptionAttrs.cancellation_details ?? {\n comment: null,\n feedback: null,\n reason: null\n }\n },\n product: subscriptionAttrs.product ? subscriptionAttrs.product as StripeProductPublic : undefined\n };\n}","import { computed, inject } from '@angular/core';\nimport { patchState, signalStore, withComputed, withHooks, withMethods, withState } from '@ngrx/signals';\nimport { addEntity, removeEntity, setAllEntities, setEntity, updateEntity, upsertEntity, withEntities } from '@ngrx/signals/entities';\nimport type { Stripe as StripeTypes } from 'stripe';\nimport { StripeCustomer, StripePaymentIntent } from '../models/database.model';\nimport { StripeClientService } from '../services/stripe-client.service';\nimport { SupabaseClientService } from '../services/supabase-client.service';\nimport { ProductsStore } from './products.store';\nimport { parseSubscription, StripeSubscriptionPublic } from './subscriptions.store';\n\nexport type CustomerStatus = 'idle' | 'loading' | 'success' | 'error';\n\nexport type StripePaymentIntentsPublic = Omit<StripePaymentIntent, 'attrs'> & {\n status: string;\n invoiceId: string;\n liveMode: boolean;\n confirmationMethod: string;\n paymentMethodId: string;\n paymentMethod?: PaymentMethodEntity;\n};\n\nexport type StripeCustomerPublic = Omit<StripeCustomer, 'attrs'>;\n\nexport type PaymentMethodEntity = StripeTypes.PaymentMethod;\n\nexport interface CustomerState {\n customer: {\n data: StripeCustomerPublic | null;\n status: CustomerStatus;\n error: string | null;\n };\n paymentIntents: {\n data: StripePaymentIntentsPublic[];\n status: CustomerStatus;\n error: string | null;\n };\n subscriptions: {\n data: StripeSubscriptionPublic[];\n status: CustomerStatus;\n error: string | null;\n };\n paymentMethodsStatus: CustomerStatus;\n paymentMethodsError: string | null;\n}\n\nconst initialCustomerState: CustomerState = {\n customer: { \n status: 'idle', \n data: null,\n error: null \n },\n paymentIntents: {\n data: [],\n status: 'idle',\n error: null,\n },\n subscriptions: {\n data: [], \n status: 'idle',\n error: null,\n },\n paymentMethodsStatus: 'idle',\n paymentMethodsError: null,\n};\n\n\nexport const CustomerStore = signalStore(\n { providedIn: 'root' },\n withState(initialCustomerState),\n withEntities<PaymentMethodEntity>(),\n withComputed((state) => ({\n isPaymentIntentsStatusLoading: computed(() => state.paymentIntents.status() === 'loading'),\n isPaymentIntentsStatusSuccess: computed(() => state.paymentIntents.status() === 'success'),\n isPaymentIntentsStatusError: computed(() => state.paymentIntents.status() === 'error'),\n isSubscriptionsStatusLoading: computed(() => state.subscriptions.status() === 'loading'),\n isSubscriptionsStatusSuccess: computed(() => state.subscriptions.status() === 'success'),\n isSubscriptionsStatusError: computed(() => state.subscriptions.status() === 'error'),\n hasSubscriptions: computed(() => state.subscriptions.data() !== null && state.subscriptions.data()!.length > 0),\n hasPaymentIntents: computed(() => state.paymentIntents.data() !== null && state.paymentIntents.data()!.length > 0),\n firstSubscription: computed(() => state.subscriptions.data()?.[0]),\n restSubscriptions: computed(() => state.subscriptions.data()?.slice(1)),\n isError: computed(() => state.paymentIntents.error()),\n isPaymentMethodsStatusLoading: computed(() => state.paymentMethodsStatus() === 'loading'),\n isPaymentMethodsStatusSuccess: computed(() => state.paymentMethodsStatus() === 'success'),\n isPaymentMethodsStatusError: computed(() => state.paymentMethodsStatus() === 'error'),\n hasPaymentMethods: computed(() => state.entities().length > 0),\n paymentMethods: computed(() => state.entities()),\n })),\n withMethods((state, supabaseService = inject(SupabaseClientService), stripeService = inject(StripeClientService), productsStore = inject(ProductsStore)) => ({\n /**\n * Load customer\n * @param customerEmail The customer email\n */\n async loadCustomer(customerEmail: string) {\n patchState(state, { customer: { status: 'loading', data: null, error: null } });\n\n const { data, error } = await supabaseService.getCustomerByEmail(customerEmail);\n const [customer] = data as StripeCustomerPublic[];\n\n if (error) {\n patchState(state, { customer: { error: error.message, status: 'error', data: null } });\n } else {\n \n if (customer) {\n this.loadPaymentIntents(customer.id as string);\n this.loadSubscriptions(customer.id as string);\n this.loadPaymentMethods(customer.id as string);\n\n patchState(state, { customer: { data: customer, status: 'success', error: null } });\n } else {\n this.createCustomer(customerEmail);\n }\n\n }\n },\n\n /**\n * Create a customer\n * @param customerEmail The customer email\n */\n async createCustomer(customerEmail: string) {\n const { customer, error } = await stripeService.createCustomer(customerEmail);\n\n if (error) {\n patchState(state, { customer: { error: error.message, status: 'error', data: null } });\n } else {\n patchState(state, { customer: { data: customer as StripeCustomerPublic, status: 'success', error: null } });\n }\n },\n\n /**\n * Load payment intents\n * @param customerId The customer ID\n */\n async loadPaymentIntents(customerId: string) {\n patchState(state, { paymentIntents: { status: 'loading', data: [], error: null } });\n\n const { data, error } = await supabaseService.getCustomerPaymentIntents(customerId);\n const paymentIntents = data?.map((paymentIntent) => parsePaymentIntent(paymentIntent, state.entityMap()));\n\n if (error) {\n patchState(state, { paymentIntents: { error: error.message, status: 'error', data: [] } });\n } else {\n patchState(state, { paymentIntents: { data: paymentIntents ?? [], status: 'success', error: null } });\n }\n }, \n\n /**\n * Load subscriptions\n * @param customerId The customer ID\n */\n async loadSubscriptions(customerId: string) {\n patchState(state, { subscriptions: { data: [], status: 'loading', error: null } });\n\n const { data, error } = await supabaseService.getCustomerSubscriptions(customerId);\n \n if (error) {\n patchState(state, { subscriptions: { error: error.message, status: 'error', data: [] } });\n } else {\n const subscriptions = data.map((subscription) => {\n const parsedSubscription = parseSubscription(subscription);\n \n // Get the product associated with this subscription\n const productId = parsedSubscription.plan.productId;\n if (productId && productsStore.products()) {\n const product = productsStore.products()?.find(p => p.id === productId);\n if (product) {\n parsedSubscription.product = product;\n }\n }\n \n return parsedSubscription;\n });\n\n console.log('🔍 [CustomerStore] subscriptions: ', subscriptions);\n \n patchState(state, { subscriptions: { data: subscriptions ?? [], status: 'success', error: null } });\n }\n },\n\n /**\n * Load payment methods for a customer\n * @param customerId The customer ID\n */\n async loadPaymentMethods(customerId: string) {\n patchState(state, { \n paymentMethodsStatus: 'loading', \n paymentMethodsError: null \n });\n\n const { paymentMethods, error } = await stripeService.getCustomerPaymentMethods(customerId);\n\n if (error) {\n patchState(state, { \n paymentMethodsStatus: 'error', \n paymentMethodsError: error.message \n });\n } else {\n patchState(state, \n setAllEntities(paymentMethods ?? []),\n { \n paymentMethodsStatus: 'success', \n paymentMethodsError: null \n }\n );\n }\n },\n\n /**\n * Load a single payment method and add/update it in the entity collection\n * @param customerId The customer ID\n * @param paymentMethodId The payment method ID\n */\n async loadPaymentMethod(customerId: string, paymentMethodId: string) {\n patchState(state, { \n paymentMethodsStatus: 'loading', \n paymentMethodsError: null \n });\n\n const { paymentMethod, error } = await stripeService.getCustomerPaymentMethod(customerId, paymentMethodId);\n\n if (error) {\n patchState(state, { \n paymentMethodsStatus: 'error', \n paymentMethodsError: error.message \n });\n } else if (paymentMethod) {\n }\n\n if (paymentMethod) {\n patchState(state, \n upsertEntity(paymentMethod),\n { \n paymentMethodsStatus: 'success', \n paymentMethodsError: null \n }\n );\n } else {\n patchState(state, { \n paymentMethodsStatus: 'error', \n paymentMethodsError: 'Payment method not found' \n });\n }\n },\n })),\n withHooks(() => {\n return {\n onInit() {\n const productsStore = inject(ProductsStore);\n\n if (!productsStore.hasProducts()) {\n console.log('🔍 [CustomerStore] loading products...');\n productsStore.loadProducts();\n }\n console.log('🔍 [CustomerStore] initialized');\n },\n onDestroy() {\n console.log('🧹 [CustomerStore] destroyed');\n }\n }\n })\n);\n\nexport function parsePaymentIntent(\n paymentIntent: StripePaymentIntent, \n paymentMethodsMap: Record<string, PaymentMethodEntity> = {}\n): StripePaymentIntentsPublic {\n console.log('🔍 [CustomerStore] paymentIntent: ', paymentIntent);\n\n const paymentIntentAttrs = paymentIntent.attrs as any;\n const paymentMethodId = paymentIntentAttrs.payment_method;\n \n return {\n ...paymentIntent,\n status: paymentIntentAttrs.status,\n invoiceId: paymentIntentAttrs.invoice as string,\n liveMode: paymentIntentAttrs.livemode as boolean,\n confirmationMethod: paymentIntentAttrs.confirmation_method,\n paymentMethodId,\n paymentMethod: paymentMethodId ? paymentMethodsMap[paymentMethodId] : undefined,\n };\n}","import { computed, inject } from '@angular/core';\nimport { patchState, signalStore, withComputed, withHooks, withMethods, withState } from '@ngrx/signals';\nimport { StripeClientService } from '../services/stripe-client.service';\nimport { CustomerStore, StripeCustomerPublic } from './customer.store';\nimport type { Stripe as StripeTypes } from 'stripe';\n\nexport type ICheckoutSessionStatus = StripeTypes.Checkout.Session;\n\nexport type CheckoutStatus = 'idle' | 'loading' | 'success' | 'error';\n\ntype CheckoutState = {\n status: CheckoutStatus;\n sessionId: string | null;\n returnPagePath: string;\n error: string | null;\n sessionStatus: ICheckoutSessionStatus | null;\n}\n\nconst initialCheckoutState: CheckoutState = {\n status: 'idle',\n sessionId: null,\n returnPagePath: '/return',\n error: null,\n sessionStatus: null\n};\n\nexport const CheckoutStore = signalStore(\n { providedIn: 'root' },\n withState(initialCheckoutState),\n withComputed((state) => ({\n isStatusLoading: computed(() => state.status() === 'loading'),\n isStatusSuccess: computed(() => state.status() === 'success'),\n isStatusError: computed(() => state.status() === 'error'),\n paymentStatus: computed(() => state.sessionStatus()?.status),\n isPaymentComplete: computed(() => state.sessionStatus()?.status === 'complete'),\n isPaymentProcessing: computed(() => state.sessionStatus()?.status === 'open'),\n isError: computed(() => state.error())\n })),\n withMethods((store, stripeService = inject(StripeClientService), customerStore = inject(CustomerStore)) => ({\n /**\n * Create a checkout session\n * @param priceId The price ID to checkout\n * @param returnPagePath The return page path after checkout\n */\n async createCheckoutSession({priceId, returnPagePath, customerEmail}: {priceId: string, returnPagePath: string, customerEmail: string | null}) {\n patchState(store, { status: 'loading', error: null });\n\n try {\n let customer: StripeCustomerPublic | null = null;\n \n if (customerEmail) {\n customer = customerStore.customer().data;\n }\n\n const { clientSecret, error } = await stripeService.createCheckoutSession(priceId, returnPagePath, customer);\n\n if (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n } else {\n const stripe = await stripeService.getStripe();\n\n if (!stripe) {\n patchState(store, {\n status: 'error',\n error: 'No Stripe instance returned',\n });\n } else {\n await stripeService.initEmbeddedCheckout(clientSecret as string);\n stripeService.mountEmbeddedCheckout();\n\n patchState(store, {\n status: 'success',\n });\n }\n }\n\n } catch (error) {\n patchState(store, {\n status: 'error',\n error: (error as Error).message,\n });\n }\n },\n\n /**\n * Get the status of a checkout session\n * @param sessionId The ID of the checkout session\n */\n async getSessionStatus({sessionId}: {sessionId: string}) {\n patchState(store, { status: 'loading', error: null });\n\n try {\n const { sessionStatus, error } = await stripeService.getCheckoutSessionStatus(sessionId);\n \n if (error) {\n patchState(store, { status: 'error', error: (error as Error).message });\n } else {\n patchState(store, { status: 'success', sessionStatus });\n }\n\n } catch (error) {\n patchState(store, { status: 'error', error: (error as Error).message });\n }\n },\n\n\n /**\n * Destroy the embedded checkout\n */\n destroyEmbeddedCheckout() {\n stripeService.destroyEmbeddedCheckout();\n },\n \n /**\n * Reset the store to initial state\n */\n reset() {\n patchState(store, initialCheckoutState);\n }\n })),\n withHooks({\n onInit() {\n console.log('🔍 [CheckoutStore] initialized');\n },\n onDestroy() {\n console.log('🧹 [CheckoutStore] destroyed');\n }\n })\n) ","import { computed, inject } from '@angular/core';\nimport { patchState, signalStore, withComputed, withMethods, withState } from '@ngrx/signals';\nimport { StripeClientService } from '../services/stripe-client.service';\n\nexport interface PortalSessionResponse {\n url: string;\n}\n\nexport type PortalStatus = 'idle' | 'loading' | 'success' | 'error';\n\nexport interface PortalState {\n status: PortalStatus;\n error: string | null;\n portalUrl: string | null;\n}\n\nconst initialPortalState: PortalState = {\n status: 'idle',\n error: null,\n portalUrl: null\n};\n\nexport const PortalAccountStore = signalStore(\n { providedIn: 'root' },\n withState(initialPortalState),\n withComputed((state) => ({\n isStatusIdle: computed(() => state.status() === 'idle'),\n isStatusLoading: computed(() => state.status() === 'loading'),\n isStatusSuccess: computed(() => state.status() === 'success'),\n isStatusError: computed(() => state.status() === 'error'),\n })),\n withMethods((store, stripeService = inject(StripeClientService)) => ({\n /**\n * Creates a customer portal session and redirects to the URL\n * @param customerId Stripe customer ID\n * @param returnUrl URL to redirect to after the portal session\n */\n async createPortalSession(customerId: string, returnUrl: string): Promise<void> {\n patchState(store, { status: 'loading', error: null, portalUrl: null });\n\n try {\n const { url, error } = await stripeService.createPortalSession(customerId, returnUrl);\n\n if (error) {\n throw new Error(error.message);\n }\n\n if (!url) {\n throw new Error('No se pudo crear la sesión del portal');\n }\n\n patchState(store, {\n status: 'success',\n portalUrl: url\n });\n\n window.location.href = url;\n } catch (error) {\n console.error('🚨 [PortalAccountStore]', error);\n \n const errorMessage = error instanceof Error ? error.message : 'Error desconocido';\n \n patchState(store, {\n status: 'error',\n error: errorMessage\n });\n }\n },\n\n /**\n * Resets the store to initial state\n */\n reset(): void {\n patchState(store, initialPortalState);\n }\n }))\n); ","import { Component } from '@angular/core';\n\n@Component({\n selector: 'lib-embedded-skeleton',\n templateUrl: './embedded-skeleton.component.html',\n standalone: true\n})\nexport class EmbeddedSkeletonComponent {} ","<div class=\"w-full max-w-md mx-auto p-4\">\n <!-- Header skeleton -->\n <div class=\"flex items-center gap-4 mb-6\">\n <div class=\"skeleton w-16 h-16 rounded-lg\"></div>\n <div class=\"skeleton h-6 w-48\"></div>\n </div>\n\n <!-- Price skeleton -->\n <div class=\"mb-8\">\n <div class=\"skeleton h-10 w-32 mb-2\"></div>\n <div class=\"skeleton h-4 w-24\"></div>\n </div>\n\n <!-- Payment form skeleton -->\n <div class=\"space-y-4\">\n <!-- Email field -->\n <div class=\"skeleton h-12 w-full\"></div>\n \n <!-- Card info field -->\n <div class=\"skeleton h-12 w-full\"></div>\n \n <!-- Name field -->\n <div class=\"skeleton h-12 w-full\"></div>\n \n <!-- Country selector -->\n <div class=\"skeleton h-12 w-full\"></div>\n \n <!-- Submit button -->\n <div class=\"skeleton h-12 w-full mt-6\"></div>\n </div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, computed, inject, input, OnInit } from '@angular/core';\nimport { CheckoutStore } from '../../store/checkout.store';\nimport { CustomerStore } from '../../store/customer.store';\nimport { EmbeddedSkeletonComponent } from '../embedded-skeleton/embedded-skeleton.component';\n\n@Component({\n selector: 'lib-embedded-checkout',\n templateUrl: './embedded-checkout.component.html',\n standalone: true,\n imports: [CommonModule, EmbeddedSkeletonComponent],\n})\nexport class EmbeddedCheckoutComponent implements OnInit {\n public readonly checkoutStore = inject(CheckoutStore);\n public readonly customerStore = inject(CustomerStore);\n \n public readonly priceId = input.required<string>();\n public readonly returnPagePath = input<string>('/return');\n \n public readonly customer = computed(() => this.customerStore.customer().data);\n\n async ngOnInit() {\n this.createCheckoutSession();\n }\n\n private createCheckoutSession() {\n const baseUrl = window.location.origin;\n const returnPath = `${baseUrl}${this.returnPagePath()}`;\n\n // Create the checkout session\n this.checkoutStore.createCheckoutSession({\n priceId: this.priceId(),\n returnPagePath: returnPath,\n customerEmail: this.customer()?.email ?? ''\n });\n }\n\n ngOnDestroy() {\n this.checkoutStore.destroyEmbeddedCheckout();\n }\n} ","<div class=\"checkout-container\">\n @if (checkoutStore.isStatusLoading()) {\n <lib-embedded-skeleton />\n }\n \n @if (checkoutStore.isStatusError()) {\n <div class=\"error\">\n <p>Error: {{ checkoutStore.error() }}</p>\n </div>\n }\n <div id=\"embedded-checkout\"></div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, OnInit, inject, input } from '@angular/core';\nimport { ActivatedRoute, Router } from '@angular/router';\nimport { CheckoutStore } from '../../../store/checkout.store';\n\n@Component({\n selector: 'lib-checkout-return-page',\n templateUrl: './return-page.component.html',\n standalone: true,\n imports: [CommonModule],\n})\nexport class ReturnPageComponent implements OnInit {\n private readonly route = inject(ActivatedRoute);\n private readonly router = inject(Router);\n \n public readonly checkoutStore = inject(CheckoutStore);\n \n public readonly returnUrl = input<string>('/');\n \n async ngOnInit() {\n this.route.queryParams.subscribe(async params => {\n const sessionId = params['session_id'];\n this.getSessionStatus(sessionId);\n });\n }\n\n private async getSessionStatus(sessionId: string) {\n if (sessionId) {\n await this.checkoutStore.getSessionStatus({ sessionId });\n } else {\n console.error('Missing session_id parameter in URL');\n }\n }\n \n public navigate(): void {\n this.router.navigateByUrl(this.returnUrl());\n }\n} ","<div class=\"return-page-container\">\n @if (checkoutStore.isStatusLoading()) {\n <div class=\"loading-state\">\n <div class=\"spinner\"></div>\n <p>Verifying your payment status...</p>\n </div>\n }\n\n @if (checkoutStore.isStatusSuccess() && checkoutStore.isPaymentComplete()) {\n <div class=\"alert alert-success alert-soft flex flex-col items-center gap-4\">\n <div class=\"flex items-center gap-4\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" fill=\"none\" viewBox=\"0 0 24 24\" stroke-width=\"1.5\" stroke=\"currentColor\" class=\"w-12 h-12\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 12.75L11.25 15 15 9.75M21 12a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n <h2 class=\"status-title\">¡Payment completed successfully!</h2>\n </div>\n </div>\n }\n\n @if (checkoutStore.isStatusSuccess() && checkoutStore.isPaymentProcessing()) {\n <div class=\"alert alert-info alert-soft flex flex-col items-center gap-4\">\n <div class=\"flex items-center gap-4\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" fill=\"none\" viewBox=\"0 0 24 24\" stroke-width=\"1.5\" stroke=\"currentColor\" class=\"w-12 h-12\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M12 6v6h4.5m4.5 0a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n <h2 class=\"status-title\">Payment in processing</h2>\n </div>\n <p class=\"status-message\">Your payment is being processed. You will receive an email confirmation when it is complete.</p>\n </div>\n }\n\n @if (checkoutStore.isStatusError()) {\n <div class=\"alert alert-error alert-soft flex flex-col items-center gap-4\">\n <div class=\"flex items-center gap-4\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" fill=\"none\" viewBox=\"0 0 24 24\" stroke-width=\"1.5\" stroke=\"currentColor\" class=\"w-12 h-12\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M12 9v3.75m-9.303 3.376c-.866 1.5.217 3.374 1.948 3.374h14.71c1.73 0 2.813-1.874 1.948-3.374L13.949 3.378c-.866-1.5-3.032-1.5-3.898 0L2.697 16.126zM12 15.75h.007v.008H12v-.008z\" />\n </svg>\n <h2 class=\"status-title\">An error occurred</h2>\n </div>\n @if (checkoutStore.error()) {\n <p class=\"status-message\">{{ checkoutStore.error() }}</p>\n } @else {\n <p class=\"status-message\">The payment could not be processed. Please try again or contact support.</p>\n }\n </div>\n }\n\n <div class=\"flex justify-end w-full pt-4\">\n <button class=\"btn btn-outline\" (click)=\"navigate()\">Back</button>\n </div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component } from '@angular/core';\n\n@Component({\n selector: 'lib-product-item-skeleton',\n standalone: true,\n imports: [CommonModule],\n templateUrl: './product-item-skeleton.component.html'\n})\nexport class ProductItemSkeletonComponent {} ","<div class=\"card bg-base-100 shadow-xl w-[350px]\">\n <figure>\n <div class=\"skeleton h-48 w-full\"></div>\n </figure>\n <div class=\"card-body\">\n <div class=\"skeleton h-8 w-32\"></div>\n <div class=\"skeleton h-6 w-48\"></div>\n <div class=\"skeleton h-4 w-full\"></div>\n <div class=\"skeleton h-4 w-3/4\"></div>\n <div class=\"card-actions justify-end mt-4\">\n <div class=\"skeleton h-10 w-24\"></div>\n </div>\n </div>\n</div> ","import { Injectable } from '@angular/core';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class UtilsService {\n\n public formatAmount(amount: number, currency = 'EUR'): string {\n if (!amount) return 'N/A';\n\n const formatter = new Intl.NumberFormat(currency.toLocaleUpperCase() === 'EUR' ? 'es-ES' : 'en-US', {\n style: 'currency',\n currency: currency || 'USD',\n });\n \n return formatter.format(amount / 100);\n }\n \n public formatDate(timestamp: number | string): string {\n if (!timestamp) return 'N/A';\n \n const date = typeof timestamp === 'number'\n ? new Date(timestamp * 1000)\n : new Date(timestamp);\n \n return date.toLocaleDateString('es-ES', {\n year: 'numeric',\n month: 'short',\n day: 'numeric'\n });\n }\n \n public getStatusBadgeClass(status: string): string {\n switch (status) {\n case 'active':\n case 'succeeded':\n case 'paid':\n return 'badge-success';\n case 'failed':\n case 'canceled':\n case 'unpaid':\n return 'badge-error';\n case 'pending':\n case 'processing':\n case 'trialing':\n return 'badge-warning';\n default:\n return 'badge-ghost';\n }\n }\n}\n","import { CommonModule } from '@angular/common';\nimport { Component, computed, inject, input, output } from '@angular/core';\nimport { DomSanitizer } from '@angular/platform-browser';\nimport { UtilsService } from '../../../services/utils.service';\nimport { StripePricePublic, StripeProductPublic } from '../../../store/products.store';\nimport { Currency } from '../../../models/currency.model';\n\n@Component({\n selector: 'lib-product-item',\n standalone: true,\n imports: [CommonModule],\n templateUrl: './product-item.component.html'\n})\nexport class ProductItemComponent {\n public readonly product = input.required<StripeProductPublic>();\n public readonly currency = input<Currency>(Currency.EUR);\n\n public readonly productSelected = output<StripeProductPublic>();\n public readonly priceSelected = output<StripePricePublic>();\n\n public readonly utils = inject(UtilsService);\n private readonly sanitizer = inject(DomSanitizer);\n\n public price = computed(() => this.product().prices.find(price => price.details.currency === this.currency()));\n\n public sanitizedImage = computed(() => {\n const imageUrl = this.product().images?.[0];\n return imageUrl ? this.sanitizer.bypassSecurityTrustUrl(imageUrl) : null;\n });\n\n onSelect() {\n this.productSelected.emit(this.product());\n this.priceSelected.emit(this.price()?.details as StripePricePublic);\n }\n} ","<div class=\"card bg-base-100 shadow-xl max-w-sm mx-auto rounded-3xl w-[350px]\">\n <!-- Header with image and favorite icon -->\n <div class=\"relative\">\n @if (sanitizedImage()) {\n <figure class=\"bg-gradient-to-br from-base-200 to-base-300\">\n <img \n [src]=\"sanitizedImage()\" \n alt=\"{{ product().name }}\" \n class=\"h-64 w-full object-cover p-8 rounded-t-3xl\" />\n </figure>\n } @else {\n <div class=\"h-64 bg-gradient-to-br from-base-200 to-base-300 flex items-center justify-center\">\n <div class=\"text-base-content/50 text-6xl\">📦</div>\n </div>\n }\n </div>\n\n <div class=\"card-body p-6 flex flex-col h-full\">\n <!-- Product title -->\n <h2 class=\"card-title text-xl font-bold text-base-content\">\n {{ product().name }}\n </h2>\n\n <!-- Description (moved under title) -->\n @if (product().description) {\n <p class=\"text-base-content/70 text-sm mb-4 line-clamp-3\">\n {{ product().description }}\n </p>\n }\n\n <!-- Price options as text -->\n <div class=\"flex justify-between gap-2\">\n <span class=\"text-xl font-bold text-base-content\">\n @if (price()?.details?.type === 'recurring') {\n {{ utils.formatAmount(price()?.details?.unit_amount ?? 0, price()?.details?.currency ?? 'EUR') }}/{{ price()?.recurringInterval === 'month' ? 'mo' : 'yr' }}\n } @else {\n {{ utils.formatAmount(price()?.details?.unit_amount ?? 0, price()?.details?.currency ?? 'EUR') }}\n }\n </span>\n\n <!-- Status badge (only show if inactive) -->\n @if (!product().active) {\n <div class=\"mt-4\">\n <div class=\"badge badge-warning badge-sm\">Inactive</div>\n </div>\n } @else {\n <button \n class=\"btn btn-primary\"\n (click)=\"onSelect()\">\n Buy now\n </button>\n }\n </div>\n </div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, inject, input, output } from '@angular/core';\nimport { ProductsStore, StripePricePublic, StripeProductPublic } from '../../store/products.store';\nimport { ProductItemSkeletonComponent } from './product-item-skeleton/product-item-skeleton.component';\nimport { ProductItemComponent } from './product-item/product-item.component';\nimport { Currency } from '../../models/currency.model';\n\n@Component({\n selector: 'stripe-product-list',\n standalone: true,\n imports: [CommonModule, ProductItemComponent, ProductItemSkeletonComponent],\n templateUrl: './product-list.component.html'\n})\nexport class ProductListComponent {\n public readonly productsStore = inject(ProductsStore);\n\n public readonly products = input<StripeProductPublic[]>([]);\n public readonly currency = input<Currency>(Currency.EUR);\n\n public readonly productSelected = output<StripeProductPublic>();\n public readonly priceSelected = output<StripePricePublic>();\n\n onProductSelect(product: StripeProductPublic) {\n this.productSelected.emit(product);\n }\n\n onPriceSelect(price: StripePricePublic) {\n this.priceSelected.emit(price);\n }\n} ","@if (productsStore.isStatusLoading()) {\n <div class=\"flex justify-start gap-8\">\n @for (item of [1,2,3]; track item) {\n <lib-product-item-skeleton></lib-product-item-skeleton>\n }\n </div>\n}\n\n@if (productsStore.isStatusError() && !productsStore.isStatusLoading()) {\n <div class=\"alert alert-error\">\n <span>{{ productsStore.error() }}</span>\n </div>\n}\n\n@if (!productsStore.hasProducts() && !productsStore.isStatusLoading()) {\n <div class=\"alert alert-info\">\n <span>No products available</span>\n </div>\n}\n\n@if (productsStore.hasProducts()) {\n <div class=\"flex justify-start gap-8\">\n @for (product of products(); track product.id) {\n <lib-product-item\n [product]=\"product\"\n [currency]=\"currency()\"\n (productSelected)=\"onProductSelect($event)\"\n (priceSelected)=\"onPriceSelect($event)\">\n </lib-product-item>\n }\n </div>\n} \n\n\n","import { CommonModule } from '@angular/common';\nimport { Component, computed, inject, input, OnInit } from '@angular/core';\nimport { CustomerStore } from '../../store/customer.store';\nimport { SubscriptionsStore } from '../../store/subscriptions.store';\nimport { EmbeddedSkeletonComponent } from '../embedded-skeleton/embedded-skeleton.component';\n\n@Component({\n selector: 'lib-embedded-subscription',\n templateUrl: './embedded-subscription.component.html',\n standalone: true,\n imports: [CommonModule, EmbeddedSkeletonComponent]\n})\nexport class EmbeddedSubscriptionComponent implements OnInit {\n public readonly subscriptionsStore = inject(SubscriptionsStore);\n public readonly customerStore = inject(CustomerStore);\n\n public readonly priceId = input.required<string>();\n public readonly returnPagePath = input<string>('/subscription-return');\n \n public readonly customer = computed(() => this.customerStore.customer().data);\n\n async ngOnInit() {\n this.createSubscription();\n }\n\n private createSubscription() {\n const baseUrl = window.location.origin;\n const returnPath = `${baseUrl}${this.returnPagePath()}`;\n this.subscriptionsStore.createSubscription(this.priceId(), returnPath, this.customer());\n }\n\n ngOnDestroy() {\n this.subscriptionsStore.destroyEmbeddedSubscription();\n }\n} ","<div class=\"subscription-container\">\n <div class=\"info-panel p-4 bg-primary-100 rounded-lg mb-4\">\n <div class=\"flex items-center\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-6 w-6 text-primary mr-2\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n <p class=\"text-primary-700\">Plan de suscripción: <span class=\"font-semibold\">{{ priceId() }}</span></p>\n </div>\n </div>\n \n @if (subscriptionsStore.isStatusLoading()) {\n <lib-embedded-skeleton />\n }\n \n @if (subscriptionsStore.isStatusError()) {\n <div class=\"error\">\n <p>Error: {{ subscriptionsStore.error() }}</p>\n </div>\n }\n \n <div id=\"embedded-checkout\" class=\"mt-4\"></div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, OnInit, computed, inject, input } from '@angular/core';\nimport { ActivatedRoute, Router } from '@angular/router';\nimport { CheckoutStore } from '../../../store/checkout.store';\nimport { SubscriptionsStore } from '../../../store/subscriptions.store';\n\n@Component({\n selector: 'lib-subscription-return-page',\n templateUrl: './subscription-return-page.component.html',\n standalone: true,\n imports: [CommonModule],\n})\nexport class SubscriptionReturnPageComponent implements OnInit {\n private readonly route = inject(ActivatedRoute);\n private readonly router = inject(Router);\n\n public readonly checkoutStore = inject(CheckoutStore);\n public readonly subscriptionsStore = inject(SubscriptionsStore);\n\n public readonly sessionStatus = computed(() => this.checkoutStore.sessionStatus());\n \n public readonly returnUrl = input<string>('/');\n \n async ngOnInit() {\n this.route.queryParams.subscribe(async params => {\n const sessionId = params['session_id'];\n this.getSessionStatus(sessionId);\n });\n }\n\n private async getSessionStatus(sessionId: string) {\n if (sessionId) {\n await this.checkoutStore.getSessionStatus({ sessionId });\n } else {\n console.error('Missing session_id parameter in URL');\n }\n }\n \n public navigate(): void {\n this.router.navigateByUrl(this.returnUrl());\n }\n} ","<div class=\"flex justify-center min-h-screen bg-gradient-to-br from-blue-50 to-indigo-100 p-4\">\n <div class=\"hero-content text-center max-w-md\">\n <div class=\"card w-full bg-base-100 shadow-2xl\">\n <div class=\"card-body items-center text-center\">\n <!-- Success Icon -->\n <div class=\"mb-6\">\n <div class=\"avatar\">\n <div class=\"w-24 h-24 rounded-full bg-success/10 flex items-center justify-center\">\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n class=\"h-full w-full text-success\"\n fill=\"none\"\n viewBox=\"0 0 24 24\"\n stroke=\"currentColor\"\n >\n <path\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n stroke-width=\"2\"\n d=\"M9 12l2 2 4-4m6 2a9 9 0 11-18 0 9 9 0 0118 0z\"\n />\n </svg>\n </div>\n </div>\n </div>\n\n <!-- Status Content -->\n @if (checkoutStore.isStatusLoading()) {\n <div class=\"flex flex-col items-center gap-4 mb-6\">\n <span class=\"loading loading-spinner loading-lg text-primary\"></span>\n <div class=\"alert alert-info\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" fill=\"none\" viewBox=\"0 0 24 24\" class=\"stroke-current shrink-0 w-6 h-6\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z\"></path>\n </svg>\n <span>Cargando detalles de la suscripción...</span>\n </div>\n </div>\n } @else if (checkoutStore.isStatusError()) {\n <div class=\"alert alert-error mb-6\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"stroke-current shrink-0 h-6 w-6\" fill=\"none\" viewBox=\"0 0 24 24\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M10 14l2-2m0 0l2-2m-2 2l-2-2m2 2l2 2m7-2a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n <span>{{ subscriptionsStore.error() }}</span>\n </div>\n } @else if (checkoutStore.isPaymentComplete()) {\n\n <!-- Title and Description -->\n <h2 class=\"card-title text-3xl font-bold text-base-content mb-2\">{{ sessionStatus()?.amount_total }}</h2>\n\n <div class=\"alert alert-success mb-6\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"stroke-current shrink-0 h-6 w-6\" fill=\"none\" viewBox=\"0 0 24 24\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M9 12l2 2 4-4m6 2a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n <span class=\"font-medium\">Tu suscripción está activa y lista para usar.</span>\n </div>\n\n <div class=\"bg-base-200 rounded-lg p-4 mb-6 w-full\">\n <h3 class=\"font-semibold text-sm text-base-content/80 mb-3\">Beneficios incluidos:</h3>\n <ul class=\"space-y-2\">\n <li class=\"flex items-center text-sm\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 text-success mr-2\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M5 13l4 4L19 7\" />\n </svg>\n Acceso completo a todas las funciones\n </li>\n <li class=\"flex items-center text-sm\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 text-success mr-2\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M5 13l4 4L19 7\" />\n </svg>\n Soporte prioritario 24/7\n </li>\n <li class=\"flex items-center text-sm\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 text-success mr-2\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M5 13l4 4L19 7\" />\n </svg>\n Actualizaciones automáticas\n </li>\n </ul>\n </div>\n }\n\n <!-- Action Buttons -->\n <div class=\"card-actions justify-center w-full\">\n <button class=\"btn btn-primary btn-wide\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-5 w-5 mr-2\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n stroke-width=\"2\"\n d=\"M3 12l2-2m0 0l7-7 7 7M5 10v10a1 1 0 001 1h3m10-11l2 2m-2-2v10a1 1 0 01-1 1h-3m-6 0a1 1 0 001-1v-4a1 1 0 011-1h2a1 1 0 011 1v4a1 1 0 001 1m-6 0h6\"\n />\n </svg>\n Ir al Panel Principal\n </button>\n </div>\n\n <!-- Additional Help -->\n <div class=\"text-center mt-4\">\n <p class=\"text-xs text-base-content/50\">\n ¿Necesitas ayuda?\n <a href=\"#\" class=\"link link-primary\">Contacta soporte</a>\n </p>\n </div>\n </div>\n </div>\n </div>\n</div>","import { Directive, ElementRef, input, effect } from '@angular/core';\nimport type { Stripe as StripeTypes } from 'stripe';\n\n@Directive({\n selector: '[ngxBrandIcon]',\n standalone: true\n})\nexport class BrandIconDirective {\n public readonly paymentMethod = input.required<StripeTypes.PaymentMethod>({ alias: 'ngxBrandIcon' });\n\n constructor(private readonly el: ElementRef<HTMLElement>) {\n\n effect(() => {\n const icon = this.getBrandIcon();\n this.el.nativeElement.textContent = icon;\n });\n }\n\n private getBrandIcon(): string {\n const brand = this.paymentMethod().card?.brand;\n const brandIcons: Record<string, string> = {\n 'visa': '💳',\n 'mastercard': '💳', \n 'amex': '💳',\n 'discover': '💳',\n 'diners': '💳',\n 'jcb': '💳',\n 'unionpay': '💳',\n 'unknown': '💳'\n };\n return brandIcons[brand || 'unknown'] || '💳';\n }\n}\n","import { Directive, ElementRef, input, effect } from '@angular/core';\nimport type { Stripe as StripeTypes } from 'stripe';\n\n@Directive({\n selector: '[ngxBrandName]',\n standalone: true\n})\nexport class BrandNameDirective {\n public readonly paymentMethod = input.required<StripeTypes.PaymentMethod>({ alias: 'ngxBrandName' });\n\n constructor(private readonly el: ElementRef<HTMLElement>) {\n\n effect(() => {\n const name = this.getBrandName();\n this.el.nativeElement.textContent = name;\n });\n }\n\n private getBrandName(): string {\n const brand = this.paymentMethod().card?.brand;\n const brandNames: Record<string, string> = {\n 'visa': 'Visa',\n 'mastercard': 'Mastercard',\n 'amex': 'American Express',\n 'discover': 'Discover',\n 'diners': 'Diners Club',\n 'jcb': 'JCB',\n 'unionpay': 'UnionPay',\n 'unknown': 'Tarjeta'\n };\n return brandNames[brand || 'unknown'] || 'Tarjeta';\n }\n}\n","import { Directive, ElementRef, input, effect } from '@angular/core';\nimport type { Stripe as StripeTypes } from 'stripe';\n\n@Directive({\n selector: '[ngxPaymentMethodType]',\n standalone: true\n})\nexport class PaymentMethodTypeDirective {\n public readonly paymentMethod = input.required<StripeTypes.PaymentMethod>({ alias: 'ngxPaymentMethodType' });\n\n constructor(private readonly el: ElementRef<HTMLElement>) {\n\n effect(() => {\n const type = this.getPaymentMethodType();\n this.el.nativeElement.textContent = type;\n });\n }\n\n private getPaymentMethodType(): string {\n const typeNames: Record<string, string> = {\n 'card': 'Tarjeta',\n 'paypal': 'PayPal',\n 'klarna': 'Klarna',\n 'afterpay_clearpay': 'Afterpay',\n 'alipay': 'Alipay',\n 'bancontact': 'Bancontact',\n 'eps': 'EPS',\n 'giropay': 'Giropay',\n 'ideal': 'iDEAL',\n 'p24': 'Przelewy24',\n 'sepa_debit': 'SEPA Direct Debit',\n 'sofort': 'Sofort',\n 'wechat_pay': 'WeChat Pay'\n };\n return typeNames[this.paymentMethod().type] || 'Método de pago';\n }\n}\n","import { Component, input } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport type { Stripe as StripeTypes } from 'stripe';\nimport { BrandIconDirective } from '../../../directives/brand-icon.directive';\nimport { BrandNameDirective } from '../../../directives/brand-name.directive';\nimport { PaymentMethodTypeDirective } from '../../../directives/payment-method-type.directive';\n\nexport type PaymentMethodDisplayMode = 'detailed' | 'compact';\n\n@Component({\n selector: 'ngx-payment-method',\n standalone: true,\n imports: [CommonModule, BrandIconDirective, BrandNameDirective, PaymentMethodTypeDirective],\n templateUrl: './payment-method.component.html'\n})\nexport class PaymentMethodComponent {\n public readonly paymentMethod = input.required<StripeTypes.PaymentMethod>();\n public readonly mode = input<PaymentMethodDisplayMode>('detailed');\n\n public get last4(): string {\n return this.paymentMethod().card?.last4 || '****';\n }\n\n public get expirationDate(): string {\n const card = this.paymentMethod().card;\n if (!card?.exp_month || !card?.exp_year) return '';\n return `${card.exp_month.toString().padStart(2, '0')}/${card.exp_year.toString().slice(-2)}`;\n }\n\n public get holderName(): string {\n return this.paymentMethod().billing_details?.name || 'N/A';\n }\n\n public get isExpired(): boolean {\n const card = this.paymentMethod().card;\n if (!card?.exp_month || !card?.exp_year) return false;\n \n const now = new Date();\n const expDate = new Date(card.exp_year, card.exp_month - 1);\n return expDate < now;\n }\n\n public get cardFunding(): string | undefined {\n return this.paymentMethod().card?.funding;\n }\n\n public get cardCountry(): string | undefined {\n return this.paymentMethod().card?.country || undefined;\n }\n\n public get billingEmail(): string | undefined {\n return this.paymentMethod().billing_details?.email || undefined;\n }\n\n public get billingPhone(): string | undefined {\n return this.paymentMethod().billing_details?.phone || undefined;\n }\n\n public get billingAddress() {\n return this.paymentMethod().billing_details?.address;\n }\n}\n","<!-- Detailed Version -->\n@if (mode() === 'detailed') {\n <div class=\"w-full max-w-md mx-auto\">\n <!-- Stack of Credit Cards -->\n <div class=\"stack w-full h-56\">\n <div class=\"bg-gradient-to-br from-primary to-accent text-neutral-content relative place-content-center rounded-box\">\n <div class=\"card-body p-6 relative z-10\">\n <!-- Card Header -->\n <div class=\"flex justify-between items-start mb-6\">\n <div class=\"flex items-center gap-2\">\n <!--<span class=\"text-3xl filter drop-shadow-lg\" [ngxBrandIcon]=\"paymentMethod()\"></span>-->\n <div class=\"font-bold text-lg text-primary-content\" [ngxBrandName]=\"paymentMethod()\"></div>\n @if (cardCountry) {\n <div class=\"text-xs text-primary-content/60 uppercase\">{{ cardCountry }}</div>\n }\n @if (isExpired) {\n <div class=\"badge badge-error badge-sm animate-pulse\">Expirada</div>\n }\n </div>\n </div>\n\n <!-- Card Number -->\n <div class=\"mb-6\">\n <div class=\"font-mono text-xl tracking-wider text-primary-content\">\n **** **** **** {{ last4 }}\n </div>\n </div>\n\n <!-- Card Bottom Info -->\n <div class=\"flex justify-start items-end\">\n <div class=\"flex-1\">\n <div class=\"text-xs text-primary-content/60 mb-1\">TITULAR</div>\n <div class=\"font-medium text-sm text-primary-content truncate max-w-32\">{{ holderName }}</div>\n </div>\n \n @if (expirationDate) {\n <div class=\"flex-1\">\n <div class=\"text-xs text-primary-content/60 mb-1\">VÁLIDA HASTA</div>\n <div class=\"font-mono text-sm text-primary-content\">{{ expirationDate }}</div>\n </div>\n }\n </div>\n </div>\n\n <!-- Card Background Pattern -->\n <div class=\"absolute inset-0 opacity-20\">\n <div class=\"absolute top-4 right-4 w-20 h-20 rounded-full bg-primary-content/30\"></div>\n <div class=\"absolute bottom-4 left-4 w-16 h-16 rounded-full bg-primary-content/20\"></div>\n <div class=\"absolute top-1/2 left-1/2 transform -translate-x-1/2 -translate-y-1/2 w-32 h-32 rounded-full bg-primary-content/10\"></div>\n </div>\n </div>\n <div class=\"bg-secondary grid place-content-center rounded-box\"></div>\n <div class=\"bg-accent grid place-content-center rounded-box\"></div>\n </div>\n\n <!-- Additional Information Below Cards -->\n <div class=\"mt-6 space-y-4\">\n <!-- Billing Information -->\n @if (billingEmail || billingPhone) {\n <div class=\"card bg-base-100 shadow-sm border border-base-200\">\n <div class=\"card-body p-4\">\n <h4 class=\"card-title text-sm mb-3 flex items-center gap-2\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M16 7a4 4 0 11-8 0 4 4 0 018 0zM12 14a7 7 0 00-7 7h14a7 7 0 00-7-7z\" />\n </svg>\n Información de Contacto\n </h4>\n \n <div class=\"space-y-2\">\n @if (billingEmail) {\n <div class=\"flex items-center gap-2 text-sm\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 text-base-content/60\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M16 12a4 4 0 10-8 0 4 4 0 008 0zm0 0v1.5a2.5 2.5 0 005 0V12a9 9 0 10-9 9m4.5-1.206a8.959 8.959 0 01-4.5 1.207\" />\n </svg>\n <span class=\"text-base-content/70\">{{ billingEmail }}</span>\n </div>\n }\n \n @if (billingPhone) {\n <div class=\"flex items-center gap-2 text-sm\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 text-base-content/60\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M3 5a2 2 0 012-2h3.28a1 1 0 01.948.684l1.498 4.493a1 1 0 01-.502 1.21l-2.257 1.13a11.042 11.042 0 005.516 5.516l1.13-2.257a1 1 0 011.21-.502l4.493 1.498a1 1 0 01.684.949V19a2 2 0 01-2 2h-1C9.716 21 3 14.284 3 6V5z\" />\n </svg>\n <span class=\"text-base-content/70\">{{ billingPhone }}</span>\n </div>\n }\n </div>\n </div>\n </div>\n }\n\n <!-- Billing Address -->\n @if (billingAddress && (billingAddress.line1 || billingAddress.city)) {\n <div class=\"card bg-base-100 shadow-sm border border-base-200\">\n <div class=\"card-body p-4\">\n <h4 class=\"card-title text-sm mb-3 flex items-center gap-2\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M17.657 16.657L13.414 20.9a1.998 1.998 0 01-2.827 0l-4.244-4.243a8 8 0 1111.314 0z\" />\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M15 11a3 3 0 11-6 0 3 3 0 016 0z\" />\n </svg>\n Dirección de Facturación\n </h4>\n \n <div class=\"text-sm text-base-content/70 space-y-1\">\n @if (billingAddress.line1) {\n <div>{{ billingAddress.line1 }}</div>\n @if (billingAddress.line2) {\n <div>{{ billingAddress.line2 }}</div>\n }\n }\n \n <div class=\"flex gap-2 flex-wrap\">\n @if (billingAddress.city) {\n <span>{{ billingAddress.city }}</span>\n }\n @if (billingAddress.postal_code) {\n <span>{{ billingAddress.postal_code }}</span>\n }\n @if (billingAddress.country) {\n <span class=\"uppercase\">{{ billingAddress.country }}</span>\n }\n </div>\n </div>\n </div>\n </div>\n }\n\n <!-- Card Creation Date -->\n <div class=\"flex items-center justify-between text-sm text-base-content/60 px-2\">\n <span>Método agregado:</span>\n <span>{{ paymentMethod().created * 1000 | date:'short' }}</span>\n </div>\n </div>\n </div>\n}\n\n<!-- Compact Version -->\n@if (mode() === 'compact') {\n <div class=\"flex items-center gap-2\">\n <!--<span class=\"text-xl filter drop-shadow-sm\" [ngxBrandIcon]=\"paymentMethod()\"></span>-->\n \n <div class=\"flex-1 min-w-0\">\n <div class=\"flex items-center gap-2\">\n <span class=\"font-medium\" [ngxBrandName]=\"paymentMethod()\"></span>\n <span class=\"text-base-content/70\">•••• {{ last4 }}</span>\n @if (paymentMethod().type === 'card' && expirationDate) {\n <span class=\"text-base-content/70 text-sm\">{{ expirationDate }}</span>\n }\n </div>\n </div>\n\n @if (isExpired) {\n <div class=\"badge badge-error badge-sm animate-pulse\">Expirada</div>\n } @else {\n <div class=\"badge badge-success badge-sm\">Activa</div>\n }\n </div>\n}\n","import { Component, input } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { StripePaymentIntentsPublic } from '../../../../store/customer.store';\nimport { UtilsService } from '../../../../services/utils.service';\nimport { PaymentMethodComponent } from '../../payment-method/payment-method.component';\n\n@Component({\n selector: 'lib-payment-intents-dialog',\n standalone: true,\n imports: [CommonModule, PaymentMethodComponent],\n templateUrl: './payment-intents-dialog.component.html'\n})\nexport class PaymentIntentsDialogComponent {\n public readonly paymentIntent = input.required<StripePaymentIntentsPublic>();\n public readonly dialogId = input.required<string>();\n \n public readonly utils = new UtilsService();\n}\n","<dialog [id]=\"dialogId()\" class=\"modal\">\n <div class=\"modal-box max-w-2xl\">\n <h3 class=\"font-bold text-lg mb-4\">Detalles del Payment Intent</h3>\n \n <!-- Header with Amount and Status -->\n <div class=\"flex items-center gap-3 mb-6 p-4 bg-base-200 rounded-lg\">\n <div class=\"flex-1\">\n <div class=\"text-3xl font-bold text-primary\">\n {{ utils.formatAmount(paymentIntent().amount ?? 0, paymentIntent().currency ?? 'EUR') }}\n </div>\n <div class=\"text-sm text-base-content/70\">\n {{ (paymentIntent().currency ?? 'EUR').toUpperCase() }}\n </div>\n </div>\n <div class=\"flex gap-2\">\n <div class=\"badge {{ utils.getStatusBadgeClass(paymentIntent().status) }}\">\n {{ paymentIntent().status }}\n </div>\n @if (!paymentIntent().liveMode) {\n <div class=\"badge badge-warning\">TEST</div>\n }\n </div>\n </div>\n\n <div class=\"space-y-6\">\n <!-- Transaction Details -->\n <div>\n <h4 class=\"text-sm font-semibold text-base-content/80 mb-3 flex items-center gap-2\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n Detalles de la Transacción\n </h4>\n \n <div class=\"grid grid-cols-1 sm:grid-cols-2 gap-3\">\n <div class=\"stat bg-base-200 rounded-lg p-3\">\n <div class=\"stat-title text-xs\">Estado</div>\n <div class=\"stat-value text-sm capitalize\">{{ paymentIntent().status }}</div>\n <div class=\"stat-desc\">{{ paymentIntent().liveMode ? 'Producción' : 'Pruebas' }}</div>\n </div>\n \n <div class=\"stat bg-base-200 rounded-lg p-3\">\n <div class=\"stat-title text-xs\">Monto</div>\n <div class=\"stat-value text-sm\">{{ utils.formatAmount(paymentIntent().amount ?? 0, paymentIntent().currency ?? 'EUR') }}</div>\n <div class=\"stat-desc\">{{ (paymentIntent().currency ?? 'EUR').toUpperCase() }}</div>\n </div>\n </div>\n\n <!-- Confirmation Method -->\n <div class=\"mt-3 flex items-center gap-2 text-sm p-2 bg-base-200 rounded\">\n <div class=\"w-2 h-2 bg-success rounded-full\"></div>\n <span class=\"text-base-content/70\">Confirmación:</span>\n <span class=\"capitalize font-medium\">{{ paymentIntent().confirmationMethod.replace('_', ' ') }}</span>\n </div>\n </div>\n\n <!-- Payment Information -->\n @if (paymentIntent().paymentMethod) {\n <div>\n <h4 class=\"text-sm font-semibold text-base-content/80 mb-3 flex items-center gap-2\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M3 10h18M7 15h1m4 0h1m-7 4h12a3 3 0 003-3V8a3 3 0 00-3-3H6a3 3 0 00-3 3v8a3 3 0 003 3z\" />\n </svg>\n Información del Pago\n </h4>\n \n <ngx-payment-method \n [paymentMethod]=\"paymentIntent().paymentMethod!\" \n mode=\"detailed\">\n </ngx-payment-method>\n </div>\n }\n\n <!-- Additional Information -->\n <div>\n <h4 class=\"text-sm font-semibold text-base-content/80 mb-3 flex items-center gap-2\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z\" />\n </svg>\n Información Adicional\n </h4>\n \n <div class=\"space-y-2\">\n @if (paymentIntent().invoiceId) {\n <div class=\"flex items-center justify-between p-2 bg-base-200 rounded\">\n <span class=\"text-sm text-base-content/70\">Factura</span>\n <span class=\"text-sm font-mono\">{{ paymentIntent().invoiceId.slice(-8) }}</span>\n </div>\n }\n \n <div class=\"flex items-center justify-between p-2 bg-base-200 rounded\">\n <span class=\"text-sm text-base-content/70\">Entorno</span>\n <span class=\"text-sm\">\n @if (paymentIntent().liveMode) {\n <span class=\"text-success\">Producción</span>\n } @else {\n <span class=\"text-warning\">Pruebas</span>\n }\n </span>\n </div>\n \n <div class=\"flex items-center justify-between p-2 bg-base-200 rounded\">\n <span class=\"text-sm text-base-content/70\">Referencia</span>\n <span class=\"text-sm font-mono\">•••{{ paymentIntent().id?.slice(-6) || 'N/A' }}</span>\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"modal-action\">\n <form method=\"dialog\">\n <button class=\"btn btn-primary\">Cerrar</button>\n </form>\n </div>\n </div>\n</dialog>\n","import { CommonModule } from '@angular/common';\nimport { Component, computed, inject, input, output } from '@angular/core';\nimport { UtilsService } from '../../../../services/utils.service';\nimport { StripePaymentIntentsPublic } from '../../../../store/customer.store';\nimport { PaymentMethodComponent } from '../../payment-method/payment-method.component';\nimport { PaymentIntentsDialogComponent } from '../payment-intents-dialog/payment-intents-dialog.component';\n\n@Component({\n selector: 'lib-payment-intents-table',\n templateUrl: './payment-intents-table.component.html',\n standalone: true,\n imports: [\n CommonModule,\n PaymentMethodComponent,\n PaymentIntentsDialogComponent\n ]\n})\nexport class PaymentIntentsTableComponent {\n public readonly paymentIntents = input.required<StripePaymentIntentsPublic[]>();\n\n public paymentIntentsTable = computed(() => {\n return this.paymentIntents().map(paymentIntent => ({\n ...paymentIntent,\n selected: false\n }));\n });\n\n public readonly loading = input<boolean>(false);\n public readonly error = input<string | null>(null);\n public readonly withControls = input<boolean>(true);\n \n public readonly exportSelected = output<StripePaymentIntentsPublic[]>();\n public readonly onRefresh = output<void>();\n \n public readonly utils = inject(UtilsService);\n \n public readonly hasPaymentIntents = computed(() => \n this.paymentIntents() && this.paymentIntents().length > 0\n );\n \n protected readonly trackByPaymentIntentId = (index: number, item: StripePaymentIntentsPublic) => item.id;\n \n public refreshPaymentIntents(): void {\n this.onRefresh.emit();\n }\n\n public allPaymentIntentsSelected(): boolean {\n return this.paymentIntentsTable().every(paymentIntent => paymentIntent.selected);\n }\n\n public somePaymentIntentsSelected(): boolean {\n return this.paymentIntentsTable().some(paymentIntent => paymentIntent.selected);\n }\n\n public toggleAllPaymentIntents(event: Event): void {\n const checkbox = event.target as HTMLInputElement;\n const isChecked = checkbox.checked;\n this.paymentIntentsTable().forEach(paymentIntent => {\n paymentIntent.selected = isChecked;\n });\n }\n\n public togglePaymentIntent(event: Event, id: string): void {\n const checkbox = event.target as HTMLInputElement;\n const isChecked = checkbox.checked;\n const paymentIntent = this.paymentIntentsTable().find(paymentIntent => paymentIntent.id === id);\n if (paymentIntent) {\n paymentIntent.selected = isChecked;\n }\n }\n\n public showDetails(id: string): void {\n const modalElement = document.getElementById(`modal-${id}`) as HTMLDialogElement;\n if (modalElement) {\n modalElement.showModal();\n }\n } \n\n public exportSelectedPaymentIntents(): void {\n this.exportSelected.emit(this.paymentIntentsTable().filter(paymentIntent => paymentIntent.selected));\n }\n} ","<div class=\"payment-intents-container\">\n @if (withControls()) {\n <div class=\"controls mb-4 flex justify-between items-center\">\n <div class=\"stats\">\n @if (hasPaymentIntents()) {\n <span class=\"badge badge-soft badge-info\">{{ paymentIntentsTable().length }} payment intents</span>\n }\n </div>\n <div class=\"flex justify-end items-center gap-2\">\n <button class=\"btn btn-sm btn-outline\" (click)=\"refreshPaymentIntents()\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 mr-1\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M4 4v5h.582m15.356 2A8.001 8.001 0 004.582 9m0 0H9m11 11v-5h-.581m0 0a8.003 8.003 0 01-15.357-2m15.357 2H15\" />\n </svg>\n Actualizar\n </button>\n <button class=\"btn btn-sm btn-primary\" [disabled]=\"!somePaymentIntentsSelected()\" (click)=\"exportSelectedPaymentIntents()\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"1em\" height=\"1em\" viewBox=\"0 0 24 24\"><path fill=\"currentColor\" d=\"M8.71 7.71L11 5.41V15a1 1 0 0 0 2 0V5.41l2.29 2.3a1 1 0 0 0 1.42 0a1 1 0 0 0 0-1.42l-4-4a1 1 0 0 0-.33-.21a1 1 0 0 0-.76 0a1 1 0 0 0-.33.21l-4 4a1 1 0 1 0 1.42 1.42M21 14a1 1 0 0 0-1 1v4a1 1 0 0 1-1 1H5a1 1 0 0 1-1-1v-4a1 1 0 0 0-2 0v4a3 3 0 0 0 3 3h14a3 3 0 0 0 3-3v-4a1 1 0 0 0-1-1\"/></svg>\n Export Selected\n </button>\n </div>\n </div>\n }\n\n @if (loading()) {\n <div class=\"overflow-x-auto\">\n <div class=\"skeleton h-32 w-full\"></div>\n </div>\n } @else if (error()) {\n <div class=\"error-container\">\n <div class=\"alert alert-error\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"stroke-current shrink-0 h-6 w-6\" fill=\"none\" viewBox=\"0 0 24 24\"><path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M10 14l2-2m0 0l2-2m-2 2l-2-2m2 2l2 2m7-2a9 9 0 11-18 0 9 9 0 0118 0z\" /></svg>\n <span>{{ error() }}</span>\n </div>\n </div>\n } @else if (hasPaymentIntents()) {\n <div class=\"overflow-x-auto rounded-box bg-base-100\">\n <table class=\"table table-zebra\">\n <!-- head -->\n <thead>\n <tr>\n <th>\n <label>\n <input type=\"checkbox\" class=\"checkbox\" (change)=\"toggleAllPaymentIntents($event)\" [checked]=\"allPaymentIntentsSelected()\" />\n </label>\n </th>\n <th>Amount</th>\n <th>Payment Method</th>\n <th>Status</th>\n <th>Mode</th>\n <th></th>\n </tr>\n </thead>\n <tbody>\n @for (paymentIntent of paymentIntentsTable(); track trackByPaymentIntentId(0, paymentIntent)) {\n <tr>\n <th>\n <label>\n <input type=\"checkbox\" class=\"checkbox\" (change)=\"togglePaymentIntent($event, paymentIntent.id ?? '')\" [checked]=\"paymentIntent.selected\" />\n </label>\n </th>\n <td>{{ utils.formatAmount(paymentIntent.amount ?? 0, paymentIntent.currency ?? 'EUR') }}</td>\n <td>\n @if (paymentIntent.paymentMethod) {\n <ngx-payment-method \n [paymentMethod]=\"paymentIntent.paymentMethod!\" \n mode=\"compact\">\n </ngx-payment-method>\n } @else {\n <span class=\"badge badge-outline\">\n {{ paymentIntent.paymentMethodId }}\n </span>\n }\n </td>\n <td>\n <span class=\"badge badge-soft {{ utils.getStatusBadgeClass(paymentIntent.status) }}\">\n {{ paymentIntent.status}}\n </span>\n </td>\n <td>{{ paymentIntent.liveMode ? 'Live' : 'Test' }}</td>\n <td>\n <button class=\"btn btn-xs btn-ghost\" (click)=\"showDetails(paymentIntent.id ?? '')\">\n Details\n </button>\n <lib-payment-intents-dialog \n [paymentIntent]=\"paymentIntent\" \n [dialogId]=\"'modal-' + paymentIntent.id\">\n </lib-payment-intents-dialog>\n </td>\n </tr>\n }\n </tbody>\n </table>\n </div>\n } @else {\n <div class=\"empty-state\">\n <div class=\"card bg-base-100 shadow-sm\">\n <div class=\"card-body items-center text-center\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-12 w-12 text-gray-400 mb-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M3 10h18M7 15h1m4 0h1m-7 4h12a3 3 0 003-3V8a3 3 0 00-3-3H6a3 3 0 00-3 3v8a3 3 0 003 3z\" />\n </svg>\n <h2 class=\"card-title text-xl\">No recent payment intents</h2>\n <p class=\"text-gray-600\">No payment intents found in your history.</p>\n </div>\n </div>\n </div>\n }\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component } from '@angular/core';\n\n@Component({\n selector: 'lib-subscription-item-skeleton',\n standalone: true,\n imports: [CommonModule],\n templateUrl: './subscription-item-skeleton.component.html',\n})\nexport class SubscriptionItemSkeletonComponent {}","<div class=\"card bg-base-100 shadow-sm\">\n <div class=\"card-body p-4\">\n <div class=\"flex justify-between\">\n <div>\n <div class=\"flex items-center gap-2\">\n <div class=\"skeleton h-6 w-32\"></div>\n <div class=\"skeleton h-5 w-20\"></div>\n </div>\n <div class=\"skeleton h-4 w-48 mt-2\"></div>\n </div>\n \n <div class=\"flex gap-2\">\n <div class=\"skeleton h-8 w-20\"></div>\n </div>\n </div>\n\n <div class=\"mt-2\">\n <div class=\"flex justify-between text-sm\">\n <div class=\"skeleton h-4 w-32\"></div>\n <div class=\"skeleton h-4 w-32\"></div>\n </div>\n </div>\n\n <!--<div class=\"mt-4 border-t pt-4\">\n <div class=\"grid grid-cols-1 md:grid-cols-2 gap-4\">\n <div>\n <div class=\"skeleton h-5 w-24 mb-2\"></div>\n <div class=\"space-y-1\">\n <div class=\"skeleton h-4 w-full\"></div>\n <div class=\"skeleton h-4 w-full\"></div>\n <div class=\"skeleton h-4 w-3/4\"></div>\n </div>\n </div>\n \n <div>\n <div class=\"skeleton h-5 w-24 mb-2\"></div>\n <div class=\"space-y-1\">\n <div class=\"skeleton h-4 w-full\"></div>\n <div class=\"skeleton h-4 w-3/4\"></div>\n </div>\n </div>\n </div>\n \n <div class=\"card-actions mt-4 justify-end\">\n <div class=\"skeleton h-8 w-32\"></div>\n </div>\n </div>-->\n </div>\n</div>","import { CommonModule } from '@angular/common';\nimport { Component, computed, inject, input, output } from '@angular/core';\nimport { DomSanitizer, SafeUrl } from '@angular/platform-browser';\nimport { UtilsService } from '../../../../../services/utils.service';\nimport { PortalAccountStore } from '../../../../../store/portal-account.store';\nimport { StripeSubscriptionPublic, SubscriptionsStore } from '../../../../../store/subscriptions.store';\n\n@Component({\n selector: 'lib-subscription-item',\n templateUrl: './subscription-item.component.html',\n standalone: true,\n imports: [CommonModule],\n})\nexport class SubscriptionItemComponent {\n public readonly subscriptionsStore = inject(SubscriptionsStore);\n public readonly portalAccountStore = inject(PortalAccountStore);\n public readonly utils = inject(UtilsService);\n private readonly sanitizer = inject(DomSanitizer);\n \n public readonly subscription = input.required<StripeSubscriptionPublic>();\n public readonly onManageSubscription = output<string>();\n\n public readonly isStatusLoading = computed(() => this.portalAccountStore.isStatusLoading());\n\n public readonly productImage = computed(() => {\n return this.subscription().product?.images?.[0] || 'https://img.daisyui.com/images/profile/demo/yellingcat@192.webp';\n });\n \n public isExpanded = false;\n \n public toggleExpand(): void {\n this.isExpanded = !this.isExpanded;\n }\n \n public manageSubscription(): void {\n this.onManageSubscription.emit(this.subscription().customer ?? '');\n }\n\n public sanitizeImageUrl(imageUrl: string): SafeUrl {\n return this.sanitizer.bypassSecurityTrustUrl(imageUrl);\n }\n} ","<div class=\"card bg-gradient-to-br from-primary/10 to-secondary/10 shadow-lg hover:shadow-xl transition-all duration-300 border border-base-300\">\n <div class=\"card-body p-6\">\n <!-- Header con título y precio -->\n <div class=\"flex justify-between items-start mb-4\">\n <div class=\"flex items-center gap-3\">\n <!-- Imagen de la suscripción -->\n <div class=\"avatar\">\n <div class=\"w-24 rounded\">\n <img [src]=\"sanitizeImageUrl(productImage())\" \n [alt]=\"subscription().product?.name || 'Subscription product'\"\n class=\"w-full h-full object-cover rounded-lg\" />\n </div>\n </div> \n \n <div>\n <h3 class=\"text-2xl font-bold text-base-content\">\n {{ subscription().product?.name || 'Subscription Plan' }}\n </h3>\n <div class=\"flex items-center gap-2 mt-1\">\n <span class=\"badge {{ utils.getStatusBadgeClass(subscription().status) }} badge-lg\">\n {{ subscription().status }}\n </span>\n @if (subscription().cancel.cancel_at_period_end) {\n <span class=\"badge badge-warning badge-lg\">Cancelada</span>\n }\n </div>\n </div>\n </div>\n \n <!-- Precio principal -->\n <div class=\"text-right\">\n <div class=\"text-4xl font-bold text-primary\">\n {{ utils.formatAmount(subscription().plan.amount, subscription().currency ?? 'EUR') }}\n </div>\n <div class=\"text-base-content/70 text-lg capitalize\">\n {{ subscription().plan.interval }}ly\n </div>\n </div>\n </div>\n\n <!-- Fechas de período -->\n <div class=\"flex justify-between items-center py-4 border-t border-base-300\">\n <div class=\"text-left\">\n <div class=\"text-base-content/70 text-sm font-medium\">Start:</div>\n <div class=\"text-base-content font-semibold\">\n {{ utils.formatDate(subscription().current_period_start ?? '') }}\n </div>\n </div>\n \n <div class=\"text-right\">\n <div class=\"text-base-content/70 text-sm font-medium\">End:</div>\n <div class=\"text-base-content font-semibold\">\n {{ utils.formatDate(subscription().current_period_end ?? '') }}\n </div>\n </div>\n </div>\n <div class=\"flex justify-end w-full\">\n <button class=\"btn btn-primary\" [disabled]=\"isStatusLoading()\" (click)=\"manageSubscription()\">\n @if (isStatusLoading()) {\n <span class=\"loading loading-spinner loading-sm\"></span>\n Cargando...\n } @else {\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-5 w-5\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M10.325 4.317c.426-1.756 2.924-1.756 3.35 0a1.724 1.724 0 002.573 1.066c1.543-.94 3.31.826 2.37 2.37a1.724 1.724 0 001.065 2.572c1.756.426 1.756 2.924 0 3.35a1.724 1.724 0 00-1.066 2.573c.94 1.543-.826 3.31-2.37 2.37a1.724 1.724 0 00-2.572 1.065c-.426 1.756-2.924 1.756-3.35 0a1.724 1.724 0 00-2.573-1.066c-1.543.94-3.31-.826-2.37-2.37a1.724 1.724 0 00-1.065-2.572c-1.756-.426-1.756-2.924 0-3.35a1.724 1.724 0 001.066-2.573c-.94-1.543.826-3.31 2.37-2.37.996.608 2.296.07 2.572-1.065z\" />\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M15 12a3 3 0 11-6 0 3 3 0 016 0z\" />\n </svg>\n Gestionar Suscripción\n }\n </button>\n </div>\n </div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, input, output } from '@angular/core';\nimport { StripeSubscriptionPublic } from '../../../../store/subscriptions.store';\nimport { SubscriptionItemSkeletonComponent } from './subscription-item-skeleton/subscription-item-skeleton.component';\nimport { SubscriptionItemComponent } from './subscription-item/subscription-item.component';\n\n@Component({\n selector: 'lib-subscriptions-list',\n templateUrl: './subscriptions-list.component.html',\n standalone: true,\n imports: [CommonModule, SubscriptionItemComponent, SubscriptionItemSkeletonComponent],\n})\nexport class SubscriptionsListComponent {\n public readonly subscriptions = input.required<StripeSubscriptionPublic[]>();\n public readonly loading = input<boolean>(false);\n public readonly error = input<string | null>(null);\n public readonly withEmptyState = input<boolean>(true);\n\n public readonly onManageSubscription = output<string>();\n\n public manageSubscription(customerId: string): void {\n this.onManageSubscription.emit(customerId);\n }\n} ","<div class=\"subscriptions-container\">\n @if (loading()) {\n <div class=\"flex flex-col gap-4\">\n @for (item of [1,2,3]; track item) {\n <lib-subscription-item-skeleton></lib-subscription-item-skeleton>\n }\n </div>\n } @else if (error()) {\n <div class=\"error-container\">\n <div class=\"alert alert-error\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"stroke-current shrink-0 h-6 w-6\" fill=\"none\" viewBox=\"0 0 24 24\"><path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M10 14l2-2m0 0l2-2m-2 2l-2-2m2 2l2 2m7-2a9 9 0 11-18 0 9 9 0 0118 0z\" /></svg>\n <span>{{ error() }}</span>\n </div>\n </div>\n } @else if (subscriptions().length > 0) {\n <div class=\"subscriptions-list flex flex-col gap-4\">\n @for (subscription of subscriptions(); track subscription.id) {\n <lib-subscription-item \n [subscription]=\"subscription\"\n (onManageSubscription)=\"manageSubscription($event)\">\n </lib-subscription-item>\n }\n </div>\n } @else if (withEmptyState() && subscriptions().length === 0 && !loading()) {\n <div class=\"empty-state\">\n <div class=\"card bg-base-100 shadow-sm\">\n <div class=\"card-body items-center text-center\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-12 w-12 text-gray-400 mb-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n <h2 class=\"card-title text-xl\">No tienes suscripciones activas</h2>\n <p class=\"text-gray-600\">Consulta nuestros planes para comenzar una suscripción.</p>\n </div>\n </div>\n </div>\n }\n</div> ","import { Component } from '@angular/core';\n\n@Component({\n selector: 'lib-subscription-card-skeleton',\n templateUrl: './subscription-card-skeleton.component.html',\n standalone: true\n})\nexport class SubscriptionCardSkeletonComponent {}\n","<div class=\"card bg-base-100 w-96 shadow-sm\">\n <figure class=\"flex items-center justify-center\">\n <div class=\"skeleton h-48 w-full\"></div>\n </figure>\n <div class=\"card-body\">\n <div class=\"flex justify-between items-center\">\n <div class=\"skeleton h-8 w-2/3\"></div>\n <div class=\"skeleton h-6 w-24 rounded-full\"></div>\n </div>\n \n <div class=\"mt-3\">\n <div class=\"skeleton h-4 w-full\"></div>\n <div class=\"skeleton h-4 w-5/6 mt-2\"></div>\n </div>\n \n <div class=\"card-actions justify-end mt-4\">\n <div class=\"skeleton h-10 w-40 rounded-lg\"></div>\n </div>\n </div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, inject, input, output } from '@angular/core';\nimport { StripeSubscriptionPublic } from '../../../../store/subscriptions.store';\nimport { SubscriptionCardSkeletonComponent } from './subscription-card-skeleton/subscription-card-skeleton.component';\nimport { UtilsService } from '../../../../services/utils.service';\n\n@Component({\n selector: 'lib-subscription-card',\n templateUrl: './subscription-card.component.html',\n standalone: true,\n imports: [CommonModule, SubscriptionCardSkeletonComponent],\n})\nexport class SubscriptionCardComponent {\n public readonly subscription = input.required<StripeSubscriptionPublic>();\n public readonly loading = input<boolean>(false);\n public readonly error = input<string | null>(null);\n\n public readonly utils = inject(UtilsService);\n \n public readonly onManageSubscription = output<string>();\n \n public hasValidProductImages(): boolean {\n const subscription = this.subscription();\n return !!subscription?.product && Array.isArray(subscription.product.images) && subscription.product.images.length > 0;\n }\n\n public getProductImage(): string {\n return this.subscription()?.product?.images?.[0] || '';\n }\n\n public getProductName(): string {\n return this.subscription()?.product?.name || '';\n }\n \n /**\n * Emit the customer ID to manage subscription\n */\n public manageSubscription(): void {\n this.onManageSubscription.emit(this.subscription().customer as string);\n }\n} ","@if (loading()) {\n <lib-subscription-card-skeleton></lib-subscription-card-skeleton>\n} @else if (error()) {\n <div class=\"alert alert-error\">{{ error() }}</div>\n} @else if (subscription()) {\n <div class=\"card bg-base-100 w-96 shadow-sm \">\n @if (hasValidProductImages()) {\n <figure class=\"flex items-center justify-center\">\n <img [src]=\"getProductImage()\" [alt]=\"getProductName()\" class=\"h-48 w-full object-cover\" />\n </figure>\n }\n <div class=\"card-body\">\n <div class=\"flex justify-between items-center\">\n <h2 class=\"card-title\">{{ getProductName() }}</h2>\n <span class=\"badge badge-soft {{ utils.getStatusBadgeClass(subscription().status) }} subscription-status\">\n {{ subscription().status }}\n </span>\n </div>\n \n <div class=\"mt-3\">\n <p class=\"opacity-75\">{{ subscription().product?.description }}</p>\n </div>\n \n <div class=\"card-actions justify-end\">\n <button class=\"btn btn-primary\" (click)=\"manageSubscription()\">\n Manage Subscription\n </button>\n </div>\n </div>\n </div>\n}\n","import { CommonModule } from '@angular/common';\nimport { Component } from '@angular/core';\n\n@Component({\n selector: 'lib-payment-intent-item-skeleton',\n templateUrl: './payment-intent-item-skeleton.component.html',\n standalone: true,\n imports: [CommonModule]\n})\nexport class PaymentIntentItemSkeletonComponent {} ","<div class=\"card bg-base-100 shadow-sm card-skeleton\">\n <div class=\"card-body p-4\">\n <!-- Header with status and expand button -->\n <div class=\"flex justify-between\">\n <div class=\"w-full\">\n <div class=\"flex items-center\">\n <!-- Title/Status placeholder -->\n <div class=\"skeleton w-32 h-6 rounded-md\"></div>\n <!-- Badge placeholder -->\n <div class=\"skeleton w-24 h-6 ml-2 rounded-full\"></div>\n </div>\n <!-- Customer ID placeholder -->\n <div class=\"skeleton w-48 h-4 mt-2 rounded-md\"></div>\n </div>\n \n <!-- Details button placeholder -->\n <div class=\"skeleton w-20 h-8 rounded-md\"></div>\n </div>\n\n <!-- Payment details summary -->\n <div class=\"flex justify-between mt-3\">\n <div>\n <!-- Amount placeholder -->\n <div class=\"skeleton w-32 h-8 rounded-md\"></div>\n </div>\n <div>\n <!-- Date placeholder -->\n <div class=\"skeleton w-28 h-6 rounded-md\"></div>\n </div>\n </div>\n \n <!-- Optional expanded details placeholder -->\n <div class=\"mt-4 border-t pt-4\">\n <div class=\"grid grid-cols-1 md:grid-cols-2 gap-4\">\n <div>\n <!-- Details heading placeholder -->\n <div class=\"skeleton w-36 h-5 mb-3 rounded-md\"></div>\n \n <!-- List items placeholders -->\n <div class=\"space-y-2\">\n <div class=\"skeleton w-full h-4 rounded-md\"></div>\n <div class=\"skeleton w-full h-4 rounded-md\"></div>\n <div class=\"skeleton w-3/4 h-4 rounded-md\"></div>\n </div>\n </div>\n \n <div>\n <!-- Second column heading placeholder -->\n <div class=\"skeleton w-36 h-5 mb-3 rounded-md\"></div>\n \n <!-- List items placeholders -->\n <div class=\"space-y-2\">\n <div class=\"skeleton w-full h-4 rounded-md\"></div>\n <div class=\"skeleton w-2/3 h-4 rounded-md\"></div>\n </div>\n </div>\n </div>\n \n <!-- Action button placeholder -->\n <div class=\"flex justify-end mt-4\">\n <div class=\"skeleton w-36 h-10 rounded-md\"></div>\n </div>\n </div>\n </div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, inject, input, signal } from '@angular/core';\nimport { StripePaymentIntentsPublic } from '../../../../../store/customer.store';\nimport { UtilsService } from '../../../../../services/utils.service';\nimport { PaymentMethodComponent } from '../../../payment-method/payment-method.component';\n\n@Component({\n selector: 'lib-payment-intent-item',\n templateUrl: './payment-intent-item.component.html',\n standalone: true,\n imports: [CommonModule, PaymentMethodComponent]\n})\nexport class PaymentIntentItemComponent {\n public readonly paymentIntent = input.required<StripePaymentIntentsPublic>();\n \n public readonly utils = inject(UtilsService);\n \n public readonly isExpanded = signal(false);\n \n public toggleExpand(): void {\n this.isExpanded.update(value => !value);\n }\n} ","<div class=\"card bg-base-100 shadow-sm hover:shadow-md transition-all duration-200 border border-base-200\">\n <div class=\"card-body p-4\">\n \n <!-- Header Section -->\n <div class=\"flex justify-between items-start mb-3\">\n <div class=\"flex-1\">\n <div class=\"flex items-center gap-2 mb-1\">\n <div class=\"text-2xl font-bold text-primary\">\n {{ utils.formatAmount(paymentIntent().amount ?? 0, paymentIntent().currency ?? 'EUR') }}\n </div>\n <div class=\"badge {{ utils.getStatusBadgeClass(paymentIntent().status) }} badge-sm\">\n {{ paymentIntent().status }}\n </div>\n @if (!paymentIntent().liveMode) {\n <div class=\"badge badge-warning badge-sm\">TEST</div>\n }\n </div>\n </div>\n \n <button \n class=\"btn btn-sm btn-ghost btn-circle\" \n (click)=\"toggleExpand()\"\n [class.rotate-180]=\"isExpanded()\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 transition-transform duration-200\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M19 9l-7 7-7-7\" />\n </svg>\n </button>\n </div>\n\n <!-- Main Info Section -->\n <div class=\"space-y-2\">\n <!-- Payment Method -->\n @if (paymentIntent().paymentMethod) {\n <ngx-payment-method \n [paymentMethod]=\"paymentIntent().paymentMethod!\" \n mode=\"compact\">\n </ngx-payment-method>\n } @else {\n <div class=\"flex items-center gap-2 p-2 bg-base-200 rounded-lg\">\n <div class=\"w-8 h-8 bg-base-300 rounded-full flex items-center justify-center\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M3 10h18M7 15h1m4 0h1m-7 4h12a3 3 0 003-3V8a3 3 0 00-3-3H6a3 3 0 00-3 3v8a3 3 0 003 3z\" />\n </svg>\n </div>\n <div>\n <div class=\"font-medium text-sm\">Método de pago</div>\n <div class=\"text-xs text-base-content/70\">•••• {{ paymentIntent().paymentMethodId.slice(-4) }}</div>\n </div>\n </div>\n }\n\n <!-- Confirmation Method -->\n <div class=\"flex items-center gap-2 text-sm\">\n <div class=\"w-2 h-2 bg-success rounded-full\"></div>\n <span class=\"text-base-content/70\">Confirmación:</span>\n <span class=\"capitalize font-medium\">{{ paymentIntent().confirmationMethod.replace('_', ' ') }}</span>\n </div>\n </div>\n\n <!-- Expanded Details -->\n @if (isExpanded()) {\n <div class=\"divider my-4\"></div>\n \n <div class=\"space-y-4\">\n <!-- Transaction Details -->\n <div>\n <h4 class=\"text-sm font-semibold text-base-content/80 mb-3 flex items-center gap-2\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z\" />\n </svg>\n Detalles de la Transacción\n </h4>\n \n <div class=\"grid grid-cols-1 sm:grid-cols-2 gap-3\">\n <div class=\"stat bg-base-200 rounded-lg p-3\">\n <div class=\"stat-title text-xs\">Estado</div>\n <div class=\"stat-value text-sm capitalize\">{{ paymentIntent().status }}</div>\n <div class=\"stat-desc\">{{ paymentIntent().liveMode ? 'Producción' : 'Pruebas' }}</div>\n </div>\n \n <div class=\"stat bg-base-200 rounded-lg p-3\">\n <div class=\"stat-title text-xs\">Monto</div>\n <div class=\"stat-value text-sm\">{{ utils.formatAmount(paymentIntent().amount ?? 0, paymentIntent().currency ?? 'EUR') }}</div>\n <div class=\"stat-desc\">{{ (paymentIntent().currency ?? 'EUR').toUpperCase() }}</div>\n </div>\n </div>\n </div>\n\n <!-- Payment Information -->\n @if (paymentIntent().paymentMethod) {\n <div>\n <h4 class=\"text-sm font-semibold text-base-content/80 mb-3 flex items-center gap-2\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M3 10h18M7 15h1m4 0h1m-7 4h12a3 3 0 003-3V8a3 3 0 00-3-3H6a3 3 0 00-3 3v8a3 3 0 003 3z\" />\n </svg>\n Información del Pago\n </h4>\n \n <ngx-payment-method \n [paymentMethod]=\"paymentIntent().paymentMethod!\" \n mode=\"detailed\">\n </ngx-payment-method>\n </div>\n }\n\n <!-- Additional Information -->\n <div>\n <h4 class=\"text-sm font-semibold text-base-content/80 mb-3 flex items-center gap-2\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z\" />\n </svg>\n Información Adicional\n </h4>\n \n <div class=\"space-y-2\">\n @if (paymentIntent().invoiceId) {\n <div class=\"flex items-center justify-between p-2 bg-base-200 rounded\">\n <span class=\"text-sm text-base-content/70\">Factura</span>\n <span class=\"text-sm font-mono\">{{ paymentIntent().invoiceId.slice(-8) }}</span>\n </div>\n }\n \n <div class=\"flex items-center justify-between p-2 bg-base-200 rounded\">\n <span class=\"text-sm text-base-content/70\">Entorno</span>\n <span class=\"text-sm\">\n @if (paymentIntent().liveMode) {\n <span class=\"text-success\">Producción</span>\n } @else {\n <span class=\"text-warning\">Pruebas</span>\n }\n </span>\n </div>\n \n <div class=\"flex items-center justify-between p-2 bg-base-200 rounded\">\n <span class=\"text-sm text-base-content/70\">Referencia</span>\n <span class=\"text-sm font-mono\">•••{{ paymentIntent().id?.slice(-6) || 'N/A' }}</span>\n </div>\n </div>\n </div>\n </div>\n }\n </div>\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, input, output } from '@angular/core';\nimport { StripePaymentIntentsPublic } from '../../../../store/customer.store';\nimport { PaymentIntentItemSkeletonComponent } from './payment-intents-item-skeleton/payment-intent-item-skeleton.component';\nimport { PaymentIntentItemComponent } from './payment-intents-item/payment-intent-item.component';\n\n@Component({\n selector: 'lib-payment-intents-list',\n templateUrl: './payment-intents-list.component.html',\n standalone: true,\n imports: [\n CommonModule,\n PaymentIntentItemSkeletonComponent,\n PaymentIntentItemComponent\n ]\n})\nexport class PaymentIntentsListComponent {\n public readonly paymentIntents = input.required<StripePaymentIntentsPublic[]>();\n public readonly loading = input<boolean>(false);\n public readonly error = input<string | null>(null);\n public readonly withControls = input<boolean>(true);\n \n public readonly onRefresh = output<void>();\n \n protected readonly trackByPaymentIntentId = (index: number, item: StripePaymentIntentsPublic) => item.id;\n \n public refreshPaymentIntents(): void {\n this.onRefresh.emit();\n }\n} ","<div class=\"payment-intents-container\">\n @if (withControls()) {\n <div class=\"controls mb-4 flex justify-between items-center\">\n <div class=\"stats\">\n @if (paymentIntents().length > 0) {\n <span class=\"badge badge-soft badge-info\">{{ paymentIntents().length }} payment intents</span>\n }\n </div>\n <button class=\"btn btn-sm btn-outline\" (click)=\"refreshPaymentIntents()\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 mr-1\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M4 4v5h.582m15.356 2A8.001 8.001 0 004.582 9m0 0H9m11 11v-5h-.581m0 0a8.003 8.003 0 01-15.357-2m15.357 2H15\" />\n </svg>\n Actualizar\n </button>\n </div>\n }\n\n @if (loading()) {\n <div class=\"flex flex-col gap-4\">\n @for (item of [1,2,3]; track item) {\n <lib-payment-intent-item-skeleton></lib-payment-intent-item-skeleton>\n }\n </div>\n } @else if (error()) {\n <div class=\"error-container\">\n <div class=\"alert alert-error\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"stroke-current shrink-0 h-6 w-6\" fill=\"none\" viewBox=\"0 0 24 24\"><path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M10 14l2-2m0 0l2-2m-2 2l-2-2m2 2l2 2m7-2a9 9 0 11-18 0 9 9 0 0118 0z\" /></svg>\n <span>{{ error() }}</span>\n </div>\n </div>\n } @else if (paymentIntents().length > 0) {\n <div class=\"flex flex-col gap-4\">\n @for (paymentIntent of paymentIntents(); track paymentIntent.id) {\n <lib-payment-intent-item [paymentIntent]=\"paymentIntent\"></lib-payment-intent-item>\n }\n </div>\n } @else {\n <div class=\"empty-state\">\n <div class=\"card bg-base-100 shadow-sm\">\n <div class=\"card-body items-center text-center\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-12 w-12 text-gray-400 mb-4\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M3 10h18M7 15h1m4 0h1m-7 4h12a3 3 0 003-3V8a3 3 0 00-3-3H6a3 3 0 00-3 3v8a3 3 0 003 3z\" />\n </svg>\n <h2 class=\"card-title text-xl\">No hay payment intents recientes</h2>\n <p class=\"text-gray-600\">No se encontraron payment intents en tu historial.</p>\n </div>\n </div>\n </div>\n }\n</div> ","import { CommonModule } from '@angular/common';\nimport { Component, inject, input } from '@angular/core';\nimport { CustomerStore } from '../../../store/customer.store';\nimport { PortalAccountStore } from '../../../store/portal-account.store';\nimport { SubscriptionCardComponent } from './subscription-card/subscription-card.component';\nimport { SubscriptionsListComponent } from './subscriptions-list/subscriptions-list.component';\n\n@Component({\n selector: 'lib-subscriptions',\n templateUrl: './subscriptions.component.html',\n standalone: true,\n imports: [CommonModule, SubscriptionCardComponent, SubscriptionsListComponent],\n})\nexport class SubscriptionsComponent {\n public readonly customerStore = inject(CustomerStore);\n public readonly portalAccountStore = inject(PortalAccountStore);\n\n public readonly returnUrl = input<string>(window.location.origin + '/account');\n\n public manageSubscription(customerId: string): void {\n this.portalAccountStore.createPortalSession(customerId, this.returnUrl());\n }\n\n public refreshSubscriptions(): void {\n if (this.customerStore.customer().data?.id) {\n this.customerStore.loadSubscriptions(this.customerStore.customer().data?.id as string);\n }\n }\n}\n\n","<div class=\"mb-4 flex flex-col justify-between items-center\">\n <div class=\"mb-6 w-full\">\n <h2 class=\"text-2xl font-bold text-gray-800\">Subscriptions</h2>\n <p class=\"text-gray-600\">Manage your subscriptions and payments in one place</p>\n </div>\n <div class=\"controls mb-4 flex justify-between items-center w-full\">\n <div class=\"stats\">\n @if (customerStore.subscriptions.data().length > 0) {\n <span class=\"badge badge-soft badge-info\">{{ customerStore.subscriptions.data().length}} subscriptions</span>\n }\n </div>\n <button class=\"btn btn-sm btn-outline\" (click)=\"refreshSubscriptions()\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"h-4 w-4 mr-1\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\">\n <path stroke-linecap=\"round\" stroke-linejoin=\"round\" stroke-width=\"2\" d=\"M4 4v5h.582m15.356 2A8.001 8.001 0 004.582 9m0 0H9m11 11v-5h-.581m0 0a8.003 8.003 0 01-15.357-2m15.357 2H15\" />\n </svg>\n Updated\n </button>\n </div>\n</div>\n\n<div class=\"flex flex-col gap-4\">\n <lib-subscription-card\n [subscription]=\"customerStore.firstSubscription()\"\n [loading]=\"customerStore.isSubscriptionsStatusLoading()\"\n [error]=\"customerStore.subscriptions.error()\"\n (onManageSubscription)=\"manageSubscription($event)\">\n </lib-subscription-card>\n <lib-subscriptions-list\n [subscriptions]=\"customerStore.restSubscriptions()\"\n [loading]=\"customerStore.isSubscriptionsStatusLoading()\"\n [error]=\"customerStore.subscriptions.error()\"\n [withEmptyState]=\"false\"\n (onManageSubscription)=\"manageSubscription($event)\">\n </lib-subscriptions-list>\n</div>","import { CommonModule } from '@angular/common';\nimport { Component, computed, inject, input, signal } from '@angular/core';\nimport { PaymentIntentsListComponent } from '../../components/customer/payment-intents/payment-intents-list/payment-intents-list.component';\nimport { PaymentIntentsTableComponent } from '../../components/customer/payment-intents/payment-intents-table/payment-intents-table.component';\nimport { SubscriptionsComponent } from '../../components/customer/subscriptions/subscriptions.component';\nimport { CustomerStore, StripePaymentIntentsPublic } from '../../store/customer.store';\n\n@Component({\n selector: 'lib-customer-dashboard',\n templateUrl: './customer.component.html',\n standalone: true,\n imports: [\n CommonModule,\n PaymentIntentsListComponent,\n PaymentIntentsTableComponent,\n SubscriptionsComponent\n ]\n}) \nexport class CustomerDashboardComponent {\n public readonly customerStore = inject(CustomerStore);\n\n public readonly returnUrl = input<string>(window.location.origin + '/account');\n \n public readonly customer = computed(() => this.customerStore.customer().data);\n \n public readonly activeTab = signal<'list' | 'table'>('list');\n\n public refreshPaymentIntents(): void {\n this.customerStore.loadPaymentIntents(this.customerStore.customer().data?.id as string);\n }\n \n public setActiveTab(tab: 'list' | 'table'): void {\n this.activeTab.set(tab);\n }\n\n public exportSelectedPaymentIntents(paymentIntents: StripePaymentIntentsPublic[]): void {\n console.log('[💰 CustomerDashboardComponent] exportSelectedPaymentIntents: ', paymentIntents);\n }\n}\n","<div class=\"container flex flex-col gap-6 mx-auto\">\n <!-- Subscriptions Section -->\n <section class=\"flex flex-col\">\n <lib-subscriptions [returnUrl]=\"returnUrl()\"></lib-subscriptions>\n </section>\n\n <!-- Payment Intents Section with Tabs -->\n <section class=\"flex flex-col\">\n <header class=\"mb-4\">\n <h2 class=\"text-2xl font-bold text-gray-800\">Payment Intents</h2>\n <p class=\"text-gray-600\">Payment intents history. Select a tab to see the list or table view.</p>\n </header>\n\n <div role=\"tablist\" class=\"tabs tabs-box w-fit mb-4\">\n <a role=\"tab\" class=\"tab\" [class.tab-active]=\"activeTab() === 'list'\" (click)=\"setActiveTab('list')\">Lista</a>\n <a role=\"tab\" class=\"tab\" [class.tab-active]=\"activeTab() === 'table'\" (click)=\"setActiveTab('table')\">Tabla</a>\n </div>\n\n @if (activeTab() === 'list') {\n <lib-payment-intents-list\n [paymentIntents]=\"customerStore.paymentIntents.data()\"\n [loading]=\"customerStore.isPaymentIntentsStatusLoading()\"\n [error]=\"customerStore.paymentIntents.error()\"\n (onRefresh)=\"refreshPaymentIntents()\">\n </lib-payment-intents-list>\n } @else {\n <lib-payment-intents-table\n [paymentIntents]=\"customerStore.paymentIntents.data()\"\n [loading]=\"customerStore.isPaymentIntentsStatusLoading()\"\n [error]=\"customerStore.paymentIntents.error()\"\n (exportSelected)=\"exportSelectedPaymentIntents($event)\"\n (onRefresh)=\"refreshPaymentIntents()\">\n </lib-payment-intents-table>\n }\n </section>\n</div>\n","/*\n * Public API Surface of ngx-supabase-stripe\n */\n\n// Export configurations\nexport * from './lib/config/ngx-supabase-stripe.config';\nexport * from './lib/config/stripe.config';\nexport * from './lib/config/supabase.config';\n\n// Export store\nexport * from './lib/store/checkout.store';\nexport * from './lib/store/products.store';\nexport * from './lib/store/subscriptions.store';\nexport * from './lib/store/customer.store';\nexport * from './lib/store/portal-account.store';\n\n// Export services\nexport * from './lib/services/stripe-client.service';\nexport * from './lib/services/supabase-client.service';\n\n// Export components\nexport * from './lib/components/embedded-checkout/embedded-checkout.component';\nexport * from './lib/components/embedded-checkout/return-page/return-page.component';\nexport * from './lib/components/product-list/product-list.component';\nexport * from './lib/components/embedded-subscription/embedded-subscription.component';\nexport * from './lib/components/embedded-subscription/return-page/subscription-return-page.component';\nexport * from './lib/components/customer/payment-intents/payment-intents-table/payment-intents-table.component';\nexport * from './lib/components/customer/subscriptions/subscriptions-list/subscriptions-list.component';\nexport * from './lib/components/customer/subscriptions/subscription-card/subscription-card.component';\nexport * from './lib/components/customer/subscriptions/subscriptions-list/subscriptions-list.component';\nexport * from './lib/components/customer/payment-intents/payment-intents-list/payment-intents-list.component';\nexport * from './lib/pages/customer/customer.component';\n\n// Export models\nexport * from './lib/models/currency.model';\n\n// Export types\nexport * from './database.types';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;MAYa,aAAa,GAAG,IAAI,cAAc,CAAe,eAAe;AAE7E;;;;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BAAA,EAAA,MAAA,EAAA,CAAA,WAAA,CAAA,EAAA,CAAA,EAAA,CAAA;;2FAGb,0BAA0B,EAAA,UAAA,EAAA,CAAA;kBAXtC,SAAS;+BACE,wBAAwB,EAAA,UAAA,EAEtB,IAAI,EACP,OAAA,EAAA;wBACP,YAAY;wBACZ,2BAA2B;wBAC3B,4BAA4B;wBAC5B;AACD,qBAAA,EAAA,QAAA,EAAA,8lDAAA,EAAA;;;AEhBH;;AAEG;AAEH;;ACJA;;AAEG;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dotted-labs/ngx-supabase-stripe",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.3",
|
|
4
4
|
"description": "An Angular library for integrating Supabase and Stripe into your applications, providing ready-to-use components that simplify the implementation of payments and subscriptions",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"angular",
|