Skip to content
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

fix(components): coin icon types #2

Merged
merged 2 commits into from
Sep 13, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/fifty-poets-reflect.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@just_testing13/components": patch
---

fix(components): coin icon types
5 changes: 3 additions & 2 deletions packages/components/src/CoinIcon/CoinIcon.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import { ForwardRefExoticComponent, forwardRef } from 'react';
import { forwardRef } from 'react';
import { IconProps } from '@just_testing13/icons';

import * as coins from '../../../icons/src/svg/coin';

import { FallbackIcon } from './FallbackIcon';
import { LPCoinIcon } from './LPCoinIcon';
import { CoinComponent } from './types';

const DATA = coins as unknown as Record<string, ForwardRefExoticComponent<any>>;
const DATA = coins as unknown as Record<string, CoinComponent>;

type Props = {
ticker: string;
Expand Down
5 changes: 3 additions & 2 deletions packages/components/src/CoinIcon/LPCoinIcon.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import { ForwardRefExoticComponent, forwardRef, useCallback } from 'react';
import { forwardRef, useCallback } from 'react';
import { Icon } from '@just_testing13/icons';

import { CoinIconProps } from './CoinIcon';
import { FallbackIcon } from './FallbackIcon';
import { CoinComponent } from './types';

type Props = {
tickers: string[];
data: Record<string, ForwardRefExoticComponent<any>>;
data: Record<string, CoinComponent>;
};

type InheritAttrs = Omit<CoinIconProps, keyof Props>;
Expand Down