import React from 'react';
import PropTypes from 'prop-types';
import cx from 'clsx';
import { motion } from 'framer-motion';
import { Link, useLocation } from 'react-router-dom';
// import { Command, Activity, Globe, Link2, Settings, File } from 'react-feather';
import {
FcAreaChart,
FcGlobe,
FcRuler,
FcDocument,
FcSettings,
FcLink,
} from 'react-icons/fc';
import { connect } from './StateProvider';
import { getTheme, switchTheme } from '../store/app';
import SvgYacd from './SvgYacd';
import s from './SideBar.module.css';
const { useCallback } = React;
// testing color icons
// const icons = {
// activity: Activity,
// globe: Globe,
// command: Command,
// file: File,
// settings: Settings,
// link: Link2
// };
const icons = {
activity: FcAreaChart,
globe: FcGlobe,
command: FcRuler,
file: FcDocument,
settings: FcSettings,
link: FcLink,
};
const SideBarRow = React.memo(function SideBarRow({
isActive,
to,
iconId,
labelText,
}) {
const Comp = icons[iconId];
const className = cx(s.row, isActive ? s.rowActive : null);
return (