fedimint / ui

MIT License
23 stars 35 forks source link

fix: broken assets links #441

Closed Kodylow closed 3 weeks ago

Kodylow commented 3 weeks ago

fixes asset paths I broke in last refactor

Summary by CodeRabbit

coderabbitai[bot] commented 3 weeks ago
Walkthrough ## Walkthrough This update involves correcting import paths for SVG icons across multiple React components within the project. The changes optimize the import structure, transitioning from relative paths to more consistent paths aligned with the overall project directory structure. ## Changes | File(s) | Change Summary | |-----------------------------------|-------------------------------------------------------------------------------------------------| | `BalanceTable.tsx` | Updated import paths for `CheckIcon` and `CloseIcon` components. | | `InviteCode.tsx` | Updated import paths for `CopyIcon` and `QrIcon` components. | | `GatewaysCard.tsx` | Corrected import path for `InfoIcon` component. | | `EditMetaField.tsx` | Updated import paths for `TrashIcon` and `PlusIcon` components. | | `ProposedMetas.tsx` | Updated import path for `CheckIcon` component. | | `ConnectGuardians.tsx` | Corrected import path for `CopyIcon` component. | | `RoleSelector.tsx` | Updated import paths for multiple SVG icons including `ArrowRightIcon`, `CheckIcon`, and others.| | `SetConfiguration.tsx` | Corrected import paths for multiple SVG assets including `FedimintLogo`, `BitcoinLogo`, and others.| | `SetupComplete.tsx` | Updated import path for `ArrowRightIcon` component. | | `SetupProgress.tsx` | Corrected import path for `CheckIcon` component. | | `VerifyGuardians.tsx` | Updated import paths for multiple SVG assets including `ArrowRightIcon`, `CopyIcon`, and others.| ## Sequence Diagram(s) *N/A*

Recent review details **Configuration used: CodeRabbit UI** **Review profile: CHILL**
Commits Files that changed from the base of the PR and between 7a1d1c1155b17a212b83c81c47a88c6b5e07554d and 8ea03ff07f43e08b27005e5d70e4c483af385c48.
Files selected for processing (11) * apps/guardian-ui/src/components/dashboard/admin/BalanceTable.tsx (1 hunks) * apps/guardian-ui/src/components/dashboard/admin/InviteCode.tsx (1 hunks) * apps/guardian-ui/src/components/dashboard/gateways/GatewaysCard.tsx (1 hunks) * apps/guardian-ui/src/components/dashboard/tabs/meta/EditMetaField.tsx (1 hunks) * apps/guardian-ui/src/components/dashboard/tabs/meta/ProposedMetas.tsx (1 hunks) * apps/guardian-ui/src/components/setup/ConnectGuardians.tsx (1 hunks) * apps/guardian-ui/src/components/setup/RoleSelector.tsx (1 hunks) * apps/guardian-ui/src/components/setup/SetConfiguration.tsx (1 hunks) * apps/guardian-ui/src/components/setup/SetupComplete.tsx (1 hunks) * apps/guardian-ui/src/components/setup/SetupProgress.tsx (1 hunks) * apps/guardian-ui/src/components/setup/VerifyGuardians.tsx (1 hunks)
Files skipped from review due to trivial changes (7) * apps/guardian-ui/src/components/dashboard/admin/BalanceTable.tsx * apps/guardian-ui/src/components/dashboard/admin/InviteCode.tsx * apps/guardian-ui/src/components/dashboard/gateways/GatewaysCard.tsx * apps/guardian-ui/src/components/dashboard/tabs/meta/EditMetaField.tsx * apps/guardian-ui/src/components/setup/RoleSelector.tsx * apps/guardian-ui/src/components/setup/SetupComplete.tsx * apps/guardian-ui/src/components/setup/SetupProgress.tsx
Additional context used
Biome
apps/guardian-ui/src/components/setup/VerifyGuardians.tsx
[error] 121-122: Change to an optional chain. (lint/complexity/useOptionalChain) Unsafe fix: Change to an optional chain. --- [error] 236-347: This else clause can be omitted because previous branches break early. (lint/style/noUselessElse) Unsafe fix: Omit the else clause. --- [error] 238-347: This else clause can be omitted because previous branches break early. (lint/style/noUselessElse) --- [error] 249-347: This else clause can be omitted because previous branches break early. (lint/style/noUselessElse)
apps/guardian-ui/src/components/dashboard/tabs/meta/ProposedMetas.tsx
[error] 181-187: This else clause can be omitted because previous branches break early. (lint/style/noUselessElse) Unsafe fix: Omit the else clause.
apps/guardian-ui/src/components/setup/SetConfiguration.tsx
[error] 216-216: Avoid the use of spread (`...`) syntax on accumulators. (lint/performance/noAccumulatingSpread) Spread syntax should be avoided on accumulators (like those in `.reduce`) because it causes a time complexity of `O(n^2)`. Consider methods such as .splice or .push instead.
Additional comments not posted (4)
apps/guardian-ui/src/components/setup/ConnectGuardians.tsx (1)
`23-23`: **Updated SVG import path for CopyIcon** This change aligns with the PR's objective to fix broken asset paths by updating them to a more absolute path. This should ensure the icon is consistently loaded across different components.
apps/guardian-ui/src/components/setup/VerifyGuardians.tsx (1)
`29-33`: **Updated SVG import paths for multiple icons** The changes to the import paths for `ArrowRightIcon`, `CopyIcon`, `CheckCircleIcon`, and `XCircleIcon` are consistent with the PR's goal to correct asset paths. This should help in maintaining a uniform reference structure across the project.
apps/guardian-ui/src/components/dashboard/tabs/meta/ProposedMetas.tsx (1)
`19-19`: **Updated SVG import path for CheckIcon** This change updates the import path for `CheckIcon` to a more absolute path, which is in line with the PR's objective to fix asset paths. This ensures that the icon is loaded correctly across various parts of the application.
apps/guardian-ui/src/components/setup/SetConfiguration.tsx (1)
`34-38`: **Updated SVG import paths for multiple icons** The changes to the import paths for `FedimintLogo`, `BitcoinLogo`, `ModulesIcon`, `ArrowRightIcon`, and `LightbulbLogo` correctly reflect the PR's goal to standardize asset paths across the project. This should help maintain consistency and ensure assets are loaded correctly.
---
Tips ### Chat There are 3 ways to chat with [CodeRabbit](https://coderabbit.ai): - Review comments: Directly reply to a review comment made by CodeRabbit. Example: - `I pushed a fix in commit .` - `Generate unit testing code for this file.` - `Open a follow-up GitHub issue for this discussion.` - Files and specific lines of code (under the "Files changed" tab): Tag `@coderabbitai` in a new review comment at the desired location with your query. Examples: - `@coderabbitai generate unit testing code for this file.` - `@coderabbitai modularize this function.` - PR comments: Tag `@coderabbitai` in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples: - `@coderabbitai generate interesting stats about this repository and render them as a table.` - `@coderabbitai show all the console.log statements in this repository.` - `@coderabbitai read src/utils.ts and generate unit testing code.` - `@coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.` - `@coderabbitai help me debug CodeRabbit configuration file.` 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 as PR comments) - `@coderabbitai pause` to pause the reviews on a PR. - `@coderabbitai resume` to resume the paused reviews. - `@coderabbitai review` to trigger an incremental review. This is useful when automatic reviews are disabled for the repository. - `@coderabbitai full review` to do a full review from scratch and review all the files again. - `@coderabbitai summary` to regenerate the summary of the PR. - `@coderabbitai resolve` resolve all the CodeRabbit review comments. - `@coderabbitai configuration` to show the current CodeRabbit configuration for the repository. - `@coderabbitai help` to get help. Additionally, you can add `@coderabbitai ignore` anywhere in the PR description to prevent this PR from being reviewed. ### CodeRabbit Configration File (`.coderabbit.yaml`) - You can programmatically configure CodeRabbit by adding a `.coderabbit.yaml` file to the root of your repository. - Please see the [configuration documentation](https://docs.coderabbit.ai/guides/configure-coderabbit) for more information. - If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: `# yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json` ### Documentation and Community - Visit our [Documentation](https://coderabbit.ai/docs) for detailed information on how to use CodeRabbit. - Join our [Discord Community](https://discord.com/invite/GsXnASn26c) to get help, request features, and share feedback. - Follow us on [X/Twitter](https://twitter.com/coderabbitai) for updates and announcements.