Skip to content

Commit 6f69985

Browse files
committed
add link to one-tap example and remove client id
1 parent a366de0 commit 6f69985

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

examples/google_one_tap_auth/main.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
# For local development, you should add http://localhost:8080 to the authorized JavaScript origins.
1010
# In production, you should add the domain of your website to the authorized JavaScript origins.
1111
# See https://developers.google.com/identity/gsi/web/guides/get-google-api-clientid#get_your_google_api_client_id.
12-
GOOGLE_CLIENT_ID = '484798726913-t4es9ner8aglom3miptbnq1m23dsqagi.apps.googleusercontent.com'
12+
GOOGLE_CLIENT_ID = '...'
1313

1414

1515
@ui.page('/')

website/examples.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ class Example:
1313

1414
def __post_init__(self) -> None:
1515
"""Post-initialization hook."""
16-
name = self.title.lower().replace(' ', '_')
16+
name = self.title.lower().replace(' ', '_').replace('-', '_')
1717
content = [p for p in (PATH / name).glob('*') if not p.name.startswith(('__pycache__', '.', 'test_'))]
1818
filename = 'main.py' if len(content) == 1 else ''
1919
self.url = f'https://github.com/zauberzeug/nicegui/tree/main/examples/{name}/{filename}'
@@ -71,4 +71,5 @@ def __post_init__(self) -> None:
7171
Example('Signature Pad', 'A custom element based on [signature_pad](https://www.npmjs.com/package/signature_pad'),
7272
Example('OpenAI Assistant', "Using OpenAI's Assistant API with async/await"),
7373
Example('Redis Storage', 'Use Redis storage to share data across multiple instances behind a reverse proxy or load balancer'),
74+
Example('Google One-Tap Auth', 'Authenticate users via Google One-Tap'),
7475
]

0 commit comments

Comments
 (0)