@razorpay/blade 3.5.3 → 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.
- package/CHANGELOG.md +7 -0
- package/build/components/index.d.ts +33 -2
- package/build/components/index.native.d.ts +33 -2
- package/build/components/index.native.js +9 -7
- package/build/components/index.native.js.map +1 -1
- package/build/components/index.web.js +48 -25
- package/build/components/index.web.js.map +1 -1
- package/build/css/bankingThemeDarkDesktop.css +20 -12
- package/build/css/bankingThemeDarkMobile.css +20 -12
- package/build/css/bankingThemeLightDesktop.css +20 -12
- package/build/css/bankingThemeLightMobile.css +20 -12
- package/build/css/paymentThemeDarkDesktop.css +20 -12
- package/build/css/paymentThemeDarkMobile.css +20 -12
- package/build/css/paymentThemeLightDesktop.css +20 -12
- package/build/css/paymentThemeLightMobile.css +20 -12
- package/build/tokens/index.d.ts +4 -1
- package/build/tokens/index.native.d.ts +4 -1
- package/build/tokens/index.native.js +3 -3
- package/build/tokens/index.native.js.map +1 -1
- package/build/tokens/index.web.js +164 -50
- package/build/tokens/index.web.js.map +1 -1
- package/package.json +4 -1
|
@@ -5377,7 +5377,7 @@ var CodeContainer = /*#__PURE__*/styled(Box).withConfig({
|
|
|
5377
5377
|
var padding = "".concat(makeSpace(props.theme.spacing[0]), " ").concat(makeSpace(props.theme.spacing[2]));
|
|
5378
5378
|
return {
|
|
5379
5379
|
padding: padding,
|
|
5380
|
-
backgroundColor: props.theme.colors.brand.gray[400],
|
|
5380
|
+
backgroundColor: props.theme.colors.brand.gray[400].lowContrast,
|
|
5381
5381
|
borderRadius: props.theme.border.radius.medium,
|
|
5382
5382
|
display: isPlatformWeb ? 'inline-block' : undefined,
|
|
5383
5383
|
// Removing the line height of container to remove extra surrounding space in background
|
|
@@ -5775,9 +5775,9 @@ var getColor = function getColor(_ref) {
|
|
|
5775
5775
|
if (intent) {
|
|
5776
5776
|
return get_1(theme.colors, "feedback.".concat(intent, ".action.icon.primary.disabled.").concat(contrast, "Contrast"));
|
|
5777
5777
|
} else if (contrast == 'low') {
|
|
5778
|
-
return get_1(theme.colors, 'brand.gray.700');
|
|
5778
|
+
return get_1(theme.colors, 'brand.gray.700.lowContrast');
|
|
5779
5779
|
} else {
|
|
5780
|
-
return get_1(theme.colors, 'brand.gray.400');
|
|
5780
|
+
return get_1(theme.colors, 'brand.gray.400.lowContrast');
|
|
5781
5781
|
}
|
|
5782
5782
|
};
|
|
5783
5783
|
|
|
@@ -6770,6 +6770,29 @@ var Button = function Button(_ref) {
|
|
|
6770
6770
|
}));
|
|
6771
6771
|
};
|
|
6772
6772
|
|
|
6773
|
+
var Counter = function Counter(_ref) {
|
|
6774
|
+
var value = _ref.value,
|
|
6775
|
+
max = _ref.max,
|
|
6776
|
+
_ref$intent = _ref.intent,
|
|
6777
|
+
intent = _ref$intent === void 0 ? 'neutral' : _ref$intent,
|
|
6778
|
+
_ref$contrast = _ref.contrast,
|
|
6779
|
+
contrast = _ref$contrast === void 0 ? 'low' : _ref$contrast,
|
|
6780
|
+
_ref$size = _ref.size,
|
|
6781
|
+
size = _ref$size === void 0 ? 'medium' : _ref$size;
|
|
6782
|
+
var content = "".concat(value);
|
|
6783
|
+
|
|
6784
|
+
if (max && value > max) {
|
|
6785
|
+
content = "".concat(max, "+");
|
|
6786
|
+
}
|
|
6787
|
+
|
|
6788
|
+
return /*#__PURE__*/jsx(Badge, {
|
|
6789
|
+
size: size,
|
|
6790
|
+
variant: intent,
|
|
6791
|
+
contrast: contrast,
|
|
6792
|
+
children: content
|
|
6793
|
+
});
|
|
6794
|
+
};
|
|
6795
|
+
|
|
6773
6796
|
/**
|
|
6774
6797
|
* Checks if `value` is `undefined`.
|
|
6775
6798
|
*
|
|
@@ -6832,7 +6855,7 @@ var checkboxIconColors = {
|
|
|
6832
6855
|
"default": {
|
|
6833
6856
|
border: {
|
|
6834
6857
|
checked: 'colors.brand.primary.500',
|
|
6835
|
-
unchecked: 'colors.brand.gray.500'
|
|
6858
|
+
unchecked: 'colors.brand.gray.500.lowContrast'
|
|
6836
6859
|
},
|
|
6837
6860
|
background: {
|
|
6838
6861
|
checked: 'colors.brand.primary.500',
|
|
@@ -6842,10 +6865,10 @@ var checkboxIconColors = {
|
|
|
6842
6865
|
disabled: {
|
|
6843
6866
|
border: {
|
|
6844
6867
|
checked: 'transparent',
|
|
6845
|
-
unchecked: 'colors.brand.gray.a100'
|
|
6868
|
+
unchecked: 'colors.brand.gray.a100.lowContrast'
|
|
6846
6869
|
},
|
|
6847
6870
|
background: {
|
|
6848
|
-
checked: 'colors.brand.gray.a100',
|
|
6871
|
+
checked: 'colors.brand.gray.a100.lowContrast',
|
|
6849
6872
|
unchecked: 'transparent'
|
|
6850
6873
|
}
|
|
6851
6874
|
},
|
|
@@ -7001,8 +7024,8 @@ var CheckboxIcon = function CheckboxIcon(_ref3) {
|
|
|
7001
7024
|
var _useTheme = useTheme(),
|
|
7002
7025
|
theme = _useTheme.theme;
|
|
7003
7026
|
|
|
7004
|
-
var defaultIconColor = get_1(theme, 'colors.brand.gray.200');
|
|
7005
|
-
var disabledIconColor = get_1(theme, 'colors.brand.gray.500');
|
|
7027
|
+
var defaultIconColor = get_1(theme, 'colors.brand.gray.200.lowContrast');
|
|
7028
|
+
var disabledIconColor = get_1(theme, 'colors.brand.gray.500.lowContrast');
|
|
7006
7029
|
var iconColor = isDisabled ? disabledIconColor : defaultIconColor;
|
|
7007
7030
|
return /*#__PURE__*/jsxs(CheckboxIconWrapper, {
|
|
7008
7031
|
size: size,
|
|
@@ -7543,11 +7566,11 @@ var variants = {
|
|
|
7543
7566
|
"default": {
|
|
7544
7567
|
background: {
|
|
7545
7568
|
checked: 'colors.brand.primary.600',
|
|
7546
|
-
unchecked: 'colors.brand.gray.a50'
|
|
7569
|
+
unchecked: 'colors.brand.gray.a50.lowContrast'
|
|
7547
7570
|
},
|
|
7548
7571
|
border: {
|
|
7549
7572
|
checked: 'colors.brand.primary.600',
|
|
7550
|
-
unchecked: 'colors.brand.gray.500'
|
|
7573
|
+
unchecked: 'colors.brand.gray.500.lowContrast'
|
|
7551
7574
|
}
|
|
7552
7575
|
}
|
|
7553
7576
|
};
|
|
@@ -8146,11 +8169,11 @@ var getInputBackgroundAndBorderStyles = function getInputBackgroundAndBorderStyl
|
|
|
8146
8169
|
isDisabled = _ref.isDisabled,
|
|
8147
8170
|
validationState = _ref.validationState;
|
|
8148
8171
|
// normal state
|
|
8149
|
-
var backgroundColor = theme.colors.brand.gray[200];
|
|
8150
|
-
var borderBottomColor = theme.colors.brand.gray[400]; //hoverState
|
|
8172
|
+
var backgroundColor = theme.colors.brand.gray[200].lowContrast;
|
|
8173
|
+
var borderBottomColor = theme.colors.brand.gray[400].lowContrast; //hoverState
|
|
8151
8174
|
|
|
8152
8175
|
if (isHovered) {
|
|
8153
|
-
backgroundColor = theme.colors.brand.gray[300];
|
|
8176
|
+
backgroundColor = theme.colors.brand.gray[300].lowContrast;
|
|
8154
8177
|
} // focused state
|
|
8155
8178
|
|
|
8156
8179
|
|
|
@@ -8160,8 +8183,8 @@ var getInputBackgroundAndBorderStyles = function getInputBackgroundAndBorderStyl
|
|
|
8160
8183
|
|
|
8161
8184
|
|
|
8162
8185
|
if (isDisabled) {
|
|
8163
|
-
backgroundColor = theme.colors.brand.gray[200];
|
|
8164
|
-
borderBottomColor = theme.colors.brand.gray[300];
|
|
8186
|
+
backgroundColor = theme.colors.brand.gray[200].lowContrast;
|
|
8187
|
+
borderBottomColor = theme.colors.brand.gray[300].lowContrast;
|
|
8165
8188
|
} // validation state
|
|
8166
8189
|
|
|
8167
8190
|
|
|
@@ -9726,12 +9749,12 @@ var radioIconColors = {
|
|
|
9726
9749
|
variants: {
|
|
9727
9750
|
"default": {
|
|
9728
9751
|
dot: {
|
|
9729
|
-
checked: 'colors.brand.gray.200',
|
|
9730
|
-
unchecked: 'colors.brand.gray.200'
|
|
9752
|
+
checked: 'colors.brand.gray.200.lowContrast',
|
|
9753
|
+
unchecked: 'colors.brand.gray.200.lowContrast'
|
|
9731
9754
|
},
|
|
9732
9755
|
border: {
|
|
9733
9756
|
checked: 'colors.brand.primary.500',
|
|
9734
|
-
unchecked: 'colors.brand.gray.500'
|
|
9757
|
+
unchecked: 'colors.brand.gray.500.lowContrast'
|
|
9735
9758
|
},
|
|
9736
9759
|
background: {
|
|
9737
9760
|
checked: 'colors.brand.primary.500',
|
|
@@ -9740,22 +9763,22 @@ var radioIconColors = {
|
|
|
9740
9763
|
},
|
|
9741
9764
|
disabled: {
|
|
9742
9765
|
dot: {
|
|
9743
|
-
checked: 'colors.brand.gray.200',
|
|
9744
|
-
unchecked: 'colors.brand.gray.200'
|
|
9766
|
+
checked: 'colors.brand.gray.200.lowContrast',
|
|
9767
|
+
unchecked: 'colors.brand.gray.200.lowContrast'
|
|
9745
9768
|
},
|
|
9746
9769
|
border: {
|
|
9747
9770
|
checked: 'transparent',
|
|
9748
|
-
unchecked: 'colors.brand.gray.a100'
|
|
9771
|
+
unchecked: 'colors.brand.gray.a100.lowContrast'
|
|
9749
9772
|
},
|
|
9750
9773
|
background: {
|
|
9751
|
-
checked: 'colors.brand.gray.a100',
|
|
9774
|
+
checked: 'colors.brand.gray.a100.lowContrast',
|
|
9752
9775
|
unchecked: 'transparent'
|
|
9753
9776
|
}
|
|
9754
9777
|
},
|
|
9755
9778
|
negative: {
|
|
9756
9779
|
dot: {
|
|
9757
|
-
checked: 'colors.brand.gray.200',
|
|
9758
|
-
unchecked: 'colors.brand.gray.200'
|
|
9780
|
+
checked: 'colors.brand.gray.200.lowContrast',
|
|
9781
|
+
unchecked: 'colors.brand.gray.200.lowContrast'
|
|
9759
9782
|
},
|
|
9760
9783
|
border: {
|
|
9761
9784
|
checked: 'colors.feedback.border.negative.highContrast',
|
|
@@ -10350,5 +10373,5 @@ var SkipNavContent = function SkipNavContent(_ref3) {
|
|
|
10350
10373
|
}, testID('skipnav-content')));
|
|
10351
10374
|
};
|
|
10352
10375
|
|
|
10353
|
-
export { Alert, AlertTriangleIcon as AlertOctagonIcon, AlertTriangleIcon$1 as AlertTriangleIcon, ArrowDownIcon, ArrowLeftIcon, ArrowRightIcon, ArrowUpIcon, ArrowUpRightIcon, Badge, BladeProvider, Button, CheckCircleIcon, CheckIcon, Checkbox, CheckboxGroup, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon, ChevronUpIcon, CloseIcon, Code, CreditCardIcon, DollarIcon, DownloadIcon, EditIcon, ExternalLinkIcon, EyeIcon, EyeOffIcon, Heading, HelpCircleIcon, HistoryIcon, HomeIcon, InfoIcon, Link, LinkIcon, MinusIcon, OTPInput, PasswordInput, PauseIcon, PlusIcon, Radio, RadioGroup, RefreshLeftIcon, RotateCounterClockWiseIcon, RupeeIcon, SearchIcon, SkipNavContent, SkipNavLink, Spinner, Text, TextArea, TextInput, Title, TrashIcon, TrendingDownIcon, TrendingUpIcon, VisuallyHidden, announce, clearAnnouncer, destroyAnnouncer, getTextProps, screenReaderStyles, useTheme };
|
|
10376
|
+
export { Alert, AlertTriangleIcon as AlertOctagonIcon, AlertTriangleIcon$1 as AlertTriangleIcon, ArrowDownIcon, ArrowLeftIcon, ArrowRightIcon, ArrowUpIcon, ArrowUpRightIcon, Badge, BladeProvider, Button, CheckCircleIcon, CheckIcon, Checkbox, CheckboxGroup, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon, ChevronUpIcon, CloseIcon, Code, Counter, CreditCardIcon, DollarIcon, DownloadIcon, EditIcon, ExternalLinkIcon, EyeIcon, EyeOffIcon, Heading, HelpCircleIcon, HistoryIcon, HomeIcon, InfoIcon, Link, LinkIcon, MinusIcon, OTPInput, PasswordInput, PauseIcon, PlusIcon, Radio, RadioGroup, RefreshLeftIcon, RotateCounterClockWiseIcon, RupeeIcon, SearchIcon, SkipNavContent, SkipNavLink, Spinner, Text, TextArea, TextInput, Title, TrashIcon, TrendingDownIcon, TrendingUpIcon, VisuallyHidden, announce, clearAnnouncer, destroyAnnouncer, getTextProps, screenReaderStyles, useTheme };
|
|
10354
10377
|
//# sourceMappingURL=index.web.js.map
|