Skip to content

Commit 6637d8d

Browse files
Apply just-the-docs theme for docs-site
1 parent 6ecd840 commit 6637d8d

File tree

8 files changed

+218
-59
lines changed

8 files changed

+218
-59
lines changed

.github/workflows/docs-site.yml

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
name: Deploy docs site
2+
3+
on:
4+
push:
5+
branches:
6+
- "main"
7+
paths:
8+
- "docs/**"
9+
10+
workflow_dispatch:
11+
12+
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
13+
permissions:
14+
contents: read
15+
pages: write
16+
id-token: write
17+
18+
# Allow one concurrent deployment
19+
concurrency:
20+
group: "pages"
21+
cancel-in-progress: true
22+
23+
jobs:
24+
build:
25+
runs-on: ubuntu-latest
26+
defaults:
27+
run:
28+
working-directory: docs
29+
steps:
30+
- name: Checkout
31+
uses: actions/checkout@v4
32+
- name: Setup Ruby
33+
uses: ruby/setup-ruby@v1
34+
with:
35+
ruby-version: '3.3' # Not needed with a .ruby-version file
36+
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
37+
cache-version: 0 # Increment this number if you need to re-download cached gems
38+
working-directory: '${{ github.workspace }}/docs'
39+
- name: Setup Pages
40+
id: pages
41+
uses: actions/configure-pages@v5
42+
- name: Build with Jekyll
43+
# Outputs to the './_site' directory by default
44+
run: bundle exec jekyll build --baseurl "${{ steps.pages.outputs.base_path }}"
45+
env:
46+
JEKYLL_ENV: production
47+
- name: Upload artifact
48+
# Automatically uploads an artifact from the './_site' directory by default
49+
uses: actions/upload-pages-artifact@v3
50+
with:
51+
path: docs/_site/
52+
53+
# Deployment job
54+
deploy:
55+
environment:
56+
name: github-pages
57+
url: ${{ steps.deployment.outputs.page_url }}
58+
runs-on: ubuntu-latest
59+
needs: build
60+
steps:
61+
- name: Deploy to GitHub Pages
62+
id: deployment
63+
uses: actions/deploy-pages@v4

docs/Gemfile

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
source 'https://rubygems.org'
2+
3+
gem "jekyll", "~> 4.4.1" # installed by `gem jekyll`
4+
# gem "webrick" # required when using Ruby >= 3 and Jekyll <= 4.2.2
5+
6+
gem "just-the-docs", "0.10.1" # pinned to the current release
7+
# gem "just-the-docs" # always download the latest release

docs/_config.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
title: Godot Firebase Android
2+
description: Documentation for the GodotFirebaseAndroid plugin
3+
theme: just-the-docs
4+
color_scheme: dark
5+
6+
url: https://syntaxerror247.github.io
7+
8+
aux_links:
9+
Plugin Repository: https://github.com/syntaxerror247/GodotFirebaseAndroid
10+
11+
# Footer content
12+
back_to_top: true
13+
back_to_top_text: "Back to top"
14+
15+
footer_content: 'Copyright &copy; 2025 Anish Mishra. Distributed by an <a href="https://github.com/syntaxerror247/GodotFirebaseAndroid/blob/main/LICENSE">MIT license.</a>'

docs/authentication.md

Lines changed: 47 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
---
2+
layout: default
3+
title: Authentication
4+
nav_order: 2
5+
---
6+
17
# Authentication
28

39
The Firebase Authentication module in **GodotFirebaseAndroid** supports anonymous login, email/password login, Google login, and account management. Each method emits signals to indicate success or failure.
@@ -7,7 +13,7 @@ The Firebase Authentication module in **GodotFirebaseAndroid** supports anonymou
713
- `auth_success(current_user_data: Dictionary)`
814
Emitted when a user successfully signs in. The dictionary contains user information such as UID, email, etc.
915

10-
- `auth_failure(error_mplugin.emitGodotSignal("realtime_db_value_changed", path, data)essage: String)`
16+
- `auth_failure(error_message: String)`
1117
Emitted when an authentication operation fails.
1218

1319
- `sign_out_success(success: bool)`
@@ -24,8 +30,11 @@ The Firebase Authentication module in **GodotFirebaseAndroid** supports anonymou
2430

2531
## Methods
2632

27-
### `sign_in_anonymously()`
33+
{: .text-green-100 }
34+
### sign_in_anonymously()
35+
2836
Signs in the user anonymously.
37+
2938
**Emits:** `auth_success` or `auth_failure`.
3039

3140
```gdscript
@@ -34,8 +43,11 @@ Firebase.auth.sign_in_anonymously()
3443

3544
---
3645

37-
### `create_user_with_email_password(email: String, password: String)`
46+
{: .text-green-100 }
47+
### create_user_with_email_password(email: String, password: String)
48+
3849
Creates a new user with the given email and password.
50+
3951
**Emits:** `auth_success` or `auth_failure`.
4052

4153
```gdscript
@@ -44,73 +56,95 @@ Firebase.auth.create_user_with_email_password("[email protected]", "password123
4456

4557
---
4658

47-
### `sign_in_with_email_password(email: String, password: String)`
59+
{: .text-green-100 }
60+
### sign_in_with_email_password(email: String, password: String)
61+
4862
Signs in a user using email and password credentials.
63+
4964
**Emits:** `auth_success` or `auth_failure`.
5065

5166
```gdscript
5267
Firebase.auth.sign_in_with_email_password("[email protected]", "password123")
5368
```
5469
---
5570

56-
### `send_password_reset_email(email: String)`
71+
{: .text-green-100 }
72+
### send_password_reset_email(email: String)
73+
5774
Sends a password reset email to the specified address.
75+
5876
**Emits:** `password_reset_sent`. It also emits `auth_failure` on failure.
5977

6078
```gdscript
6179
Firebase.auth.send_password_reset_email("[email protected]")
6280
```
6381
---
6482

65-
### `send_email_verification()`
83+
{: .text-green-100 }
84+
### send_email_verification()
85+
6686
Sends an email verification to the currently signed-in user.
87+
6788
**Emits:** `email_verification_sent`. It also emits `auth_failure` on failure.
6889

6990
```gdscript
7091
Firebase.auth.send_email_verification()
7192
```
7293
---
7394

74-
### `sign_in_with_google()`
95+
{: .text-green-100 }
96+
### sign_in_with_google()
97+
7598
Signs in the user using Google. Ensure Google Sign-In is properly configured in the Firebase console.
99+
76100
**Emits:** `auth_success` or `auth_failure`.
77101

78102
```gdscript
79103
Firebase.auth.sign_in_with_google()
80104
```
81105
---
82106

83-
### `get_current_user_data() -> Dictionary`
107+
{: .text-green-100 }
108+
### get_current_user_data() -> Dictionary
109+
84110
If no user is signed in, returns an dictionary with error.
111+
85112
**Returns** a dictionary containing the currently signed-in user's data.
86113

87114
```gdscript
88115
Firebase.auth.get_current_user_data()
89116
```
90117
---
91118

92-
### `delete_current_user()`
119+
{: .text-green-100 }
120+
### delete_current_user()
121+
93122
Deletes the currently signed-in user.
123+
94124
**Emits:** `user_deleted`. It also emits `auth_failure` on failure.
95125

96126
```gdscript
97127
Firebase.auth.delete_current_user()
98128
```
99129
---
100130

101-
### `is_signed_in() -> bool`
131+
{: .text-green-100 }
132+
### is_signed_in() -> bool
133+
102134
**Returns** `true` if a user is currently signed in, otherwise `false`.
103135

104136
```gdscript
105137
Firebase.auth.is_signed_in()
106138
```
107139
---
108140

109-
### `sign_out()`
110-
Signs out the current user.
141+
{: .text-green-100 }
142+
### sign_out()
143+
144+
Signs out the current user.
145+
111146
**Emits:** `sign_out_success`. It also emits `auth_failure` on failure.
112147

113148
```gdscript
114149
Firebase.auth.sign_out()
115150
```
116-
---

docs/firestore.md

Lines changed: 27 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,28 @@
1+
---
2+
layout: default
3+
title: Cloud Firestore
4+
nav_order: 3
5+
---
6+
17
# Cloud Firestore
28

39
The Cloud Firestore module in **GodotFirebaseAndroid** supports adding, retrieving, updating, and deleting documents, as well as listening for document changes.
410

511
## Signals
612

7-
-`write_task_completed(result: Dictionary)`
13+
- `write_task_completed(result: Dictionary)`
814
Emitted after adding or setting a document.
915

10-
-`get_task_completed(result: Dictionary)`
16+
- `get_task_completed(result: Dictionary)`
1117
Emitted after retrieving a document or a list of documents.
1218

13-
-`update_task_completed(result: Dictionary)`
19+
- `update_task_completed(result: Dictionary)`
1420
Emitted after updating a document.
1521

16-
-`delete_task_completed(result: Dictionary)`
22+
- `delete_task_completed(result: Dictionary)`
1723
Emitted after deleting a document.
1824

19-
-`document_changed(document_path: String, data: Dictionary)`
25+
- `document_changed(document_path: String, data: Dictionary)`
2026
Emitted when a listened document is changed.
2127

2228
**Note**: All signal result dictionaries contain the following keys:
@@ -31,7 +37,8 @@ The Cloud Firestore module in **GodotFirebaseAndroid** supports adding, retrievi
3137

3238
## Methods
3339

34-
### `add_document(collection: String, data: Dictionary)`
40+
{: .text-green-100 }
41+
### add_document(collection: String, data: Dictionary)
3542

3643
Adds a new document to the specified collection with an auto-generated ID.
3744
**Emits:** `write_task_completed`
@@ -42,7 +49,8 @@ Firebase.firestore.add_document("players", {"name": "Alice", "score": 100})
4249

4350
---
4451

45-
### `set_document(collection: String, documentId: String, data: Dictionary, merge: bool = false)`
52+
{: .text-green-100 }
53+
### set_document(collection: String, documentId: String, data: Dictionary, merge: bool = false)
4654

4755
Sets data for a document. If the document exists, it will be overwritten unless `merge` is `true`.
4856
**Emits:** `write_task_completed`
@@ -53,7 +61,8 @@ Firebase.firestore.set_document("players", "user_123", {"score": 150}, true)
5361

5462
---
5563

56-
### `get_document(collection: String, documentId: String)`
64+
{: .text-green-100 }
65+
### get_document(collection: String, documentId: String)
5766

5867
Retrieves a single document from the specified collection.
5968
**Emits:** `get_task_completed`
@@ -64,7 +73,8 @@ Firebase.firestore.get_document("players", "user_123")
6473

6574
---
6675

67-
### `get_documents_in_collection(collection: String)`
76+
{: .text-green-100 }
77+
### get_documents_in_collection(collection: String)
6878

6979
Retrieves all documents in a given collection.
7080
**Emits:** `get_task_completed`
@@ -75,7 +85,8 @@ Firebase.firestore.get_documents_in_collection("players")
7585

7686
---
7787

78-
### `update_document(collection: String, documentId: String, data: Dictionary)`
88+
{: .text-green-100 }
89+
### update_document(collection: String, documentId: String, data: Dictionary)
7990

8091
Updates fields in a document without overwriting the entire document.
8192
**Emits:** `update_task_completed`
@@ -86,7 +97,8 @@ Firebase.firestore.update_document("players", "user_123", {"score": 200})
8697

8798
---
8899

89-
### `delete_document(collection: String, documentId: String)`
100+
{: .text-green-100 }
101+
### `delete_document(collection: String, documentId: String)
90102

91103
Deletes a document from the specified collection.
92104
**Emits:** `delete_task_completed`
@@ -97,7 +109,8 @@ Firebase.firestore.delete_document("players", "user_123")
97109

98110
---
99111

100-
### `listen_to_document(documentPath: String)`
112+
{: .text-green-100 }
113+
### listen_to_document(documentPath: String)
101114

102115
Starts listening to changes on a specific document path.
103116
**Emits:** `document_changed`
@@ -108,7 +121,8 @@ Firebase.firestore.listen_to_document("players/user_123")
108121

109122
---
110123

111-
### `stop_listening_to_document(documentPath: String)`
124+
{: .text-green-100 }
125+
### stop_listening_to_document(documentPath: String)
112126

113127
Stops listening to changes for a document path.
114128

docs/index.md

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
---
2+
layout: default
3+
title: Firebase Android
4+
nav_order: 1
5+
---
6+
17
# GodotFirebaseAndroid
28

39
**GodotFirebaseAndroid** is an Android plugin for the Godot Engine that integrates Firebase services in Godot Android games and apps.
@@ -27,14 +33,6 @@
2733
- Open **Project > Export**
2834
- Enable `gradle_build/use_gradle_build` in Android preset.
2935

30-
## Documentation
31-
32-
- [Authentication](authentication.md)
33-
- [Cloud Firestore](firestore.md)
34-
- [Realtime Database](realtime_database.md)
35-
- [Cloud Storage](storage.md)
36-
- [Cloud Messaging](messaging.md)
37-
3836
## License
3937

4038
MIT License

0 commit comments

Comments
 (0)