fix: Light icons are not responsive to dark theme

This commit is contained in:
Tom Moor
2024-07-07 21:06:04 -04:00
parent 07b6441655
commit 43cf33fc0a
8 changed files with 58 additions and 45 deletions

View File

@@ -16,7 +16,7 @@ import { IconButton } from "./IconButton";
const BUTTON_SIZE = 32;
type OutlineNode = {
type: IconType.Outline;
type: IconType.SVG;
name: string;
color: string;
initial: string;
@@ -66,7 +66,7 @@ const GridTemplate = (
);
const items = node.icons.map((item) => {
if (item.type === IconType.Outline) {
if (item.type === IconType.SVG) {
return (
<IconButton
key={item.name}

View File

@@ -129,7 +129,7 @@ const IconPanel = ({
const baseIcons: DataNode = {
category,
icons: filteredIcons.map((name, index) => ({
type: IconType.Outline,
type: IconType.SVG,
name,
color,
initial,
@@ -144,7 +144,7 @@ const IconPanel = ({
{
category: DisplayCategory.Frequent,
icons: freqIcons.map((name, index) => ({
type: IconType.Outline,
type: IconType.SVG,
name,
color,
initial,

View File

@@ -98,7 +98,7 @@ const IconPicker = ({
(ic: string) => {
popover.hide();
const icType = determineIconType(ic);
const finalColor = icType === IconType.Outline ? chosenColor : null;
const finalColor = icType === IconType.SVG ? chosenColor : null;
onChange(ic, finalColor);
},
[popover, onChange, chosenColor]
@@ -110,7 +110,7 @@ const IconPicker = ({
const icType = determineIconType(icon);
// Outline icon set; propagate color change
if (icType === IconType.Outline) {
if (icType === IconType.SVG) {
onChange(icon, c);
}
},