dhre-ui-kit 3.5.0 → 3.6.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.
@@ -0,0 +1,30 @@
1
+ declare const styles: {
2
+ container: {
3
+ flexDirection: "row";
4
+ alignItems: "center";
5
+ justifyContent: "space-between";
6
+ paddingVertical: number;
7
+ paddingHorizontal: number;
8
+ borderWidth: number;
9
+ borderStyle: "dashed";
10
+ borderRadius: number;
11
+ marginBottom: number;
12
+ };
13
+ fileUploadContainerStyle: {
14
+ flexDirection: "row";
15
+ alignItems: "center";
16
+ justifyContent: "space-between";
17
+ paddingVertical: number;
18
+ paddingHorizontal: number;
19
+ borderRadius: number;
20
+ marginBottom: number;
21
+ };
22
+ innerContainer: {
23
+ flexDirection: "row";
24
+ columnGap: number;
25
+ };
26
+ titleContainer: {
27
+ gap: number;
28
+ };
29
+ };
30
+ export default styles;
File without changes
@@ -21,6 +21,8 @@ interface CommonTextInputProps extends BaseTextInputProps {
21
21
  disableBorder?: boolean;
22
22
  /** Force RTL layout. When omitted, auto-detected from the label/value text. */
23
23
  forceRTL?: boolean;
24
+ /** Overrides the computed outline/border color (error/disabled/focused/filled logic). */
25
+ borderColor?: string;
24
26
  }
25
27
  declare const _default: (props: CommonTextInputProps) => React.JSX.Element;
26
28
  export default _default;
package/lib/index.js CHANGED
@@ -2013,7 +2013,7 @@ function buildPlainContainerStyle(variant, disabled, disabledColor, theme) {
2013
2013
  }
2014
2014
  if (variant === "quaternary") {
2015
2015
  return {
2016
- backgroundColor: "transparent",
2016
+ backgroundColor: theme[Theme.BUTTON_INVRTED_FILL],
2017
2017
  borderWidth: 1,
2018
2018
  borderColor: disabled ? theme[Theme.BUTTON_QUATERNARY_DISABLED_STROKE] : theme[Theme.BUTTON_QUATERNARY_DEFAULT_STROKE]
2019
2019
  };
@@ -3813,7 +3813,7 @@ const CustomHeader = ({
3813
3813
  {
3814
3814
  variant: "BODY1_MEDIUM",
3815
3815
  text: title,
3816
- style: { color: titleColor ?? theme.CONTENT_PRIMARY["dark"] }
3816
+ style: { color: titleColor ?? theme.CONTENT_PRIMARY }
3817
3817
  }
3818
3818
  ), titleSuffixIcon && React__default["default"].cloneElement(titleSuffixIcon, {
3819
3819
  width: ICON_SIZE,
@@ -11776,7 +11776,8 @@ const CommonTextInput = (props) => {
11776
11776
  onRightIconPress,
11777
11777
  onlyErrorBorderLabel,
11778
11778
  disableBorder = false,
11779
- forceRTL
11779
+ forceRTL,
11780
+ borderColor: borderColorOverride
11780
11781
  } = props;
11781
11782
  const [isFocused, setIsFocused] = React.useState(false);
11782
11783
  const handleFocus = () => setIsFocused(true);
@@ -11785,7 +11786,7 @@ const CommonTextInput = (props) => {
11785
11786
  const isDisabled = !editable;
11786
11787
  const isError = !!(errorMessage?.length || onlyErrorBorderLabel);
11787
11788
  const hasValue = !!value?.length;
11788
- const currentBorderColor = isError ? theme[Theme.ERROR] : isDisabled ? theme[Theme.STROKE_TERTIARY] : isFocused || hasValue && !disableBorder ? theme[Theme.STROKE_ACTIVE] : theme[Theme.STROKE_SECONDARY];
11789
+ const currentBorderColor = borderColorOverride ?? (isError ? theme[Theme.ERROR] : isDisabled ? theme[Theme.STROKE_TERTIARY] : isFocused || hasValue && !disableBorder ? theme[Theme.STROKE_ACTIVE] : theme[Theme.STROKE_SECONDARY]);
11789
11790
  const borderWidth = isFocused && !isDisabled ? 2 : 1;
11790
11791
  const inputTextColor = isDisabled ? theme[Theme.CONTENT_TERTIARY] : theme[Theme.CONTENT_PRIMARY];
11791
11792
  const placeholderColor = theme[Theme.CONTENT_SECONDRY];