diff --git a/.changeset/config.json b/.changeset/config.json index 9a410f57..f26daf14 100644 --- a/.changeset/config.json +++ b/.changeset/config.json @@ -1,10 +1,11 @@ { - "$schema": "https://unpkg.com/@changesets/config@2.1.1/schema.json", + "$schema": "https://unpkg.com/@changesets/config@2.3.1/schema.json", + "changelog": "@changesets/cli/changelog", "commit": false, "fixed": [], "linked": [], "access": "public", "baseBranch": "main", "updateInternalDependencies": "patch", - "changedFilePatterns": ["src/**", "template/**"] + "ignore": [] } diff --git a/.github/workflows/prerelease-comment.yml b/.github/workflows/prerelease-comment.yml index 72fba7e7..0768c09a 100644 --- a/.github/workflows/prerelease-comment.yml +++ b/.github/workflows/prerelease-comment.yml @@ -22,7 +22,7 @@ jobs: const allArtifacts = await github.rest.actions.listWorkflowRunArtifacts({ owner: context.repo.owner, repo: context.repo.repo, - run_id: context.payload.workflow_run.id, + run_id: context.payload.workflow_run.id }); for (const artifact of allArtifacts.data.artifacts) { @@ -48,7 +48,12 @@ jobs: A new proofkit prerelease is available for testing. You can install this latest build in your project with: ```sh - pnpm create t3-app@${{ env.BETA_PACKAGE_VERSION }} + pnpm update @proofgeist/kit@${{ env.BETA_PACKAGE_VERSION }} + ``` + + or to create a new project: + ```sh + pnpx @proofgeist/kit@${{ env.BETA_PACKAGE_VERSION }} ``` - name: "Remove the autorelease label once published" @@ -56,9 +61,10 @@ jobs: with: github-token: ${{ secrets.GH_TOKEN }} script: | - github.rest.issues.removeLabel({ + const issueNumber = process.env.WORKFLOW_RUN_PR; + await github.rest.issues.removeLabel({ owner: context.repo.owner, repo: context.repo.repo, - issue_number: ${{ env.WORKFLOW_RUN_PR }}, - name: '🚀 autorelease', + issue_number: issueNumber, + name: '🚀 autorelease' }); diff --git a/.github/workflows/prerelease.yml b/.github/workflows/prerelease.yml index b01e2c66..ace5d6cf 100644 --- a/.github/workflows/prerelease.yml +++ b/.github/workflows/prerelease.yml @@ -5,14 +5,16 @@ name: Release - Beta on: pull_request: - types: [labeled] + types: [labeled, synchronize] branches: - main + jobs: prerelease: if: | github.repository_owner == 'proofgeist' && - contains(github.event.pull_request.labels.*.name, '🚀 autorelease') + (github.event.action == 'labeled' && contains(github.event.pull_request.labels.*.name, '🚀 autorelease') || + github.event.action == 'synchronize' && contains(github.event.pull_request.labels.*.name, '🚀 autorelease')) name: Build & Publish a beta release to NPM runs-on: ubuntu-latest diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 1554d76b..200c8952 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -8,32 +8,26 @@ on: branches: - main +concurrency: ${{ github.workflow }}-${{ github.ref }} + jobs: release: - if: ${{ github.repository_owner == 'proofgeist' }} - name: Create a PR for release workflow + name: Release runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - name: Checkout Repo + uses: actions/checkout@v4 with: fetch-depth: 0 - - uses: ./.github/actions/setup - - - name: Check for errors - run: pnpm check - - name: Build the package - run: pnpm build:cli + - name: Setup + uses: ./.github/actions/setup - - name: Create Version PR or Publish to NPM + - name: Create Release Pull Request or Publish to npm id: changesets uses: changesets/action@v1 with: - commit: "chore(release): version packages" - title: "chore(release): version packages" - version: node .github/changeset-version.js - publish: npx changeset publish + publish: pnpm pub:release env: GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} NPM_TOKEN: ${{ secrets.NPM_ACCESS_TOKEN }} - NODE_ENV: "production" diff --git a/cli/src/cli/add/auth.ts b/cli/src/cli/add/auth.ts index 8370f0f3..0f4b47b1 100644 --- a/cli/src/cli/add/auth.ts +++ b/cli/src/cli/add/auth.ts @@ -22,23 +22,23 @@ export async function runAddAuthAction() { message: "What auth provider do you want to use?", options: [ { - label: "Clerk", - value: "clerk", - hint: "Easy to setup and use, may required a paid plan", + value: "fmaddon", + label: "FM Add-on Auth", + hint: "Self-hosted auth with email/password", }, { - label: "ProofKit Auth", - value: "proofkit", - hint: "More advanced, but self-hosted and customizable", + value: "clerk", + label: "Clerk", + hint: "Hosted auth service with many providers", }, ], }) ); - const type = z.enum(["clerk", "proofkit"]).parse(authType); + const type = z.enum(["clerk", "fmaddon"]).parse(authType); state.authType = type; - if (type === "proofkit") { + if (type === "fmaddon") { const emailProviderAnswer = (state.emailProvider ? state.emailProvider @@ -89,11 +89,11 @@ export const makeAddAuthCommand = () => { .option("--authType ", "Type of auth provider to use") .option( "--emailProvider ", - "Email provider to use (only for ProofKit Auth)" + "Email provider to use (only for FM Add-on Auth)" ) .option( "--apiKey ", - "API key to use for the email provider (only for ProofKit Auth)" + "API key to use for the email provider (only for FM Add-on Auth)" ) .addOption(ciOption) .addOption(debugOption) diff --git a/cli/src/generators/auth.ts b/cli/src/generators/auth.ts index 3b94224a..23a86e1d 100644 --- a/cli/src/generators/auth.ts +++ b/cli/src/generators/auth.ts @@ -11,7 +11,7 @@ export async function addAuth({ options: | { type: "clerk" } | { - type: "proofkit"; + type: "fmaddon"; emailProvider?: "plunk" | "resend"; apiKey?: string; }; @@ -25,8 +25,8 @@ export async function addAuth({ if (options.type === "clerk") { await addClerkAuth({ projectDir }); - } else if (options.type === "proofkit") { - await addProofkitAuth(options); + } else if (options.type === "fmaddon") { + await addFmaddonAuth(options); } if (!noInstall) { @@ -43,11 +43,11 @@ async function addClerkAuth({ mergeSettings({ auth: { type: "clerk" } }); } -async function addProofkitAuth({ +async function addFmaddonAuth({ emailProvider, }: { emailProvider?: "plunk" | "resend"; }) { await proofkitAuthInstaller(); - mergeSettings({ auth: { type: "proofkit" } }); + mergeSettings({ auth: { type: "fmaddon" } }); } diff --git a/cli/src/installers/install-fm-addon.ts b/cli/src/installers/install-fm-addon.ts index 1846729b..37849362 100644 --- a/cli/src/installers/install-fm-addon.ts +++ b/cli/src/installers/install-fm-addon.ts @@ -12,8 +12,8 @@ export async function installFmAddon({ }: { addonName: "auth" | "wv"; }) { - const friendlyName = - addonName === "auth" ? "ProofKit Auth" : "ProofKit WebViewer"; + const addonDisplayName = + addonName === "auth" ? "FM Add-on Auth" : "ProofKit WebViewer"; let targetDir: string | null = null; if (process.platform === "win32") { @@ -38,7 +38,7 @@ export async function installFmAddon({ if (!targetDir) { logger.warn( - `Could not install the ${friendlyName} addon. You will need to do this manually.` + `Could not install the ${addonDisplayName} addon. You will need to do this manually.` ); return; } @@ -62,8 +62,8 @@ export async function installFmAddon({ if (addonName === "auth") { console.log( `${chalk.yellowBright( - "You must install the ProofKit Auth addon in your FileMaker file." - )} ${chalk.dim("(Learn more: https://proofkit.dev/auth/proofkit)")}` + "You must install the FM Add-on Auth addon in your FileMaker file." + )} ${chalk.dim("(Learn more: https://proofkit.dev/auth/fm-addon)")}` ); } else { console.log( @@ -74,7 +74,7 @@ export async function installFmAddon({ } const steps = [ "Restart FileMaker Pro (if it's currently running)", - `Open your FileMaker file, go to layout mode, and install the ${friendlyName} addon to the file`, + `Open your FileMaker file, go to layout mode, and install the ${addonDisplayName} addon to the file`, "Run the typegen command to add the types into your project:", ]; steps.forEach((step, index) => { @@ -84,5 +84,7 @@ export async function installFmAddon({ console.log(chalk.cyan(` ${getUserPkgManager()} typegen`)); console.log(""); - return; + throw new Error( + "You must install the FM Add-on Auth addon in your FileMaker file." + ); } diff --git a/cli/src/installers/proofkit-auth.ts b/cli/src/installers/proofkit-auth.ts index 7534868c..541b5d3e 100644 --- a/cli/src/installers/proofkit-auth.ts +++ b/cli/src/installers/proofkit-auth.ts @@ -1,4 +1,3 @@ -import os from "os"; import path from "path"; import { type OttoAPIKey } from "@proofgeist/fmdapi"; import chalk from "chalk"; @@ -12,8 +11,6 @@ import { addConfig, runCodegenCommand } from "~/generators/fmdapi.js"; import { injectTanstackQuery } from "~/generators/tanstack-query.js"; import { state } from "~/state.js"; import { addPackageDependency } from "~/utils/addPackageDependency.js"; -import { getUserPkgManager } from "~/utils/getUserPkgManager.js"; -import { logger } from "~/utils/logger.js"; import { getSettings } from "~/utils/parseSettings.js"; import { formatAndSaveSourceFiles, getNewProject } from "~/utils/ts-morph.js"; import { addToHeaderSlot } from "./auth-shared.js"; @@ -40,16 +37,16 @@ export const proofkitAuthInstaller = async () => { devMode: true, }); - // copy all files from template/extras/proofkit-auth to projectDir/src + // copy all files from template/extras/fmaddon-auth to projectDir/src await fs.copy( - path.join(PKG_ROOT, "template/extras/proofkit-auth"), + path.join(PKG_ROOT, "template/extras/fmaddon-auth"), path.join(projectDir, "src") ); const project = getNewProject(projectDir); // ensure tanstack query is installed - await injectTanstackQuery({ projectDir, project }); + await injectTanstackQuery({ project }); // inject signin/signout components to header slots addToHeaderSlot( @@ -210,7 +207,7 @@ async function checkForProofKitLayouts(projectDir: string): Promise { if (allProofkitAuthLayoutsExist) { console.log( chalk.green( - "Successfully detected all required layouts for ProofKit Auth in your FileMaker file." + "Successfully detected all required layouts for FM Add-on Auth in your FileMaker file." ) ); return true; diff --git a/cli/src/state.ts b/cli/src/state.ts index a92ac8c1..f4127c1c 100644 --- a/cli/src/state.ts +++ b/cli/src/state.ts @@ -7,7 +7,7 @@ const schema = z baseCommand: z.enum(["add", "init", "deploy"]).optional().catch(undefined), appType: z.enum(["browser", "webviewer"]).optional().catch(undefined), projectDir: z.string().default(process.cwd()), - authType: z.enum(["clerk", "proofkit"]).optional(), + authType: z.enum(["clerk", "fmaddon"]).optional(), emailProvider: z.enum(["plunk", "resend", "none"]).optional(), }) .passthrough(); diff --git a/cli/src/utils/parseSettings.ts b/cli/src/utils/parseSettings.ts index 1c051aa5..9297398a 100644 --- a/cli/src/utils/parseSettings.ts +++ b/cli/src/utils/parseSettings.ts @@ -13,7 +13,10 @@ const authSchema = z type: z.literal("next-auth"), }), z.object({ - type: z.literal("proofkit"), + type: z.literal("proofkit").transform(() => "fmaddon"), + }), + z.object({ + type: z.literal("fmaddon"), }), z.object({ type: z.literal("none"), diff --git a/cli/template/extras/emailProviders/none/email.tsx b/cli/template/extras/emailProviders/none/email.tsx index 688ed5be..e6599ccd 100644 --- a/cli/template/extras/emailProviders/none/email.tsx +++ b/cli/template/extras/emailProviders/none/email.tsx @@ -17,7 +17,7 @@ export async function sendEmail({ const subject = type === "verification" ? "Verify Your Email" : "Reset Your Password" // TODO: Customize this function to actually send the email to your users - // Learn more: https://proofkit.dev/auth/proofkit + // Learn more: https://proofkit.dev/auth/fm-addon console.warn("TODO: Customize this function to actually send to your users"); console.log(`To ${to}: Your ${type} code is ${code}`); } diff --git a/cli/template/extras/proofkit-auth/app/(main)/auth/profile/actions.ts b/cli/template/extras/fmaddon-auth/app/(main)/auth/profile/actions.ts similarity index 100% rename from cli/template/extras/proofkit-auth/app/(main)/auth/profile/actions.ts rename to cli/template/extras/fmaddon-auth/app/(main)/auth/profile/actions.ts diff --git a/cli/template/extras/proofkit-auth/app/(main)/auth/profile/page.tsx b/cli/template/extras/fmaddon-auth/app/(main)/auth/profile/page.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/app/(main)/auth/profile/page.tsx rename to cli/template/extras/fmaddon-auth/app/(main)/auth/profile/page.tsx diff --git a/cli/template/extras/proofkit-auth/app/(main)/auth/profile/profile-form.tsx b/cli/template/extras/fmaddon-auth/app/(main)/auth/profile/profile-form.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/app/(main)/auth/profile/profile-form.tsx rename to cli/template/extras/fmaddon-auth/app/(main)/auth/profile/profile-form.tsx diff --git a/cli/template/extras/proofkit-auth/app/(main)/auth/profile/reset-password-form.tsx b/cli/template/extras/fmaddon-auth/app/(main)/auth/profile/reset-password-form.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/app/(main)/auth/profile/reset-password-form.tsx rename to cli/template/extras/fmaddon-auth/app/(main)/auth/profile/reset-password-form.tsx diff --git a/cli/template/extras/proofkit-auth/app/(main)/auth/profile/schema.ts b/cli/template/extras/fmaddon-auth/app/(main)/auth/profile/schema.ts similarity index 100% rename from cli/template/extras/proofkit-auth/app/(main)/auth/profile/schema.ts rename to cli/template/extras/fmaddon-auth/app/(main)/auth/profile/schema.ts diff --git a/cli/template/extras/proofkit-auth/app/auth/forgot-password/actions.ts b/cli/template/extras/fmaddon-auth/app/auth/forgot-password/actions.ts similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/forgot-password/actions.ts rename to cli/template/extras/fmaddon-auth/app/auth/forgot-password/actions.ts diff --git a/cli/template/extras/proofkit-auth/app/auth/forgot-password/forgot-form.tsx b/cli/template/extras/fmaddon-auth/app/auth/forgot-password/forgot-form.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/forgot-password/forgot-form.tsx rename to cli/template/extras/fmaddon-auth/app/auth/forgot-password/forgot-form.tsx diff --git a/cli/template/extras/proofkit-auth/app/auth/forgot-password/page.tsx b/cli/template/extras/fmaddon-auth/app/auth/forgot-password/page.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/forgot-password/page.tsx rename to cli/template/extras/fmaddon-auth/app/auth/forgot-password/page.tsx diff --git a/cli/template/extras/proofkit-auth/app/auth/forgot-password/schema.ts b/cli/template/extras/fmaddon-auth/app/auth/forgot-password/schema.ts similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/forgot-password/schema.ts rename to cli/template/extras/fmaddon-auth/app/auth/forgot-password/schema.ts diff --git a/cli/template/extras/proofkit-auth/app/auth/login/actions.ts b/cli/template/extras/fmaddon-auth/app/auth/login/actions.ts similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/login/actions.ts rename to cli/template/extras/fmaddon-auth/app/auth/login/actions.ts diff --git a/cli/template/extras/proofkit-auth/app/auth/login/login-form.tsx b/cli/template/extras/fmaddon-auth/app/auth/login/login-form.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/login/login-form.tsx rename to cli/template/extras/fmaddon-auth/app/auth/login/login-form.tsx diff --git a/cli/template/extras/proofkit-auth/app/auth/login/page.tsx b/cli/template/extras/fmaddon-auth/app/auth/login/page.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/login/page.tsx rename to cli/template/extras/fmaddon-auth/app/auth/login/page.tsx diff --git a/cli/template/extras/proofkit-auth/app/auth/login/schema.ts b/cli/template/extras/fmaddon-auth/app/auth/login/schema.ts similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/login/schema.ts rename to cli/template/extras/fmaddon-auth/app/auth/login/schema.ts diff --git a/cli/template/extras/proofkit-auth/app/auth/reset-password/actions.ts b/cli/template/extras/fmaddon-auth/app/auth/reset-password/actions.ts similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/reset-password/actions.ts rename to cli/template/extras/fmaddon-auth/app/auth/reset-password/actions.ts diff --git a/cli/template/extras/proofkit-auth/app/auth/reset-password/page.tsx b/cli/template/extras/fmaddon-auth/app/auth/reset-password/page.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/reset-password/page.tsx rename to cli/template/extras/fmaddon-auth/app/auth/reset-password/page.tsx diff --git a/cli/template/extras/proofkit-auth/app/auth/reset-password/reset-password-form.tsx b/cli/template/extras/fmaddon-auth/app/auth/reset-password/reset-password-form.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/reset-password/reset-password-form.tsx rename to cli/template/extras/fmaddon-auth/app/auth/reset-password/reset-password-form.tsx diff --git a/cli/template/extras/proofkit-auth/app/auth/reset-password/schema.ts b/cli/template/extras/fmaddon-auth/app/auth/reset-password/schema.ts similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/reset-password/schema.ts rename to cli/template/extras/fmaddon-auth/app/auth/reset-password/schema.ts diff --git a/cli/template/extras/proofkit-auth/app/auth/reset-password/verify-email/actions.ts b/cli/template/extras/fmaddon-auth/app/auth/reset-password/verify-email/actions.ts similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/reset-password/verify-email/actions.ts rename to cli/template/extras/fmaddon-auth/app/auth/reset-password/verify-email/actions.ts diff --git a/cli/template/extras/proofkit-auth/app/auth/reset-password/verify-email/page.tsx b/cli/template/extras/fmaddon-auth/app/auth/reset-password/verify-email/page.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/reset-password/verify-email/page.tsx rename to cli/template/extras/fmaddon-auth/app/auth/reset-password/verify-email/page.tsx diff --git a/cli/template/extras/proofkit-auth/app/auth/reset-password/verify-email/schema.ts b/cli/template/extras/fmaddon-auth/app/auth/reset-password/verify-email/schema.ts similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/reset-password/verify-email/schema.ts rename to cli/template/extras/fmaddon-auth/app/auth/reset-password/verify-email/schema.ts diff --git a/cli/template/extras/proofkit-auth/app/auth/reset-password/verify-email/verify-email-form.tsx b/cli/template/extras/fmaddon-auth/app/auth/reset-password/verify-email/verify-email-form.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/reset-password/verify-email/verify-email-form.tsx rename to cli/template/extras/fmaddon-auth/app/auth/reset-password/verify-email/verify-email-form.tsx diff --git a/cli/template/extras/proofkit-auth/app/auth/signup/actions.ts b/cli/template/extras/fmaddon-auth/app/auth/signup/actions.ts similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/signup/actions.ts rename to cli/template/extras/fmaddon-auth/app/auth/signup/actions.ts diff --git a/cli/template/extras/proofkit-auth/app/auth/signup/page.tsx b/cli/template/extras/fmaddon-auth/app/auth/signup/page.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/signup/page.tsx rename to cli/template/extras/fmaddon-auth/app/auth/signup/page.tsx diff --git a/cli/template/extras/proofkit-auth/app/auth/signup/schema.ts b/cli/template/extras/fmaddon-auth/app/auth/signup/schema.ts similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/signup/schema.ts rename to cli/template/extras/fmaddon-auth/app/auth/signup/schema.ts diff --git a/cli/template/extras/proofkit-auth/app/auth/signup/signup-form.tsx b/cli/template/extras/fmaddon-auth/app/auth/signup/signup-form.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/signup/signup-form.tsx rename to cli/template/extras/fmaddon-auth/app/auth/signup/signup-form.tsx diff --git a/cli/template/extras/proofkit-auth/app/auth/verify-email/actions.ts b/cli/template/extras/fmaddon-auth/app/auth/verify-email/actions.ts similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/verify-email/actions.ts rename to cli/template/extras/fmaddon-auth/app/auth/verify-email/actions.ts diff --git a/cli/template/extras/proofkit-auth/app/auth/verify-email/email-verification-form.tsx b/cli/template/extras/fmaddon-auth/app/auth/verify-email/email-verification-form.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/verify-email/email-verification-form.tsx rename to cli/template/extras/fmaddon-auth/app/auth/verify-email/email-verification-form.tsx diff --git a/cli/template/extras/proofkit-auth/app/auth/verify-email/page.tsx b/cli/template/extras/fmaddon-auth/app/auth/verify-email/page.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/verify-email/page.tsx rename to cli/template/extras/fmaddon-auth/app/auth/verify-email/page.tsx diff --git a/cli/template/extras/proofkit-auth/app/auth/verify-email/resend-button.tsx b/cli/template/extras/fmaddon-auth/app/auth/verify-email/resend-button.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/verify-email/resend-button.tsx rename to cli/template/extras/fmaddon-auth/app/auth/verify-email/resend-button.tsx diff --git a/cli/template/extras/proofkit-auth/app/auth/verify-email/schema.ts b/cli/template/extras/fmaddon-auth/app/auth/verify-email/schema.ts similarity index 100% rename from cli/template/extras/proofkit-auth/app/auth/verify-email/schema.ts rename to cli/template/extras/fmaddon-auth/app/auth/verify-email/schema.ts diff --git a/cli/template/extras/proofkit-auth/components/auth/actions.ts b/cli/template/extras/fmaddon-auth/components/auth/actions.ts similarity index 100% rename from cli/template/extras/proofkit-auth/components/auth/actions.ts rename to cli/template/extras/fmaddon-auth/components/auth/actions.ts diff --git a/cli/template/extras/proofkit-auth/components/auth/protect.tsx b/cli/template/extras/fmaddon-auth/components/auth/protect.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/components/auth/protect.tsx rename to cli/template/extras/fmaddon-auth/components/auth/protect.tsx diff --git a/cli/template/extras/proofkit-auth/components/auth/redirect.tsx b/cli/template/extras/fmaddon-auth/components/auth/redirect.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/components/auth/redirect.tsx rename to cli/template/extras/fmaddon-auth/components/auth/redirect.tsx diff --git a/cli/template/extras/proofkit-auth/components/auth/use-user.ts b/cli/template/extras/fmaddon-auth/components/auth/use-user.ts similarity index 100% rename from cli/template/extras/proofkit-auth/components/auth/use-user.ts rename to cli/template/extras/fmaddon-auth/components/auth/use-user.ts diff --git a/cli/template/extras/proofkit-auth/components/auth/user-menu.tsx b/cli/template/extras/fmaddon-auth/components/auth/user-menu.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/components/auth/user-menu.tsx rename to cli/template/extras/fmaddon-auth/components/auth/user-menu.tsx diff --git a/cli/template/extras/proofkit-auth/emails/auth-code.tsx b/cli/template/extras/fmaddon-auth/emails/auth-code.tsx similarity index 100% rename from cli/template/extras/proofkit-auth/emails/auth-code.tsx rename to cli/template/extras/fmaddon-auth/emails/auth-code.tsx diff --git a/cli/template/extras/proofkit-auth/middleware.ts b/cli/template/extras/fmaddon-auth/middleware.ts similarity index 100% rename from cli/template/extras/proofkit-auth/middleware.ts rename to cli/template/extras/fmaddon-auth/middleware.ts diff --git a/cli/template/extras/proofkit-auth/server/auth/utils/email-verification.ts b/cli/template/extras/fmaddon-auth/server/auth/utils/email-verification.ts similarity index 100% rename from cli/template/extras/proofkit-auth/server/auth/utils/email-verification.ts rename to cli/template/extras/fmaddon-auth/server/auth/utils/email-verification.ts diff --git a/cli/template/extras/proofkit-auth/server/auth/utils/encryption.ts b/cli/template/extras/fmaddon-auth/server/auth/utils/encryption.ts similarity index 100% rename from cli/template/extras/proofkit-auth/server/auth/utils/encryption.ts rename to cli/template/extras/fmaddon-auth/server/auth/utils/encryption.ts diff --git a/cli/template/extras/proofkit-auth/server/auth/utils/index.ts b/cli/template/extras/fmaddon-auth/server/auth/utils/index.ts similarity index 100% rename from cli/template/extras/proofkit-auth/server/auth/utils/index.ts rename to cli/template/extras/fmaddon-auth/server/auth/utils/index.ts diff --git a/cli/template/extras/proofkit-auth/server/auth/utils/password-reset.ts b/cli/template/extras/fmaddon-auth/server/auth/utils/password-reset.ts similarity index 100% rename from cli/template/extras/proofkit-auth/server/auth/utils/password-reset.ts rename to cli/template/extras/fmaddon-auth/server/auth/utils/password-reset.ts diff --git a/cli/template/extras/proofkit-auth/server/auth/utils/password.ts b/cli/template/extras/fmaddon-auth/server/auth/utils/password.ts similarity index 100% rename from cli/template/extras/proofkit-auth/server/auth/utils/password.ts rename to cli/template/extras/fmaddon-auth/server/auth/utils/password.ts diff --git a/cli/template/extras/proofkit-auth/server/auth/utils/redirect.ts b/cli/template/extras/fmaddon-auth/server/auth/utils/redirect.ts similarity index 100% rename from cli/template/extras/proofkit-auth/server/auth/utils/redirect.ts rename to cli/template/extras/fmaddon-auth/server/auth/utils/redirect.ts diff --git a/cli/template/extras/proofkit-auth/server/auth/utils/session.ts b/cli/template/extras/fmaddon-auth/server/auth/utils/session.ts similarity index 100% rename from cli/template/extras/proofkit-auth/server/auth/utils/session.ts rename to cli/template/extras/fmaddon-auth/server/auth/utils/session.ts diff --git a/cli/template/extras/proofkit-auth/server/auth/utils/user.ts b/cli/template/extras/fmaddon-auth/server/auth/utils/user.ts similarity index 100% rename from cli/template/extras/proofkit-auth/server/auth/utils/user.ts rename to cli/template/extras/fmaddon-auth/server/auth/utils/user.ts diff --git a/cli/template/fm-addon/ProofKitAuth/de.xml b/cli/template/fm-addon/ProofKitAuth/de.xml index 90f4cef1..5df205c4 100644 --- a/cli/template/fm-addon/ProofKitAuth/de.xml +++ b/cli/template/fm-addon/ProofKitAuth/de.xml @@ -162,9 +162,9 @@ com.fmi.calculation.text.1F27E3E6452F6E3D407EC45CDFF933C3 - https://proofkit.dev/auth/proofkit/ - https://proofkit.dev/auth/proofkit/ - com.fmi.calculation.text.https://proofkit.dev/auth/proofkit/ + https://proofkit.dev/auth/fm-addon/ + https://proofkit.dev/auth/fm-addon/ + com.fmi.calculation.text.https://proofkit.dev/auth/fm-addon/ diff --git a/cli/template/fm-addon/ProofKitAuth/en.xml b/cli/template/fm-addon/ProofKitAuth/en.xml index 90f4cef1..5df205c4 100644 --- a/cli/template/fm-addon/ProofKitAuth/en.xml +++ b/cli/template/fm-addon/ProofKitAuth/en.xml @@ -162,9 +162,9 @@ com.fmi.calculation.text.1F27E3E6452F6E3D407EC45CDFF933C3 - https://proofkit.dev/auth/proofkit/ - https://proofkit.dev/auth/proofkit/ - com.fmi.calculation.text.https://proofkit.dev/auth/proofkit/ + https://proofkit.dev/auth/fm-addon/ + https://proofkit.dev/auth/fm-addon/ + com.fmi.calculation.text.https://proofkit.dev/auth/fm-addon/ diff --git a/cli/template/fm-addon/ProofKitAuth/es.xml b/cli/template/fm-addon/ProofKitAuth/es.xml index 90f4cef1..5df205c4 100644 --- a/cli/template/fm-addon/ProofKitAuth/es.xml +++ b/cli/template/fm-addon/ProofKitAuth/es.xml @@ -162,9 +162,9 @@ com.fmi.calculation.text.1F27E3E6452F6E3D407EC45CDFF933C3 - https://proofkit.dev/auth/proofkit/ - https://proofkit.dev/auth/proofkit/ - com.fmi.calculation.text.https://proofkit.dev/auth/proofkit/ + https://proofkit.dev/auth/fm-addon/ + https://proofkit.dev/auth/fm-addon/ + com.fmi.calculation.text.https://proofkit.dev/auth/fm-addon/ diff --git a/cli/template/fm-addon/ProofKitAuth/fr.xml b/cli/template/fm-addon/ProofKitAuth/fr.xml index 90f4cef1..5df205c4 100644 --- a/cli/template/fm-addon/ProofKitAuth/fr.xml +++ b/cli/template/fm-addon/ProofKitAuth/fr.xml @@ -162,9 +162,9 @@ com.fmi.calculation.text.1F27E3E6452F6E3D407EC45CDFF933C3 - https://proofkit.dev/auth/proofkit/ - https://proofkit.dev/auth/proofkit/ - com.fmi.calculation.text.https://proofkit.dev/auth/proofkit/ + https://proofkit.dev/auth/fm-addon/ + https://proofkit.dev/auth/fm-addon/ + com.fmi.calculation.text.https://proofkit.dev/auth/fm-addon/ diff --git a/cli/template/fm-addon/ProofKitAuth/info.json b/cli/template/fm-addon/ProofKitAuth/info.json index 7e00efee..4e283be8 100644 --- a/cli/template/fm-addon/ProofKitAuth/info.json +++ b/cli/template/fm-addon/ProofKitAuth/info.json @@ -5,7 +5,7 @@ "ProofKit" ], "Attribution" : "Proof+Geist", - "URL" : "https://proofkit.dev", + "URL" : "https://proofkit.dev/auth/fm-addon", "Icon_Color" : "#7F7F7F", "Version" : "1.0" } diff --git a/cli/template/fm-addon/ProofKitAuth/info_de.json b/cli/template/fm-addon/ProofKitAuth/info_de.json index b7dc5b87..d78faede 100644 --- a/cli/template/fm-addon/ProofKitAuth/info_de.json +++ b/cli/template/fm-addon/ProofKitAuth/info_de.json @@ -1,5 +1,5 @@ { - "Title" : "ProofKit Auth", + "Title" : "FileMaker Add-on Auth", "Description" : "*** DESCRIPTION MISSING *** - DNL", diff --git a/cli/template/fm-addon/ProofKitAuth/info_en.json b/cli/template/fm-addon/ProofKitAuth/info_en.json index 5c440965..d9a26675 100644 --- a/cli/template/fm-addon/ProofKitAuth/info_en.json +++ b/cli/template/fm-addon/ProofKitAuth/info_en.json @@ -1,11 +1,7 @@ { - "Title": "ProofKit Auth", - "Description": "ProofKit Auth - User authentication with ProofKit Web apps", - "Category": "Web", - "Features": [], - "Optimized": [ - "Desktop", - "Tablet", - "Mobile" - ] + "Title": "FileMaker Add-on Auth", + "Description": "FileMaker Add-on Auth - User authentication with FileMaker web apps", + "Version": "1.0", + "Type": "fmaddon", + "RequiredFMPVersion": "20.0.0" } diff --git a/cli/template/fm-addon/ProofKitAuth/info_es.json b/cli/template/fm-addon/ProofKitAuth/info_es.json index b7dc5b87..bcfd5b62 100644 --- a/cli/template/fm-addon/ProofKitAuth/info_es.json +++ b/cli/template/fm-addon/ProofKitAuth/info_es.json @@ -1,5 +1,5 @@ { - "Title" : "ProofKit Auth", + "Title" : "FileMaker Add-on Auth", "Description" : "*** DESCRIPTION MISSING *** - DNL", @@ -8,7 +8,7 @@ "Features" : [ - ], + ], "Optimized" : [ diff --git a/cli/template/fm-addon/ProofKitAuth/info_fr.json b/cli/template/fm-addon/ProofKitAuth/info_fr.json index bd4b0287..d78faede 100644 --- a/cli/template/fm-addon/ProofKitAuth/info_fr.json +++ b/cli/template/fm-addon/ProofKitAuth/info_fr.json @@ -1,5 +1,5 @@ { - "Title" : "ProofKitAuth", + "Title" : "FileMaker Add-on Auth", "Description" : "*** DESCRIPTION MISSING *** - DNL", diff --git a/cli/template/fm-addon/ProofKitAuth/info_it.json b/cli/template/fm-addon/ProofKitAuth/info_it.json index bd4b0287..d78faede 100644 --- a/cli/template/fm-addon/ProofKitAuth/info_it.json +++ b/cli/template/fm-addon/ProofKitAuth/info_it.json @@ -1,5 +1,5 @@ { - "Title" : "ProofKitAuth", + "Title" : "FileMaker Add-on Auth", "Description" : "*** DESCRIPTION MISSING *** - DNL", diff --git a/cli/template/fm-addon/ProofKitAuth/info_ja.json b/cli/template/fm-addon/ProofKitAuth/info_ja.json index bd4b0287..d78faede 100644 --- a/cli/template/fm-addon/ProofKitAuth/info_ja.json +++ b/cli/template/fm-addon/ProofKitAuth/info_ja.json @@ -1,5 +1,5 @@ { - "Title" : "ProofKitAuth", + "Title" : "FileMaker Add-on Auth", "Description" : "*** DESCRIPTION MISSING *** - DNL", diff --git a/cli/template/fm-addon/ProofKitAuth/info_ko.json b/cli/template/fm-addon/ProofKitAuth/info_ko.json index bd4b0287..d78faede 100644 --- a/cli/template/fm-addon/ProofKitAuth/info_ko.json +++ b/cli/template/fm-addon/ProofKitAuth/info_ko.json @@ -1,5 +1,5 @@ { - "Title" : "ProofKitAuth", + "Title" : "FileMaker Add-on Auth", "Description" : "*** DESCRIPTION MISSING *** - DNL", diff --git a/cli/template/fm-addon/ProofKitAuth/info_nl.json b/cli/template/fm-addon/ProofKitAuth/info_nl.json index bd4b0287..d78faede 100644 --- a/cli/template/fm-addon/ProofKitAuth/info_nl.json +++ b/cli/template/fm-addon/ProofKitAuth/info_nl.json @@ -1,5 +1,5 @@ { - "Title" : "ProofKitAuth", + "Title" : "FileMaker Add-on Auth", "Description" : "*** DESCRIPTION MISSING *** - DNL", diff --git a/cli/template/fm-addon/ProofKitAuth/info_pt.json b/cli/template/fm-addon/ProofKitAuth/info_pt.json index bd4b0287..d78faede 100644 --- a/cli/template/fm-addon/ProofKitAuth/info_pt.json +++ b/cli/template/fm-addon/ProofKitAuth/info_pt.json @@ -1,5 +1,5 @@ { - "Title" : "ProofKitAuth", + "Title" : "FileMaker Add-on Auth", "Description" : "*** DESCRIPTION MISSING *** - DNL", diff --git a/cli/template/fm-addon/ProofKitAuth/info_sv.json b/cli/template/fm-addon/ProofKitAuth/info_sv.json index bd4b0287..d78faede 100644 --- a/cli/template/fm-addon/ProofKitAuth/info_sv.json +++ b/cli/template/fm-addon/ProofKitAuth/info_sv.json @@ -1,5 +1,5 @@ { - "Title" : "ProofKitAuth", + "Title" : "FileMaker Add-on Auth", "Description" : "*** DESCRIPTION MISSING *** - DNL", diff --git a/cli/template/fm-addon/ProofKitAuth/info_zh.json b/cli/template/fm-addon/ProofKitAuth/info_zh.json index bd4b0287..d78faede 100644 --- a/cli/template/fm-addon/ProofKitAuth/info_zh.json +++ b/cli/template/fm-addon/ProofKitAuth/info_zh.json @@ -1,5 +1,5 @@ { - "Title" : "ProofKitAuth", + "Title" : "FileMaker Add-on Auth", "Description" : "*** DESCRIPTION MISSING *** - DNL", diff --git a/cli/template/fm-addon/ProofKitAuth/it.xml b/cli/template/fm-addon/ProofKitAuth/it.xml index 90f4cef1..5df205c4 100644 --- a/cli/template/fm-addon/ProofKitAuth/it.xml +++ b/cli/template/fm-addon/ProofKitAuth/it.xml @@ -162,9 +162,9 @@ com.fmi.calculation.text.1F27E3E6452F6E3D407EC45CDFF933C3 - https://proofkit.dev/auth/proofkit/ - https://proofkit.dev/auth/proofkit/ - com.fmi.calculation.text.https://proofkit.dev/auth/proofkit/ + https://proofkit.dev/auth/fm-addon/ + https://proofkit.dev/auth/fm-addon/ + com.fmi.calculation.text.https://proofkit.dev/auth/fm-addon/ diff --git a/cli/template/fm-addon/ProofKitAuth/ja.xml b/cli/template/fm-addon/ProofKitAuth/ja.xml index 90f4cef1..5df205c4 100644 --- a/cli/template/fm-addon/ProofKitAuth/ja.xml +++ b/cli/template/fm-addon/ProofKitAuth/ja.xml @@ -162,9 +162,9 @@ com.fmi.calculation.text.1F27E3E6452F6E3D407EC45CDFF933C3 - https://proofkit.dev/auth/proofkit/ - https://proofkit.dev/auth/proofkit/ - com.fmi.calculation.text.https://proofkit.dev/auth/proofkit/ + https://proofkit.dev/auth/fm-addon/ + https://proofkit.dev/auth/fm-addon/ + com.fmi.calculation.text.https://proofkit.dev/auth/fm-addon/ diff --git a/cli/template/fm-addon/ProofKitAuth/ko.xml b/cli/template/fm-addon/ProofKitAuth/ko.xml index 90f4cef1..5df205c4 100644 --- a/cli/template/fm-addon/ProofKitAuth/ko.xml +++ b/cli/template/fm-addon/ProofKitAuth/ko.xml @@ -162,9 +162,9 @@ com.fmi.calculation.text.1F27E3E6452F6E3D407EC45CDFF933C3 - https://proofkit.dev/auth/proofkit/ - https://proofkit.dev/auth/proofkit/ - com.fmi.calculation.text.https://proofkit.dev/auth/proofkit/ + https://proofkit.dev/auth/fm-addon/ + https://proofkit.dev/auth/fm-addon/ + com.fmi.calculation.text.https://proofkit.dev/auth/fm-addon/ diff --git a/cli/template/fm-addon/ProofKitAuth/nl.xml b/cli/template/fm-addon/ProofKitAuth/nl.xml index 90f4cef1..5df205c4 100644 --- a/cli/template/fm-addon/ProofKitAuth/nl.xml +++ b/cli/template/fm-addon/ProofKitAuth/nl.xml @@ -162,9 +162,9 @@ com.fmi.calculation.text.1F27E3E6452F6E3D407EC45CDFF933C3 - https://proofkit.dev/auth/proofkit/ - https://proofkit.dev/auth/proofkit/ - com.fmi.calculation.text.https://proofkit.dev/auth/proofkit/ + https://proofkit.dev/auth/fm-addon/ + https://proofkit.dev/auth/fm-addon/ + com.fmi.calculation.text.https://proofkit.dev/auth/fm-addon/ diff --git a/cli/template/fm-addon/ProofKitAuth/pt.xml b/cli/template/fm-addon/ProofKitAuth/pt.xml index 90f4cef1..5df205c4 100644 --- a/cli/template/fm-addon/ProofKitAuth/pt.xml +++ b/cli/template/fm-addon/ProofKitAuth/pt.xml @@ -162,9 +162,9 @@ com.fmi.calculation.text.1F27E3E6452F6E3D407EC45CDFF933C3 - https://proofkit.dev/auth/proofkit/ - https://proofkit.dev/auth/proofkit/ - com.fmi.calculation.text.https://proofkit.dev/auth/proofkit/ + https://proofkit.dev/auth/fm-addon/ + https://proofkit.dev/auth/fm-addon/ + com.fmi.calculation.text.https://proofkit.dev/auth/fm-addon/ diff --git a/cli/template/fm-addon/ProofKitAuth/sv.xml b/cli/template/fm-addon/ProofKitAuth/sv.xml index 90f4cef1..5df205c4 100644 --- a/cli/template/fm-addon/ProofKitAuth/sv.xml +++ b/cli/template/fm-addon/ProofKitAuth/sv.xml @@ -162,9 +162,9 @@ com.fmi.calculation.text.1F27E3E6452F6E3D407EC45CDFF933C3 - https://proofkit.dev/auth/proofkit/ - https://proofkit.dev/auth/proofkit/ - com.fmi.calculation.text.https://proofkit.dev/auth/proofkit/ + https://proofkit.dev/auth/fm-addon/ + https://proofkit.dev/auth/fm-addon/ + com.fmi.calculation.text.https://proofkit.dev/auth/fm-addon/ diff --git a/cli/template/fm-addon/ProofKitAuth/zh.xml b/cli/template/fm-addon/ProofKitAuth/zh.xml index 90f4cef1..5df205c4 100644 --- a/cli/template/fm-addon/ProofKitAuth/zh.xml +++ b/cli/template/fm-addon/ProofKitAuth/zh.xml @@ -162,9 +162,9 @@ com.fmi.calculation.text.1F27E3E6452F6E3D407EC45CDFF933C3 - https://proofkit.dev/auth/proofkit/ - https://proofkit.dev/auth/proofkit/ - com.fmi.calculation.text.https://proofkit.dev/auth/proofkit/ + https://proofkit.dev/auth/fm-addon/ + https://proofkit.dev/auth/fm-addon/ + com.fmi.calculation.text.https://proofkit.dev/auth/fm-addon/ diff --git a/docs/astro.config.mjs b/docs/astro.config.mjs index db777bef..d37cb350 100644 --- a/docs/astro.config.mjs +++ b/docs/astro.config.mjs @@ -35,6 +35,9 @@ export default defineConfig({ }), react(), ], + redirects: { + "/auth/proofkit": "/auth/fm-addon", + }, output: "server", adapter: vercel(), diff --git a/docs/src/content/docs/auth/proofkit.mdx b/docs/src/content/docs/auth/fm-addon.mdx similarity index 52% rename from docs/src/content/docs/auth/proofkit.mdx rename to docs/src/content/docs/auth/fm-addon.mdx index e5e5fbb7..29e427dd 100644 --- a/docs/src/content/docs/auth/proofkit.mdx +++ b/docs/src/content/docs/auth/fm-addon.mdx @@ -1,37 +1,37 @@ --- -title: ProofKit Auth -description: How to add ProofKit Auth to your FileMaker file +title: FileMaker Add-on Auth +description: How to add FileMaker Add-on Auth to your FileMaker file sidebar: order: 1 --- import CliCommand from "../../../components/CliCommand.astro"; -ProofKit Auth is a self-hosted authentication solution that is built to be flexible and easy to customize. Rather than using a third-party library or authentication service, the ProofKit CLI installs all of the necessary functions into your project and then you just have to install the ProofKit Auth addon in your FileMaker file to get the necessary tables in your database. +ProofKit includes a self-hosted authentication solution that is built to be flexible and easy to customize. Rather than using a third-party library or authentication service, the ProofKit CLI installs all of the necessary functions into your project and then you just have to install the FileMaker add-on in your FileMaker file to get the necessary tables in your database. -While ProofKit Auth is built to be secure, it is more advanced than a typical third-party authentication service and does warrant a good understanding of how it works before you customize it. For more details about the security principles behind it, see the [Lucia documentation](https://lucia-auth.com/). +While FileMaker Add-on Auth is built to be secure, it is more advanced than a typical third-party authentication service and does warrant a good understanding of how it works before you customize it beyond the default settings. For more details about the security principles behind it, see the [Lucia documentation](https://lucia-auth.com/). ## Installing From within a ProofKit project, run the following command: - + -ProofKit Auth requires that some specific tables and layouts exist in your FileMaker file. The CLI will detect if these layouts and not in your file, and notify you to install the ProofKit Auth addon if they are missing. The FileMaker addon encapsulates all of the changes needed and makes it easy to add the requirements to your file. +This auth integration requires that some specific tables and layouts exist in your FileMaker file. The CLI will detect if these layouts and not in your file, and notify you to install the FileMaker Add-on if they are missing. The FileMaker Add-on encapsulates all of the changes needed and makes it easy to add the requirements to your file. -To easily install the addon, enter Layout mode on any layout and open the "Add-ons" tab in the left pane. Click the + icon in the lower left corner, then select the "ProofKit Auth" addon from the list. +To easily install the add-on, enter Layout mode on any layout and open the "Add-ons" tab in the left pane. Click the + icon in the lower left corner, then select the "ProofKit Auth" add-on from the list. :::caution[Troubleshooting] -If you don't see the addon after installing ProofKit Auth from the CLI, quit and re-open FileMaker Pro. +If you don't see the add-on after installing FileMaker Add-on Auth from the CLI, quit and re-open FileMaker Pro. ::: -After you install the addon for the first time, make sure you re-run the `typegen` command to add the types in your project. +After you install the add-on for the first time, make sure you re-run the `typegen` command to add the types in your project. ## Email Verification Setup -By default, ProofKit Auth works with an email/password based login and asks users to verify their email address when they change their email and when they first sign up. However, you must implement the email sending functionality with the third-party service of your choice. If you skipped the email provider question during the setup, the email verification codes will be displayed in the terminal of your running dev server for your testing. +By default, FileMaker Add-on Auth works with an email/password based login and asks users to verify their email address when they change their email and when they first sign up. However, you must implement the email sending functionality with the third-party service of your choice. If you skipped the email provider question during the setup, the email verification codes will be displayed in the terminal of your running dev server for your testing. To customize the email sent to your users, edit the `src/server/auth/email.tsx` file. The actual email is rendered to HTML using the [React Email](https://react.email/docs/introduction) library and can be sent with any email service you choose, but ProofKit has built-in support for [Resend](https://resend.com/) and [Plunk](https://www.useplunk.com/). @@ -40,18 +40,18 @@ To customize the email sent to your users, edit the `src/server/auth/email.tsx` ## Customizing :::danger[Security Considerations] -Make sure you fully understand the security implications of any changes you make to the ProofKit Auth code. For a full guide to the security principles behind it, see the [Lucia documentation](https://lucia-auth.com/) and [The Copenhagen Book](https://thecopenhagenbook.com/). +Make sure you fully understand the security implications of any changes you make to the FileMaker Add-on Auth code. For a full guide to the security principles behind it, see the [Lucia documentation](https://lucia-auth.com/) and [The Copenhagen Book](https://thecopenhagenbook.com/). ::: -Once the addon is installed in your FileMaker file, you can customize the tables and layouts to better fit your solution. For example, if you already have a users table, you may wish to use that instead of the new one created by the addon. +Once the add-on is installed in your FileMaker file, you can customize the tables and layouts to better fit your solution. For example, if you already have a users table, you may wish to use that instead of the new one created by the add-on. -The easiest way to customize is to use the tables from ProofKit Auth and create a one-to-one relationship with your existing table(s). You can also add new fields to the ProofKit tables to extend their functionality. +The easiest way to customize is to use the tables from FileMaker Add-on and create a one-to-one relationship with your existing table(s). You can also add new fields to the FileMaker Add-on tables to extend their functionality. After you've made your modifications, run the `typegen` command again to update the types in your project. -Then, we suggest running the `tsc` command to check for any errors in the ProofKit Auth code. +Then, we suggest running the `tsc` command to check for any errors in the FileMaker Add-on Auth code. @@ -73,7 +73,7 @@ By default, the layout for the session table should be named `proofkit_auth_sess ### Users Table -This table store information about a user's account, including their email address, email verification status, and password hash. You should be careful to never expose the password hash to the client, nor query this layout directly outside of the provided ProofKit Auth functions. +This table store information about a user's account, including their email address, email verification status, and password hash. You should be careful to never expose the password hash to the client, nor query this layout directly outside of the provided FileMaker Add-on Auth functions. By default, the layout for the users table should be named `proofkit_auth_users` but this can be customized in the fmschema.config.mjs file. @@ -91,4 +91,4 @@ By default, the layout for the password reset table should be named `proofkit_au ### Alternative Authentication Methods -At this time, ProofKit Auth will only setup email/password authentication for you, but any other authentication methods can be added by modifying the code yourself. Guides for integrating OAuth providers, passkeys (WebAuthn), two-factor, and more are available in the [Lucia documentation](https://lucia-auth.com/). Just keep in mind that you'll likely need to add more fields to the tables and layouts as mentioned above to support those additional features. +At this time, FileMaker Add-on Auth will only setup email/password authentication for you, but any other authentication methods can be added by modifying the code yourself. Guides for integrating OAuth providers, passkeys (WebAuthn), two-factor, and more are available in the [Lucia documentation](https://lucia-auth.com/). Just keep in mind that you'll likely need to add more fields to the tables and layouts as mentioned above to support those additional features. diff --git a/docs/src/content/docs/webviewer/getting-started.mdx b/docs/src/content/docs/webviewer/getting-started.mdx index 739ef797..b29ed584 100644 --- a/docs/src/content/docs/webviewer/getting-started.mdx +++ b/docs/src/content/docs/webviewer/getting-started.mdx @@ -42,10 +42,10 @@ Refer to the [main Getting Started guide](/guides/getting-started) for more deta The ProofKit CLI will automatically install the ProofKit WebViewer to your computer, but you must install it into your FileMaker file to receive the necessary tables, layouts, and scripts. -To easily install the addon, enter Layout mode on any layout and open the "Add-ons" tab in the left pane. Click the + icon in the lower left corner, then select the "ProofKit Auth" addon from the list. +To easily install the add-on, enter Layout mode on any layout and open the "Add-ons" tab in the left pane. Click the + icon in the lower left corner, then select the "ProofKit Auth" add-on from the list. :::caution[Troubleshooting] -If you don't see the addon after initialing your project with the CLI, quit and re-open FileMaker Pro. +If you don't see the add-on after initialing your project with the CLI, quit and re-open FileMaker Pro. ::: ## Developing with the WebViewer