@okta/odyssey-react-mui 1.23.0 → 1.24.0

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.
Files changed (73) hide show
  1. package/CHANGELOG.md +21 -0
  2. package/dist/Autocomplete.js +2 -0
  3. package/dist/Autocomplete.js.map +1 -1
  4. package/dist/Banner.js +6 -2
  5. package/dist/Banner.js.map +1 -1
  6. package/dist/Callout.js +6 -2
  7. package/dist/Callout.js.map +1 -1
  8. package/dist/ContrastModeProvider.js +86 -0
  9. package/dist/ContrastModeProvider.js.map +1 -0
  10. package/dist/FieldHint.js +20 -6
  11. package/dist/FieldHint.js.map +1 -1
  12. package/dist/Link.js.map +1 -1
  13. package/dist/OdysseyProvider.js +40 -20
  14. package/dist/OdysseyProvider.js.map +1 -1
  15. package/dist/Stack.js +32 -0
  16. package/dist/Stack.js.map +1 -0
  17. package/dist/Tag.js +64 -22
  18. package/dist/Tag.js.map +1 -1
  19. package/dist/Typography.js +27 -6
  20. package/dist/Typography.js.map +1 -1
  21. package/dist/index.js +2 -0
  22. package/dist/index.js.map +1 -1
  23. package/dist/index.scss +8 -4
  24. package/dist/labs/datePickerTheme.js +3 -6
  25. package/dist/labs/datePickerTheme.js.map +1 -1
  26. package/dist/src/Autocomplete.d.ts +7 -1
  27. package/dist/src/Autocomplete.d.ts.map +1 -1
  28. package/dist/src/Banner.d.ts +16 -12
  29. package/dist/src/Banner.d.ts.map +1 -1
  30. package/dist/src/Callout.d.ts +9 -9
  31. package/dist/src/Callout.d.ts.map +1 -1
  32. package/dist/src/ContrastModeProvider.d.ts +34 -0
  33. package/dist/src/ContrastModeProvider.d.ts.map +1 -0
  34. package/dist/src/FieldHint.d.ts.map +1 -1
  35. package/dist/src/Link.d.ts +3 -1
  36. package/dist/src/Link.d.ts.map +1 -1
  37. package/dist/src/OdysseyProvider.d.ts +5 -3
  38. package/dist/src/OdysseyProvider.d.ts.map +1 -1
  39. package/dist/src/Stack.d.ts +33 -0
  40. package/dist/src/Stack.d.ts.map +1 -0
  41. package/dist/src/Tag.d.ts.map +1 -1
  42. package/dist/src/Typography.d.ts +3 -2
  43. package/dist/src/Typography.d.ts.map +1 -1
  44. package/dist/src/index.d.ts +6 -2
  45. package/dist/src/index.d.ts.map +1 -1
  46. package/dist/src/labs/datePickerTheme.d.ts.map +1 -1
  47. package/dist/src/theme/components.d.ts.map +1 -1
  48. package/dist/src/theme/palette.d.ts.map +1 -1
  49. package/dist/src/theme/palette.types.d.ts +2 -0
  50. package/dist/src/theme/palette.types.d.ts.map +1 -1
  51. package/dist/theme/components.js +276 -273
  52. package/dist/theme/components.js.map +1 -1
  53. package/dist/theme/palette.js +2 -1
  54. package/dist/theme/palette.js.map +1 -1
  55. package/dist/theme/palette.types.js.map +1 -1
  56. package/dist/tsconfig.production.tsbuildinfo +1 -1
  57. package/package.json +3 -3
  58. package/src/Autocomplete.tsx +13 -0
  59. package/src/Banner.tsx +29 -14
  60. package/src/Callout.tsx +18 -11
  61. package/src/ContrastModeProvider.tsx +131 -0
  62. package/src/FieldHint.tsx +28 -4
  63. package/src/Link.tsx +3 -1
  64. package/src/OdysseyProvider.tsx +54 -27
  65. package/src/Stack.tsx +56 -0
  66. package/src/Tag.tsx +65 -21
  67. package/src/Typography.test.tsx +26 -0
  68. package/src/Typography.tsx +38 -6
  69. package/src/index.ts +4 -0
  70. package/src/labs/datePickerTheme.tsx +2 -6
  71. package/src/theme/components.tsx +285 -283
  72. package/src/theme/palette.ts +2 -1
  73. package/src/theme/palette.types.ts +2 -0
@@ -253,6 +253,8 @@ export const components = ({
253
253
  justifyContent: "center",
254
254
  alignItems: "center",
255
255
  borderRadius: 0,
256
+ borderWidth: 0,
257
+ borderBottomWidth: "1px",
256
258
 
257
259
  ...(ownerState.onClose !== undefined && {
258
260
  paddingInline: odysseyTokens.Spacing6,
@@ -575,207 +577,164 @@ export const components = ({
575
577
  disableElevation: true,
576
578
  },
577
579
  styleOverrides: {
578
- root: ({ ownerState }) => ({
579
- minWidth: "unset",
580
- paddingBlock: odysseyTokens.Spacing3,
581
- paddingInline: odysseyTokens.Spacing4,
582
- display: "inline-flex",
583
- height: odysseyTokens.Spacing7,
584
- position: "relative",
585
- marginBlock: "0",
586
- marginInline: "0",
587
- transitionProperty:
588
- "color, background-color, border-color, box-shadow",
589
- transitionDuration: "100ms",
590
- transitionTimingFunction: "linear",
591
- borderWidth: odysseyTokens.BorderWidthMain,
592
- borderStyle: odysseyTokens.BorderStyleMain,
593
- borderRadius: odysseyTokens.BorderRadiusMain,
594
- borderColor: "transparent",
595
- fontSize: odysseyTokens.TypographySizeBody,
596
- fontWeight: odysseyTokens.TypographyWeightHeading,
597
- fontFamily: odysseyTokens.TypographyFamilyButton,
598
- lineHeight: odysseyTokens.TypographyLineHeightUi,
599
- whiteSpace: "nowrap",
600
-
601
- [`.${buttonClasses.root} + &`]: {
602
- marginInlineStart: odysseyTokens.Spacing2,
603
- },
604
-
605
- "&:focus-visible": {
606
- boxShadow: `0 0 0 2px ${odysseyTokens.HueNeutralWhite}, 0 0 0 4px ${odysseyTokens.PalettePrimaryMain}`,
607
- outline: "2px solid transparent",
608
- outlineOffset: "1px",
609
- },
610
-
611
- "&:disabled": {
612
- pointerEvents: "none",
613
- },
614
-
615
- [`.${buttonClasses.startIcon}, .${buttonClasses.endIcon}`]: {
616
- "& > *:nth-of-type(1)": {
617
- fontSize: `${odysseyTokens.TypographyLineHeightUi}em`,
618
- },
619
- },
580
+ root: ({ ownerState, theme }) => {
581
+ const contrastMode = theme.odysseyContrastMode;
620
582
 
621
- ...(ownerState.variant === "primary" && {
622
- color: odysseyTokens.HueNeutralWhite,
623
- backgroundColor: odysseyTokens.PalettePrimaryMain,
583
+ return {
584
+ minWidth: "unset",
585
+ paddingBlock: odysseyTokens.Spacing3,
586
+ paddingInline: odysseyTokens.Spacing4,
587
+ display: "inline-flex",
588
+ height: odysseyTokens.Spacing7,
589
+ position: "relative",
590
+ marginBlock: "0",
591
+ marginInline: "0",
592
+ transitionProperty:
593
+ "color, background-color, border-color, box-shadow",
594
+ transitionDuration: "100ms",
595
+ transitionTimingFunction: "linear",
596
+ borderWidth: odysseyTokens.BorderWidthMain,
597
+ borderStyle: odysseyTokens.BorderStyleMain,
598
+ borderRadius: odysseyTokens.BorderRadiusMain,
599
+ borderColor: "transparent",
600
+ fontSize: odysseyTokens.TypographySizeBody,
601
+ fontWeight: odysseyTokens.TypographyWeightHeading,
602
+ fontFamily: odysseyTokens.TypographyFamilyButton,
603
+ lineHeight: odysseyTokens.TypographyLineHeightUi,
604
+ whiteSpace: "nowrap",
624
605
 
625
- "&:hover": {
626
- backgroundColor: odysseyTokens.PalettePrimaryDark,
606
+ [`.${buttonClasses.root} + &`]: {
607
+ marginInlineStart: odysseyTokens.Spacing2,
627
608
  },
628
609
 
629
- "&:active": {
630
- backgroundColor: odysseyTokens.PalettePrimaryDarker,
610
+ "&:focus-visible": {
611
+ boxShadow: `0 0 0 2px ${odysseyTokens.HueNeutralWhite}, 0 0 0 4px ${odysseyTokens.PalettePrimaryMain}`,
612
+ outline: "2px solid transparent",
613
+ outlineOffset: "1px",
631
614
  },
632
615
 
633
616
  "&:disabled": {
634
- color: odysseyTokens.PalettePrimaryLight,
635
- backgroundColor: odysseyTokens.HueBlue100,
636
- },
637
- }),
638
-
639
- ...(ownerState.variant === "secondary" && {
640
- backgroundColor: "transparent",
641
- borderColor: odysseyTokens.HueNeutral300,
642
- color: odysseyTokens.TypographyColorBody,
643
-
644
- "&:hover": {
645
- backgroundColor: odysseyTokens.HueNeutral100,
617
+ pointerEvents: "none",
646
618
  },
647
619
 
648
- "&:active": {
649
- backgroundColor: "transparent",
650
- borderColor: odysseyTokens.BorderColorPrimaryControl,
651
- color: odysseyTokens.TypographyColorAction,
620
+ [`.${buttonClasses.startIcon}, .${buttonClasses.endIcon}`]: {
621
+ "& > *:nth-of-type(1)": {
622
+ fontSize: `${odysseyTokens.TypographyLineHeightUi}em`,
623
+ },
652
624
  },
653
625
 
654
- "&:disabled": {
655
- backgroundColor: odysseyTokens.HueNeutral100,
656
- borderColor: "transparent",
657
- color: odysseyTokens.TypographyColorDisabled,
658
- },
659
- }),
626
+ ...(ownerState.variant === "primary" && {
627
+ color: odysseyTokens.HueNeutralWhite,
628
+ backgroundColor: odysseyTokens.PalettePrimaryMain,
660
629
 
661
- ...(ownerState.variant === "danger" && {
662
- backgroundColor: odysseyTokens.PaletteDangerMain,
663
- color: odysseyTokens.HueNeutralWhite,
630
+ "&:hover": {
631
+ backgroundColor: odysseyTokens.PalettePrimaryDark,
632
+ },
664
633
 
665
- "&:hover": {
666
- backgroundColor: odysseyTokens.PaletteDangerDark,
667
- },
634
+ "&:active": {
635
+ backgroundColor: odysseyTokens.PalettePrimaryDarker,
636
+ },
668
637
 
669
- "&:focus-visible": {
670
- boxShadow: `0 0 0 2px ${odysseyTokens.HueNeutralWhite}, 0 0 0 4px ${odysseyTokens.PaletteDangerMain}`,
671
- },
638
+ "&:disabled": {
639
+ color: odysseyTokens.PalettePrimaryLight,
640
+ backgroundColor: odysseyTokens.HueBlue100,
641
+ },
642
+ }),
672
643
 
673
- "&:active": {
674
- backgroundColor: odysseyTokens.PaletteDangerDarker,
675
- },
644
+ ...(ownerState.variant === "secondary" && {
645
+ backgroundColor: "transparent",
646
+ borderColor: odysseyTokens.HueNeutral300,
647
+ color: odysseyTokens.TypographyColorBody,
676
648
 
677
- "&:disabled": {
678
- color: odysseyTokens.PaletteDangerLight,
679
- backgroundColor: odysseyTokens.HueRed100,
680
- },
681
- }),
682
- ...(ownerState.variant === "dangerSecondary" && {
683
- backgroundColor: "transparent",
684
- borderColor: odysseyTokens.HueNeutral300,
685
- color: odysseyTokens.PaletteDangerMain,
649
+ "&:hover": {
650
+ backgroundColor: odysseyTokens.HueNeutral100,
651
+ },
686
652
 
687
- "&:hover": {
688
- backgroundColor: odysseyTokens.HueNeutral100,
689
- color: odysseyTokens.PaletteDangerMain,
690
- },
653
+ "&:active": {
654
+ backgroundColor: "transparent",
655
+ borderColor: odysseyTokens.BorderColorPrimaryControl,
656
+ color: odysseyTokens.TypographyColorAction,
657
+ },
691
658
 
692
- "&:active": {
693
- backgroundColor: "transparent",
694
- borderColor: odysseyTokens.PaletteDangerMain,
695
- color: odysseyTokens.PaletteDangerMain,
696
- },
659
+ "&:disabled": {
660
+ ...(contrastMode === "lowContrast" && {
661
+ backgroundColor: odysseyTokens.HueNeutral200,
662
+ borderColor: "transparent",
663
+ color: odysseyTokens.TypographyColorDisabled,
664
+ }),
697
665
 
698
- "&:disabled": {
699
- backgroundColor: "transparent",
700
- borderColor: odysseyTokens.PaletteDangerLight,
701
- color: odysseyTokens.PaletteDangerLight,
702
- },
703
- }),
704
- ...(ownerState.variant === "floating" && {
705
- backgroundColor: "transparent",
706
- color: odysseyTokens.TypographyColorBody,
666
+ ...(contrastMode === "highContrast" && {
667
+ backgroundColor: odysseyTokens.HueNeutral100,
668
+ borderColor: "transparent",
669
+ color: odysseyTokens.TypographyColorDisabled,
670
+ }),
671
+ },
672
+ }),
707
673
 
708
- "&:hover": {
709
- backgroundColor: odysseyTokens.HueNeutral100,
710
- },
674
+ ...(ownerState.variant === "danger" && {
675
+ backgroundColor: odysseyTokens.PaletteDangerMain,
676
+ color: odysseyTokens.HueNeutralWhite,
711
677
 
712
- "&:active": {
713
- backgroundColor: odysseyTokens.HueNeutral200,
714
- },
678
+ "&:hover": {
679
+ backgroundColor: odysseyTokens.PaletteDangerDark,
680
+ },
715
681
 
716
- "&:disabled": {
717
- backgroundColor: "transparent",
718
- color: odysseyTokens.TypographyColorDisabled,
719
- },
720
- }),
721
- ...(ownerState.variant === "floatingAction" && {
722
- backgroundColor: "transparent",
723
- color: odysseyTokens.TypographyColorAction,
682
+ "&:focus-visible": {
683
+ boxShadow: `0 0 0 2px ${odysseyTokens.HueNeutralWhite}, 0 0 0 4px ${odysseyTokens.PaletteDangerMain}`,
684
+ },
724
685
 
725
- "&:hover": {
726
- backgroundColor: odysseyTokens.HueNeutral100,
727
- },
686
+ "&:active": {
687
+ backgroundColor: odysseyTokens.PaletteDangerDarker,
688
+ },
728
689
 
729
- "&:active": {
730
- backgroundColor: odysseyTokens.HueNeutral200,
731
- },
690
+ "&:disabled": {
691
+ color: odysseyTokens.PaletteDangerLight,
692
+ backgroundColor: odysseyTokens.HueRed100,
693
+ },
694
+ }),
732
695
 
733
- "&:disabled": {
696
+ ...(ownerState.variant === "dangerSecondary" && {
734
697
  backgroundColor: "transparent",
735
- color: odysseyTokens.TypographyColorDisabled,
736
- },
737
- }),
738
- ...(ownerState.size === "small" && {
739
- height: odysseyTokens.Spacing6,
740
- paddingBlock: odysseyTokens.Spacing2,
741
- paddingInline: odysseyTokens.Spacing3,
742
- fontSize: odysseyTokens.TypographySizeBody,
743
- }),
744
- ...(ownerState.size === "large" && {
745
- height: odysseyTokens.Spacing8,
746
- paddingBlock: odysseyTokens.Spacing4,
747
- paddingInline: odysseyTokens.Spacing4,
748
- }),
749
- ...(ownerState.fullWidth === true && {
750
- width: "100%",
751
- marginBlock: "0",
752
- marginInline: "0",
698
+ borderColor: odysseyTokens.HueNeutral300,
699
+ color: odysseyTokens.PaletteDangerMain,
753
700
 
754
- "&:not(:last-child)": {
755
- marginBlockEnd: odysseyTokens.Spacing4,
756
- },
757
- }),
758
- ...(ownerState.children === "" && {
759
- minWidth: "auto",
760
- padding: odysseyTokens.Spacing3,
701
+ "&:hover": {
702
+ backgroundColor: odysseyTokens.HueNeutral100,
703
+ color: odysseyTokens.PaletteDangerMain,
704
+ },
761
705
 
762
- [`.${buttonClasses.endIcon}, .${buttonClasses.startIcon}`]: {
763
- margin: "0",
764
- },
706
+ "&:active": {
707
+ backgroundColor: "transparent",
708
+ borderColor: odysseyTokens.PaletteDangerMain,
709
+ color: odysseyTokens.PaletteDangerMain,
710
+ },
765
711
 
766
- ...(ownerState.size === "large" && {
767
- padding: odysseyTokens.Spacing4,
712
+ "&:disabled": {
713
+ backgroundColor: "transparent",
714
+ borderColor: odysseyTokens.PaletteDangerLight,
715
+ color: odysseyTokens.PaletteDangerLight,
716
+ },
768
717
  }),
769
718
 
770
- ...(ownerState.size === "small" && {
771
- padding: odysseyTokens.Spacing2,
772
- }),
719
+ ...(ownerState.variant === "floating" && {
720
+ backgroundColor: "transparent",
721
+ color: odysseyTokens.TypographyColorBody,
722
+
723
+ "&:hover": {
724
+ backgroundColor: odysseyTokens.HueNeutral100,
725
+ },
726
+
727
+ "&:active": {
728
+ backgroundColor: odysseyTokens.HueNeutral200,
729
+ },
773
730
 
774
- ...(ownerState.size === "large" && {
775
- padding: odysseyTokens.Spacing4,
731
+ "&:disabled": {
732
+ backgroundColor: "transparent",
733
+ color: odysseyTokens.TypographyColorDisabled,
734
+ },
776
735
  }),
777
- }),
778
- }),
736
+ };
737
+ },
779
738
 
780
739
  endIcon: ({ ownerState }) => ({
781
740
  display: "inline-flex",
@@ -988,136 +947,172 @@ export const components = ({
988
947
  },
989
948
  },
990
949
  },
950
+
991
951
  MuiChip: {
992
952
  defaultProps: {
993
953
  deleteIcon: <CloseCircleFilledIcon />,
994
954
  },
995
955
  styleOverrides: {
996
- root: ({ ownerState }) => ({
997
- height: "auto",
998
- paddingBlock: `calc(${odysseyTokens.Spacing2} - ${odysseyTokens.BorderWidthMain})`,
999
- paddingInline: odysseyTokens.Spacing3,
1000
- fontSize: odysseyTokens.TypographySizeBody,
1001
- lineHeight: odysseyTokens.TypographyLineHeightUi,
1002
- borderRadius: odysseyTokens.BorderRadiusRound,
1003
- backgroundColor: odysseyTokens.HueNeutral100,
1004
- borderWidth: odysseyTokens.BorderWidthMain,
1005
- borderColor: odysseyTokens.HueNeutral200,
1006
- borderStyle: odysseyTokens.BorderStyleMain,
1007
- color: odysseyTokens.HueNeutral700,
956
+ root: ({ ownerState, theme }) => {
957
+ const contrastMode = theme.odysseyContrastMode;
958
+ return {
959
+ height: "auto",
960
+ paddingBlock: `calc(${odysseyTokens.Spacing2} - ${odysseyTokens.BorderWidthMain})`,
961
+ paddingInline: odysseyTokens.Spacing3,
962
+ fontSize: odysseyTokens.TypographySizeBody,
963
+ lineHeight: odysseyTokens.TypographyLineHeightUi,
964
+ borderRadius: odysseyTokens.BorderRadiusRound,
965
+ backgroundColor: odysseyTokens.HueNeutral100,
966
+ borderWidth: odysseyTokens.BorderWidthMain,
967
+ borderColor: odysseyTokens.HueNeutral200,
968
+ borderStyle: odysseyTokens.BorderStyleMain,
969
+ color: odysseyTokens.HueNeutral700,
1008
970
 
1009
- ...(ownerState.onDelete && {
1010
- paddingInlineEnd: odysseyTokens.Spacing2,
1011
- }),
971
+ ...(ownerState.onDelete && {
972
+ paddingInlineEnd: odysseyTokens.Spacing2,
973
+ }),
1012
974
 
1013
- [`&.${chipClasses.disabled}`]: {
1014
- opacity: 1,
1015
- pointerEvents: "none",
1016
- borderColor: odysseyTokens.BorderColorDisabled,
1017
- color: odysseyTokens.TypographyColorDisabled,
975
+ [`&.${chipClasses.disabled}`]: {
976
+ opacity: 1,
977
+ pointerEvents: "none",
978
+ borderColor: odysseyTokens.BorderColorDisabled,
979
+ color: odysseyTokens.TypographyColorDisabled,
1018
980
 
1019
- [`& .${chipClasses.deleteIcon}`]: {
1020
- color: odysseyTokens.HueNeutral300,
981
+ [`& .${chipClasses.deleteIcon}`]: {
982
+ color: odysseyTokens.HueNeutral300,
983
+ },
1021
984
  },
1022
- },
1023
985
 
1024
- ...(ownerState.clickable && {
1025
- "&:hover": {
1026
- backgroundColor: odysseyTokens.HueNeutral200,
1027
- },
1028
- [`&.${chipClasses.focusVisible}`]: {
1029
- backgroundColor: odysseyTokens.HueNeutral200,
1030
- outlineColor: odysseyTokens.FocusOutlineColorPrimary,
1031
- outlineOffset: odysseyTokens.FocusOutlineOffsetTight,
1032
- outlineStyle: odysseyTokens.FocusOutlineStyle,
1033
- outlineWidth: odysseyTokens.FocusOutlineWidthMain,
1034
- },
1035
- "&:active": {
1036
- boxShadow: "none",
1037
- backgroundColor: odysseyTokens.HueNeutral300,
986
+ ...(ownerState.clickable && {
987
+ "&:hover": {
988
+ backgroundColor: odysseyTokens.HueNeutral200,
989
+ },
990
+ [`&.${chipClasses.focusVisible}`]: {
991
+ backgroundColor: odysseyTokens.HueNeutral200,
992
+ outlineColor: odysseyTokens.FocusOutlineColorPrimary,
993
+ outlineOffset: odysseyTokens.FocusOutlineOffsetTight,
994
+ outlineStyle: odysseyTokens.FocusOutlineStyle,
995
+ outlineWidth: odysseyTokens.FocusOutlineWidthMain,
996
+ },
997
+ "&:active": {
998
+ boxShadow: "none",
999
+ backgroundColor: odysseyTokens.HueNeutral300,
1000
+ },
1001
+ }),
1002
+
1003
+ [`& .${chipClasses.icon}`]: {
1004
+ margin: 0,
1005
+ marginInlineEnd: odysseyTokens.Spacing1,
1038
1006
  },
1039
- }),
1040
1007
 
1041
- [`& .${chipClasses.icon}`]: {
1042
- margin: 0,
1043
- marginInlineEnd: odysseyTokens.Spacing1,
1044
- },
1008
+ ...(ownerState.variant === "lamp" && {
1009
+ paddingBlock: 0,
1010
+ paddingInline: 0,
1011
+ borderRadius: 0,
1012
+ border: 0,
1013
+ backgroundColor: "transparent",
1014
+ color: odysseyTokens.TypographyColorBody,
1045
1015
 
1046
- ...(ownerState.variant === "lamp" && {
1047
- paddingBlock: 0,
1048
- paddingInline: 0,
1049
- borderRadius: 0,
1050
- border: 0,
1051
- backgroundColor: "transparent",
1052
- color: odysseyTokens.TypographyColorBody,
1016
+ "&::before": {
1017
+ content: "''",
1018
+ width: odysseyTokens.Spacing2,
1019
+ height: odysseyTokens.Spacing2,
1020
+ marginInlineEnd: odysseyTokens.Spacing2,
1021
+ borderRadius: "100%",
1022
+ backgroundColor: odysseyTokens.HueNeutral600,
1023
+ },
1053
1024
 
1054
- "&::before": {
1055
- content: "''",
1056
- width: odysseyTokens.Spacing2,
1057
- height: odysseyTokens.Spacing2,
1058
- marginInlineEnd: odysseyTokens.Spacing2,
1059
- borderRadius: "100%",
1060
- backgroundColor: odysseyTokens.HueNeutral600,
1061
- },
1025
+ [`&.${chipClasses.colorError}`]: {
1026
+ "&::before": {
1027
+ border: 0,
1028
+ backgroundColor: odysseyTokens.PaletteDangerMain,
1029
+ },
1030
+ },
1062
1031
 
1063
- [`&.${chipClasses.colorError}`]: {
1064
- "&::before": {
1065
- border: 0,
1066
- backgroundColor: odysseyTokens.PaletteDangerMain,
1032
+ [`&.${chipClasses.colorSuccess}`]: {
1033
+ "&::before": {
1034
+ border: 0,
1035
+ backgroundColor: odysseyTokens.PaletteSuccessMain,
1036
+ },
1067
1037
  },
1068
- },
1069
1038
 
1070
- [`&.${chipClasses.colorSuccess}`]: {
1071
- "&::before": {
1072
- border: 0,
1073
- backgroundColor: odysseyTokens.PaletteSuccessMain,
1039
+ [`&.${chipClasses.colorWarning}`]: {
1040
+ "&::before": {
1041
+ border: 0,
1042
+ backgroundColor: odysseyTokens.HueYellow200,
1043
+ },
1074
1044
  },
1075
- },
1045
+ }),
1076
1046
 
1077
- [`&.${chipClasses.colorWarning}`]: {
1078
- "&::before": {
1079
- border: 0,
1080
- backgroundColor: odysseyTokens.HueYellow200,
1047
+ ...(ownerState.variant === "pill" && {
1048
+ paddingBlock: odysseyTokens.Spacing1,
1049
+ paddingInline: odysseyTokens.Spacing2,
1050
+ borderRadius: odysseyTokens.BorderRadiusMain,
1051
+ border: 0,
1052
+ fontWeight: odysseyTokens.TypographyWeightHeadingBold,
1053
+ lineHeight: odysseyTokens.TypographyLineHeightOverline,
1054
+ fontSize: "0.71428571rem",
1055
+ textTransform: "uppercase",
1056
+
1057
+ ...(contrastMode === "lowContrast" && {
1058
+ backgroundColor: odysseyTokens.HueNeutral200,
1059
+ color: odysseyTokens.HueNeutral700,
1060
+ }),
1061
+ ...(contrastMode === "highContrast" && {
1062
+ backgroundColor: odysseyTokens.HueNeutral50,
1063
+ color: odysseyTokens.TypographyColorSubordinate,
1064
+ }),
1065
+
1066
+ [`&.${chipClasses.colorError}`]: {
1067
+ ...(contrastMode === "lowContrast" && {
1068
+ backgroundColor: odysseyTokens.HueRed100,
1069
+ color: odysseyTokens.HueRed700,
1070
+ }),
1071
+ ...(contrastMode === "highContrast" && {
1072
+ backgroundColor: odysseyTokens.PaletteDangerLighter,
1073
+ color: odysseyTokens.TypographyColorDanger,
1074
+ }),
1081
1075
  },
1082
- },
1083
- }),
1084
- ...(ownerState.variant === "pill" && {
1085
- paddingBlock: odysseyTokens.Spacing1,
1086
- paddingInline: odysseyTokens.Spacing2,
1087
- borderRadius: odysseyTokens.BorderRadiusMain,
1088
- border: 0,
1089
- fontWeight: odysseyTokens.TypographyWeightHeadingBold,
1090
- lineHeight: odysseyTokens.TypographyLineHeightOverline,
1091
- backgroundColor: odysseyTokens.HueNeutral50,
1092
- color: odysseyTokens.TypographyColorSubordinate,
1093
- fontSize: "0.71428571rem",
1094
- textTransform: "uppercase",
1095
1076
 
1096
- [`&.${chipClasses.colorError}`]: {
1097
- backgroundColor: odysseyTokens.PaletteDangerLighter,
1098
- color: odysseyTokens.TypographyColorDanger,
1099
- },
1077
+ [`&.${chipClasses.colorInfo}`]: {
1078
+ ...(contrastMode === "lowContrast" && {
1079
+ backgroundColor: odysseyTokens.HueBlue100,
1080
+ color: odysseyTokens.HueBlue700,
1081
+ }),
1082
+ ...(contrastMode === "highContrast" && {
1083
+ backgroundColor: odysseyTokens.PalettePrimaryLighter,
1084
+ color: odysseyTokens.PalettePrimaryText,
1085
+ }),
1086
+ },
1100
1087
 
1101
- [`&.${chipClasses.colorInfo}`]: {
1102
- backgroundColor: odysseyTokens.PalettePrimaryLighter,
1103
- color: odysseyTokens.PalettePrimaryText,
1104
- },
1088
+ [`&.${chipClasses.colorSuccess}`]: {
1089
+ ...(contrastMode === "lowContrast" && {
1090
+ backgroundColor: odysseyTokens.HueGreen200,
1091
+ color: odysseyTokens.HueGreen700,
1092
+ }),
1093
+ ...(contrastMode === "highContrast" && {
1094
+ backgroundColor: odysseyTokens.PaletteSuccessLighter,
1095
+ color: odysseyTokens.TypographyColorSuccess,
1096
+ }),
1097
+ },
1105
1098
 
1106
- [`&.${chipClasses.colorSuccess}`]: {
1107
- backgroundColor: odysseyTokens.PaletteSuccessLighter,
1108
- color: odysseyTokens.TypographyColorSuccess,
1109
- },
1099
+ [`&.${chipClasses.colorWarning}`]: {
1100
+ ...(contrastMode === "lowContrast" && {
1101
+ backgroundColor: odysseyTokens.HueYellow100,
1102
+ color: odysseyTokens.HueYellow700,
1103
+ }),
1104
+ ...(contrastMode === "highContrast" && {
1105
+ backgroundColor: odysseyTokens.PaletteWarningLighter,
1106
+ color: odysseyTokens.TypographyColorWarning,
1107
+ }),
1108
+ },
1109
+ }),
1110
1110
 
1111
- [`&.${chipClasses.colorWarning}`]: {
1112
- backgroundColor: odysseyTokens.PaletteWarningLighter,
1113
- color: odysseyTokens.TypographyColorWarning,
1111
+ [`.${inputBaseClasses.root}.${inputBaseClasses.disabled} &`]: {
1112
+ backgroundColor: odysseyTokens.HueNeutral200,
1114
1113
  },
1115
- }),
1116
-
1117
- [`.${inputBaseClasses.root}.${inputBaseClasses.disabled} &`]: {
1118
- backgroundColor: odysseyTokens.HueNeutral200,
1119
- },
1120
- }),
1114
+ };
1115
+ },
1121
1116
 
1122
1117
  label: {
1123
1118
  padding: 0,
@@ -1125,7 +1120,7 @@ export const components = ({
1125
1120
  [`.${inputBaseClasses.root}.${inputBaseClasses.disabled} &`]: {
1126
1121
  color: odysseyTokens.TypographyColorDisabled,
1127
1122
  WebkitTextFillColor: odysseyTokens.TypographyColorDisabled,
1128
- } satisfies CSSProperties,
1123
+ } as CSSProperties,
1129
1124
  },
1130
1125
 
1131
1126
  deleteIcon: {
@@ -1746,25 +1741,20 @@ export const components = ({
1746
1741
  },
1747
1742
  styleOverrides: {
1748
1743
  root: {
1749
- display: "flex",
1750
- justifyContent: "flex-start",
1751
- alignItems: "center",
1752
1744
  fontSize: odysseyTokens.TypographySizeSubordinate,
1753
1745
  lineHeight: odysseyTokens.TypographyLineHeightBody,
1746
+ marginBlockEnd: odysseyTokens.Spacing2,
1754
1747
  marginBlockStart: odysseyTokens.Spacing1,
1748
+ textAlign: "start",
1749
+
1755
1750
  [`.${formLabelClasses.root} + &`]: {
1756
1751
  marginBlockStart: `-${odysseyTokens.Spacing1}`,
1757
1752
  color: odysseyTokens.TypographyColorSubordinate,
1758
1753
  },
1759
- marginBlockEnd: odysseyTokens.Spacing2,
1754
+
1760
1755
  "&:last-child": {
1761
1756
  marginBlockEnd: 0,
1762
1757
  },
1763
- textAlign: "start",
1764
-
1765
- ".field-hint-link-component": {
1766
- marginInlineStart: odysseyTokens.Spacing1,
1767
- },
1768
1758
 
1769
1759
  ".Mui-disabled &": {
1770
1760
  color: odysseyTokens.TypographyColorDisabled,
@@ -3109,6 +3099,7 @@ export const components = ({
3109
3099
  body1: "p",
3110
3100
  inherit: "p",
3111
3101
  legend: "legend",
3102
+ overline: "p",
3112
3103
  },
3113
3104
  },
3114
3105
  styleOverrides: {
@@ -3119,6 +3110,17 @@ export const components = ({
3119
3110
  marginBlockEnd: 0,
3120
3111
  },
3121
3112
  },
3113
+ overline: {
3114
+ fontSize: odysseyTokens.TypographySizeOverline,
3115
+ fontWeight: odysseyTokens.TypographyWeightBodyBold,
3116
+ lineHeight: odysseyTokens.TypographyLineHeightOverline,
3117
+ letterSpacing: odysseyTokens.TypographyLetterSpacingOverline,
3118
+ textTransform: "none",
3119
+
3120
+ ":is(:lang(en-*), :lang(en))": {
3121
+ textTransform: "uppercase",
3122
+ },
3123
+ },
3122
3124
  },
3123
3125
  },
3124
3126
  };