Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
70 changes: 70 additions & 0 deletions .github/workflows/docs-js-libs-update.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
name: Update JS Client Libraries Docs

on:
workflow_dispatch:
inputs:
version:
description: "Version that was released (e.g., patch, minor, major, or v2.1.0)"
required: true
type: string
source:
description: "Source of the documentation update"
required: false
type: string
default: "manual"

permissions:
pull-requests: write
contents: write

jobs:
update-docs:
runs-on: blacksmith-4vcpu-ubuntu-2404

steps:
- uses: actions/checkout@v4
with:
ref: master
sparse-checkout: |
apps/docs

- uses: pnpm/action-setup@v4
name: Install pnpm
with:
run_install: false

- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: "pnpm"

- name: Install deps
run: pnpm i

- name: Regenerate JS client libraries tsdoc files
working-directory: apps/docs/spec
run: |
echo "Regenerating tsdoc files for JS client libraries..."
echo "Source: ${{ github.event.inputs.source }}"
echo "Version: ${{ github.event.inputs.version }}"
make

- name: Create pull request
uses: peter-evans/create-pull-request@v6
with:
token: ${{ secrets.GITHUB_TOKEN }}
commit-message: "docs: update js client libraries (${{ github.event.inputs.version }})"
title: "docs: update js client libraries (${{ github.event.inputs.version }})"
body: |
Updates JS client libraries documentation following stable release.
Ran `make` in apps/docs/spec to regenerate tsdoc files.

**Details:**
- **Version:** `${{ github.event.inputs.version }}`
- **Source:** `${{ github.event.inputs.source }}`
- **Changes:** Regenerated tsdoc files from latest spec files

🤖 Auto-generated from supabase-js-libs stable release.
branch: "gha/update-js-libs-docs-${{ github.run_number }}"
base: "master"
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { yupResolver } from '@hookform/resolvers/yup'
import { PermissionAction } from '@supabase/shared-types/out/constants'
import { Eye, EyeOff } from 'lucide-react'
import Link from 'next/link'
import { useEffect, useState } from 'react'
import { useForm } from 'react-hook-form'
import { toast } from 'sonner'
Expand All @@ -18,6 +19,7 @@ import {
AlertDescription_Shadcn_,
AlertTitle_Shadcn_,
Alert_Shadcn_,
Badge,
Button,
Card,
CardContent,
Expand Down Expand Up @@ -267,6 +269,29 @@ export const ProtectionAuthSettingsForm = () => {
</>
)}

<CardContent>
<FormField_Shadcn_
control={protectionForm.control}
name="PASSWORD_HIBP_ENABLED"
render={({ field }) => (
<FormItemLayout
layout="flex-row-reverse"
label="Prevent use of leaked passwords"
description="Rejects the use of known or easy to guess passwords on sign up or password change. "
>
<div className="flex items-center gap-2">
<Badge variant={field.value ? 'success' : 'default'}>
{field.value ? 'Enabled' : 'Disabled'}
</Badge>
<Link href={`/project/${projectRef}/auth/providers?provider=Email`}>
<Button type="default">Configure email provider</Button>
</Link>
</div>
</FormItemLayout>
)}
/>
</CardContent>

<CardFooter className="justify-end space-x-2">
{protectionForm.formState.isDirty && (
<Button type="default" onClick={() => protectionForm.reset()}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,8 @@ export const DecryptedReadOnlyInput = ({
return (
<Input
readOnly
copy
// If the value is secure, allow copying to clipboard if the value is revealed. Otherwise, always allow copying
copy={!secureEntry || (!isDecryptedValueLoading && showHidden)}
disabled
label={
<div className="flex items-center gap-x-2">
Expand Down
Loading