@okta/odyssey-react-mui 0.21.2 → 0.21.3

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/CHANGELOG.md CHANGED
@@ -3,6 +3,18 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [0.21.3](https://github.com/okta/odyssey/compare/v0.21.2...v0.21.3) (2023-04-06)
7
+
8
+ ### Features
9
+
10
+ - add Odyssey styles to Radio and Checkbox ([39ebde0](https://github.com/okta/odyssey/commit/39ebde08d4cb83f933a98d79000ac23ad15c12c9))
11
+ - **odyssey-react-mui:** add transitions to form controls, update state ui ([7388c00](https://github.com/okta/odyssey/commit/7388c00e5ca112ff12d429e45996ab5aa557a36a))
12
+
13
+ ### Bug Fixes
14
+
15
+ - **odyssey-react-mui:** make text disabled color more a11y-friendly ([372a010](https://github.com/okta/odyssey/commit/372a010b934efc8421c42c8fa7d3a9323af8182f))
16
+ - upgraded loader-utils and fastify for security ([#1734](https://github.com/okta/odyssey/issues/1734)) ([d6f3d27](https://github.com/okta/odyssey/commit/d6f3d27daefd1994059463ad33f9adceb35e36a0))
17
+
6
18
  ## [0.21.2](https://github.com/okta/odyssey/compare/v0.21.1...v0.21.2) (2023-03-30)
7
19
 
8
20
  ### Features
@@ -1 +1 @@
1
- {"version":3,"file":"components.d.ts","sourceRoot":"","sources":["../../../src/theme/components.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AA4B7C,eAAO,MAAM,UAAU,EAAE,YAAY,CAAC,YAAY,CAmxDjD,CAAC"}
1
+ {"version":3,"file":"components.d.ts","sourceRoot":"","sources":["../../../src/theme/components.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AA8B7C,eAAO,MAAM,UAAU,EAAE,YAAY,CAAC,YAAY,CAs5DjD,CAAC"}
@@ -25,8 +25,9 @@ import { tableHeadClasses } from "@mui/material/TableHead";
25
25
  import { tableRowClasses } from "@mui/material/TableRow";
26
26
  import { tableSortLabelClasses } from "@mui/material/TableSortLabel";
27
27
  import { tooltipClasses } from "@mui/material/Tooltip";
28
- import { AlertTriangleFilledIcon, ArrowDownIcon, CheckCircleFilledIcon, ChevronDownIcon, CloseCircleFilledIcon, InformationCircleFilledIcon } from "../iconDictionary/index.js";
28
+ import { AlertTriangleFilledIcon, ArrowDownIcon, CheckIcon, CheckCircleFilledIcon, ChevronDownIcon, CloseCircleFilledIcon, InformationCircleFilledIcon, SubtractIcon } from "../iconDictionary/index.js";
29
29
  import { jsx as _jsx } from "react/jsx-runtime";
30
+ import { Fragment as _Fragment } from "react/jsx-runtime";
30
31
  export const components = {
31
32
  MuiAlert: {
32
33
  defaultProps: {
@@ -418,7 +419,10 @@ export const components = {
418
419
  },
419
420
  MuiCheckbox: {
420
421
  defaultProps: {
421
- size: "small"
422
+ size: "small",
423
+ icon: _jsx(_Fragment, {}),
424
+ checkedIcon: _jsx(CheckIcon, {}),
425
+ indeterminateIcon: _jsx(SubtractIcon, {})
422
426
  },
423
427
  styleOverrides: {
424
428
  root: _ref17 => {
@@ -426,20 +430,69 @@ export const components = {
426
430
  theme
427
431
  } = _ref17;
428
432
  return {
429
- borderRadius: "4px",
430
- "&:hover": {
431
- backgroundColor: "transparent"
432
- },
433
+ width: `${theme.typography.ui.lineHeight}em`,
434
+ height: `${theme.typography.ui.lineHeight}em`,
435
+ borderRadius: theme.mixins.borderRadius,
436
+ borderWidth: theme.mixins.borderWidth,
437
+ borderStyle: theme.mixins.borderStyle,
438
+ borderColor: theme.palette.grey[500],
433
439
  padding: 0,
440
+ boxShadow: `0 0 0 0 transparent`,
441
+ transition: theme.transitions.create(["border-color", "background-color", "box-shadow"], {
442
+ duration: theme.transitions.duration.short
443
+ }),
444
+ ".MuiSvgIcon-root": {
445
+ color: theme.palette.common.white,
446
+ width: "0.5em",
447
+ height: "0.5em",
448
+ transition: theme.transitions.create(["color"], {
449
+ duration: theme.transitions.duration.short
450
+ })
451
+ },
452
+ "&.Mui-checked": {
453
+ backgroundColor: theme.palette.primary.main,
454
+ borderColor: theme.palette.primary.main,
455
+ ".MuiFormControlLabel-root:hover > &": {
456
+ backgroundColor: theme.palette.primary.dark,
457
+ borderColor: theme.palette.primary.dark
458
+ }
459
+ },
460
+ ".MuiFormControlLabel-root:hover > &": {
461
+ backgroundColor: "transparent",
462
+ borderColor: theme.palette.grey[900]
463
+ },
464
+ ".Mui-error:hover > &": {
465
+ borderColor: theme.palette.error.dark,
466
+ "&.Mui-checked": {
467
+ backgroundColor: theme.palette.error.dark,
468
+ borderColor: theme.palette.error.dark
469
+ }
470
+ },
434
471
  ".Mui-error > &": {
435
- color: theme.palette.error.main,
436
- "&:hover": {
437
- color: theme.palette.error.dark
472
+ borderColor: theme.palette.error.main,
473
+ "&.Mui-checked": {
474
+ backgroundColor: theme.palette.error.main,
475
+ borderColor: theme.palette.error.main
476
+ },
477
+ "&.Mui-focusVisible": {
478
+ boxShadow: `0 0 0 2px ${theme.palette.background.default}, 0 0 0 4px ${theme.palette.error.main}`
438
479
  }
439
480
  },
440
- ".Mui-error > &.Mui-checked": {
441
- "&:hover": {
442
- color: theme.palette.error.dark
481
+ "&.Mui-focusVisible": {
482
+ borderColor: theme.palette.grey[900],
483
+ boxShadow: `0 0 0 2px ${theme.palette.background.default}, 0 0 0 4px ${theme.palette.primary.main}`,
484
+ outline: "2px solid transparent",
485
+ outlineOffset: "1px"
486
+ },
487
+ "&.Mui-disabled": {
488
+ backgroundColor: theme.palette.grey[50],
489
+ borderColor: theme.palette.grey[300],
490
+ ".Mui-error > &": {
491
+ backgroundColor: theme.palette.grey[50],
492
+ borderColor: theme.palette.grey[300]
493
+ },
494
+ ".MuiSvgIcon-root": {
495
+ color: theme.palette.common.black
443
496
  }
444
497
  }
445
498
  };
@@ -1158,10 +1211,16 @@ export const components = {
1158
1211
  borderStyle: theme.mixins.borderStyle,
1159
1212
  borderRadius: theme.mixins.borderRadius,
1160
1213
  borderColor: theme.palette.grey[500],
1214
+ boxShadow: `0 0 0 0 transparent`,
1215
+ backgroundColor: theme.palette.common.white,
1216
+ transition: theme.transitions.create(["border-color", "background-color", "box-shadow"], {
1217
+ duration: theme.transitions.duration.short
1218
+ }),
1161
1219
  ...(ownerState.fullWidth && {
1162
1220
  width: "100%"
1163
1221
  }),
1164
1222
  ...(ownerState.readOnly === true && {
1223
+ borderColor: "transparent",
1165
1224
  backgroundColor: theme.palette.grey[50]
1166
1225
  }),
1167
1226
  [`&:hover`]: {
@@ -1444,7 +1503,9 @@ export const components = {
1444
1503
  },
1445
1504
  MuiRadio: {
1446
1505
  defaultProps: {
1447
- size: "small"
1506
+ size: "small",
1507
+ icon: _jsx(_Fragment, {}),
1508
+ checkedIcon: _jsx(_Fragment, {})
1448
1509
  },
1449
1510
  styleOverrides: {
1450
1511
  root: _ref43 => {
@@ -1452,21 +1513,69 @@ export const components = {
1452
1513
  theme
1453
1514
  } = _ref43;
1454
1515
  return {
1455
- "&:hover": {
1456
- backgroundColor: "transparent"
1457
- },
1516
+ width: `${theme.typography.ui.lineHeight}em`,
1517
+ height: `${theme.typography.ui.lineHeight}em`,
1518
+ borderRadius: `${theme.typography.ui.lineHeight}em`,
1519
+ borderWidth: theme.mixins.borderWidth,
1520
+ borderStyle: theme.mixins.borderStyle,
1521
+ borderColor: theme.palette.grey[500],
1458
1522
  padding: 0,
1523
+ boxShadow: `0 0 0 0 transparent`,
1524
+ transition: theme.transitions.create(["border-color", "background-color", "box-shadow"], {
1525
+ duration: theme.transitions.duration.short
1526
+ }),
1527
+ "&::before": {
1528
+ content: "''",
1529
+ position: "absolute",
1530
+ width: "0.5em",
1531
+ height: "0.5em",
1532
+ borderRadius: "50%",
1533
+ backgroundColor: "transparent",
1534
+ transition: theme.transitions.create(["background-color"], {
1535
+ duration: theme.transitions.duration.short
1536
+ })
1537
+ },
1538
+ ".MuiFormControlLabel-root:hover > &": {
1539
+ backgroundColor: "transparent",
1540
+ borderColor: theme.palette.grey[900]
1541
+ },
1542
+ ".Mui-error:hover > &": {
1543
+ backgroundColor: "transparent",
1544
+ borderColor: theme.palette.error.dark,
1545
+ "&::before": {
1546
+ backgroundColor: theme.palette.error.dark
1547
+ }
1548
+ },
1459
1549
  ".Mui-error > &": {
1460
- color: theme.palette.error.main,
1461
- "&:hover": {
1462
- color: theme.palette.error.dark
1550
+ borderColor: theme.palette.error.main,
1551
+ "&::before": {
1552
+ backgroundColor: theme.palette.error.main
1553
+ },
1554
+ "&.Mui-focusVisible": {
1555
+ boxShadow: `0 0 0 2px ${theme.palette.background.default}, 0 0 0 4px ${theme.palette.error.main}`
1463
1556
  }
1464
1557
  },
1465
1558
  "&.Mui-focusVisible": {
1466
- outlineColor: theme.palette.primary.main,
1467
- outlineOffset: 0,
1468
- outlineStyle: "solid",
1469
- outlineWidth: "2px"
1559
+ borderColor: theme.palette.grey[900],
1560
+ boxShadow: `0 0 0 2px ${theme.palette.background.default}, 0 0 0 4px ${theme.palette.primary.main}`,
1561
+ outline: "2px solid transparent",
1562
+ outlineOffset: "1px"
1563
+ },
1564
+ "&.Mui-checked": {
1565
+ position: "relative",
1566
+ "&::before": {
1567
+ backgroundColor: theme.palette.primary.main
1568
+ }
1569
+ },
1570
+ ".Mui-error > &.Mui-checked::before": {
1571
+ backgroundColor: theme.palette.error.main
1572
+ },
1573
+ "&.Mui-disabled": {
1574
+ backgroundColor: theme.palette.grey[50],
1575
+ borderColor: theme.palette.grey[300],
1576
+ "&::before": {
1577
+ backgroundColor: theme.palette.grey[300]
1578
+ }
1470
1579
  }
1471
1580
  };
1472
1581
  }