mirror of
				https://github.com/inventree/InvenTree.git
				synced 2025-11-04 07:05:41 +00:00 
			
		
		
		
	added some visual improvements (#9342)
* added some visual improvements * fix lint * Undo changes to sample icons for now * use primary color
This commit is contained in:
		@@ -14,8 +14,8 @@ export const ApiIcon = ({ name: _name, size = 22 }: ApiIconProps) => {
 | 
			
		||||
 | 
			
		||||
  const unicode = icon ? String.fromCodePoint(Number.parseInt(icon, 16)) : '';
 | 
			
		||||
 | 
			
		||||
  if (!unicode) {
 | 
			
		||||
    console.warn(`ApiIcon not found: ${_name}`);
 | 
			
		||||
  if (!unicode && _name !== '') {
 | 
			
		||||
    console.warn(`ApiIcon not found: '${_name}'`);
 | 
			
		||||
  }
 | 
			
		||||
 | 
			
		||||
  return (
 | 
			
		||||
 
 | 
			
		||||
@@ -168,6 +168,7 @@ export default function NavigationTree({
 | 
			
		||||
          <Anchor
 | 
			
		||||
            onClick={(event: any) => follow(payload.node, event)}
 | 
			
		||||
            aria-label={`nav-tree-item-${payload.node.value}`}
 | 
			
		||||
            c='var(--mantine-color-text)'
 | 
			
		||||
          >
 | 
			
		||||
            {payload.node.label}
 | 
			
		||||
          </Anchor>
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										10
									
								
								src/frontend/src/components/panels/PanelGroup.css.ts
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								src/frontend/src/components/panels/PanelGroup.css.ts
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,10 @@
 | 
			
		||||
import { style } from '@vanilla-extract/css';
 | 
			
		||||
import { vars } from '../../theme';
 | 
			
		||||
 | 
			
		||||
export const selectedPanelTab = style({
 | 
			
		||||
  selectors: {
 | 
			
		||||
    '&[data-active]': {
 | 
			
		||||
      background: vars.colors.primaryColors.light
 | 
			
		||||
    }
 | 
			
		||||
  }
 | 
			
		||||
});
 | 
			
		||||
@@ -37,6 +37,7 @@ import { useLocalState } from '../../states/LocalState';
 | 
			
		||||
import { Boundary } from '../Boundary';
 | 
			
		||||
import { StylishText } from '../items/StylishText';
 | 
			
		||||
import type { PanelType } from '../panels/Panel';
 | 
			
		||||
import * as classes from './PanelGroup.css';
 | 
			
		||||
 | 
			
		||||
/**
 | 
			
		||||
 * Set of properties which define a panel group:
 | 
			
		||||
@@ -161,6 +162,7 @@ function BasePanelGroup({
 | 
			
		||||
          orientation='vertical'
 | 
			
		||||
          keepMounted={false}
 | 
			
		||||
          aria-label={`panel-group-${pageKey}`}
 | 
			
		||||
          classNames={{ tab: classes.selectedPanelTab }}
 | 
			
		||||
        >
 | 
			
		||||
          <Tabs.List justify='left' aria-label={`panel-tabs-${pageKey}`}>
 | 
			
		||||
            {allPanels.map(
 | 
			
		||||
 
 | 
			
		||||
@@ -109,6 +109,12 @@ export const tab = style({
 | 
			
		||||
  ':hover': {
 | 
			
		||||
    [vars.lightSelector]: { backgroundColor: vars.colors.gray[1] },
 | 
			
		||||
    [vars.darkSelector]: { backgroundColor: vars.colors.dark[5] }
 | 
			
		||||
  },
 | 
			
		||||
 | 
			
		||||
  selectors: {
 | 
			
		||||
    '&[data-active]': {
 | 
			
		||||
      backgroundColor: vars.colors.primaryColors.light
 | 
			
		||||
    }
 | 
			
		||||
  }
 | 
			
		||||
});
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user