init commit for iPAL-kit plugin
This commit is contained in:
+19
-1
@@ -1 +1,19 @@
|
||||
export { BeforeDashboardClient } from '../components/BeforeDashboardClient.js'
|
||||
'use client'
|
||||
export { Analytics } from '../modules/analytics/client.js'
|
||||
/**
|
||||
* Entry point: ipal-kit/client
|
||||
*
|
||||
* Client-side ('use client') exports — React hooks, providers, and UI
|
||||
* components. Kept separate from the main entry so server bundles don't pull in
|
||||
* client-only code.
|
||||
*/
|
||||
export {
|
||||
ConsentProvider,
|
||||
CookieBanner,
|
||||
CookieButton,
|
||||
useConsent,
|
||||
useConsentContext,
|
||||
} from '../modules/consent/client.js'
|
||||
export type { CookieBannerClassNames } from '../modules/consent/client.js'
|
||||
export { Turnstile } from '../modules/turnstile/client.js'
|
||||
export type { TurnstileProps } from '../modules/turnstile/client.js'
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
/**
|
||||
* Entry point: ipal-kit/next/middleware
|
||||
*
|
||||
* Re-exports the locale middleware factory and default matcher for use in a
|
||||
* client project's next-middleware.ts. Kept as a thin re-export so the Next-facing
|
||||
* surface is separate from the main package export.
|
||||
*/
|
||||
export { createLocaleMiddleware, DEFAULT_MIDDLEWARE_MATCHER } from '../modules/i18n/index.js'
|
||||
export type { LocaleMiddlewareResult } from '../modules/i18n/index.js'
|
||||
+14
-1
@@ -1 +1,14 @@
|
||||
export { BeforeDashboardServer } from '../components/BeforeDashboardServer.js'
|
||||
/**
|
||||
* Entry point: ipal-kit/rsc
|
||||
*
|
||||
* Server-component exports. RenderBlocks is a React Server Component, so it
|
||||
* lives here rather than in the main package entry to keep React out of the
|
||||
* server-config bundle.
|
||||
*/
|
||||
export { RenderBlocks } from '../modules/blocks/index.js'
|
||||
export type {
|
||||
BlockComponentMap,
|
||||
BlockData,
|
||||
EnhanceProps,
|
||||
RenderBlocksProps,
|
||||
} from '../modules/blocks/index.js'
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
/**
|
||||
* Entry point: ipal-kit/server
|
||||
*
|
||||
* Server-only runtime functions — these import 'server-only' (Turnstile secret,
|
||||
* SMTP password, nodemailer). Kept OUT of the main entry so that loading the
|
||||
* Payload config or running `payload generate:importmap` (both Node scripts,
|
||||
* no bundler) never pulls in 'server-only', which throws outside a bundled
|
||||
* server context.
|
||||
*
|
||||
* Import these only from Server Actions, route handlers, or server components —
|
||||
* never from the Payload config or client code.
|
||||
*/
|
||||
export { verifyTurnstile } from '../modules/turnstile/index.js'
|
||||
export { sendEmail } from '../modules/email/index.js'
|
||||
export type { SendEmailArgs, SendEmailResult } from '../modules/email/index.js'
|
||||
export { submitForm } from '../modules/forms/index.js'
|
||||
export type { SubmitFormArgs, SubmitFormResult } from '../modules/forms/index.js'
|
||||
Reference in New Issue
Block a user