-
Notifications
You must be signed in to change notification settings - Fork 595
add setting modal #1874
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
add setting modal #1874
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Caution
Changes requested ❌
Reviewed everything up to 22eb91d in 1 minute and 34 seconds. Click for details.
- Reviewed
443
lines of code in11
files - Skipped
0
files when reviewing. - Skipped posting
6
draft comments. View those below. - Modify your settings and rules to customize what types of comments Ellipsis leaves. And don't forget to react with 👍 or 👎 to teach Ellipsis.
1. apps/web/client/src/components/ui/modal/settings/index.tsx:34
- Draft comment:
The useEffect that triggers scans when settingsOpen becomes true depends on both editorEngine.state.settingsOpen and project. Consider adding 'project' to the dependency array to avoid missing updates when the project changes. - Reason this comment was not posted:
Confidence changes required:50%
<= threshold50%
None
2. apps/web/client/src/components/store/project/manager.ts:31
- Draft comment:
Since 'domains' and 'versions' are always initialized in the constructor, consider removing the null union from their types to clarify that these properties are always set. - Reason this comment was not posted:
Confidence changes required:33%
<= threshold50%
None
3. apps/web/client/src/components/ui/modal/settings/preferences.tsx:33
- Draft comment:
Remove the commented-out updateAnalytics function if it's not needed to improve code clarity. - Reason this comment was not posted:
Confidence changes required:33%
<= threshold50%
None
4. apps/web/client/src/components/ui/modal/settings/site/index.tsx:59
- Draft comment:
When constructing the favicon path using the uploaded file name, ensure the filename is properly sanitized to prevent potential security issues. - Reason this comment was not posted:
Confidence changes required:33%
<= threshold50%
None
5. apps/web/client/src/components/ui/modal/settings/index.tsx:201
- Draft comment:
It looks like there’s an extraneous closing comment (*/
) after<Separator />
. This seems unintentional and should be removed, unless intended for a specific purpose. - Reason this comment was not posted:
Comment looked like it was already resolved.
6. apps/web/client/src/components/ui/modal/settings/preferences.tsx:200
- Draft comment:
There's an unexpected '*/' token at the end of this line, which appears to be a leftover from a block comment. If this was not intended, please remove it. - Reason this comment was not posted:
Comment looked like it was already resolved.
Workflow ID: wflow_tFbYpNDWyOe3n0hg
You can customize by changing your verbosity settings, reacting with 👍 or 👎, replying to comments, or adding code review rules.
|
||
export async function extractMetadata(filePath: string): Promise<PageMetadata | undefined> { | ||
try { | ||
const editorEngine = useEditorEngine(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using the React hook useEditorEngine
inside an async utility function is a violation of hook rules. Consider refactoring (e.g. pass editorEngine
as a parameter or use a custom hook) so the hook is only called within React components.
Description
Related Issues
Type of Change
Testing
Screenshots (if applicable)
Additional Notes
Important
Add settings modal with page metadata management, including metadata extraction and UI enhancements for project settings.
SettingsModal
toModals
inindex.tsx
for managing page metadata.scanProjectMetadata()
inProjectManager
to extract metadata fromlayout.tsx
.SiteTab
to handle metadata form submission and favicon/image uploads.extractMetadata()
inmetadata.ts
to parse and extract metadata from a file.BaseDomain
andDangerZone
components for domain management in settings.PreferencesTab
to manage user preferences like language and theme.Project
interface inproject.ts
to includesiteMetadata
anddomains
.This description was created by
for 22eb91d. You can customize this summary. It will automatically update as commits are pushed.