pixel-react 1.2.1 → 1.2.2
Sign up to get free protection for your applications and to get access to all the features.
- package/lib/components/AppHeader/types.d.ts +11 -2
- package/lib/components/Avatar/Avatar.d.ts +5 -0
- package/lib/components/Avatar/Avatar.stories.d.ts +10 -0
- package/lib/components/Avatar/index.d.ts +1 -0
- package/lib/components/Avatar/types.d.ts +26 -0
- package/lib/components/ExcelFile/ExcelFile/Excel/ActiveCell.d.ts +2 -2
- package/lib/components/ExcelFile/ExcelFile/Excel/ColumnIndicator.d.ts +2 -2
- package/lib/components/ExcelFile/ExcelFile/Excel/Copied.d.ts +1 -1
- package/lib/components/ExcelFile/ExcelFile/Excel/CornerIndicator.d.ts +2 -2
- package/lib/components/ExcelFile/ExcelFile/Excel/DataEditor.d.ts +2 -2
- package/lib/components/ExcelFile/ExcelFile/Excel/DataViewer.d.ts +2 -2
- package/lib/components/ExcelFile/ExcelFile/Excel/FloatingRect.d.ts +2 -2
- package/lib/components/ExcelFile/ExcelFile/Excel/HeaderRow.d.ts +1 -1
- package/lib/components/ExcelFile/ExcelFile/Excel/Row.d.ts +1 -1
- package/lib/components/ExcelFile/ExcelFile/Excel/RowIndicator.d.ts +2 -2
- package/lib/components/ExcelFile/ExcelFile/Excel/Selected.d.ts +1 -1
- package/lib/components/ExcelFile/ExcelFile/Excel/Spreadsheet.d.ts +6 -7
- package/lib/components/ExcelFile/ExcelFile/Excel/Table.d.ts +1 -1
- package/lib/components/ExcelFile/ExcelFile/Excel/actions.d.ts +49 -5
- package/lib/components/ExcelFile/ExcelFile/Excel/context.d.ts +3 -3
- package/lib/components/ExcelFile/ExcelFile/Excel/engine/engine.d.ts +5 -5
- package/lib/components/ExcelFile/ExcelFile/Excel/engine/formula.d.ts +6 -6
- package/lib/components/ExcelFile/ExcelFile/Excel/engine/index.d.ts +2 -2
- package/lib/components/ExcelFile/ExcelFile/Excel/engine/point-graph.d.ts +2 -2
- package/lib/components/ExcelFile/ExcelFile/Excel/engine/point-hash.d.ts +1 -1
- package/lib/components/ExcelFile/ExcelFile/Excel/engine/point-set.d.ts +1 -1
- package/lib/components/ExcelFile/ExcelFile/Excel/index.d.ts +11 -11
- package/lib/components/ExcelFile/ExcelFile/Excel/matrix.d.ts +1 -1
- package/lib/components/ExcelFile/ExcelFile/Excel/point-range.d.ts +1 -1
- package/lib/components/ExcelFile/ExcelFile/Excel/reducer.d.ts +5 -5
- package/lib/components/ExcelFile/ExcelFile/Excel/selection.d.ts +3 -3
- package/lib/components/ExcelFile/ExcelFile/Excel/types.d.ts +11 -48
- package/lib/components/ExcelFile/ExcelFile/Excel/use-dispatch.d.ts +1 -1
- package/lib/components/ExcelFile/ExcelFile/Excel/use-selector.d.ts +1 -1
- package/lib/components/ExcelFile/ExcelFile/Excel/util.d.ts +11 -12
- package/lib/components/ExcelFile/ExcelFile/ExcelFile.d.ts +16 -0
- package/lib/components/ExcelFile/ExcelSheetBar/ExcelSheetBar.d.ts +0 -3
- package/lib/components/ExcelFile/ExcelToolBar/ExcelToolBar.d.ts +12 -0
- package/lib/components/ExcelFile/Types.d.ts +2 -49
- package/lib/components/Form/Form.d.ts +1 -15
- package/lib/components/Form/Form.stories.d.ts +6 -5
- package/lib/components/Form/Forms.d.ts +8 -0
- package/lib/components/Form/index.d.ts +1 -1
- package/lib/components/MenuOption/types.d.ts +7 -7
- package/lib/components/ModulesChip/ModuleChip.d.ts +4 -0
- package/lib/components/ModulesChip/ModuleChip.stories.d.ts +6 -0
- package/lib/components/ModulesChip/index.d.ts +1 -0
- package/lib/components/ModulesChip/types.d.ts +14 -0
- package/lib/components/MultiSelect/MultiSelectTypes.d.ts +1 -0
- package/lib/components/Toastify/Toastify.d.ts +8 -0
- package/lib/components/Toastify/Toastify.stories.d.ts +6 -0
- package/lib/components/Toastify/index.d.ts +1 -0
- package/lib/components/Toastify/types.d.ts +7 -0
- package/lib/components/Tooltip/types.d.ts +6 -0
- package/lib/components/Typography/types.d.ts +1 -0
- package/lib/index.d.ts +75 -22
- package/lib/index.esm.js +26686 -870
- package/lib/index.esm.js.map +1 -1
- package/lib/index.js +26684 -864
- package/lib/index.js.map +1 -1
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/src/StyleGuide/ColorPalette/colorPaletteList.ts +10 -0
- package/src/assets/Themes/BaseTheme.scss +2 -0
- package/src/assets/Themes/DarkTheme.scss +2 -0
- package/src/assets/icons/client_profile.svg +4 -0
- package/src/assets/icons/fireflink_finder_logo.svg +7 -0
- package/src/assets/icons/fireflink_platform.svg +4 -0
- package/src/assets/icons/license_expired.svg +20 -0
- package/src/components/AppHeader/AppHeader.stories.tsx +24 -3
- package/src/components/AppHeader/AppHeader.tsx +29 -11
- package/src/components/AppHeader/types.ts +11 -3
- package/src/components/Avatar/Avatar.scss +24 -0
- package/src/components/Avatar/Avatar.stories.tsx +56 -0
- package/src/components/Avatar/Avatar.tsx +25 -0
- package/src/components/Avatar/index.ts +1 -0
- package/src/components/Avatar/types.ts +27 -0
- package/src/components/ExcelFile/ColorBarselector/ColorBarSelector.scss +0 -2
- package/src/components/ExcelFile/ContextMenu/ContextMenu.scss +1 -4
- package/src/components/ExcelFile/ContextMenu/ContextMenu.tsx +0 -1
- package/src/components/ExcelFile/ExcelFile/Excel/ActiveCell.tsx +13 -13
- package/src/components/ExcelFile/ExcelFile/Excel/Cell.tsx +13 -12
- package/src/components/ExcelFile/ExcelFile/Excel/ColumnIndicator.tsx +40 -32
- package/src/components/ExcelFile/ExcelFile/Excel/Copied.tsx +4 -4
- package/src/components/ExcelFile/ExcelFile/Excel/CornerIndicator.tsx +10 -10
- package/src/components/ExcelFile/ExcelFile/Excel/DataEditor.tsx +5 -5
- package/src/components/ExcelFile/ExcelFile/Excel/DataViewer.tsx +10 -10
- package/src/components/ExcelFile/ExcelFile/Excel/FloatingRect.tsx +6 -6
- package/src/components/ExcelFile/ExcelFile/Excel/HeaderRow.tsx +1 -1
- package/src/components/ExcelFile/ExcelFile/Excel/Row.tsx +1 -1
- package/src/components/ExcelFile/ExcelFile/Excel/RowIndicator.tsx +34 -27
- package/src/components/ExcelFile/ExcelFile/Excel/Selected.tsx +5 -5
- package/src/components/ExcelFile/ExcelFile/Excel/{Spreadsheet.css → Spreadsheet.scss} +21 -37
- package/src/components/ExcelFile/ExcelFile/Excel/Spreadsheet.tsx +87 -78
- package/src/components/ExcelFile/ExcelFile/Excel/Table.tsx +2 -2
- package/src/components/ExcelFile/ExcelFile/Excel/actions.ts +121 -31
- package/src/components/ExcelFile/ExcelFile/Excel/areModelsEqual.ts +1 -1
- package/src/components/ExcelFile/ExcelFile/Excel/context.ts +4 -4
- package/src/components/ExcelFile/ExcelFile/Excel/engine/engine.ts +7 -7
- package/src/components/ExcelFile/ExcelFile/Excel/engine/formula.ts +11 -11
- package/src/components/ExcelFile/ExcelFile/Excel/engine/index.ts +2 -2
- package/src/components/ExcelFile/ExcelFile/Excel/engine/point-graph.ts +3 -3
- package/src/components/ExcelFile/ExcelFile/Excel/engine/point-hash.ts +2 -2
- package/src/components/ExcelFile/ExcelFile/Excel/engine/point-set.ts +2 -2
- package/src/components/ExcelFile/ExcelFile/Excel/index.ts +12 -11
- package/src/components/ExcelFile/ExcelFile/Excel/matrix.ts +18 -24
- package/src/components/ExcelFile/ExcelFile/Excel/point-range.ts +1 -1
- package/src/components/ExcelFile/ExcelFile/Excel/reducer.ts +311 -41
- package/src/components/ExcelFile/ExcelFile/Excel/selection.ts +5 -5
- package/src/components/ExcelFile/ExcelFile/Excel/types.ts +14 -66
- package/src/components/ExcelFile/ExcelFile/Excel/typings/fast-formula-parser.d.ts +8 -8
- package/src/components/ExcelFile/ExcelFile/Excel/use-dispatch.ts +2 -2
- package/src/components/ExcelFile/ExcelFile/Excel/use-selector.ts +3 -3
- package/src/components/ExcelFile/ExcelFile/Excel/util.ts +21 -22
- package/src/components/ExcelFile/ExcelFile/ExcelFile.scss +0 -3
- package/src/components/ExcelFile/ExcelFile/ExcelFile.tsx +45 -403
- package/src/components/ExcelFile/ExcelFile.stories.tsx +10 -29
- package/src/components/ExcelFile/ExcelSheetBar/ExcelSheetBar.tsx +1 -12
- package/src/components/ExcelFile/ExcelToolBar/ExcelToolBar.scss +0 -3
- package/src/components/ExcelFile/ExcelToolBar/ExcelToolBar.tsx +147 -127
- package/src/components/ExcelFile/Types.ts +3 -70
- package/src/components/ExcelFile/index.ts +1 -1
- package/src/components/Form/Form.d.ts +3 -0
- package/src/components/Form/Form.scss +31 -4
- package/src/components/Form/Form.stories.tsx +172 -138
- package/src/components/Form/Form.ts +2 -0
- package/src/components/Form/Forms.tsx +25 -0
- package/src/components/Form/index.ts +1 -1
- package/src/components/Icon/iconList.ts +8 -0
- package/src/components/IconButton/IconButton.scss +1 -1
- package/src/components/MenuOption/types.ts +7 -6
- package/src/components/ModulesChip/ModuleChip.scss +20 -0
- package/src/components/ModulesChip/ModuleChip.stories.tsx +41 -0
- package/src/components/ModulesChip/ModuleChip.tsx +31 -0
- package/src/components/ModulesChip/index.ts +1 -0
- package/src/components/ModulesChip/types.ts +14 -0
- package/src/components/MultiSelect/Dropdown.tsx +6 -1
- package/src/components/MultiSelect/MultiSelect.scss +17 -10
- package/src/components/MultiSelect/MultiSelect.stories.tsx +16 -4
- package/src/components/MultiSelect/MultiSelect.tsx +11 -4
- package/src/components/MultiSelect/MultiSelectTypes.ts +4 -3
- package/src/components/Select/Select.scss +4 -0
- package/src/components/Select/Select.tsx +2 -2
- package/src/components/Toastify/Toastify.stories.tsx +52 -0
- package/src/components/Toastify/Toastify.tsx +66 -0
- package/src/components/Toastify/index.ts +1 -0
- package/src/components/Toastify/types.ts +8 -0
- package/src/components/Tooltip/Tooltip.tsx +2 -1
- package/src/components/Tooltip/types.ts +6 -0
- package/src/components/Typography/Typography.scss +12 -4
- package/src/components/Typography/Typography.stories.tsx +2 -0
- package/src/components/Typography/Typography.tsx +2 -0
- package/src/components/Typography/types.ts +1 -0
- package/src/index.ts +10 -2
- package/src/components/ExcelFile/ChangeExcelStyles.tsx +0 -78
- package/src/components/ExcelFile/ImportExcelStyles.tsx +0 -86
- package/src/components/Form/Form.tsx +0 -57
@@ -6,25 +6,41 @@ import Tooltip from '../../Tooltip';
|
|
6
6
|
import Icon from '../../Icon';
|
7
7
|
import classNames from 'classnames';
|
8
8
|
import Select from '../../Select';
|
9
|
+
import { CellBase } from '../ExcelFile/Excel';
|
10
|
+
import * as Matrix from '../ExcelFile/Excel/matrix';
|
9
11
|
|
10
|
-
|
12
|
+
interface ExcelToolBarProps {
|
13
|
+
toolbar?: 'show' | 'disable' | 'hide';
|
14
|
+
data: Matrix.Matrix<CellBase>;
|
15
|
+
onBold: (data: Matrix.Matrix<CellBase>) => void;
|
16
|
+
onItalic: (data: Matrix.Matrix<CellBase>) => void;
|
17
|
+
onUnderline: (data: Matrix.Matrix<CellBase>) => void;
|
18
|
+
setColor: (data: Matrix.Matrix<CellBase>, value: string) => void;
|
19
|
+
setBackgroundColor: (data: Matrix.Matrix<CellBase>, value: string) => void;
|
20
|
+
setFormatePainter: (data: Matrix.Matrix<CellBase>) => void;
|
21
|
+
}
|
11
22
|
|
12
23
|
const ExcelToolBar: React.FC<ExcelToolBarProps> = ({
|
13
24
|
toolbar = 'show',
|
14
|
-
|
15
|
-
|
25
|
+
data,
|
26
|
+
onBold,
|
27
|
+
onItalic,
|
28
|
+
onUnderline,
|
29
|
+
setColor,
|
30
|
+
setBackgroundColor,
|
31
|
+
setFormatePainter,
|
16
32
|
}) => {
|
17
33
|
const [borderType, setBorderType] = useState<string>('All Border');
|
18
34
|
const [textAlign, setTextAlign] = useState<string>('Text Left');
|
19
35
|
const [colorContainer, setColorPicker] = useState<ColorContainer>({
|
20
|
-
color:
|
21
|
-
backgroundColor:
|
22
|
-
borderColor:
|
36
|
+
color: 'var(--error-light)',
|
37
|
+
backgroundColor: 'var(--error-light)',
|
38
|
+
borderColor: 'var(--text-color)',
|
23
39
|
});
|
24
|
-
const [
|
25
|
-
|
26
|
-
const borderTypeIcon = () =>{
|
40
|
+
const [formatePainterState, setFormatePainterState] =
|
41
|
+
useState<boolean>(false);
|
27
42
|
|
43
|
+
const borderTypeIcon = () => {
|
28
44
|
return [
|
29
45
|
{ value: 'border-all-sides', label: 'All Border', icon: 'all_borders' },
|
30
46
|
{ value: 'border-bottom', label: 'Border Bottom', icon: 'border_bottom' },
|
@@ -32,18 +48,26 @@ const ExcelToolBar: React.FC<ExcelToolBarProps> = ({
|
|
32
48
|
{ value: 'border-right', label: 'Border Right', icon: 'border_right' },
|
33
49
|
{ value: 'border-top', label: 'Border Top', icon: 'border_top' },
|
34
50
|
{ value: 'border-none', label: 'No Border', icon: 'no_border' },
|
35
|
-
]
|
36
|
-
}
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
51
|
+
];
|
52
|
+
};
|
53
|
+
const TextAlignIcon = () => {
|
54
|
+
return [
|
55
|
+
{ label: 'Text Left', value: 'text-align-left', icon: 'text_align_left' },
|
56
|
+
{
|
57
|
+
label: 'Text Center',
|
58
|
+
value: 'text-align-center',
|
59
|
+
icon: 'text_align_center',
|
60
|
+
},
|
61
|
+
{
|
62
|
+
label: 'Text Right',
|
63
|
+
value: 'text-align-right',
|
64
|
+
icon: 'text_align_right',
|
65
|
+
},
|
66
|
+
];
|
67
|
+
};
|
44
68
|
|
45
69
|
const getTextColor = (color: string) => {
|
46
|
-
setColorPicker((prev) => ({ ...prev, color }));
|
70
|
+
setColorPicker((prev) => ({ ...prev, color: color }));
|
47
71
|
};
|
48
72
|
|
49
73
|
const getBackgroundColor = (color: string) => {
|
@@ -52,8 +76,10 @@ const ExcelToolBar: React.FC<ExcelToolBarProps> = ({
|
|
52
76
|
|
53
77
|
useEffect(() => {
|
54
78
|
let timeGap = setTimeout(() => {
|
55
|
-
|
56
|
-
|
79
|
+
console.log(colorContainer.color);
|
80
|
+
|
81
|
+
setColor(data, colorContainer.color);
|
82
|
+
}, 0);
|
57
83
|
return () => {
|
58
84
|
clearTimeout(timeGap);
|
59
85
|
};
|
@@ -61,8 +87,8 @@ const ExcelToolBar: React.FC<ExcelToolBarProps> = ({
|
|
61
87
|
|
62
88
|
useEffect(() => {
|
63
89
|
let timeGap = setTimeout(() => {
|
64
|
-
|
65
|
-
},
|
90
|
+
setBackgroundColor(data, colorContainer.backgroundColor);
|
91
|
+
}, 0);
|
66
92
|
return () => {
|
67
93
|
clearTimeout(timeGap);
|
68
94
|
};
|
@@ -78,7 +104,7 @@ const ExcelToolBar: React.FC<ExcelToolBarProps> = ({
|
|
78
104
|
<Icon
|
79
105
|
disabled={toolbar === 'disable'}
|
80
106
|
onClick={() => {
|
81
|
-
|
107
|
+
onBold(data);
|
82
108
|
}}
|
83
109
|
name="bold"
|
84
110
|
/>
|
@@ -87,148 +113,142 @@ const ExcelToolBar: React.FC<ExcelToolBarProps> = ({
|
|
87
113
|
<Icon
|
88
114
|
disabled={toolbar === 'disable'}
|
89
115
|
onClick={() => {
|
90
|
-
|
116
|
+
onItalic(data);
|
91
117
|
}}
|
92
118
|
name="italic"
|
93
119
|
/>
|
94
120
|
</Tooltip>
|
95
121
|
|
96
122
|
<Select
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
107
|
-
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
112
|
-
|
113
|
-
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
}}
|
118
|
-
/>
|
119
|
-
<Select
|
120
|
-
label="Text Size"
|
121
|
-
onChange={()=>{}}
|
122
|
-
optionsList={[
|
123
|
-
{
|
124
|
-
label: 'Option 1',
|
125
|
-
value: '1'
|
126
|
-
},
|
127
|
-
{
|
128
|
-
label: 'Option 2',
|
129
|
-
value: '2'
|
130
|
-
},
|
131
|
-
{
|
132
|
-
label: 'Option 3',
|
133
|
-
value: '3'
|
134
|
-
}
|
135
|
-
]}
|
136
|
-
selectedOption={{
|
137
|
-
label: 'Option 2',
|
138
|
-
value: '11'
|
139
|
-
}}
|
140
|
-
/>
|
141
|
-
<div style={{display:"flex",alignItems:'center'}}>
|
142
|
-
<Tooltip placement="top" title={'Formate Painter'}>
|
143
|
-
<div className={formatePainter ? 'formate-painter-active' : ''}>
|
144
|
-
<Icon
|
145
|
-
disabled={toolbar === 'disable'}
|
146
|
-
onClick={() => {
|
147
|
-
setFormatePainter((prev) => !prev);
|
148
|
-
formatePaint();
|
149
|
-
}}
|
150
|
-
name="all_borders"
|
151
|
-
/>
|
152
|
-
</div>
|
153
|
-
</Tooltip>
|
154
|
-
<MenuOption
|
155
|
-
iconName="more"
|
156
|
-
options={borderTypeIcon()}
|
157
|
-
tooltipTitle="Border Type"
|
158
|
-
tooltipPlacement="top"
|
159
|
-
onOptionClick={(e) => {
|
160
|
-
setBorderType(borderType);
|
161
|
-
applyStyle('border', e.label);
|
123
|
+
className="textType"
|
124
|
+
label="Text type"
|
125
|
+
onChange={() => {}}
|
126
|
+
optionsList={[
|
127
|
+
{
|
128
|
+
label: 'Option 1',
|
129
|
+
value: '1',
|
130
|
+
},
|
131
|
+
{
|
132
|
+
label: 'Option 2',
|
133
|
+
value: '2',
|
134
|
+
},
|
135
|
+
{
|
136
|
+
label: 'Option 3',
|
137
|
+
value: '3',
|
138
|
+
},
|
139
|
+
]}
|
140
|
+
selectedOption={{
|
141
|
+
label: 'Option 2',
|
142
|
+
value: 'Arial',
|
162
143
|
}}
|
163
144
|
/>
|
164
|
-
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
setTextAlign(textAlign);
|
185
|
-
applyStyle('alignment', e.label);
|
145
|
+
<Select
|
146
|
+
label="Text Size"
|
147
|
+
onChange={() => {}}
|
148
|
+
optionsList={[
|
149
|
+
{
|
150
|
+
label: 'Option 1',
|
151
|
+
value: '1',
|
152
|
+
},
|
153
|
+
{
|
154
|
+
label: 'Option 2',
|
155
|
+
value: '2',
|
156
|
+
},
|
157
|
+
{
|
158
|
+
label: 'Option 3',
|
159
|
+
value: '3',
|
160
|
+
},
|
161
|
+
]}
|
162
|
+
selectedOption={{
|
163
|
+
label: 'Option 2',
|
164
|
+
value: '11',
|
186
165
|
}}
|
187
166
|
/>
|
167
|
+
<div style={{ display: 'flex', alignItems: 'center' }}>
|
168
|
+
<Tooltip placement="top" title={'Formate Painter'}>
|
169
|
+
<div className={formatePainterState ? 'formate-painter-active' : ''}>
|
170
|
+
<Icon
|
171
|
+
disabled={toolbar === 'disable'}
|
172
|
+
onClick={() => {
|
173
|
+
setFormatePainterState((prev) => !prev);
|
174
|
+
}}
|
175
|
+
name="all_borders"
|
176
|
+
/>
|
177
|
+
</div>
|
178
|
+
</Tooltip>
|
179
|
+
<MenuOption
|
180
|
+
iconName="more"
|
181
|
+
options={borderTypeIcon()}
|
182
|
+
tooltipTitle="Border Type"
|
183
|
+
tooltipPlacement="top"
|
184
|
+
onOptionClick={() => {
|
185
|
+
setBorderType(borderType);
|
186
|
+
}}
|
187
|
+
/>
|
188
|
+
</div>
|
189
|
+
<div style={{ display: 'flex', alignItems: 'center' }}>
|
190
|
+
<Tooltip placement="top" title={'Formate Painter'}>
|
191
|
+
<div className={formatePainterState ? 'formate-painter-active' : ''}>
|
192
|
+
<Icon
|
193
|
+
disabled={toolbar === 'disable'}
|
194
|
+
onClick={() => {
|
195
|
+
setFormatePainter(data);
|
196
|
+
setFormatePainterState((prev) => !prev);
|
197
|
+
}}
|
198
|
+
name="text_align_left"
|
199
|
+
/>
|
200
|
+
</div>
|
201
|
+
</Tooltip>
|
202
|
+
<MenuOption
|
203
|
+
iconName="more"
|
204
|
+
options={TextAlignIcon()}
|
205
|
+
tooltipTitle="Text Align"
|
206
|
+
tooltipPlacement="top"
|
207
|
+
onOptionClick={() => {
|
208
|
+
setTextAlign(textAlign);
|
209
|
+
}}
|
210
|
+
/>
|
188
211
|
</div>
|
189
212
|
<Tooltip placement="top" title={'Formate Painter'}>
|
190
|
-
<div className={
|
213
|
+
<div className={formatePainterState ? 'formate-painter-active' : ''}>
|
191
214
|
<Icon
|
192
215
|
disabled={toolbar === 'disable'}
|
193
216
|
onClick={() => {
|
194
|
-
|
195
|
-
formatePaint();
|
217
|
+
setFormatePainterState((prev) => !prev);
|
196
218
|
}}
|
197
219
|
name="formate_painter"
|
198
220
|
/>
|
199
221
|
</div>
|
200
222
|
</Tooltip>
|
201
223
|
<Tooltip placement="top" title={'Formate Painter'}>
|
202
|
-
<div className={
|
224
|
+
<div className={formatePainterState ? 'formate-painter-active' : ''}>
|
203
225
|
<Icon
|
204
226
|
disabled={toolbar === 'disable'}
|
205
227
|
onClick={() => {
|
206
|
-
|
207
|
-
formatePaint();
|
228
|
+
setFormatePainterState((prev) => !prev);
|
229
|
+
// formatePaint();
|
208
230
|
}}
|
209
231
|
name="strike_through"
|
210
232
|
/>
|
211
233
|
</div>
|
212
234
|
</Tooltip>
|
213
|
-
<Tooltip placement="top" title={'
|
214
|
-
<div
|
235
|
+
<Tooltip placement="top" title={'Underline'}>
|
236
|
+
<div>
|
215
237
|
<Icon
|
216
238
|
disabled={toolbar === 'disable'}
|
217
239
|
onClick={() => {
|
218
|
-
|
219
|
-
formatePaint();
|
240
|
+
onUnderline(data);
|
220
241
|
}}
|
221
242
|
name="underline"
|
222
243
|
/>
|
223
244
|
</div>
|
224
245
|
</Tooltip>
|
225
246
|
<Tooltip placement="top" title={'Formate Painter'}>
|
226
|
-
<div className={
|
247
|
+
<div className={formatePainterState ? 'formate-painter-active' : ''}>
|
227
248
|
<Icon
|
228
249
|
disabled={toolbar === 'disable'}
|
229
250
|
onClick={() => {
|
230
|
-
|
231
|
-
formatePaint();
|
251
|
+
setFormatePainterState((prev) => !prev);
|
232
252
|
}}
|
233
253
|
name="double_underline"
|
234
254
|
/>
|
@@ -239,7 +259,7 @@ const ExcelToolBar: React.FC<ExcelToolBarProps> = ({
|
|
239
259
|
<Icon
|
240
260
|
disabled={toolbar === 'disable'}
|
241
261
|
onClick={() => {
|
242
|
-
|
262
|
+
setColor(data, colorContainer.color);
|
243
263
|
}}
|
244
264
|
name="text_color"
|
245
265
|
/>
|
@@ -254,7 +274,7 @@ const ExcelToolBar: React.FC<ExcelToolBarProps> = ({
|
|
254
274
|
<Icon
|
255
275
|
disabled={toolbar === 'disable'}
|
256
276
|
onClick={() => {
|
257
|
-
|
277
|
+
setBackgroundColor(data, colorContainer.backgroundColor);
|
258
278
|
}}
|
259
279
|
name="fill_color"
|
260
280
|
/>
|
@@ -31,64 +31,8 @@ interface WorkData {
|
|
31
31
|
value: string;
|
32
32
|
|
33
33
|
/** Styling options for the cell */
|
34
|
-
style:
|
35
|
-
type?:boolean;
|
36
|
-
}
|
37
|
-
|
38
|
-
interface CellStyle {
|
39
|
-
/** Font name for the cell text */
|
40
|
-
name?: string;
|
41
|
-
|
42
|
-
/** Font size of the cell text */
|
43
|
-
size?: number;
|
44
|
-
|
45
|
-
position?:string;
|
46
|
-
|
47
|
-
/** Whether the text is bold */
|
48
|
-
bold?: boolean;
|
49
|
-
|
50
|
-
fontSize?: string,
|
51
|
-
fontFamily?: string,
|
52
|
-
|
53
|
-
|
54
|
-
/** Whether the text is italicized */
|
55
|
-
italic?: boolean;
|
56
|
-
|
57
|
-
/** Text color in the cell (hex code) */
|
58
|
-
color?: string;
|
59
|
-
|
60
|
-
/** Background color of the cell (hex code) */
|
61
|
-
backgroundColor?: string;
|
62
|
-
|
63
|
-
/** Border color of the cell (hex code) */
|
64
|
-
borderColor?: string;
|
65
|
-
|
66
|
-
/** Border styles for each side of the cell */
|
67
|
-
border?: {
|
68
|
-
/** Border style for the top side of the cell */
|
69
|
-
top: string;
|
70
|
-
|
71
|
-
/** Border style for the bottom side of the cell */
|
72
|
-
bottom: string;
|
73
|
-
|
74
|
-
/** Border style for the left side of the cell */
|
75
|
-
left: string;
|
76
|
-
|
77
|
-
/** Border style for the right side of the cell */
|
78
|
-
right: string;
|
79
|
-
};
|
80
|
-
|
81
|
-
/** Text alignment and wrapping properties */
|
82
|
-
alignment?: {
|
83
|
-
/** Horizontal text alignment ('left', 'center', or 'right') */
|
84
|
-
horizontal: string;
|
85
|
-
|
86
|
-
/** Vertical text alignment ('top', 'middle', or 'bottom') */
|
87
|
-
vertical: string;
|
88
|
-
|
89
|
-
/** Whether the text is wrapped within the cell */
|
90
|
-
wrapText: boolean;
|
91
|
-
};
|
34
|
+
style: React.CSSProperties;
|
35
|
+
type?: boolean;
|
92
36
|
}
|
93
37
|
|
94
38
|
/** A generic type to represent a 2D matrix of any type (or undefined values) */
|
@@ -160,22 +104,11 @@ interface SelectedValue {
|
|
160
104
|
alphaCol: string;
|
161
105
|
|
162
106
|
/** The style applied to the selected cell */
|
163
|
-
style:
|
107
|
+
style: React.CSSProperties;
|
164
108
|
|
165
109
|
/** The sheet name where the cell is located */
|
166
110
|
sheet: string;
|
167
111
|
}
|
168
|
-
interface ExcelToolBarProps {
|
169
|
-
/** use this to hide/show/disable the toolbar */
|
170
|
-
toolbar?: 'show' | 'disable' | 'hide';
|
171
|
-
|
172
|
-
/** function to apply styles */
|
173
|
-
applyStyle: (styleType: string, value: any) => void;
|
174
|
-
|
175
|
-
/** function to trigger format painter */
|
176
|
-
formatePaint: () => void;
|
177
|
-
}
|
178
|
-
|
179
112
|
interface ExcelSheetBarProps {
|
180
113
|
/** Object containing details about the file, including sheet names */
|
181
114
|
fileDetails: {
|
@@ -1 +1 @@
|
|
1
|
-
export { default } from './ExcelFile/ExcelFile';
|
1
|
+
export { default } from './ExcelFile/ExcelFile';
|
@@ -56,19 +56,20 @@
|
|
56
56
|
}
|
57
57
|
}
|
58
58
|
}
|
59
|
-
|
59
|
+
|
60
60
|
.ff-form-radio-group {
|
61
|
-
display: flex;
|
61
|
+
display: flex;
|
62
62
|
flex-direction: column;
|
63
63
|
gap: 1rem;
|
64
64
|
margin-bottom: 16px;
|
65
|
-
|
65
|
+
|
66
|
+
.ff-radio-group-wrapper {
|
66
67
|
display: flex;
|
67
68
|
}
|
68
69
|
.ff-radio-gender {
|
69
70
|
display: flex;
|
70
71
|
flex-direction: column;
|
71
|
-
align-items: center;
|
72
|
+
align-items: center;
|
72
73
|
|
73
74
|
input[type="radio"] {
|
74
75
|
margin-right: 0.5rem;
|
@@ -96,3 +97,29 @@
|
|
96
97
|
}
|
97
98
|
}
|
98
99
|
}
|
100
|
+
|
101
|
+
.ff-main {
|
102
|
+
padding: 30px;
|
103
|
+
border-radius: 10px;
|
104
|
+
background-color: var(--tree-connecting-lines-color);
|
105
|
+
|
106
|
+
.ff-button-layout {
|
107
|
+
width: 99%;
|
108
|
+
display: flex;
|
109
|
+
gap: 12px;
|
110
|
+
margin-top: 24px;
|
111
|
+
|
112
|
+
button {
|
113
|
+
width: 50%;
|
114
|
+
background-color: var(--brand-color);
|
115
|
+
color: var(--primary-button-text-color);
|
116
|
+
border: none;
|
117
|
+
border-radius: 8px;
|
118
|
+
padding: 10px;
|
119
|
+
cursor: pointer;
|
120
|
+
}
|
121
|
+
}
|
122
|
+
.ff-select {
|
123
|
+
width: 90%;
|
124
|
+
}
|
125
|
+
}
|