@sanity/ui 0.37.14 → 0.37.17

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.
@@ -1 +1 @@
1
- {"version":3,"file":"popover.d.ts","sourceRoot":"","sources":["../../../../../src/primitives/popover/popover.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA4E,MAAM,OAAO,CAAA;AAKhG,OAAO,EAAC,mBAAmB,EAAW,MAAM,aAAa,CAAA;AACzD,OAAO,EAAC,QAAQ,EAAE,SAAS,EAAE,cAAc,EAAC,MAAM,aAAa,CAAA;AAC/D,OAAO,EAAQ,UAAU,EAAwC,MAAM,aAAa,CAAA;AAIpF,OAAO,EAAC,qBAAqB,EAAE,qBAAqB,EAAE,oBAAoB,EAAC,MAAM,UAAU,CAAA;AAI3F;;GAEG;AACH,MAAM,WAAW,YACf,SAAQ,IAAI,CAAC,UAAU,EAAE,IAAI,CAAC,EAC5B,qBAAqB,EACrB,qBAAqB,EACrB,oBAAoB;IACtB;;OAEG;IACH,kBAAkB,CAAC,EAAE,cAAc,CAAA;IACnC,qBAAqB,CAAC,EAAE,SAAS,EAAE,CAAA;IACnC,KAAK,CAAC,EAAE,OAAO,CAAA;IACf,eAAe,CAAC,EAAE,WAAW,GAAG,IAAI,CAAA;IACpC,QAAQ,CAAC,EAAE,KAAK,CAAC,YAAY,CAAA;IAC7B,aAAa,CAAC,EAAE,OAAO,CAAA;IACvB,OAAO,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IACzB,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,kBAAkB,CAAC,EAAE,SAAS,EAAE,CAAA;IAChC,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAA;IAC3B,SAAS,CAAC,EAAE,SAAS,CAAA;IACrB,MAAM,CAAC,EAAE,OAAO,GAAG,MAAM,CAAA;IACzB,eAAe,CAAC,EAAE,OAAO,CAAA;IACz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,EAAE,SAAS,EAAE,CAAA;IAChC,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAA;IAC3B,SAAS,CAAC,EAAE,SAAS,CAAA;IACrB,MAAM,CAAC,EAAE,OAAO,GAAG,MAAM,CAAA;IACzB,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB,gBAAgB,CAAC,EAAE,WAAW,GAAG,IAAI,CAAA;IACrC,mBAAmB,CAAC,EAAE,OAAO,CAAA;IAC7B,MAAM,CAAC,EAAE,mBAAmB,CAAA;IAC5B,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,YAAY,CAAC,EAAE,MAAM,GAAG,CAAC,CAAC,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,MAAM,CAAC,CAAA;IACpD,IAAI,CAAC,EAAE,QAAQ,CAAA;CAChB;AAiDD;;GAEG;AACH,eAAO,MAAM,OAAO,+1LA8JlB,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"textArea.d.ts","sourceRoot":"","sources":["../../../../../src/primitives/textArea/textArea.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAA;AAevC,OAAO,EAAC,kBAAkB,EAAe,MAAM,aAAa,CAAA;AAC5D,OAAO,EAAC,qBAAqB,EAAC,MAAM,UAAU,CAAA;AAE9C;;GAEG;AACH,MAAM,WAAW,aAAc,SAAQ,qBAAqB;IAC1D,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAA;IAC5B,OAAO,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAA;IAC3B,MAAM,CAAC,EAAE,kBAAkB,CAAA;CAC5B;AAsBD;;GAEG;AACH,eAAO,MAAM,QAAQ,i4LA6CnB,CAAA"}
1
+ {"version":3,"file":"textArea.d.ts","sourceRoot":"","sources":["../../../../../src/primitives/textArea/textArea.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAA;AAevC,OAAO,EAAC,kBAAkB,EAAe,MAAM,aAAa,CAAA;AAC5D,OAAO,EAAC,qBAAqB,EAAC,MAAM,UAAU,CAAA;AAE9C;;GAEG;AACH,MAAM,WAAW,aAAc,SAAQ,qBAAqB;IAC1D,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAA;IAC5B,OAAO,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAA;IAC3B,MAAM,CAAC,EAAE,kBAAkB,CAAA;CAC5B;AAsBD;;GAEG;AACH,eAAO,MAAM,QAAQ,i4LA+CnB,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"textInput.d.ts","sourceRoot":"","sources":["../../../../../src/primitives/textInput/textInput.tsx"],"names":[],"mappings":"AACA,OAAO,KAAwE,MAAM,OAAO,CAAA;AAiB5F,OAAO,EAAC,kBAAkB,EAAe,MAAM,aAAa,CAAA;AAE5D,OAAO,EAAS,WAAW,EAAC,MAAM,WAAW,CAAA;AAI7C;;GAEG;AACH,oBAAY,yBAAyB,GAAG,IAAI,CAAC,WAAW,EAAE,IAAI,CAAC,GAC7D,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,iBAAiB,CAAC,EAAE,IAAI,GAAG,SAAS,GAAG,aAAa,GAAG,KAAK,CAAC,CAAA;AAEpF;;GAEG;AACH,oBAAY,aAAa,GACrB,MAAM,GACN,gBAAgB,GAChB,OAAO,GACP,KAAK,GACL,OAAO,GACP,QAAQ,GACR,UAAU,GACV,KAAK,GACL,MAAM,GACN,MAAM,GACN,MAAM,CAAA;AAEV;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB;;OAEG;IACH,WAAW,CAAC,EAAE,OAAO,GA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CAAA;CAC7B;AAMD;;GAEG;AACH,eAAO,MAAM,OAAO,w2LAyKlB,CAAA"}
@@ -1,5 +1,5 @@
1
1
  import { CSSObject, FlattenSimpleInterpolation } from 'styled-components';
2
- import { ThemeFontWeightKey } from '../../theme';
2
+ import { ThemeColorSchemeKey, ThemeFontWeightKey } from '../../theme';
3
3
  import { CardTone } from '../../types';
4
4
  import { ThemeProps } from '../types';
5
5
  /**
@@ -7,6 +7,7 @@ import { ThemeProps } from '../types';
7
7
  */
8
8
  export interface TextInputInputStyleProps {
9
9
  $fontSize: number[];
10
+ $scheme: ThemeColorSchemeKey;
10
11
  $tone: CardTone;
11
12
  $weight?: ThemeFontWeightKey;
12
13
  }
@@ -17,6 +18,7 @@ export interface TextInputRepresentationStyleProps {
17
18
  $border?: boolean;
18
19
  $hasPrefix?: boolean;
19
20
  $hasSuffix?: boolean;
21
+ $scheme: ThemeColorSchemeKey;
20
22
  $tone: CardTone;
21
23
  }
22
24
  export declare function textInputRootStyle(): FlattenSimpleInterpolation;
@@ -1 +1 @@
1
- {"version":3,"file":"textInputStyle.d.ts","sourceRoot":"","sources":["../../../../../src/styles/input/textInputStyle.ts"],"names":[],"mappings":"AAAA,OAAO,EAAM,SAAS,EAAE,0BAA0B,EAAC,MAAM,mBAAmB,CAAA;AAC5E,OAAO,EAAC,kBAAkB,EAAC,MAAM,aAAa,CAAA;AAC9C,OAAO,EAAC,QAAQ,EAAC,MAAM,aAAa,CAAA;AAGpC,OAAO,EAAC,UAAU,EAAC,MAAM,UAAU,CAAA;AAEnC;;GAEG;AACH,MAAM,WAAW,wBAAwB;IACvC,SAAS,EAAE,MAAM,EAAE,CAAA;IACnB,KAAK,EAAE,QAAQ,CAAA;IACf,OAAO,CAAC,EAAE,kBAAkB,CAAA;CAC7B;AAED;;GAEG;AACH,MAAM,WAAW,iCAAiC;IAChD,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,UAAU,CAAC,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KAAK,EAAE,wBAAwB,GAAG,UAAU,GAAG,SAAS,EAAE,CAYhG;AAED,wBAAgB,4BAA4B,CAC1C,KAAK,EAAE,iCAAiC,GAAG,UAAU,GACpD,0BAA0B,CA2F5B"}
@@ -1 +1 @@
1
- {"version":3,"file":"color.d.ts","sourceRoot":"","sources":["../../../../../src/theme/studioTheme/color.ts"],"names":[],"mappings":"AAgBA,eAAO,MAAM,KAAK,0CA4mBhB,CAAA"}
1
+ {"version":3,"file":"color.d.ts","sourceRoot":"","sources":["../../../../../src/theme/studioTheme/color.ts"],"names":[],"mappings":"AAgBA,eAAO,MAAM,KAAK,0CA6mBhB,CAAA"}
package/lib/sanity-ui.js CHANGED
@@ -1984,18 +1984,20 @@ var color = createColorTheme({
1984
1984
  name = _ref.name;
1985
1985
 
1986
1986
  if (name === 'default') {
1987
- var _skeletonFrom = dark ? color$1.hues.gray[900].hex : color$1.hues.gray[100].hex;
1987
+ var _tints = color$1.hues.gray;
1988
+
1989
+ var _skeletonFrom = dark ? _tints[900].hex : _tints[100].hex;
1988
1990
 
1989
1991
  return {
1990
1992
  fg: dark ? color$1.white.hex : color$1.black.hex,
1991
1993
  bg: dark ? color$1.black.hex : color$1.white.hex,
1992
- border: color$1.hues.gray[dark ? 800 : 200].hex,
1994
+ border: _tints[dark ? 800 : 200].hex,
1993
1995
  focusRing: color$1.hues.blue[dark ? 500 : 500].hex,
1994
1996
  shadow: {
1995
- outline: rgba(color$1.hues.gray[500].hex, 0.4),
1996
- umbra: rgba(dark ? color$1.black.hex : color$1.hues.gray[500].hex, 0.2),
1997
- penumbra: rgba(dark ? color$1.black.hex : color$1.hues.gray[500].hex, 0.14),
1998
- ambient: rgba(dark ? color$1.black.hex : color$1.hues.gray[500].hex, 0.12)
1997
+ outline: rgba(_tints[500].hex, 0.4),
1998
+ umbra: dark ? rgba(_tints[950].hex, 0.4) : rgba(_tints[500].hex, 0.2),
1999
+ penumbra: dark ? rgba(_tints[950].hex, 0.28) : rgba(_tints[500].hex, 0.14),
2000
+ ambient: dark ? rgba(_tints[950].hex, 0.24) : rgba(_tints[500].hex, 0.12)
1999
2001
  },
2000
2002
  skeleton: {
2001
2003
  from: _skeletonFrom,
@@ -2005,18 +2007,18 @@ var color = createColorTheme({
2005
2007
  }
2006
2008
 
2007
2009
  if (name === 'transparent') {
2008
- var _tints = tones["default"];
2009
- var _skeletonFrom2 = _tints[dark ? 800 : 200].hex;
2010
+ var _tints2 = tones["default"];
2011
+ var _skeletonFrom2 = _tints2[dark ? 800 : 200].hex;
2010
2012
  return {
2011
- fg: _tints[dark ? 100 : 900].hex,
2012
- bg: _tints[dark ? 950 : 50].hex,
2013
- border: _tints[dark ? 800 : 300].hex,
2013
+ fg: _tints2[dark ? 100 : 900].hex,
2014
+ bg: _tints2[dark ? 950 : 50].hex,
2015
+ border: _tints2[dark ? 800 : 300].hex,
2014
2016
  focusRing: color$1.hues.blue[500].hex,
2015
2017
  shadow: {
2016
- outline: rgba(_tints[500].hex, dark ? 0.2 : 0.4),
2017
- umbra: rgba(dark ? color$1.black.hex : _tints[500].hex, 0.2),
2018
- penumbra: rgba(dark ? color$1.black.hex : _tints[500].hex, 0.14),
2019
- ambient: rgba(dark ? color$1.black.hex : _tints[500].hex, 0.12)
2018
+ outline: rgba(_tints2[500].hex, 0.4),
2019
+ umbra: dark ? rgba(_tints2[900].hex, 0.4) : rgba(_tints2[500].hex, 0.2),
2020
+ penumbra: dark ? rgba(_tints2[900].hex, 0.28) : rgba(_tints2[500].hex, 0.14),
2021
+ ambient: dark ? rgba(_tints2[900].hex, 0.24) : rgba(_tints2[500].hex, 0.12)
2020
2022
  },
2021
2023
  skeleton: {
2022
2024
  from: _skeletonFrom2,
@@ -2033,10 +2035,10 @@ var color = createColorTheme({
2033
2035
  border: tints[dark ? 800 : 200].hex,
2034
2036
  focusRing: tints[500].hex,
2035
2037
  shadow: {
2036
- outline: rgba(tints[500].hex, dark ? 0.2 : 0.4),
2037
- umbra: rgba(dark ? color$1.black.hex : tints[500].hex, 0.2),
2038
- penumbra: rgba(dark ? color$1.black.hex : tints[500].hex, 0.14),
2039
- ambient: rgba(dark ? color$1.black.hex : tints[500].hex, 0.12)
2038
+ outline: rgba(tints[500].hex, 0.4),
2039
+ umbra: dark ? rgba(tints[900].hex, 0.4) : rgba(tints[500].hex, 0.2),
2040
+ penumbra: dark ? rgba(tints[900].hex, 0.28) : rgba(tints[500].hex, 0.14),
2041
+ ambient: dark ? rgba(tints[900].hex, 0.24) : rgba(tints[500].hex, 0.12)
2040
2042
  },
2041
2043
  skeleton: {
2042
2044
  from: skeletonFrom,
@@ -3701,11 +3703,12 @@ function textInputRootStyle() {
3701
3703
  }
3702
3704
  function textInputBaseStyle(props) {
3703
3705
  var theme = props.theme,
3706
+ $scheme = props.$scheme,
3704
3707
  $tone = props.$tone,
3705
3708
  $weight = props.$weight;
3706
3709
  var font = theme.sanity.fonts.text;
3707
3710
  var color = theme.sanity.color.input;
3708
- return styled.css(_templateObject2$n || (_templateObject2$n = _taggedTemplateLiteralLoose(["\n appearance: none;\n background: none;\n border: 0;\n border-radius: 0;\n outline: none;\n width: 100%;\n box-sizing: border-box;\n font-family: ", ";\n font-weight: ", ";\n margin: 0;\n position: relative;\n z-index: 1;\n display: block;\n\n /* NOTE: This is a hack to disable Chrome\u2019s autofill styles */\n &:-webkit-autofill,\n &:-webkit-autofill:hover,\n &:-webkit-autofill:focus,\n &:-webkit-autofill:active {\n -webkit-text-fill-color: var(--input-fg-color) !important;\n transition: background-color 5000s;\n transition-delay: 86400s /* 24h */;\n }\n\n /* &:is(textarea) */\n &[data-as='textarea'] {\n resize: none;\n }\n\n color: var(--input-fg-color);\n\n &::placeholder {\n color: var(--input-placeholder-color);\n }\n\n &[data-tone='", "'] {\n --input-fg-color: ", ";\n --input-placeholder-color: ", ";\n\n /* enabled */\n &:not(:invalid):not(:disabled):not(:read-only) {\n --input-fg-color: ", ";\n --input-placeholder-color: ", ";\n }\n\n /* disabled */\n &:not(:invalid):disabled {\n --input-fg-color: ", ";\n --input-placeholder-color: ", ";\n }\n\n /* invalid */\n &:invalid {\n --input-fg-color: ", ";\n --input-placeholder-color: ", ";\n }\n\n /* readOnly */\n &:read-only {\n --input-fg-color: ", ";\n --input-placeholder-color: ", ";\n }\n }\n "])), font.family, $weight && font.weights[$weight] || font.weights.regular, $tone, color["default"].enabled.fg, color["default"].enabled.placeholder, color["default"].enabled.fg, color["default"].enabled.placeholder, color["default"].disabled.fg, color["default"].disabled.placeholder, color.invalid.enabled.fg, color.invalid.enabled.placeholder, color["default"].readOnly.fg, color["default"].readOnly.placeholder);
3711
+ return styled.css(_templateObject2$n || (_templateObject2$n = _taggedTemplateLiteralLoose(["\n appearance: none;\n background: none;\n border: 0;\n border-radius: 0;\n outline: none;\n width: 100%;\n box-sizing: border-box;\n font-family: ", ";\n font-weight: ", ";\n margin: 0;\n position: relative;\n z-index: 1;\n display: block;\n\n /* NOTE: This is a hack to disable Chrome\u2019s autofill styles */\n &:-webkit-autofill,\n &:-webkit-autofill:hover,\n &:-webkit-autofill:focus,\n &:-webkit-autofill:active {\n -webkit-text-fill-color: var(--input-fg-color) !important;\n transition: background-color 5000s;\n transition-delay: 86400s /* 24h */;\n }\n\n /* &:is(textarea) */\n &[data-as='textarea'] {\n resize: none;\n }\n\n color: var(--input-fg-color);\n\n &::placeholder {\n color: var(--input-placeholder-color);\n }\n\n &[data-scheme='", "'][data-tone='", "'] {\n --input-fg-color: ", ";\n --input-placeholder-color: ", ";\n\n /* enabled */\n &:not(:invalid):not(:disabled):not(:read-only) {\n --input-fg-color: ", ";\n --input-placeholder-color: ", ";\n }\n\n /* disabled */\n &:not(:invalid):disabled {\n --input-fg-color: ", ";\n --input-placeholder-color: ", ";\n }\n\n /* invalid */\n &:invalid {\n --input-fg-color: ", ";\n --input-placeholder-color: ", ";\n }\n\n /* readOnly */\n &:read-only {\n --input-fg-color: ", ";\n --input-placeholder-color: ", ";\n }\n }\n "])), font.family, $weight && font.weights[$weight] || font.weights.regular, $scheme, $tone, color["default"].enabled.fg, color["default"].enabled.placeholder, color["default"].enabled.fg, color["default"].enabled.placeholder, color["default"].disabled.fg, color["default"].disabled.placeholder, color.invalid.enabled.fg, color.invalid.enabled.placeholder, color["default"].readOnly.fg, color["default"].readOnly.placeholder);
3709
3712
  }
3710
3713
  function textInputFontSizeStyle(props) {
3711
3714
  var theme = props.theme;
@@ -3724,13 +3727,14 @@ function textInputRepresentationStyle(props) {
3724
3727
  var $border = props.$border,
3725
3728
  $hasPrefix = props.$hasPrefix,
3726
3729
  $hasSuffix = props.$hasSuffix,
3730
+ $scheme = props.$scheme,
3727
3731
  $tone = props.$tone,
3728
3732
  theme = props.theme;
3729
3733
  var _theme$sanity2 = theme.sanity,
3730
3734
  focusRing = _theme$sanity2.focusRing,
3731
3735
  input = _theme$sanity2.input;
3732
3736
  var color = theme.sanity.color.input;
3733
- return styled.css(_templateObject3$e || (_templateObject3$e = _taggedTemplateLiteralLoose(["\n --input-box-shadow: none;\n\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n display: block;\n pointer-events: none;\n z-index: 0;\n\n background-color: var(--card-bg-color);\n box-shadow: var(--input-box-shadow);\n\n border-top-left-radius: ", ";\n border-bottom-left-radius: ", ";\n border-top-right-radius: ", ";\n border-bottom-right-radius: ", ";\n\n &[data-tone='", "'] {\n --card-bg-color: ", ";\n --card-fg-color: ", ";\n\n /* enabled */\n *:not(:disabled) + & {\n --input-box-shadow: ", ";\n }\n\n /* invalid */\n *:not(:disabled):invalid + & {\n --card-bg-color: ", ";\n --card-fg-color: ", ";\n --input-box-shadow: ", ";\n }\n\n /* focused */\n *:not(:disabled):focus + & {\n --input-box-shadow: ", ";\n }\n\n /* disabled */\n *:disabled + & {\n --card-bg-color: ", " !important;\n --card-fg-color: ", " !important;\n --input-box-shadow: ", ";\n }\n\n /* readOnly */\n *:read-only + & {\n --card-bg-color: ", " !important;\n --card-fg-color: ", " !important;\n }\n\n /* hovered */\n @media (hover: hover) {\n *:not(:disabled):not(:read-only):not(:invalid):hover + & {\n --card-bg-color: ", ";\n --card-fg-color: ", ";\n }\n\n *:not(:disabled):not(:read-only):not(:invalid):not(:focus):hover + & {\n --input-box-shadow: ", ";\n }\n }\n }\n "])), $hasPrefix ? 0 : undefined, $hasPrefix ? 0 : undefined, $hasSuffix ? 0 : undefined, $hasSuffix ? 0 : undefined, $tone, color["default"].enabled.bg, color["default"].enabled.fg, $border ? focusRingBorderStyle({
3737
+ return styled.css(_templateObject3$e || (_templateObject3$e = _taggedTemplateLiteralLoose(["\n --input-box-shadow: none;\n\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n display: block;\n pointer-events: none;\n z-index: 0;\n\n background-color: var(--card-bg-color);\n box-shadow: var(--input-box-shadow);\n\n border-top-left-radius: ", ";\n border-bottom-left-radius: ", ";\n border-top-right-radius: ", ";\n border-bottom-right-radius: ", ";\n\n &[data-scheme='", "'][data-tone='", "'] {\n --card-bg-color: ", ";\n --card-fg-color: ", ";\n\n /* enabled */\n *:not(:disabled) + & {\n --input-box-shadow: ", ";\n }\n\n /* invalid */\n *:not(:disabled):invalid + & {\n --card-bg-color: ", ";\n --card-fg-color: ", ";\n --input-box-shadow: ", ";\n }\n\n /* focused */\n *:not(:disabled):focus + & {\n --input-box-shadow: ", ";\n }\n\n /* disabled */\n *:disabled + & {\n --card-bg-color: ", " !important;\n --card-fg-color: ", " !important;\n --input-box-shadow: ", ";\n }\n\n /* readOnly */\n *:read-only + & {\n --card-bg-color: ", " !important;\n --card-fg-color: ", " !important;\n }\n\n /* hovered */\n @media (hover: hover) {\n *:not(:disabled):not(:read-only):not(:invalid):hover + & {\n --card-bg-color: ", ";\n --card-fg-color: ", ";\n }\n\n *:not(:disabled):not(:read-only):not(:invalid):not(:focus):hover + & {\n --input-box-shadow: ", ";\n }\n }\n }\n "])), $hasPrefix ? 0 : undefined, $hasPrefix ? 0 : undefined, $hasSuffix ? 0 : undefined, $hasSuffix ? 0 : undefined, $scheme, $tone, color["default"].enabled.bg, color["default"].enabled.fg, $border ? focusRingBorderStyle({
3734
3738
  color: color["default"].enabled.border,
3735
3739
  width: input.border.width
3736
3740
  }) : undefined, color.invalid.enabled.bg, color.invalid.enabled.fg, $border ? focusRingBorderStyle({
@@ -6152,7 +6156,7 @@ var Popover = /*#__PURE__*/React.forwardRef(function Popover(props, ref) {
6152
6156
  setArrowElement = _useState3[1];
6153
6157
 
6154
6158
  var popperReferenceElement = referenceElementProp || referenceElement;
6155
- var width = useArrayProp(widthProp);
6159
+ var width = useArrayProp(matchReferenceWidth ? 'auto' : widthProp);
6156
6160
  var modifiers = usePopoverModifiers({
6157
6161
  allowedAutoPlacements: allowedAutoPlacements,
6158
6162
  arrow: arrow,
@@ -6193,13 +6197,21 @@ var Popover = /*#__PURE__*/React.forwardRef(function Popover(props, ref) {
6193
6197
  var popoverStyle = React.useMemo(function () {
6194
6198
  return _extends({}, style, styles.popper);
6195
6199
  }, [style, styles]);
6200
+ var updateTimeoutRef = React.useRef(null);
6196
6201
  React.useEffect(function () {
6197
- if (forceUpdate) {
6198
- try {
6199
- forceUpdate();
6200
- } catch (_) {// ignore caught error
6201
- }
6202
+ if (updateTimeoutRef.current) {
6203
+ clearTimeout(updateTimeoutRef.current);
6204
+ updateTimeoutRef.current = null;
6202
6205
  }
6206
+
6207
+ updateTimeoutRef.current = setTimeout(function () {
6208
+ if (forceUpdate) {
6209
+ try {
6210
+ forceUpdate();
6211
+ } catch (_) {// ignore caught error
6212
+ }
6213
+ }
6214
+ }, 0);
6203
6215
  }, [content, forceUpdate, open, popperReferenceElement]);
6204
6216
 
6205
6217
  if (disabled) {
@@ -6581,6 +6593,7 @@ var TextArea = /*#__PURE__*/React.forwardRef(function TextArea(props, forwardedR
6581
6593
  }, restProps, {
6582
6594
  "$fontSize": useArrayProp(fontSize),
6583
6595
  "$padding": useArrayProp(padding),
6596
+ "$scheme": rootTheme.scheme,
6584
6597
  "$space": useArrayProp(0),
6585
6598
  "$tone": rootTheme.tone,
6586
6599
  "$weight": weight,
@@ -6589,6 +6602,7 @@ var TextArea = /*#__PURE__*/React.forwardRef(function TextArea(props, forwardedR
6589
6602
  })), /*#__PURE__*/React__default["default"].createElement(Presentation$1, {
6590
6603
  "$border": border,
6591
6604
  "$radius": useArrayProp(radius),
6605
+ "$scheme": rootTheme.scheme,
6592
6606
  "$tone": rootTheme.tone,
6593
6607
  "data-tone": rootTheme.tone
6594
6608
  })));
@@ -6690,7 +6704,9 @@ var TextInput = /*#__PURE__*/React.forwardRef(function TextInput(props, forwarde
6690
6704
  "$hasPrefix": $hasPrefix,
6691
6705
  "$hasSuffix": $hasSuffix,
6692
6706
  "$radius": radius,
6707
+ "$scheme": rootTheme.scheme,
6693
6708
  "$tone": rootTheme.tone,
6709
+ "data-scheme": rootTheme.scheme,
6694
6710
  "data-tone": rootTheme.tone
6695
6711
  }, icon && /*#__PURE__*/React__default["default"].createElement(LeftBox, {
6696
6712
  padding: padding
@@ -6701,7 +6717,7 @@ var TextInput = /*#__PURE__*/React.forwardRef(function TextInput(props, forwarde
6701
6717
  }, /*#__PURE__*/React__default["default"].createElement(Text, {
6702
6718
  size: fontSize
6703
6719
  }, /*#__PURE__*/React.isValidElement(iconRight) && iconRight, ReactIs.isValidElementType(iconRight) && /*#__PURE__*/React.createElement(iconRight))));
6704
- }, [border, fontSize, icon, iconRight, padding, radius, rootTheme.tone, $hasClearButton, $hasPrefix, $hasSuffix]); // Render clear button (memoized)
6720
+ }, [border, fontSize, icon, iconRight, padding, radius, rootTheme, $hasClearButton, $hasPrefix, $hasSuffix]); // Render clear button (memoized)
6705
6721
 
6706
6722
  var clearButtonBoxPadding = React.useMemo(function () {
6707
6723
  return padding.map(function (v) {
@@ -6756,12 +6772,14 @@ var TextInput = /*#__PURE__*/React.forwardRef(function TextInput(props, forwarde
6756
6772
  tone: rootTheme.tone
6757
6773
  }, prefixNode, /*#__PURE__*/React__default["default"].createElement(InputRoot, null, /*#__PURE__*/React__default["default"].createElement(Input, _extends({
6758
6774
  "data-as": "input",
6775
+ "data-scheme": rootTheme.scheme,
6759
6776
  "data-tone": rootTheme.tone
6760
6777
  }, restProps, {
6761
6778
  "$fontSize": fontSize,
6762
6779
  "$iconLeft": $hasIcon,
6763
6780
  "$iconRight": $hasIconRight || $hasClearButton,
6764
6781
  "$padding": padding,
6782
+ "$scheme": rootTheme.scheme,
6765
6783
  "$space": space,
6766
6784
  "$tone": rootTheme.tone,
6767
6785
  "$weight": weight,
@@ -6903,13 +6921,21 @@ var Tooltip = /*#__PURE__*/React.forwardRef(function Tooltip(props, ref) {
6903
6921
  window.removeEventListener('mousemove', handleWindowMouseMove);
6904
6922
  };
6905
6923
  }, [isOpen, referenceElement]);
6924
+ var updateTimeoutRef = React.useRef(null);
6906
6925
  React.useEffect(function () {
6907
- if (forceUpdate) {
6908
- try {
6909
- forceUpdate();
6910
- } catch (_) {// ignore caught error
6911
- }
6926
+ if (updateTimeoutRef.current) {
6927
+ clearTimeout(updateTimeoutRef.current);
6928
+ updateTimeoutRef.current = null;
6912
6929
  }
6930
+
6931
+ updateTimeoutRef.current = setTimeout(function () {
6932
+ if (forceUpdate) {
6933
+ try {
6934
+ forceUpdate();
6935
+ } catch (_) {// ignore caught error
6936
+ }
6937
+ }
6938
+ }, 0);
6913
6939
  }, [forceUpdate, content]); // Close when `disabled` changes to `true`
6914
6940
 
6915
6941
  React.useEffect(function () {
@@ -7717,7 +7743,7 @@ function dialogStyle(_ref) {
7717
7743
  alignItems: 'center',
7718
7744
  justifyContent: 'center',
7719
7745
  outline: 'none',
7720
- background: color.shadow.penumbra
7746
+ background: color.shadow.umbra
7721
7747
  };
7722
7748
  }
7723
7749
  function responsiveDialogPositionStyle(props) {