Kindly view both. Apologies for the inconvenience caused.
To get started on the platform, users must first create an account. The registration process typically requires the user to provide basic credentials such as username, and password. The password is first hashed and then stored in the database. Upon successful registration, the user gains access to the full functionality of the platform, which includes the ability to create notes, manage privacy settings, and view other users' notes. Once registered, users can log in to their account using their credentials. The login process is designed to be straightforward, requiring only the username and password. Users also have the option to change their password at any time via the Change Password option in the Home page. This is an important feature for user security and helps in cases where an account might be compromised or if the user simply wants to update their credentials. One of the central features of the platform is the ability to create text-based notes. When logged into the system, users can create a new note by clicking on the “Create Notes” option which will open /notes with request.method = ‘GET’ which will be the value of an hidden input named ‘method’, submitted when save button is clicked. /notes via ‘GET’ opens a simple editor where users can write their content into a new note. Each note requires a filename and a privacy setting before it can be saved. The filename serves as the identifier for the note, and it must be unique within the user's account to prevent overwriting existing notes. This helps avoid confusion or unintentional data loss, ensuring that each note has its own distinct name. The privacy setting is also a crucial part of the note creation process. The user must select whether they want the note to be private or public. If set to private, the note will be accessible only to the user who created it, ensuring that no one else can view it. On the other hand, if the note is set to public, it will be made available to other users on the platform, who can view its content but not edit it. A key feature of the platform is that users cannot save a note without filling in both the filename and privacy setting. If the user tries to save the note without providing either of these, the system will prompt an alert, reminding them to complete the necessary fields before proceeding. Additionally, if a user attempts to save a ‘new’ note with a filename that already exists, the platform will display a warning message. This ensures that each file is saved with a unique name, avoiding potential conflicts or data overwriting. Once the user has entered content, selected a privacy setting, and assigned a filename, they can click the Save button to store the note. If the filename contains characters not allowed in filename, then an error message will be displayed, preventing the note from being saved until the user renames it to an acceptable filename. If all fields are correctly filled in and the filename is unique, the note is saved to the user's personal account and becomes available for future editing or viewing. On the Home page, users can view a list of the notes they have created. This list displays each note’s filename (being a button (styled to look like a hyperlink text) which when clicked will open the document with all its properties being jinja injected) and privacy setting. Each note listed on the Home page will also have an option to delete it. This provides users with the ability to manage their content actively. If a user no longer wishes to keep a particular note, they can delete it, and it will be permanently removed from their account. Public notes are accessible on the Discover page, a feature that allows users to explore content created by others. The Discover page does not allow users to edit any of the publicly shared notes, but they can view and read the content. The user will have to first search the username and click on search button and then will be provided with the ordered list (list style being none) of public notes created by the user searched. While searching there is an unordered list dynamically generated providing the list of usernames similar to what typed in the input field. On the discover page, the request method for the unordered list generation is POST and the request for the ordered list is GET. Also, the elements in the ordered list are buttons when clicked will request /notes via POST. When the user clicks on his/her already saved note, it will open /note via POST and the value of the hidden input ‘method’ will become ‘POST’. When the save button (styles by CSS to look like hyperlink text) is clicked, the /save will know the method was POST and hence will allow the filename to be the old one or else would have prompted with error message “File with this name already exists” if method was GET. If a user decides they no longer want to use the platform, they can simply log out. The noteshub.db database contain 2 tables – users and notes. Users table store the login credentials of the users of the platform. Notes stores the all the details of the notes created on the platform.
blinker==1.9.0 cachelib==0.13.0 click==8.1.7 cs50==9.4.0 Flask==3.1.0 Flask-Session==0.8.0 greenlet==3.1.1 itsdangerous==2.2.0 Jinja2==3.1.4 MarkupSafe==3.0.2 msgspec==0.18.6 packaging==24.2 SQLAlchemy==2.0.36 sqlparse==0.5.3 termcolor==2.5.0 typing_extensions==4.12.2 Werkzeug==3.1.3 wheel==0.45.1