Skip to content

Commit

Permalink
Update <SvgIcon /> with global className
Browse files Browse the repository at this point in the history
  • Loading branch information
calebjacob committed Nov 8, 2024
1 parent 479b969 commit 77aeac8
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 11 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@near-pagoda/ui",
"version": "2.0.1",
"version": "2.0.2",
"description": "A React component library that implements the official NEAR design system.",
"license": "MIT",
"repository": {
Expand Down
4 changes: 2 additions & 2 deletions src/components/Dropdown/Dropdown.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@
cursor: pointer;
transition: var(--transitions);

[data-icon][data-color='current'] {
:global(.svgIcon[data-color='current']) {
color: var(--sand-10) !important;
}

Expand All @@ -109,7 +109,7 @@
&[data-state='open'] {
background-color: var(--sand-3);

[data-icon] {
:global(.svgIcon) {
color: var(--violet-10) !important;
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/components/ImageIcon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ type Props = {

export const ImageIcon = ({ alt, className = '', fallbackIcon, size = 'm', src, ...props }: Props) => {
return (
<div className={`${s.imageIcon} ${className}`} data-icon data-size={size} {...props}>
<div className={`${s.imageIcon} ${className} image-icon`} data-size={size} {...props}>
{src ? <img src={src} alt={alt} /> : fallbackIcon}
</div>
);
Expand Down
3 changes: 1 addition & 2 deletions src/components/SvgIcon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,8 @@ export const SvgIcon = ({
}: Props) => {
return (
<div
className={`${s.svgIcon} ${className}`}
className={`${s.svgIcon} ${className} svgIcon`}
data-color={color}
data-icon
data-size={size}
data-no-fill={noFill}
data-no-stroke={noStroke}
Expand Down
5 changes: 0 additions & 5 deletions src/components/Table/Table.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,6 @@
bottom: var(--table-half-padding);
}
}

&[data-test='true'] {
position: fixed;
top: 100px;
}
}

.foot {
Expand Down

0 comments on commit 77aeac8

Please sign in to comment.