Repository navigation
fix: update default frontend hardcoded route links #5016
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -57,7 +57,7 @@ export function MessageError({ message, className = '' }: MessageErrorProps) { | |||||||||||||||||||||||
| variant='outline' | ||||||||||||||||||||||||
| size='sm' | ||||||||||||||||||||||||
| onClick={() => | ||||||||||||||||||||||||
| window.open('/console/setting?tab=ratio', '_blank') | ||||||||||||||||||||||||
| window.open('/system-settings/billing/model-pricing', '_blank') | ||||||||||||||||||||||||
| } | ||||||||||||||||||||||||
|
Comment on lines
59
to
61
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Use secure Please include Suggested fix- onClick={() =>
- window.open('/system-settings/billing/model-pricing', '_blank')
- }
+ onClick={() =>
+ window.open(
+ '/system-settings/billing/model-pricing',
+ '_blank',
+ 'noopener,noreferrer'
+ )
+ }📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||||||||||||||||
| > | ||||||||||||||||||||||||
| <Settings className='mr-1 h-3.5 w-3.5' /> | ||||||||||||||||||||||||
|
|
||||||||||||||||||||||||
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.
🧩 Analysis chain
🏁 Script executed:
Repository: QuantumNous/new-api
Length of output: 106
🏁 Script executed:
Repository: QuantumNous/new-api
Length of output: 6792
Harden
window.open(..., '_blank')against tabnabbing/referrer leakageweb/default/src/features/channels/components/dialogs/channel-test-dialog.tsxuseswindow.open(..., '_blank')withoutnoopener,noreferrer(lines 762-764); add the third argument to prevent opener/referrer leakage._blankcallsites also lack full protection and should be updated similarly:web/default/src/components/layout/components/chat-presets-item.tsx,web/default/src/features/channels/components/channels-columns.tsx,web/default/src/features/keys/components/dialogs/cc-switch-dialog.tsx,web/default/src/features/keys/components/data-table-row-actions.tsx,web/default/src/features/models/components/dialogs/view-details-dialog.tsx,web/default/src/features/playground/components/message-error.tsx,web/default/src/features/subscriptions/components/dialogs/subscription-purchase-dialog.tsx,web/default/src/features/system-settings/integrations/ionet-deployment-settings-section.tsx,web/default/src/features/usage-logs/components/dialogs/audio-preview-dialog.tsx,web/default/src/features/wallet/hooks/use-creem-payment.ts,web/default/src/features/wallet/hooks/use-payment.ts,web/default/src/features/wallet/hooks/use-waffo-payment.ts,web/default/src/lib/oauth.ts.Suggested fix
📝 Committable suggestion
🤖 Prompt for AI Agents