@moderneinc/neo-styled-components 2.6.0 → 2.7.0-next.b4c3dc
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ButtonTab/ButtonTab.d.ts +19 -0
- package/dist/ButtonTabGroup/ButtonTabGroup.d.ts +39 -0
- package/dist/GeneralAvatar/GeneralAvatar.d.ts +26 -0
- package/dist/ListItemButton/ListItemButton.d.ts +1 -1
- package/dist/MarketplaceCard/MarketplaceCard.d.ts +2 -2
- package/dist/MarketplaceLargeCard/MarketplaceLargeCard.d.ts +2 -2
- package/dist/NavigationAvatar/NavigationAvatar.d.ts +15 -0
- package/dist/StatusBanner/StatusBanner.d.ts +4 -4
- package/dist/index.d.ts +87 -30
- package/dist/index.esm.js +264 -128
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +267 -128
- package/dist/index.js.map +1 -1
- package/dist/utils/avatarColors.d.ts +7 -0
- package/dist/utils/focusRing.d.ts +3 -3
- package/package.json +1 -1
- package/dist/ButtonGroup/ButtonGroup.d.ts +0 -41
package/dist/index.esm.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
2
|
-
import {
|
|
2
|
+
import { semanticColors, colors, spacing, typography, borderRadius, shadows } from '@moderneinc/neo-design';
|
|
3
3
|
import Box from '@mui/material/Box';
|
|
4
4
|
import { styled, alpha } from '@mui/material/styles';
|
|
5
5
|
import Avatar from '@mui/material/Avatar';
|
|
@@ -7,12 +7,13 @@ import Chip, { chipClasses } from '@mui/material/Chip';
|
|
|
7
7
|
import SvgIcon, { svgIconClasses } from '@mui/material/SvgIcon';
|
|
8
8
|
import Alert, { alertClasses } from '@mui/material/Alert';
|
|
9
9
|
import IconButton, { iconButtonClasses } from '@mui/material/IconButton';
|
|
10
|
-
import React, { forwardRef, createElement, useState, useMemo,
|
|
10
|
+
import React, { forwardRef, createElement, useRef, useCallback, useState, useMemo, useEffect } from 'react';
|
|
11
11
|
import Breadcrumbs, { breadcrumbsClasses } from '@mui/material/Breadcrumbs';
|
|
12
12
|
import Link from '@mui/material/Link';
|
|
13
13
|
import ButtonBase, { buttonBaseClasses } from '@mui/material/ButtonBase';
|
|
14
14
|
import CircularProgress from '@mui/material/CircularProgress';
|
|
15
|
-
import
|
|
15
|
+
import MuiToggleButton, { toggleButtonClasses } from '@mui/material/ToggleButton';
|
|
16
|
+
import MuiToggleButtonGroup, { toggleButtonGroupClasses } from '@mui/material/ToggleButtonGroup';
|
|
16
17
|
import Checkbox, { checkboxClasses } from '@mui/material/Checkbox';
|
|
17
18
|
import { useGridApiContext, useGridSelector, gridColumnDefinitionsSelector, gridColumnVisibilityModelSelector, GridPanelWrapper, useGridApiRef, gridClasses as gridClasses$1, DataGridPro, ColumnsPanelTrigger, ToolbarButton, gridFilterModelSelector, FilterPanelTrigger, Toolbar } from '@mui/x-data-grid-pro';
|
|
18
19
|
import Button, { buttonClasses } from '@mui/material/Button';
|
|
@@ -60,22 +61,20 @@ import Switch, { switchClasses } from '@mui/material/Switch';
|
|
|
60
61
|
import { useTreeItemModel } from '@mui/x-tree-view/hooks';
|
|
61
62
|
import { TreeItem, treeItemClasses } from '@mui/x-tree-view/TreeItem';
|
|
62
63
|
import { RichTreeViewPro } from '@mui/x-tree-view-pro/RichTreeViewPro';
|
|
63
|
-
import ToggleButton, { toggleButtonClasses } from '@mui/material/ToggleButton';
|
|
64
|
-
import ToggleButtonGroup, { toggleButtonGroupClasses } from '@mui/material/ToggleButtonGroup';
|
|
65
64
|
|
|
66
65
|
/**
|
|
67
|
-
* Outline-based focus ring styles derived from Neo
|
|
66
|
+
* Outline-based focus ring styles derived from Neo border tokens.
|
|
68
67
|
* Uses CSS outline (not box-shadow) so focus rings are never clipped by overflow:hidden.
|
|
69
68
|
*
|
|
70
|
-
* Produces a double-ring effect: a white inner gap (via outline-offset) and a
|
|
69
|
+
* Produces a double-ring effect: a white inner gap (via outline-offset) and a colored outer ring.
|
|
71
70
|
*/
|
|
72
71
|
const focusRingStyles = {
|
|
73
|
-
outline:
|
|
74
|
-
outlineOffset:
|
|
72
|
+
outline: `2px solid ${semanticColors.border.focus}`,
|
|
73
|
+
outlineOffset: '2px',
|
|
75
74
|
};
|
|
76
75
|
|
|
77
76
|
// biome-ignore lint/suspicious/noExplicitAny: Type cast required to override MUI Avatar variant type without global augmentation
|
|
78
|
-
const StyledAvatar = styled(Avatar, {
|
|
77
|
+
const StyledAvatar$1 = styled(Avatar, {
|
|
79
78
|
shouldForwardProp: prop => prop !== 'size' && prop !== 'variant',
|
|
80
79
|
})(({ theme, size = 'medium', variant = 'circular' }) => ({
|
|
81
80
|
boxSizing: 'border-box',
|
|
@@ -177,7 +176,7 @@ const AvatarContainer = styled(Box)(({ size = 'medium' }) => ({
|
|
|
177
176
|
*/
|
|
178
177
|
const NeoAvatar = ({ size = 'medium', variant = 'circular', ...props }) => {
|
|
179
178
|
// shouldForwardProp filters out size and variant from being passed to the DOM
|
|
180
|
-
const avatar = jsx(StyledAvatar, { size: size, variant: variant, ...props });
|
|
179
|
+
const avatar = jsx(StyledAvatar$1, { size: size, variant: variant, ...props });
|
|
181
180
|
// Medium size with circular variant (image) gets wrapped in white container
|
|
182
181
|
if (size === 'medium' && variant === 'circular') {
|
|
183
182
|
return jsx(AvatarContainer, { size: size, children: avatar });
|
|
@@ -219,7 +218,7 @@ const StyledChip$2 = styled(Chip)(({ theme }) => ({
|
|
|
219
218
|
[`&.${chipClasses.colorDefault}`]: {
|
|
220
219
|
backgroundColor: semanticColors.status.neutral.light,
|
|
221
220
|
color: semanticColors.status.neutral.dark,
|
|
222
|
-
border: `1px solid ${semanticColors.status.neutral.
|
|
221
|
+
border: `1px solid ${semanticColors.status.neutral.default}80`,
|
|
223
222
|
[`& .${chipClasses.icon}, & .${chipClasses.deleteIcon}`]: {
|
|
224
223
|
color: semanticColors.status.neutral.dark,
|
|
225
224
|
},
|
|
@@ -228,7 +227,7 @@ const StyledChip$2 = styled(Chip)(({ theme }) => ({
|
|
|
228
227
|
[`&.${chipClasses.colorError}`]: {
|
|
229
228
|
backgroundColor: semanticColors.status.error.light,
|
|
230
229
|
color: semanticColors.status.error.dark,
|
|
231
|
-
border: `1px solid ${semanticColors.status.error.
|
|
230
|
+
border: `1px solid ${semanticColors.status.error.default}80`,
|
|
232
231
|
[`& .${chipClasses.icon}, & .${chipClasses.deleteIcon}`]: {
|
|
233
232
|
color: semanticColors.status.error.dark,
|
|
234
233
|
},
|
|
@@ -237,7 +236,7 @@ const StyledChip$2 = styled(Chip)(({ theme }) => ({
|
|
|
237
236
|
[`&.${chipClasses.colorWarning}`]: {
|
|
238
237
|
backgroundColor: semanticColors.status.warning.light,
|
|
239
238
|
color: semanticColors.status.warning.dark,
|
|
240
|
-
border: `1px solid ${semanticColors.status.warning.
|
|
239
|
+
border: `1px solid ${semanticColors.status.warning.default}80`,
|
|
241
240
|
[`& .${chipClasses.icon}, & .${chipClasses.deleteIcon}`]: {
|
|
242
241
|
color: semanticColors.status.warning.dark,
|
|
243
242
|
},
|
|
@@ -246,7 +245,7 @@ const StyledChip$2 = styled(Chip)(({ theme }) => ({
|
|
|
246
245
|
[`&.${chipClasses.colorSuccess}`]: {
|
|
247
246
|
backgroundColor: semanticColors.status.success.light,
|
|
248
247
|
color: semanticColors.status.success.dark,
|
|
249
|
-
border: `1px solid ${semanticColors.status.success.
|
|
248
|
+
border: `1px solid ${semanticColors.status.success.default}80`,
|
|
250
249
|
[`& .${chipClasses.icon}, & .${chipClasses.deleteIcon}`]: {
|
|
251
250
|
color: semanticColors.status.success.dark,
|
|
252
251
|
},
|
|
@@ -255,7 +254,7 @@ const StyledChip$2 = styled(Chip)(({ theme }) => ({
|
|
|
255
254
|
[`&.${chipClasses.colorInfo}`]: {
|
|
256
255
|
backgroundColor: semanticColors.status.info.light,
|
|
257
256
|
color: semanticColors.status.info.dark,
|
|
258
|
-
border: `1px solid ${semanticColors.status.info.
|
|
257
|
+
border: `1px solid ${semanticColors.status.info.default}80`,
|
|
259
258
|
[`& .${chipClasses.icon}, & .${chipClasses.deleteIcon}`]: {
|
|
260
259
|
color: semanticColors.status.info.dark,
|
|
261
260
|
},
|
|
@@ -1066,13 +1065,13 @@ const NeoBanner = ({ variant = 'light', message, messagePosition = 'left', linkT
|
|
|
1066
1065
|
return semanticColors.surfaces.white;
|
|
1067
1066
|
}
|
|
1068
1067
|
if (variant === 'success') {
|
|
1069
|
-
return semanticColors.status.success.
|
|
1068
|
+
return semanticColors.status.success.default;
|
|
1070
1069
|
}
|
|
1071
1070
|
if (variant === 'error') {
|
|
1072
|
-
return semanticColors.status.error.
|
|
1071
|
+
return semanticColors.status.error.default;
|
|
1073
1072
|
}
|
|
1074
1073
|
if (variant === 'warning') {
|
|
1075
|
-
return semanticColors.status.warning.
|
|
1074
|
+
return semanticColors.status.warning.default;
|
|
1076
1075
|
}
|
|
1077
1076
|
return colors.grey['800'];
|
|
1078
1077
|
};
|
|
@@ -1104,7 +1103,7 @@ const StyledBreadcrumbLink = styled(Link, {
|
|
|
1104
1103
|
color: current ? semanticColors.buttons.tertiary.hover : semanticColors.icons.hover,
|
|
1105
1104
|
},
|
|
1106
1105
|
'&:focus-visible': {
|
|
1107
|
-
outline: `2px solid ${semanticColors.
|
|
1106
|
+
outline: `2px solid ${semanticColors.border.focus}`,
|
|
1108
1107
|
outlineOffset: 2,
|
|
1109
1108
|
},
|
|
1110
1109
|
}));
|
|
@@ -1194,7 +1193,7 @@ const StyledButtonBase$1 = styled(ButtonBase, {
|
|
|
1194
1193
|
},
|
|
1195
1194
|
// Focus visible for keyboard navigation
|
|
1196
1195
|
[`&.${buttonBaseClasses.focusVisible}`]: {
|
|
1197
|
-
outline: `2px solid ${semanticColors.
|
|
1196
|
+
outline: `2px solid ${semanticColors.border.focus}`,
|
|
1198
1197
|
outlineOffset: 2,
|
|
1199
1198
|
},
|
|
1200
1199
|
};
|
|
@@ -1234,7 +1233,7 @@ const StyledButtonBase$1 = styled(ButtonBase, {
|
|
|
1234
1233
|
: {
|
|
1235
1234
|
[`&.${buttonBaseClasses.disabled}`]: {
|
|
1236
1235
|
backgroundColor: semanticColors.buttons.secondary.disabledBackground,
|
|
1237
|
-
borderColor: semanticColors.
|
|
1236
|
+
borderColor: semanticColors.border.secondary,
|
|
1238
1237
|
color: semanticColors.typography.button.disabled,
|
|
1239
1238
|
},
|
|
1240
1239
|
}),
|
|
@@ -1362,40 +1361,102 @@ function NeoButton({ variant = 'primary', size = 'medium', loading = false, chil
|
|
|
1362
1361
|
}
|
|
1363
1362
|
NeoButton.displayName = 'NeoButton';
|
|
1364
1363
|
|
|
1364
|
+
const StyledButtonTab = styled(MuiToggleButton)(({ theme }) => ({
|
|
1365
|
+
fontFamily: typography.fontFamily.body,
|
|
1366
|
+
fontSize: theme.typography.pxToRem(typography.fontSize.sm),
|
|
1367
|
+
lineHeight: 1,
|
|
1368
|
+
color: semanticColors.typography.tab.inactive,
|
|
1369
|
+
backgroundColor: 'transparent',
|
|
1370
|
+
border: 'none',
|
|
1371
|
+
padding: theme.spacing(1, 1.5),
|
|
1372
|
+
cursor: 'pointer',
|
|
1373
|
+
textTransform: 'none',
|
|
1374
|
+
transition: theme.transitions.create(['color'], {
|
|
1375
|
+
duration: theme.transitions.duration.short,
|
|
1376
|
+
}),
|
|
1377
|
+
'&:hover': {
|
|
1378
|
+
color: semanticColors.typography.tab.active,
|
|
1379
|
+
},
|
|
1380
|
+
'&.Mui-focusVisible': {
|
|
1381
|
+
outline: `2px solid ${semanticColors.border.focus}`,
|
|
1382
|
+
outlineOffset: -2,
|
|
1383
|
+
borderRadius: borderRadius.xXS,
|
|
1384
|
+
},
|
|
1385
|
+
'&.Mui-disabled': {
|
|
1386
|
+
color: semanticColors.typography.button.disabled,
|
|
1387
|
+
cursor: 'default',
|
|
1388
|
+
pointerEvents: 'none',
|
|
1389
|
+
},
|
|
1390
|
+
}));
|
|
1391
|
+
/**
|
|
1392
|
+
* Syncs aria-selected with MUI's Mui-selected class via MutationObserver.
|
|
1393
|
+
* MUI ToggleButton computes selection internally from context and applies
|
|
1394
|
+
* the Mui-selected class — we mirror that to aria-selected for tab semantics.
|
|
1395
|
+
*/
|
|
1396
|
+
function useTabAriaSync() {
|
|
1397
|
+
const observerRef = useRef(null);
|
|
1398
|
+
return useCallback((node) => {
|
|
1399
|
+
if (observerRef.current) {
|
|
1400
|
+
observerRef.current.disconnect();
|
|
1401
|
+
observerRef.current = null;
|
|
1402
|
+
}
|
|
1403
|
+
if (!node)
|
|
1404
|
+
return;
|
|
1405
|
+
const sync = () => {
|
|
1406
|
+
node.setAttribute('role', 'tab');
|
|
1407
|
+
node.setAttribute('aria-selected', String(node.classList.contains('Mui-selected')));
|
|
1408
|
+
};
|
|
1409
|
+
sync();
|
|
1410
|
+
observerRef.current = new MutationObserver(sync);
|
|
1411
|
+
observerRef.current.observe(node, { attributes: true, attributeFilter: ['class'] });
|
|
1412
|
+
}, []);
|
|
1413
|
+
}
|
|
1414
|
+
/**
|
|
1415
|
+
* NeoButtonTab - A tab-style toggle button for use within NeoButtonGroup
|
|
1416
|
+
*
|
|
1417
|
+
* @figma https://www.figma.com/design/fQTkGSFbYyE7LiHuQJsENC?node-id=4106-11048
|
|
1418
|
+
*/
|
|
1419
|
+
const NeoButtonTab = ({ children, ...props }) => {
|
|
1420
|
+
const tabRef = useTabAriaSync();
|
|
1421
|
+
return (jsx(StyledButtonTab, { ref: tabRef, ...props, children: children }));
|
|
1422
|
+
};
|
|
1423
|
+
NeoButtonTab.displayName = 'NeoButtonTab';
|
|
1424
|
+
|
|
1365
1425
|
/**
|
|
1366
|
-
* Styled
|
|
1426
|
+
* Styled toggle button group that implements the Figma "Button tab group" design.
|
|
1367
1427
|
*
|
|
1368
|
-
*
|
|
1369
|
-
* -
|
|
1370
|
-
* -
|
|
1371
|
-
* -
|
|
1428
|
+
* Built on MUI ToggleButtonGroup which provides:
|
|
1429
|
+
* - Selection state management (value/onChange/exclusive)
|
|
1430
|
+
* - Size and disabled propagation via context
|
|
1431
|
+
* - Positional classes (firstButton/middleButton/lastButton)
|
|
1372
1432
|
*
|
|
1373
|
-
* Custom styling
|
|
1374
|
-
* -
|
|
1433
|
+
* Custom styling:
|
|
1434
|
+
* - Pill-shaped border (borderRadius.full)
|
|
1375
1435
|
* - Size variants (small=32px, medium=40px)
|
|
1376
1436
|
* - Border colors using semantic tokens
|
|
1377
|
-
* -
|
|
1437
|
+
* - Selected state colors from Neo design tokens
|
|
1378
1438
|
*/
|
|
1379
|
-
const
|
|
1439
|
+
const StyledButtonTabGroup = styled(MuiToggleButtonGroup)(({ theme, size = 'medium' }) => {
|
|
1380
1440
|
const sizeStyles = {
|
|
1381
1441
|
small: {
|
|
1382
|
-
height:
|
|
1442
|
+
height: spacing.spacing_4,
|
|
1383
1443
|
},
|
|
1384
1444
|
medium: {
|
|
1385
1445
|
height: spacing.spacing_5,
|
|
1386
1446
|
},
|
|
1387
1447
|
};
|
|
1388
1448
|
return {
|
|
1389
|
-
// Apply pill-shaped border radius
|
|
1390
1449
|
borderRadius: borderRadius.full,
|
|
1391
1450
|
border: `1px solid ${semanticColors.border.primary}`,
|
|
1392
|
-
|
|
1393
|
-
|
|
1451
|
+
overflow: 'hidden',
|
|
1452
|
+
// Style all grouped children
|
|
1453
|
+
[`& .${toggleButtonGroupClasses.grouped}`]: {
|
|
1454
|
+
flex: 1,
|
|
1394
1455
|
minWidth: 'auto',
|
|
1395
1456
|
height: sizeStyles[size].height,
|
|
1396
1457
|
padding: `${theme.spacing(1)} ${theme.spacing(2)}`,
|
|
1397
1458
|
fontSize: theme.typography.pxToRem(typography.fontSize.sm),
|
|
1398
|
-
fontWeight: typography.fontWeight.
|
|
1459
|
+
fontWeight: typography.fontWeight.regular,
|
|
1399
1460
|
lineHeight: 1,
|
|
1400
1461
|
textTransform: 'none',
|
|
1401
1462
|
border: 'none',
|
|
@@ -1406,40 +1467,35 @@ const StyledButtonGroup = styled(MuiButtonGroup)(({ theme, size = 'medium' }) =>
|
|
|
1406
1467
|
transition: theme.transitions.create(['background-color', 'color', 'border-color'], {
|
|
1407
1468
|
duration: theme.transitions.duration.short,
|
|
1408
1469
|
}),
|
|
1409
|
-
//
|
|
1410
|
-
|
|
1470
|
+
// Selected state — double selector for specificity over MUI ToggleButton defaults
|
|
1471
|
+
[`&.${toggleButtonClasses.selected}.${toggleButtonClasses.selected}`]: {
|
|
1411
1472
|
backgroundColor: semanticColors.surfaces.white,
|
|
1412
1473
|
color: semanticColors.buttons.tertiary.default,
|
|
1413
1474
|
fontWeight: typography.fontWeight.semiBold,
|
|
1414
1475
|
},
|
|
1415
1476
|
// Hover state
|
|
1416
|
-
|
|
1477
|
+
[`&:hover, &.${toggleButtonClasses.selected}:hover`]: {
|
|
1417
1478
|
backgroundColor: semanticColors.buttons.secondary.hoverBackground,
|
|
1418
|
-
borderRight: `1px solid ${semanticColors.border.primary}`,
|
|
1419
1479
|
},
|
|
1420
1480
|
// Focus visible for keyboard navigation
|
|
1421
|
-
|
|
1422
|
-
outline: `2px solid ${semanticColors.
|
|
1481
|
+
'&.Mui-focusVisible': {
|
|
1482
|
+
outline: `2px solid ${semanticColors.border.focus}`,
|
|
1423
1483
|
outlineOffset: -2,
|
|
1424
1484
|
zIndex: 1,
|
|
1425
1485
|
},
|
|
1426
1486
|
// First button: rounded left edge
|
|
1427
|
-
[`&.${
|
|
1487
|
+
[`&.${toggleButtonGroupClasses.firstButton}`]: {
|
|
1428
1488
|
borderTopLeftRadius: borderRadius.full,
|
|
1429
1489
|
borderBottomLeftRadius: borderRadius.full,
|
|
1430
1490
|
},
|
|
1431
1491
|
// Last button: rounded right edge, no right border
|
|
1432
|
-
[`&.${
|
|
1492
|
+
[`&.${toggleButtonGroupClasses.lastButton}`]: {
|
|
1433
1493
|
borderTopRightRadius: borderRadius.full,
|
|
1434
1494
|
borderBottomRightRadius: borderRadius.full,
|
|
1435
1495
|
borderRight: 'none',
|
|
1436
1496
|
},
|
|
1437
|
-
// Middle buttons: no border radius
|
|
1438
|
-
[`&.${buttonGroupClasses.middleButton}`]: {
|
|
1439
|
-
borderRadius: 0,
|
|
1440
|
-
},
|
|
1441
1497
|
// Disabled state
|
|
1442
|
-
[`&.${
|
|
1498
|
+
[`&.${toggleButtonClasses.disabled}`]: {
|
|
1443
1499
|
backgroundColor: semanticColors.buttons.secondary.disabledBackground,
|
|
1444
1500
|
color: semanticColors.typography.button.disabled,
|
|
1445
1501
|
cursor: 'not-allowed',
|
|
@@ -1449,29 +1505,27 @@ const StyledButtonGroup = styled(MuiButtonGroup)(({ theme, size = 'medium' }) =>
|
|
|
1449
1505
|
};
|
|
1450
1506
|
});
|
|
1451
1507
|
/**
|
|
1452
|
-
*
|
|
1508
|
+
* NeoButtonTabGroup - Button tab group container
|
|
1453
1509
|
*
|
|
1454
1510
|
* @figma https://www.figma.com/design/fQTkGSFbYyE7LiHuQJsENC/Neo---Moderne-Design-system---2025?node-id=4106-11129
|
|
1455
1511
|
*
|
|
1456
1512
|
* Figma Props Mapping:
|
|
1457
1513
|
* - Size (Sm|Md) → size prop (small|medium)
|
|
1458
|
-
* - Active button state → Controlled
|
|
1514
|
+
* - Active button state → Controlled via value/onChange props
|
|
1459
1515
|
*
|
|
1460
1516
|
* Usage:
|
|
1461
1517
|
* ```tsx
|
|
1462
|
-
* <
|
|
1463
|
-
* <
|
|
1464
|
-
* <
|
|
1465
|
-
* <
|
|
1466
|
-
* </
|
|
1518
|
+
* <NeoButtonTabGroup value={selected} onChange={(_, val) => setSelected(val)} size="medium">
|
|
1519
|
+
* <NeoButtonTab value="tab1">Tab 1</NeoButtonTab>
|
|
1520
|
+
* <NeoButtonTab value="tab2">Tab 2</NeoButtonTab>
|
|
1521
|
+
* <NeoButtonTab value="tab3">Tab 3</NeoButtonTab>
|
|
1522
|
+
* </NeoButtonTabGroup>
|
|
1467
1523
|
* ```
|
|
1468
|
-
*
|
|
1469
|
-
* Note: To show active state, add 'active' class to the selected button
|
|
1470
1524
|
*/
|
|
1471
|
-
const
|
|
1472
|
-
return jsx(
|
|
1525
|
+
const NeoButtonTabGroup = ({ size = 'medium', exclusive = true, ...props }) => {
|
|
1526
|
+
return jsx(StyledButtonTabGroup, { role: "tablist", size: size, exclusive: exclusive, ...props });
|
|
1473
1527
|
};
|
|
1474
|
-
|
|
1528
|
+
NeoButtonTabGroup.displayName = 'NeoButtonTabGroup';
|
|
1475
1529
|
|
|
1476
1530
|
// Border radius per size (from Figma)
|
|
1477
1531
|
const borderRadiusConfig = {
|
|
@@ -1545,7 +1599,7 @@ const StyledCheckbox = styled(Checkbox, {
|
|
|
1545
1599
|
height: config.size,
|
|
1546
1600
|
padding: 0,
|
|
1547
1601
|
marginTop: size === 'xs' ? 3 : 2,
|
|
1548
|
-
color: semanticColors.border.
|
|
1602
|
+
color: semanticColors.border.primary,
|
|
1549
1603
|
flexShrink: 0,
|
|
1550
1604
|
// Root element
|
|
1551
1605
|
[`&.${checkboxClasses.root}`]: {
|
|
@@ -1568,20 +1622,20 @@ const StyledCheckbox = styled(Checkbox, {
|
|
|
1568
1622
|
},
|
|
1569
1623
|
// Disabled state
|
|
1570
1624
|
[`&.${checkboxClasses.disabled}`]: {
|
|
1571
|
-
color: semanticColors.border.
|
|
1625
|
+
color: semanticColors.border.primary,
|
|
1572
1626
|
cursor: 'not-allowed',
|
|
1573
1627
|
// When checked and disabled
|
|
1574
1628
|
[`&.${checkboxClasses.checked}`]: {
|
|
1575
|
-
color: semanticColors.border.
|
|
1629
|
+
color: semanticColors.border.primary,
|
|
1576
1630
|
},
|
|
1577
1631
|
// When indeterminate and disabled
|
|
1578
1632
|
[`&.${checkboxClasses.indeterminate}`]: {
|
|
1579
|
-
color: semanticColors.border.
|
|
1633
|
+
color: semanticColors.border.primary,
|
|
1580
1634
|
},
|
|
1581
1635
|
},
|
|
1582
1636
|
// Focus visible for keyboard navigation
|
|
1583
1637
|
'&.Mui-focusVisible': {
|
|
1584
|
-
outline: `2px solid ${semanticColors.
|
|
1638
|
+
outline: `2px solid ${semanticColors.border.focus}`,
|
|
1585
1639
|
outlineOffset: 2,
|
|
1586
1640
|
borderRadius: config.borderRadius,
|
|
1587
1641
|
},
|
|
@@ -1711,7 +1765,7 @@ const StyledButtonBase = styled(ButtonBase, {
|
|
|
1711
1765
|
cursor: 'text',
|
|
1712
1766
|
// Focus visible for keyboard navigation
|
|
1713
1767
|
[`&.${buttonBaseClasses.focusVisible}`]: {
|
|
1714
|
-
outline: `2px solid ${semanticColors.
|
|
1768
|
+
outline: `2px solid ${semanticColors.border.focus}`,
|
|
1715
1769
|
outlineOffset: 2,
|
|
1716
1770
|
},
|
|
1717
1771
|
};
|
|
@@ -1782,7 +1836,7 @@ const StyledSearchField = styled(TextField)(({ theme }) => ({
|
|
|
1782
1836
|
fontSize: theme.typography.pxToRem(typography.fontSize.default),
|
|
1783
1837
|
borderRadius: borderRadius.input,
|
|
1784
1838
|
backgroundColor: semanticColors.input.background,
|
|
1785
|
-
border: `1px solid ${semanticColors.border.
|
|
1839
|
+
border: `1px solid ${semanticColors.border.primary}`,
|
|
1786
1840
|
paddingTop: spacing.spacing_1,
|
|
1787
1841
|
paddingBottom: spacing.spacing_1,
|
|
1788
1842
|
paddingLeft: spacing.spacing_1_1_2,
|
|
@@ -2039,11 +2093,11 @@ const ChevronDownIcon = (props) => (jsx(ChevronDown, { ...props, size: spacing.s
|
|
|
2039
2093
|
const StyledSelect = styled(MuiSelect)({
|
|
2040
2094
|
minHeight: spacing.spacing_5,
|
|
2041
2095
|
backgroundColor: semanticColors.input.background,
|
|
2042
|
-
border: `1px solid ${semanticColors.border.
|
|
2096
|
+
border: `1px solid ${semanticColors.border.primary}`,
|
|
2043
2097
|
borderRadius: `${borderRadius.input}px`,
|
|
2044
2098
|
'&:hover': {
|
|
2045
2099
|
backgroundColor: semanticColors.input.hoverBackground,
|
|
2046
|
-
borderColor: semanticColors.border.
|
|
2100
|
+
borderColor: semanticColors.border.primary,
|
|
2047
2101
|
},
|
|
2048
2102
|
'&.Mui-focused': {
|
|
2049
2103
|
backgroundColor: semanticColors.input.background,
|
|
@@ -2159,7 +2213,7 @@ const StyledGridFilterPanel = styled(GridFilterPanel)({
|
|
|
2159
2213
|
position: 'relative',
|
|
2160
2214
|
minHeight: spacing.spacing_5,
|
|
2161
2215
|
backgroundColor: semanticColors.input.background,
|
|
2162
|
-
border: `1px solid ${semanticColors.border.
|
|
2216
|
+
border: `1px solid ${semanticColors.border.primary}`,
|
|
2163
2217
|
borderRadius: `${borderRadius.input}px`,
|
|
2164
2218
|
fontSize: typography.fontSize.default,
|
|
2165
2219
|
fontWeight: typography.fontWeight.regular,
|
|
@@ -2167,11 +2221,11 @@ const StyledGridFilterPanel = styled(GridFilterPanel)({
|
|
|
2167
2221
|
},
|
|
2168
2222
|
[`& .${gridClasses.filterForm} .${inputBaseClasses.root}:hover`]: {
|
|
2169
2223
|
backgroundColor: semanticColors.input.hoverBackground,
|
|
2170
|
-
borderColor: semanticColors.border.
|
|
2224
|
+
borderColor: semanticColors.border.primary,
|
|
2171
2225
|
},
|
|
2172
2226
|
[`& .${gridClasses.filterForm} .${inputBaseClasses.root}.${inputBaseClasses.focused}`]: {
|
|
2173
2227
|
backgroundColor: semanticColors.input.background,
|
|
2174
|
-
borderColor: semanticColors.border.
|
|
2228
|
+
borderColor: semanticColors.border.primary,
|
|
2175
2229
|
},
|
|
2176
2230
|
[`& .${gridClasses.filterForm} .${inputBaseClasses.root}::before`]: {
|
|
2177
2231
|
display: 'none',
|
|
@@ -2595,11 +2649,11 @@ const outlinedColorStyles = {
|
|
|
2595
2649
|
},
|
|
2596
2650
|
};
|
|
2597
2651
|
const filledColorStyles = {
|
|
2598
|
-
default: semanticColors.status.neutral.
|
|
2599
|
-
error: semanticColors.status.error.
|
|
2600
|
-
warning: semanticColors.status.warning.
|
|
2601
|
-
success: semanticColors.status.success.
|
|
2602
|
-
info: semanticColors.status.info.
|
|
2652
|
+
default: semanticColors.status.neutral.default,
|
|
2653
|
+
error: semanticColors.status.error.default,
|
|
2654
|
+
warning: semanticColors.status.warning.default,
|
|
2655
|
+
success: semanticColors.status.success.default,
|
|
2656
|
+
info: semanticColors.status.info.default,
|
|
2603
2657
|
violet: colors.violet[500],
|
|
2604
2658
|
beta: colors.digitalBlue[300],
|
|
2605
2659
|
};
|
|
@@ -3207,7 +3261,7 @@ const StyledIconButton = styled(IconButton, {
|
|
|
3207
3261
|
},
|
|
3208
3262
|
// Focus visible for keyboard navigation
|
|
3209
3263
|
'&:focus-visible': {
|
|
3210
|
-
outline: `2px solid ${semanticColors.
|
|
3264
|
+
outline: `2px solid ${semanticColors.border.focus}`,
|
|
3211
3265
|
outlineOffset: 2,
|
|
3212
3266
|
},
|
|
3213
3267
|
};
|
|
@@ -3547,7 +3601,7 @@ const sizeMap = {
|
|
|
3547
3601
|
};
|
|
3548
3602
|
const StyledBadge = styled(Badge)(({ ownerState }) => {
|
|
3549
3603
|
const size = sizeMap[ownerState.size];
|
|
3550
|
-
const color = semanticColors.status[ownerState.color].
|
|
3604
|
+
const color = semanticColors.status[ownerState.color].default;
|
|
3551
3605
|
return {
|
|
3552
3606
|
[`& .${badgeClasses.badge}`]: {
|
|
3553
3607
|
width: size,
|
|
@@ -3575,7 +3629,7 @@ const StyledBadge = styled(Badge)(({ ownerState }) => {
|
|
|
3575
3629
|
*/
|
|
3576
3630
|
const NeoDot = ({ size = 'medium', variant = 'solid', color = 'neutral', ...props }) => {
|
|
3577
3631
|
const dotSize = sizeMap[size];
|
|
3578
|
-
const mediumColor = semanticColors.status[color].
|
|
3632
|
+
const mediumColor = semanticColors.status[color].default;
|
|
3579
3633
|
const lightColor = semanticColors.status[color].light;
|
|
3580
3634
|
// For outline variant, use SVG for precise control
|
|
3581
3635
|
const renderDot = () => {
|
|
@@ -3941,6 +3995,56 @@ const NeoFooter = ({ variant = 'pagination', showShadow = false, loading = false
|
|
|
3941
3995
|
};
|
|
3942
3996
|
NeoFooter.displayName = 'NeoFooter';
|
|
3943
3997
|
|
|
3998
|
+
/**
|
|
3999
|
+
* Shared color palette for avatar components (GeneralAvatar, NavigationAvatar).
|
|
4000
|
+
* Maps color index (1-7) to background color token pairs.
|
|
4001
|
+
*/
|
|
4002
|
+
const avatarColorPalette = {
|
|
4003
|
+
1: { bg: colors.digitalBlue[100] },
|
|
4004
|
+
2: { bg: colors.digitalGreen[100] },
|
|
4005
|
+
3: { bg: colors.gold[100] },
|
|
4006
|
+
4: { bg: colors.red[100] },
|
|
4007
|
+
5: { bg: colors.violet[100] },
|
|
4008
|
+
6: { bg: colors.tealGreen[100] },
|
|
4009
|
+
7: { bg: colors.orange[100] },
|
|
4010
|
+
};
|
|
4011
|
+
|
|
4012
|
+
const sizeConfig$1 = {
|
|
4013
|
+
small: { width: spacing.spacing_4, height: spacing.spacing_4, fontSize: typography.fontSize.xs },
|
|
4014
|
+
medium: { width: spacing.spacing_5, height: spacing.spacing_5, fontSize: typography.fontSize.sm },
|
|
4015
|
+
};
|
|
4016
|
+
const StyledAvatar = styled(Avatar, {
|
|
4017
|
+
shouldForwardProp: prop => prop !== 'avatarSize' && prop !== 'colorIndex',
|
|
4018
|
+
})(({ theme, avatarSize, colorIndex }) => {
|
|
4019
|
+
const size = sizeConfig$1[avatarSize];
|
|
4020
|
+
const palette = avatarColorPalette[colorIndex];
|
|
4021
|
+
return {
|
|
4022
|
+
boxSizing: 'border-box',
|
|
4023
|
+
width: size.width,
|
|
4024
|
+
height: size.height,
|
|
4025
|
+
fontSize: theme.typography.pxToRem(size.fontSize),
|
|
4026
|
+
fontFamily: typography.fontFamily.body,
|
|
4027
|
+
fontWeight: typography.fontWeight.regular,
|
|
4028
|
+
lineHeight: 1,
|
|
4029
|
+
color: semanticColors.typography.body,
|
|
4030
|
+
backgroundColor: palette ? palette.bg : undefined,
|
|
4031
|
+
border: `1px solid ${semanticColors.border.primary}`,
|
|
4032
|
+
'&:focus-visible': {
|
|
4033
|
+
...focusRingStyles,
|
|
4034
|
+
borderColor: semanticColors.border.focus,
|
|
4035
|
+
},
|
|
4036
|
+
};
|
|
4037
|
+
});
|
|
4038
|
+
/**
|
|
4039
|
+
* NeoGeneralAvatar - Avatar with image or colored initials display
|
|
4040
|
+
*
|
|
4041
|
+
* @figma https://www.figma.com/design/fQTkGSFbYyE7LiHuQJsENC?node-id=9600-185
|
|
4042
|
+
*/
|
|
4043
|
+
const NeoGeneralAvatar = ({ size = 'medium', colorIndex = 0, children, ...props }) => {
|
|
4044
|
+
return (jsx(StyledAvatar, { avatarSize: size, colorIndex: colorIndex, ...props, children: children }));
|
|
4045
|
+
};
|
|
4046
|
+
NeoGeneralAvatar.displayName = 'NeoGeneralAvatar';
|
|
4047
|
+
|
|
3944
4048
|
const customProps$1 = ['iconSize'];
|
|
3945
4049
|
const StyledIconWrapper = styled('div', {
|
|
3946
4050
|
shouldForwardProp: prop => !customProps$1.includes(prop),
|
|
@@ -4122,9 +4226,9 @@ const StyledInputBase = styled(InputBase, {
|
|
|
4122
4226
|
},
|
|
4123
4227
|
medium: {
|
|
4124
4228
|
height: spacing.spacing_5_1_2,
|
|
4125
|
-
padding: `${spacing.
|
|
4229
|
+
padding: `${spacing.spacing_1_1_4}px ${spacing.spacing_2}px ${spacing.spacing_1_1_4}px ${startAdornment ? 0 : spacing.spacing_2}px`,
|
|
4126
4230
|
fontSize: theme.typography.pxToRem(typography.fontSize.default),
|
|
4127
|
-
borderRadius:
|
|
4231
|
+
borderRadius: spacing.spacing_8,
|
|
4128
4232
|
},
|
|
4129
4233
|
};
|
|
4130
4234
|
const sizeStyles = sizeConfig[size];
|
|
@@ -4133,7 +4237,7 @@ const StyledInputBase = styled(InputBase, {
|
|
|
4133
4237
|
fontSize: sizeStyles.fontSize,
|
|
4134
4238
|
borderRadius: sizeStyles.borderRadius,
|
|
4135
4239
|
backgroundColor: semanticColors.input.background,
|
|
4136
|
-
border: `1px solid ${destructive ? semanticColors.status.error.
|
|
4240
|
+
border: `1px solid ${destructive ? semanticColors.status.error.default : semanticColors.border.primary}`,
|
|
4137
4241
|
transition: theme.transitions.create(['border-color', 'background-color'], {
|
|
4138
4242
|
duration: theme.transitions.duration.short,
|
|
4139
4243
|
}),
|
|
@@ -4147,19 +4251,21 @@ const StyledInputBase = styled(InputBase, {
|
|
|
4147
4251
|
// Hover state
|
|
4148
4252
|
'&:hover': {
|
|
4149
4253
|
backgroundColor: semanticColors.input.hoverBackground,
|
|
4150
|
-
borderColor: destructive
|
|
4254
|
+
borderColor: destructive
|
|
4255
|
+
? semanticColors.status.error.default
|
|
4256
|
+
: semanticColors.border.primary,
|
|
4151
4257
|
},
|
|
4152
4258
|
// Focused state
|
|
4153
4259
|
[`&.${inputBaseClasses.focused}`]: {
|
|
4154
4260
|
backgroundColor: semanticColors.input.background,
|
|
4155
4261
|
borderColor: destructive
|
|
4156
|
-
? semanticColors.status.error.
|
|
4262
|
+
? semanticColors.status.error.default
|
|
4157
4263
|
: semanticColors.buttons.primary.default,
|
|
4158
4264
|
},
|
|
4159
4265
|
// Disabled state
|
|
4160
4266
|
[`&.${inputBaseClasses.disabled}`]: {
|
|
4161
4267
|
backgroundColor: semanticColors.input.disabledBackground,
|
|
4162
|
-
borderColor: semanticColors.border.
|
|
4268
|
+
borderColor: semanticColors.border.primary,
|
|
4163
4269
|
color: semanticColors.icons.disabled,
|
|
4164
4270
|
[`& .${inputBaseClasses.input}`]: {
|
|
4165
4271
|
WebkitTextFillColor: semanticColors.icons.disabled,
|
|
@@ -4167,11 +4273,11 @@ const StyledInputBase = styled(InputBase, {
|
|
|
4167
4273
|
},
|
|
4168
4274
|
// Error state
|
|
4169
4275
|
[`&.${inputBaseClasses.error}`]: {
|
|
4170
|
-
borderColor: semanticColors.status.error.
|
|
4276
|
+
borderColor: semanticColors.status.error.default,
|
|
4171
4277
|
},
|
|
4172
4278
|
// Adornment styling
|
|
4173
4279
|
[`& .${inputAdornmentClasses.root}`]: {
|
|
4174
|
-
color: destructive ? semanticColors.status.error.
|
|
4280
|
+
color: destructive ? semanticColors.status.error.default : semanticColors.icons.placeholder,
|
|
4175
4281
|
},
|
|
4176
4282
|
};
|
|
4177
4283
|
});
|
|
@@ -4185,7 +4291,7 @@ const StyledFormHelperText = styled(FormHelperText, {
|
|
|
4185
4291
|
fontSize: theme.typography.pxToRem(typography.fontSize.sm),
|
|
4186
4292
|
color: semanticColors.typography.input.helper,
|
|
4187
4293
|
[`&.${formHelperTextClasses.error}`]: {
|
|
4188
|
-
color: semanticColors.status.error.
|
|
4294
|
+
color: semanticColors.status.error.default,
|
|
4189
4295
|
},
|
|
4190
4296
|
[`&.${formHelperTextClasses.disabled}`]: {
|
|
4191
4297
|
color: semanticColors.icons.disabled,
|
|
@@ -4485,7 +4591,7 @@ const StyledListItemButton = styled(ListItemButton)(({ theme }) => ({
|
|
|
4485
4591
|
transition: theme.transitions.create(['border', 'background-color']),
|
|
4486
4592
|
// Active (selected) state
|
|
4487
4593
|
[`&.${listItemButtonClasses.selected}`]: {
|
|
4488
|
-
border: `2px solid ${semanticColors.
|
|
4594
|
+
border: `2px solid ${semanticColors.buttons.primary.default}`,
|
|
4489
4595
|
backgroundColor: theme.palette.common.white,
|
|
4490
4596
|
'&:hover': {
|
|
4491
4597
|
backgroundColor: theme.palette.common.white,
|
|
@@ -4519,9 +4625,9 @@ const StyledListItemButton = styled(ListItemButton)(({ theme }) => ({
|
|
|
4519
4625
|
},
|
|
4520
4626
|
// Focus state
|
|
4521
4627
|
[`&.${listItemButtonClasses.focusVisible}`]: {
|
|
4522
|
-
outline: `2px solid ${semanticColors.
|
|
4628
|
+
outline: `2px solid ${semanticColors.buttons.primary.default}`,
|
|
4523
4629
|
outlineOffset: 2,
|
|
4524
|
-
border: `2px solid ${semanticColors.
|
|
4630
|
+
border: `2px solid ${semanticColors.buttons.primary.default}`,
|
|
4525
4631
|
backgroundColor: theme.palette.common.white,
|
|
4526
4632
|
[`& .${listItemIconClasses.root}`]: {
|
|
4527
4633
|
color: semanticColors.icons.default,
|
|
@@ -4580,7 +4686,7 @@ const StyledListItemButton = styled(ListItemButton)(({ theme }) => ({
|
|
|
4580
4686
|
* - showIcon → Conditional rendering of ListItemIcon child
|
|
4581
4687
|
*
|
|
4582
4688
|
* Design Tokens Used:
|
|
4583
|
-
* - semanticColors.
|
|
4689
|
+
* - semanticColors.buttons.primary.default (#2f42ff) - Active border
|
|
4584
4690
|
* - semanticColors.border.primary (#d1d5db) - Default/disabled border
|
|
4585
4691
|
* - semanticColors.icons.default (#1f2937) - Active icon color
|
|
4586
4692
|
* - semanticColors.icons.disabled (#d1d5db) - Deselected/disabled icon color
|
|
@@ -4613,17 +4719,17 @@ const StyledCard = styled(MuiCard, {
|
|
|
4613
4719
|
flexDirection: 'column',
|
|
4614
4720
|
gap: theme.spacing(2), // 16px
|
|
4615
4721
|
backgroundColor: semanticColors.surfaces.card,
|
|
4616
|
-
border: `1px solid ${selected ? semanticColors.
|
|
4722
|
+
border: `1px solid ${selected ? semanticColors.buttons.primary.default : semanticColors.border.primary}`,
|
|
4617
4723
|
borderRadius: borderRadius.xS,
|
|
4618
4724
|
boxShadow: selected ? activeShadow$1 : 'none',
|
|
4619
4725
|
transition: theme.transitions.create(['border-color', 'background-color', 'box-shadow']),
|
|
4620
4726
|
cursor: 'pointer',
|
|
4621
4727
|
'&:hover': {
|
|
4622
|
-
borderColor: semanticColors.
|
|
4728
|
+
borderColor: semanticColors.buttons.primary.default,
|
|
4623
4729
|
boxShadow: activeShadow$1,
|
|
4624
4730
|
},
|
|
4625
4731
|
'&:focus-visible': {
|
|
4626
|
-
borderColor: semanticColors.
|
|
4732
|
+
borderColor: semanticColors.buttons.primary.default,
|
|
4627
4733
|
...focusRingStyles,
|
|
4628
4734
|
},
|
|
4629
4735
|
...(disabled && {
|
|
@@ -4727,8 +4833,8 @@ const Description$1 = styled('p')(({ theme }) => ({
|
|
|
4727
4833
|
* Design Tokens Used:
|
|
4728
4834
|
* - semanticColors.surfaces.card (#FFFFFF) - Default card background
|
|
4729
4835
|
* - semanticColors.status.info.light (#f2f3ff) - Active/focused card background
|
|
4730
|
-
* - semanticColors.border.
|
|
4731
|
-
* - semanticColors.
|
|
4836
|
+
* - semanticColors.border.primary (#d1d5db) - Default border
|
|
4837
|
+
* - semanticColors.buttons.primary.default (#2f42ff) - Active/focused border
|
|
4732
4838
|
* - shadows.focusWhite1 - Inner white focus ring (2px spread)
|
|
4733
4839
|
* - shadows.focusBlue2 - Outer blue focus ring (4px spread)
|
|
4734
4840
|
* - colors.grey[800] (#1F2937) - Text color
|
|
@@ -4751,10 +4857,12 @@ const StyledLargeCard = styled(MuiCard, {
|
|
|
4751
4857
|
const isActive = cardState === 'active';
|
|
4752
4858
|
const isDisabled = cardState === 'disabled';
|
|
4753
4859
|
const isFocused = cardState === 'focused';
|
|
4754
|
-
const activeBorderColor = isLight
|
|
4860
|
+
const activeBorderColor = isLight
|
|
4861
|
+
? semanticColors.buttons.primary.default
|
|
4862
|
+
: colors.digitalGreen[300];
|
|
4755
4863
|
const defaultBorderColor = isLight
|
|
4756
|
-
? semanticColors.border.
|
|
4757
|
-
: `${semanticColors.border.
|
|
4864
|
+
? semanticColors.border.primary
|
|
4865
|
+
: `${semanticColors.border.primary}80`;
|
|
4758
4866
|
return {
|
|
4759
4867
|
width: 340,
|
|
4760
4868
|
height: 162,
|
|
@@ -4770,7 +4878,7 @@ const StyledLargeCard = styled(MuiCard, {
|
|
|
4770
4878
|
overflow: 'hidden',
|
|
4771
4879
|
...(isFocused && focusRingStyles),
|
|
4772
4880
|
'&:focus-visible': {
|
|
4773
|
-
borderColor: isLight ? semanticColors.
|
|
4881
|
+
borderColor: isLight ? semanticColors.buttons.primary.default : colors.digitalGreen[300],
|
|
4774
4882
|
...focusRingStyles,
|
|
4775
4883
|
},
|
|
4776
4884
|
...(isDisabled && {
|
|
@@ -4850,8 +4958,8 @@ const ButtonsRow = styled('div')({
|
|
|
4850
4958
|
* Design Tokens Used:
|
|
4851
4959
|
* - semanticColors.surfaces.card (#ffffff) - Light theme background
|
|
4852
4960
|
* - colors.grey[800] (#1f2937) - Dark theme background
|
|
4853
|
-
* - semanticColors.border.
|
|
4854
|
-
* - semanticColors.
|
|
4961
|
+
* - semanticColors.border.primary (#d1d5db) - Default border (50% opacity on dark)
|
|
4962
|
+
* - semanticColors.buttons.primary.default (#2f42ff) - Active/focused border (light theme)
|
|
4855
4963
|
* - colors.digitalGreen[300] (#88fe9b) - Active/focused border (dark theme)
|
|
4856
4964
|
* - borderRadius.xS (4px) - Corner radius
|
|
4857
4965
|
* - shadows.focusWhite1 + shadows.focusBlue2 - Focus ring
|
|
@@ -4923,7 +5031,7 @@ NeoMenu.displayName = 'NeoMenu';
|
|
|
4923
5031
|
const StyledDialog = styled(Dialog)({
|
|
4924
5032
|
[`& .${dialogClasses.paper}`]: {
|
|
4925
5033
|
borderRadius: borderRadius.card,
|
|
4926
|
-
border: `1px solid ${semanticColors.border.
|
|
5034
|
+
border: `1px solid ${semanticColors.border.primary}`,
|
|
4927
5035
|
boxShadow: 'none',
|
|
4928
5036
|
},
|
|
4929
5037
|
[`& .${dialogClasses.container}`]: {
|
|
@@ -5106,6 +5214,34 @@ const NeoModalFooter = ({ leadingContent, children }) => {
|
|
|
5106
5214
|
};
|
|
5107
5215
|
NeoModalFooter.displayName = 'NeoModalFooter';
|
|
5108
5216
|
|
|
5217
|
+
const NavigationAvatarContainer = styled('div')({
|
|
5218
|
+
display: 'flex',
|
|
5219
|
+
boxSizing: 'border-box',
|
|
5220
|
+
width: spacing.spacing_5_1_2,
|
|
5221
|
+
height: spacing.spacing_5_1_2,
|
|
5222
|
+
padding: spacing.spacing_3_4,
|
|
5223
|
+
justifyContent: 'center',
|
|
5224
|
+
alignItems: 'center',
|
|
5225
|
+
borderRadius: '50%',
|
|
5226
|
+
border: `1px solid ${semanticColors.border.primary}`,
|
|
5227
|
+
backgroundColor: semanticColors.buttons.secondary.defaultBackground,
|
|
5228
|
+
'&:focus-within': {
|
|
5229
|
+
borderColor: semanticColors.border.focus,
|
|
5230
|
+
},
|
|
5231
|
+
});
|
|
5232
|
+
/**
|
|
5233
|
+
* NeoNavigationAvatar - Compact avatar for navigation contexts
|
|
5234
|
+
*
|
|
5235
|
+
* Wraps NeoGeneralAvatar (size="small") in a 44px container with 6px padding,
|
|
5236
|
+
* providing a larger interactive area for navigation UI.
|
|
5237
|
+
*
|
|
5238
|
+
* @figma https://www.figma.com/design/fQTkGSFbYyE7LiHuQJsENC?node-id=11325-102
|
|
5239
|
+
*/
|
|
5240
|
+
const NeoNavigationAvatar = ({ colorIndex = 0, children, ...props }) => {
|
|
5241
|
+
return (jsx(NavigationAvatarContainer, { children: jsx(NeoGeneralAvatar, { size: "small", colorIndex: colorIndex, ...props, children: children }) }));
|
|
5242
|
+
};
|
|
5243
|
+
NeoNavigationAvatar.displayName = 'NeoNavigationAvatar';
|
|
5244
|
+
|
|
5109
5245
|
const customProps = ['selected'];
|
|
5110
5246
|
const StyledRoot = styled(ButtonBase, {
|
|
5111
5247
|
shouldForwardProp: prop => !customProps.includes(prop),
|
|
@@ -5445,7 +5581,7 @@ const StyledLinearProgress$1 = styled(LinearProgress, {
|
|
|
5445
5581
|
// Cancelled variant uses warning color
|
|
5446
5582
|
'&[data-variant="cancelled"]': {
|
|
5447
5583
|
[`& .${linearProgressClasses.bar}`]: {
|
|
5448
|
-
backgroundColor: semanticColors.status.warning.
|
|
5584
|
+
backgroundColor: semanticColors.status.warning.default,
|
|
5449
5585
|
},
|
|
5450
5586
|
},
|
|
5451
5587
|
}));
|
|
@@ -5510,7 +5646,7 @@ const StyledTextField = styled(TextField)(({ theme }) => ({
|
|
|
5510
5646
|
fontSize: theme.typography.pxToRem(typography.fontSize.default),
|
|
5511
5647
|
borderRadius: borderRadius.input,
|
|
5512
5648
|
backgroundColor: semanticColors.input.background,
|
|
5513
|
-
border: `1px solid ${semanticColors.border.
|
|
5649
|
+
border: `1px solid ${semanticColors.border.primary}`,
|
|
5514
5650
|
paddingTop: spacing.spacing_1,
|
|
5515
5651
|
paddingBottom: spacing.spacing_1,
|
|
5516
5652
|
paddingLeft: spacing.spacing_1_1_2,
|
|
@@ -5605,7 +5741,7 @@ NeoQuickFilter.displayName = 'NeoQuickFilter';
|
|
|
5605
5741
|
const UncheckedIcon = ({ size }) => {
|
|
5606
5742
|
const dimensions = size === 'small' ? 16 : 20;
|
|
5607
5743
|
const radius = size === 'small' ? 8 : 10;
|
|
5608
|
-
return (jsxs("svg", { width: dimensions, height: dimensions, viewBox: `0 0 ${dimensions} ${dimensions}`, fill: "none", "aria-hidden": "true", children: [jsx("title", { children: "Unchecked radio button" }), jsx("circle", { cx: dimensions / 2, cy: dimensions / 2, r: radius - 0.5, stroke: semanticColors.border.
|
|
5744
|
+
return (jsxs("svg", { width: dimensions, height: dimensions, viewBox: `0 0 ${dimensions} ${dimensions}`, fill: "none", "aria-hidden": "true", children: [jsx("title", { children: "Unchecked radio button" }), jsx("circle", { cx: dimensions / 2, cy: dimensions / 2, r: radius - 0.5, stroke: semanticColors.border.primary, strokeWidth: "1", fill: "transparent" })] }));
|
|
5609
5745
|
};
|
|
5610
5746
|
const CheckedIcon = ({ size }) => {
|
|
5611
5747
|
const dimensions = size === 'small' ? 16 : 20;
|
|
@@ -5861,19 +5997,19 @@ const StyledAlert$1 = styled(Alert, {
|
|
|
5861
5997
|
const colorMap = {
|
|
5862
5998
|
success: {
|
|
5863
5999
|
light: semanticColors.status.success.light,
|
|
5864
|
-
medium: semanticColors.status.success.
|
|
6000
|
+
medium: semanticColors.status.success.default,
|
|
5865
6001
|
},
|
|
5866
6002
|
error: {
|
|
5867
6003
|
light: semanticColors.status.error.light,
|
|
5868
|
-
medium: semanticColors.status.error.
|
|
6004
|
+
medium: semanticColors.status.error.default,
|
|
5869
6005
|
},
|
|
5870
6006
|
neutral: {
|
|
5871
6007
|
light: semanticColors.status.neutral.light,
|
|
5872
|
-
medium: semanticColors.status.neutral.
|
|
6008
|
+
medium: semanticColors.status.neutral.default,
|
|
5873
6009
|
},
|
|
5874
6010
|
info: {
|
|
5875
6011
|
light: semanticColors.status.info.light,
|
|
5876
|
-
medium: semanticColors.status.info.
|
|
6012
|
+
medium: semanticColors.status.info.default,
|
|
5877
6013
|
},
|
|
5878
6014
|
};
|
|
5879
6015
|
const severityColors = colorMap[severity];
|
|
@@ -5944,10 +6080,10 @@ const StyledAlert$1 = styled(Alert, {
|
|
|
5944
6080
|
* - Mode (Light|Dark) → variant ('outlined'|'filled')
|
|
5945
6081
|
*
|
|
5946
6082
|
* Design Tokens Used:
|
|
5947
|
-
* - status.success.light, status.success.
|
|
5948
|
-
* - status.error.light, status.error.
|
|
5949
|
-
* - status.neutral.light, status.neutral.
|
|
5950
|
-
* - status.info.light, status.info.
|
|
6083
|
+
* - status.success.light, status.success.default
|
|
6084
|
+
* - status.error.light, status.error.default
|
|
6085
|
+
* - status.neutral.light, status.neutral.default
|
|
6086
|
+
* - status.info.light, status.info.default
|
|
5951
6087
|
* - typography.tooltip, typography.bodySecondary
|
|
5952
6088
|
* - grey[800]
|
|
5953
6089
|
* - fontSize.default, fontSize.sm
|
|
@@ -5984,7 +6120,7 @@ NeoStatusBanner.displayName = 'NeoStatusBanner';
|
|
|
5984
6120
|
const NeoTabs = styled(MuiTabs)(() => ({
|
|
5985
6121
|
minHeight: spacing.spacing_5,
|
|
5986
6122
|
[`& .${tabsClasses.indicator}`]: {
|
|
5987
|
-
backgroundColor: semanticColors.
|
|
6123
|
+
backgroundColor: semanticColors.buttons.primary.default,
|
|
5988
6124
|
height: 2,
|
|
5989
6125
|
},
|
|
5990
6126
|
[`& .${tabsClasses.flexContainer}`]: {
|
|
@@ -6006,7 +6142,7 @@ const StyledTab = styled(MuiTab)(({ theme }) => ({
|
|
|
6006
6142
|
fontWeight: typography.fontWeight.semiBold,
|
|
6007
6143
|
},
|
|
6008
6144
|
[`&.${buttonBaseClasses.focusVisible}`]: {
|
|
6009
|
-
outline: `2px solid ${semanticColors.
|
|
6145
|
+
outline: `2px solid ${semanticColors.border.focus}`,
|
|
6010
6146
|
outlineOffset: -2,
|
|
6011
6147
|
},
|
|
6012
6148
|
[`&.${tabClasses.disabled}`]: {
|
|
@@ -6086,17 +6222,17 @@ const StyledAlert = styled(Alert, {
|
|
|
6086
6222
|
error: {
|
|
6087
6223
|
backgroundColor: semanticColors.status.error.light,
|
|
6088
6224
|
color: semanticColors.status.error.dark,
|
|
6089
|
-
border: `1px solid ${semanticColors.status.error.
|
|
6225
|
+
border: `1px solid ${semanticColors.status.error.default}`,
|
|
6090
6226
|
},
|
|
6091
6227
|
success: {
|
|
6092
6228
|
backgroundColor: semanticColors.status.success.light,
|
|
6093
6229
|
color: semanticColors.status.success.dark,
|
|
6094
|
-
border: `1px solid ${semanticColors.status.success.
|
|
6230
|
+
border: `1px solid ${semanticColors.status.success.default}`,
|
|
6095
6231
|
},
|
|
6096
6232
|
info: {
|
|
6097
6233
|
backgroundColor: semanticColors.status.info.light,
|
|
6098
6234
|
color: semanticColors.status.info.dark,
|
|
6099
|
-
border: `1px solid ${semanticColors.status.info.
|
|
6235
|
+
border: `1px solid ${semanticColors.status.info.default}`,
|
|
6100
6236
|
},
|
|
6101
6237
|
download: {
|
|
6102
6238
|
backgroundColor: semanticColors.surfaces.snackbarDarkMode,
|
|
@@ -6324,7 +6460,7 @@ const StyledSwitch = styled(Switch, {
|
|
|
6324
6460
|
// Focus visible for keyboard navigation
|
|
6325
6461
|
'&.Mui-focusVisible': {
|
|
6326
6462
|
[`& + .${switchClasses.track}`]: {
|
|
6327
|
-
outline: `2px solid ${semanticColors.
|
|
6463
|
+
outline: `2px solid ${semanticColors.border.focus}`,
|
|
6328
6464
|
outlineOffset: 2,
|
|
6329
6465
|
},
|
|
6330
6466
|
},
|
|
@@ -6665,7 +6801,7 @@ const StyledTreeView = styled(RichTreeViewPro)({
|
|
|
6665
6801
|
backgroundColor: semanticColors.surfaces.listHover,
|
|
6666
6802
|
},
|
|
6667
6803
|
[`& .${treeItemClasses.content}.Mui-focused`]: {
|
|
6668
|
-
boxShadow: `inset 0 0 0 2px ${semanticColors.
|
|
6804
|
+
boxShadow: `inset 0 0 0 2px ${semanticColors.border.focus}`,
|
|
6669
6805
|
backgroundColor: 'transparent',
|
|
6670
6806
|
},
|
|
6671
6807
|
[`& .${treeItemClasses.content}.Mui-selected`]: {
|
|
@@ -6676,7 +6812,7 @@ const StyledTreeView = styled(RichTreeViewPro)({
|
|
|
6676
6812
|
},
|
|
6677
6813
|
[`& .${treeItemClasses.content}.Mui-selected.Mui-focused`]: {
|
|
6678
6814
|
backgroundColor: semanticColors.surfaces.listHover,
|
|
6679
|
-
boxShadow: `inset 0 0 0 2px ${semanticColors.
|
|
6815
|
+
boxShadow: `inset 0 0 0 2px ${semanticColors.border.focus}`,
|
|
6680
6816
|
},
|
|
6681
6817
|
[`& .${treeItemClasses.label}`]: {
|
|
6682
6818
|
fontSize: typography.fontSize.xs,
|
|
@@ -6701,7 +6837,7 @@ const StyledTreeView = styled(RichTreeViewPro)({
|
|
|
6701
6837
|
|
|
6702
6838
|
// Figma-exact border radius for toggle buttons — no matching design token
|
|
6703
6839
|
const TOGGLE_BUTTON_BORDER_RADIUS = 14;
|
|
6704
|
-
const StyledToggleButtonGroup = styled(
|
|
6840
|
+
const StyledToggleButtonGroup = styled(MuiToggleButtonGroup)(({ theme }) => ({
|
|
6705
6841
|
backgroundColor: colors.grey[50],
|
|
6706
6842
|
padding: theme.spacing(0.625, 0.875),
|
|
6707
6843
|
borderRadius: borderRadius.full,
|
|
@@ -6719,7 +6855,7 @@ const StyledToggleButtonGroup = styled(ToggleButtonGroup)(({ theme }) => ({
|
|
|
6719
6855
|
},
|
|
6720
6856
|
},
|
|
6721
6857
|
}));
|
|
6722
|
-
const StyledToggleButton = styled(
|
|
6858
|
+
const StyledToggleButton = styled(MuiToggleButton)(({ theme }) => ({
|
|
6723
6859
|
padding: theme.spacing(0.625),
|
|
6724
6860
|
minWidth: 'auto',
|
|
6725
6861
|
color: semanticColors.icons.default,
|
|
@@ -6768,5 +6904,5 @@ NeoTypologyControl.displayName = 'NeoTypologyControl';
|
|
|
6768
6904
|
|
|
6769
6905
|
const version = '0.0.0-development';
|
|
6770
6906
|
|
|
6771
|
-
export { ActivityScene, CIRCLE_RADIUS, NeoActivityHeader, NeoActivityIndicatorCell, NeoAvatar, NeoBadge, NeoBanner, NeoBreadcrumbLink, NeoBreadcrumbs, NeoButton,
|
|
6907
|
+
export { ActivityScene, CIRCLE_RADIUS, NeoActivityHeader, NeoActivityIndicatorCell, NeoAvatar, NeoBadge, NeoBanner, NeoBreadcrumbLink, NeoBreadcrumbs, NeoButton, NeoButtonTab, NeoButtonTabGroup, NeoCheckbox, NeoCodeSnippet, NeoDataGrid, NeoDataGridCellContent, NeoDataGridColumnsButton, NeoDataGridColumnsPanel, NeoDataGridFilterPanel, NeoDataGridFilterPanelAddIcon, NeoDataGridFilterPanelDeleteIcon, NeoDataGridFilterPanelRemoveAllIcon, NeoDataGridFiltersButton, NeoDataGridHeaderLabel, NeoSelect as NeoDataGridSelect, NeoDatePicker, NeoDivider, NeoDot, NeoFilterChip, NeoFooter, NeoGeneralAvatar, NeoIconButton, NeoIconWrapper, NeoInfiniteScrollGrid, NeoInputField, NeoListItem, NeoListItemButton, NeoLoadingSpinner, NeoMarketplaceCard, NeoMarketplaceLargeCard, NeoMenu, NeoMenuItem, NeoModal, NeoModalContent, NeoModalFooter, NeoModalHeader, NeoMultiBadgesCell, NeoNavigationAvatar, NeoNavigationItem, NeoPageContent, NeoPaginatedGrid, NeoProgressbar, NeoQuickFilter, NeoRadio, NeoSearchChip, NeoSelect, NeoMenuItem as NeoSelectOption, NeoSkeleton, NeoStatusBadgeCell, NeoStatusBanner, NeoTab, NeoTabs, NeoTag, NeoToast, NeoToastButton, NeoToggle, NeoToolbar, NeoTooltip, NeoTreeItem, NeoTreeView, StyledToggleButton as NeoTypologyButton, NeoTypologyControl, NeoUserAvatarCell, SortedAscendingIcon, SortedDescendingIcon, UnsortedIcon, getDataGridHeaderStyles, neoRowHeights, version };
|
|
6772
6908
|
//# sourceMappingURL=index.esm.js.map
|