Skip to content

feat: custom date time format#718

Merged
nicotsx merged 2 commits intomainfrom
feat/custom-date-time-format
Mar 29, 2026
Merged

feat: custom date time format#718
nicotsx merged 2 commits intomainfrom
feat/custom-date-time-format

Conversation

@nicotsx
Copy link
Copy Markdown
Owner

@nicotsx nicotsx commented Mar 29, 2026

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Mar 29, 2026

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: eae8b108-a82f-47d9-8220-d1d93957a70a

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@dosubot
Copy link
Copy Markdown

dosubot bot commented Mar 29, 2026

Documentation Updates

1 document(s) were updated by changes in this PR:

User Authentication and Account Management
View Changes
@@ -32,6 +32,8 @@
 | `banned` | boolean | Account suspension status |
 | `banReason` | text | Optional reason for account ban |
 | `banExpires` | timestamp | Optional expiration for temporary bans |
+| `dateFormat` | text | User's preferred date format (default: `"MM/DD/YYYY"`) |
+| `timeFormat` | text | User's preferred time format (default: `"12h"`) |
 | `createdAt` | timestamp | Account creation time |
 | `updatedAt` | timestamp | Last update time |
 
@@ -271,7 +273,8 @@
 2. Calls `authClient.signUp.email()` to create the account
 3. [First user automatically receives](https://github.com/nicotsx/zerobyte/blob/fdd8edec702ac43721ceffce5ac9af5cf4e545d5/app/server/lib/auth.ts#L52-L58) the `"admin"` role
 4. System creates a personal organization and generates encryption keys
-5. User is redirected to download their backup recovery key
+5. New users are assigned default preferences: `MM/DD/YYYY` for date format and `12h` for time format
+6. User is redirected to download their backup recovery key
 
 
 #### Admin-Created Users
@@ -940,6 +943,22 @@
 - **Revocation**: Sessions can be invalidated individually or in bulk (e.g., on password change)
 - **Security metadata**: IP address and user agent stored for audit purposes (see [Proxy Configuration](#proxy-configuration) for deployments behind reverse proxies)
 
+#### Date and Time Format Preferences
+Users can customize how dates and times are displayed throughout the application:
+
+**Configuring Preferences:**
+1. Navigate to Settings → Account tab
+2. Locate the "Date and Time Format" section
+3. Select your preferred date format: `MM/DD/YYYY`, `DD/MM/YYYY`, or `YYYY/MM/DD`
+4. Select your preferred time format: `12h` (12-hour with AM/PM) or `24h` (24-hour)
+5. View a live preview showing how the selected format will display dates and times
+6. Changes take effect after saving and reloading the page
+
+**Default Settings:**
+- New users are assigned `MM/DD/YYYY` for date format and `12h` for time format during registration
+- User preferences are stored in the `dateFormat` and `timeFormat` fields of the user record
+- These preferences are available throughout the application via the user context
+
 #### Encryption
 The [crypto utilities](https://github.com/nicotsx/zerobyte/blob/fdd8edec702ac43721ceffce5ac9af5cf4e545d5/app/server/utils/crypto.ts) provide encryption for sensitive data:
 

How did I do? Any feedback?  Join Discord

@nicotsx nicotsx force-pushed the feat/custom-date-time-format branch from 9963885 to ce8b0fe Compare March 29, 2026 15:12
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9963885e3a

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@nicotsx nicotsx merged commit f89b8c3 into main Mar 29, 2026
10 checks passed
@nicotsx nicotsx deleted the feat/custom-date-time-format branch March 29, 2026 15:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant