@campxdev/react-blueprint 1.2.10 → 1.2.11

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@campxdev/react-blueprint",
3
- "version": "1.2.10",
3
+ "version": "1.2.11",
4
4
  "main": "./export.ts",
5
5
  "private": false,
6
6
  "dependencies": {
@@ -60,7 +60,7 @@ const TreeMap = ({
60
60
  style={treeMapStyle}
61
61
  isAnimationActive={isAnimationActive}
62
62
  animationEasing={animationEasing}
63
- content={<CustomizedContent colors={colors} />}
63
+ content={<CustomizedContent colors={colors} fill={fill} />}
64
64
  >
65
65
  {showToolTip && <Tooltip content={CustomTooltip} />}
66
66
  </ReTreeMap>
@@ -81,9 +81,10 @@ const CustomizedContent = (props: any) => {
81
81
  height,
82
82
  index,
83
83
  payload,
84
- colors,
85
84
  rank,
86
85
  name,
86
+ fill,
87
+ stroke,
87
88
  } = props;
88
89
 
89
90
  return (
@@ -94,13 +95,8 @@ const CustomizedContent = (props: any) => {
94
95
  width={width}
95
96
  height={height}
96
97
  style={{
97
- fill:
98
- depth < 2
99
- ? colors[
100
- Math.floor((index / root.children.length) * colors.length)
101
- ]
102
- : '#ffffff00',
103
- stroke: theme.palette.surface.grey,
98
+ fill: fill,
99
+ stroke: stroke,
104
100
  strokeWidth: 2,
105
101
  strokeOpacity: 1,
106
102
  }}
@@ -126,7 +122,7 @@ const CustomTooltip = ({ active, payload }: any) => {
126
122
  if (active && payload && payload.length) {
127
123
  return (
128
124
  <StyledContainer>
129
- <Typography variant="body2">{`${payload[0].payload.root.name}`}</Typography>
125
+ <Typography variant="body2">{`${payload[0].payload.name}`}</Typography>
130
126
  <Typography variant="caption">
131
127
  <span>{`${payload[0].payload.name}`}</span>
132
128
  <span
@@ -26,7 +26,7 @@ function sleep(duration: number): Promise<void> {
26
26
  export type SingleSelectProps = {
27
27
  options?: { label: string; subLabel?: string; value: any }[] | any[];
28
28
  optionsApiEndPoint?: string;
29
- useCampxAxios: boolean;
29
+ useCampxAxios?: boolean;
30
30
  required?: boolean;
31
31
  label?: string;
32
32
  name?: string;
@@ -41,7 +41,7 @@ const CustomPaper = (props: PaperProps) => (
41
41
  <Paper
42
42
  {...props}
43
43
  sx={{
44
- boxShadow: 'none',
44
+ boxShadow: 'none',
45
45
  borderRadius: '0px 0px 4px 4px',
46
46
  }}
47
47
  >
@@ -50,7 +50,6 @@ const CustomPaper = (props: PaperProps) => (
50
50
  </Paper>
51
51
  );
52
52
 
53
-
54
53
  enum SingleSelectActionsTypes {
55
54
  OPEN = 'open',
56
55
  CLOSE = 'close',