Added backend DB schema page with embedded iframe#463
Added backend DB schema page with embedded iframe#463rahulharpal1603 merged 5 commits intoAOSSIE-Org:mainfrom
Conversation
WalkthroughA new documentation file embedding the backend database schema diagram via an iframe has been added. The documentation navigation was updated to include a "DB Schema" entry under the "Home" section, linking to the new schema documentation page. Changes
Assessment against linked issues
Poem
✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Actionable comments posted: 0
🧹 Nitpick comments (2)
mkdocs.yml (1)
60-66: Re-locate “DB Schema” under the existing “Backend” section for clearer IAPlacing the database-specific page at the root of “Home” makes it a sibling of “Overview” and “Setup”, while the rest of the backend docs live under the nested Backend list that follows. Moving it into that existing group keeps related content together and avoids a duplicate top-level entry later if more schema docs appear.
Example diff (indentation adjusted):
- - DB Schema: backend/db-schema.md - - Setup: setup.md - - Backend: + - Setup: setup.md + - Backend: + - DB Schema: backend/db-schema.md - Python Backend API: backend/backend_python/api.mdThis single change improves navigation consistency without affecting page paths.
docs/backend/db-schema.md (1)
5-5: Make the iframe responsive & accessibleHard-coding
width="560" height="315"fixes the iframe to a 16:9 box that clips on narrow screens and lacks an accessibility label. Prefer a responsive style,loading="lazy", and atitleattribute:-<iframe width="560" height="315" src='https://dbdiagram.io/e/685704c4f039ec6d364647e1/68701a53f413ba350850acf9'> </iframe> +<iframe + src="https://dbdiagram.io/e/685704c4f039ec6d364647e1/68701a53f413ba350850acf9" + title="PictoPy backend database schema" + style="width:100%; aspect-ratio:16/9; border:0;" + loading="lazy" + allowfullscreen> +</iframe>This scales with the viewport, adds an explicit title for screen-readers, and delays loading until the iframe scrolls into view.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
docs/backend/db-schema.md(1 hunks)mkdocs.yml(1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
- GitHub Check: Backend Tests
- GitHub Check: Tauri Tests
🔇 Additional comments (1)
docs/backend/db-schema.md (1)
1-6: Consider an offline-friendly fallbackBecause the diagram is hosted externally, builds viewed without internet access (e.g., on an internal network or PDF export) will render a blank area. Providing a static PNG/SVG export or link underneath the iframe mitigates this.
No code change required now—just flagging the potential UX gap.
docs/backend/db-schema.md
Outdated
|
|
||
| This section embeds our current database design. | ||
|
|
||
| <iframe width="560" height="315" src='https://dbdiagram.io/e/685704c4f039ec6d364647e1/68701a53f413ba350850acf9'> </iframe> |
There was a problem hiding this comment.
No need to create a separate file for this, just put this in backend/backend_python/database.md. Also ensure that the width and height does not have a weird ratio.
Allow users to open the db diagram via this link also: https://dbdiagram.io/d/PictoPy-685704c4f039ec6d364647e1
Python.Backend.Database.-.PictoPy.and.4.more.pages.-.Personal.-.Microsoft.Edge.2025-07-13.13-30-42.mp4 |
|
@rahulharpal1603 How's this one? If this is fine then I can update the PR with these changes |
It is good, just shift the schema part to the top of the database section |
|
@rahulharpal1603 Okay I will. |
|
@rahulharpal1603 Now please check |
There was a problem hiding this comment.
Actionable comments posted: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
backend/app/database/images.py(5 hunks)docs/backend/backend_python/database.md(2 hunks)frontend/src-tauri/tauri.conf.json(1 hunks)
✅ Files skipped from review due to trivial changes (2)
- docs/backend/backend_python/database.md
- backend/app/database/images.py
🧰 Additional context used
🪛 Biome (1.9.4)
frontend/src-tauri/tauri.conf.json
[error] 32-32: unexpected character <
(parse)
[error] 32-32: unexpected character <
(parse)
[error] 32-32: unexpected character <
(parse)
[error] 32-32: unexpected character <
(parse)
[error] 32-32: unexpected character <
(parse)
[error] 32-32: unexpected character <
(parse)
[error] 32-32: String values must be double quoted.
(parse)
[error] 33-33: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 33-33: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 33-33: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 33-34: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 33-34: unexpected character =
(parse)
[error] 34-34: unexpected character =
(parse)
[error] 34-34: unexpected character =
(parse)
[error] 34-34: unexpected character =
(parse)
[error] 34-34: unexpected character =
(parse)
[error] 34-34: unexpected character =
(parse)
[error] 34-34: unexpected character =
(parse)
[error] 35-35: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 35-35: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 35-35: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 35-36: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 35-36: unexpected character >
(parse)
[error] 36-36: unexpected character >
(parse)
[error] 36-36: unexpected character >
(parse)
[error] 36-36: unexpected character >
(parse)
[error] 36-36: unexpected character >
(parse)
[error] 36-36: unexpected character >
(parse)
[error] 36-36: unexpected character >
(parse)
[error] 36-36: End of file expected
Use an array for a sequence of values: [1, 2]
(parse)
[error] 36-36: String values must be double quoted.
(parse)
[error] 36-36: unexpected character (
(parse)
[error] 36-36: String values must be double quoted.
(parse)
[error] 36-36: String values must be double quoted.
(parse)
[error] 36-36: String values must be double quoted.
(parse)
[error] 36-36: String values must be double quoted.
(parse)
[error] 36-36: String values must be double quoted.
(parse)
[error] 36-36: String values must be double quoted.
(parse)
[error] 36-36: String values must be double quoted.
(parse)
[error] 36-36: unexpected character (
(parse)
[error] 36-36: String values must be double quoted.
(parse)
[error] 36-36: String values must be double quoted.
(parse)
[error] 36-36: unexpected character &
(parse)
[error] 36-36: String values must be double quoted.
(parse)
[error] 36-36: unexpected character )
(parse)
[error] 36-36: unexpected character )
(parse)
|
Thank you @ssz2605! |
|
@rahulharpal1603 Always up for contributing!!. |
Summary
db-schema.mdunderdocs/backend/mkdocs.ymlto include this in the navigationCloses #458
Summary by CodeRabbit