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
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"build:backends": "dash-generate-components ./src/ts/components dash_auth_plus_components -p package-info.json --jl-prefix 'components' --ignore \\.test\\.",
"build": "npm run build:js && npm run build:backends && npm run build:fix-n-copy && npm run build:cleanup",
"build:js": "webpack --mode production",
"build:fix-n-copy": "black dash_auth_plus_components/*.py && cpy dash_auth_plus_components/* dash_auth_plus/DashAuthComponents",
"build:fix-n-copy": "black dash_auth_plus_components/*.py && cpy dash_auth_plus_components/* dash_auth_plus/DashAuthComponents --flat",
"build:cleanup": "mv dash_auth_plus_components/package-info.json dash_auth_plus/ && rimraf dash_auth_plus_components"
},
"author": "Bryan Schroeder <bryan.ri.schroeder@gmail.com>",
Expand Down
6 changes: 3 additions & 3 deletions src/ts/components/ClerkProvider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const themes = {
};

export interface ClerkProviderProps {
PUBLISHABLE_KEY: string;
publishableKey: string;
afterSignOutUrl?: string;
children: React.ReactNode;
themeName?: string;
Expand All @@ -18,7 +18,7 @@ export interface ClerkProviderProps {


const ClerkProvider: React.FC<PropsWithChildren<ClerkProviderProps>> = ({
PUBLISHABLE_KEY,
publishableKey,
afterSignOutUrl,
children,
themeName,
Expand All @@ -32,7 +32,7 @@ const ClerkProvider: React.FC<PropsWithChildren<ClerkProviderProps>> = ({

return (
<ClerkClerkProvider
publishableKey={PUBLISHABLE_KEY}
publishableKey={publishableKey}
afterSignOutUrl={afterSignOutUrl}
appearance={appearance}
{...others}
Expand Down
6 changes: 5 additions & 1 deletion tests/test_clerk_auth.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from selenium.webdriver.common.keys import Keys
from dash import Dash, html, dcc, page_container
from dash_auth_plus import ClerkAuth
from dash_auth_plus import ClerkAuth, DashAuthComponents
import os
import pytest

Expand All @@ -21,6 +21,10 @@ def spinup_app():

app.layout = html.Div(
[
DashAuthComponents.ClerkProvider(
[],
publishableKey=os.getenv("CLERK_PUBLISHABLE_KEY")
),
html.Div(
[
dcc.Link("Home", href="/"),
Expand Down