pixel-react-excel-sheet 1.0.31 → 1.0.33

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.
Files changed (138) hide show
  1. package/lib/components/Accordion/Accordion.d.ts +1 -1
  2. package/lib/components/Accordion/types.d.ts +4 -0
  3. package/lib/components/AllProjectsDropdown/types.d.ts +2 -0
  4. package/lib/components/Button/Button.d.ts +2 -2
  5. package/lib/components/Button/types.d.ts +17 -0
  6. package/lib/components/Charts/DashboardDonutChart/types.d.ts +2 -0
  7. package/lib/components/Charts/MultiRadialChart/types.d.ts +3 -0
  8. package/lib/components/ChooseFile/ChooseFile.d.ts +3 -0
  9. package/lib/components/ChooseFile/types.d.ts +68 -0
  10. package/lib/components/ConditionalDropdown/ConditionalDropdown.d.ts +1 -2
  11. package/lib/components/ConditionalDropdown/types.d.ts +4 -4
  12. package/lib/components/ConnectingBranch/ConnectingBranch.d.ts +2 -1
  13. package/lib/components/ConnectingBranch/data.d.ts +19 -33
  14. package/lib/components/ConnectingBranch/types.d.ts +10 -0
  15. package/lib/components/Excel/ExcelFile/ExcelFileComponents/actions.d.ts +7 -1
  16. package/lib/components/FileDropzone/types.d.ts +12 -4
  17. package/lib/components/LabelEditTextField/types.d.ts +3 -1
  18. package/lib/components/MachineInputField/MachineInputField.d.ts +4 -1
  19. package/lib/components/ScriptSwitchButton/ScriptSwitchButton.d.ts +9 -0
  20. package/lib/components/ScriptSwitchButton/index.d.ts +1 -0
  21. package/lib/components/Select/types.d.ts +1 -1
  22. package/lib/components/StatusCard/types.d.ts +2 -0
  23. package/lib/components/TableTree/Components/TableCell.d.ts +1 -1
  24. package/lib/components/TableTree/Components/TableRow.d.ts +1 -1
  25. package/lib/components/TableTree/data.d.ts +115 -1
  26. package/lib/components/TableTree/types.d.ts +4 -0
  27. package/lib/components/TextArea/Textarea.d.ts +1 -1
  28. package/lib/components/TextArea/Types.d.ts +1 -0
  29. package/lib/components/ThemeProvider/types.d.ts +1 -1
  30. package/lib/index.d.ts +250 -75
  31. package/lib/index.esm.js +863 -489
  32. package/lib/index.esm.js.map +1 -1
  33. package/lib/index.js +909 -488
  34. package/lib/index.js.map +1 -1
  35. package/lib/tsconfig.tsbuildinfo +1 -1
  36. package/lib/utils/validateFile/validateFile.d.ts +2 -0
  37. package/lib/validations/regex.d.ts +46 -0
  38. package/package.json +2 -2
  39. package/src/StyleGuide/ColorPalette/colorPaletteList.ts +5 -0
  40. package/src/assets/Themes/BaseTheme.scss +2 -1
  41. package/src/assets/Themes/BlueTheme.scss +279 -0
  42. package/src/assets/Themes/DarkTheme.scss +2 -1
  43. package/src/assets/Themes/Theme.scss +5 -0
  44. package/src/assets/icons/failed_status_icon.svg +1 -1
  45. package/src/assets/icons/flaky_status_icon.svg +1 -1
  46. package/src/assets/icons/settings.svg +3 -0
  47. package/src/assets/icons/skipped_status_icon.svg +1 -1
  48. package/src/assets/icons/warning_status_icon.svg +1 -1
  49. package/src/components/Accordion/Accordion.stories.tsx +13 -0
  50. package/src/components/Accordion/Accordion.tsx +2 -1
  51. package/src/components/Accordion/types.ts +4 -0
  52. package/src/components/AllProjectsDropdown/types.ts +2 -0
  53. package/src/components/AppHeader/AppHeader.scss +6 -2
  54. package/src/components/AppHeader/AppHeader.tsx +4 -2
  55. package/src/components/Button/Button.scss +12 -0
  56. package/src/components/Button/Button.tsx +29 -11
  57. package/src/components/Button/types.ts +21 -0
  58. package/src/components/Charts/DashboardDonutChart/DashboardDonutChart.scss +83 -30
  59. package/src/components/Charts/DashboardDonutChart/DashboardDonutChart.stories.tsx +3 -0
  60. package/src/components/Charts/DashboardDonutChart/DashboardDonutChart.tsx +39 -16
  61. package/src/components/Charts/DashboardDonutChart/types.ts +2 -0
  62. package/src/components/Charts/MultiRadialChart/MultiRadialChart.scss +0 -1
  63. package/src/components/Charts/MultiRadialChart/MultiRadialChart.stories.tsx +2 -1
  64. package/src/components/Charts/MultiRadialChart/MultiRadialChart.tsx +18 -4
  65. package/src/components/Charts/MultiRadialChart/types.ts +4 -1
  66. package/src/components/ChooseFile/ChooseFile.stories.tsx +190 -0
  67. package/src/components/ChooseFile/ChooseFile.tsx +46 -0
  68. package/src/components/ChooseFile/types.ts +78 -0
  69. package/src/components/ConditionalDropdown/ConditionalDropdown.stories.tsx +8 -5
  70. package/src/components/ConditionalDropdown/ConditionalDropdown.tsx +133 -135
  71. package/src/components/ConditionalDropdown/types.ts +8 -8
  72. package/src/components/ConnectingBranch/BranchComponents/MachineInstances.tsx +94 -79
  73. package/src/components/ConnectingBranch/ConnectingBranch.scss +183 -195
  74. package/src/components/ConnectingBranch/ConnectingBranch.stories.tsx +33 -1
  75. package/src/components/ConnectingBranch/ConnectingBranch.tsx +121 -107
  76. package/src/components/ConnectingBranch/{data.ts → data.tsx} +106 -17
  77. package/src/components/ConnectingBranch/types.ts +21 -0
  78. package/src/components/DatePicker/DatePicker.scss +310 -0
  79. package/src/components/Excel/ExcelFile/ExcelFile.tsx +4 -4
  80. package/src/components/Excel/ExcelFile/ExcelFileComponents/ActiveCell.tsx +22 -10
  81. package/src/components/Excel/ExcelFile/ExcelFileComponents/ColumnIndicator.tsx +2 -2
  82. package/src/components/Excel/ExcelFile/ExcelFileComponents/DataEditor.tsx +4 -1
  83. package/src/components/Excel/ExcelFile/ExcelFileComponents/FloatingRect.tsx +6 -1
  84. package/src/components/Excel/ExcelFile/ExcelFileComponents/RowIndicator.tsx +2 -2
  85. package/src/components/Excel/ExcelFile/ExcelFileComponents/Spreadsheet.scss +30 -11
  86. package/src/components/Excel/ExcelFile/ExcelFileComponents/Spreadsheet.tsx +65 -19
  87. package/src/components/Excel/ExcelFile/ExcelFileComponents/actions.ts +14 -0
  88. package/src/components/Excel/ExcelFile/ExcelFileComponents/reducer.ts +16 -0
  89. package/src/components/Excel/ExcelFile/ExcelFileComponents/reducerFunctions.ts +77 -10
  90. package/src/components/Excel/ExcelToolBar/ExcelToolBar.tsx +6 -5
  91. package/src/components/FileDropzone/Dropzone.tsx +3 -0
  92. package/src/components/FileDropzone/FileDropzone.scss +18 -0
  93. package/src/components/FileDropzone/FileDropzone.stories.tsx +75 -7
  94. package/src/components/FileDropzone/FileDropzone.tsx +2 -0
  95. package/src/components/FileDropzone/RadioFilePreview.tsx +7 -3
  96. package/src/components/FileDropzone/types.ts +13 -4
  97. package/src/components/Icon/iconList.ts +4 -2
  98. package/src/components/InputWithDropdown/InputWithDropdown.tsx +1 -1
  99. package/src/components/LabelEditTextField/LabelEditTextField.scss +4 -0
  100. package/src/components/LabelEditTextField/LabelEditTextField.stories.tsx +8 -3
  101. package/src/components/LabelEditTextField/LabelEditTextField.tsx +42 -18
  102. package/src/components/LabelEditTextField/types.ts +3 -1
  103. package/src/components/MachineInputField/MachineInputField.tsx +67 -70
  104. package/src/components/NLPInput/components/NlpDropDown/NlpDropdown.scss +1 -1
  105. package/src/components/ScriptSwitchButton/ScriptSwitchButton.scss +33 -0
  106. package/src/components/ScriptSwitchButton/ScriptSwitchButton.stories.tsx +48 -0
  107. package/src/components/ScriptSwitchButton/ScriptSwitchButton.tsx +65 -0
  108. package/src/components/ScriptSwitchButton/index.ts +1 -0
  109. package/src/components/Search/Search.tsx +3 -1
  110. package/src/components/Select/Select.tsx +4 -4
  111. package/src/components/Select/types.ts +1 -1
  112. package/src/components/SequentialConnectingBranch/components/Branches/Branches.scss +1 -0
  113. package/src/components/SequentialConnectingBranch/components/Branches/Branches.tsx +2 -8
  114. package/src/components/StatusCard/StatusCard.scss +2 -1
  115. package/src/components/StatusCard/StatusCard.stories.tsx +59 -1
  116. package/src/components/StatusCard/StatusCard.tsx +10 -2
  117. package/src/components/StatusCard/types.ts +2 -0
  118. package/src/components/TableTree/Components/TableBody.tsx +20 -16
  119. package/src/components/TableTree/Components/TableCell.tsx +47 -31
  120. package/src/components/TableTree/Components/TableRow.tsx +4 -0
  121. package/src/components/TableTree/TableTree.scss +121 -109
  122. package/src/components/TableTree/data.ts +48 -2
  123. package/src/components/TableTree/types.ts +4 -0
  124. package/src/components/TextArea/Textarea.tsx +2 -0
  125. package/src/components/TextArea/Types.ts +3 -0
  126. package/src/components/ThemeProvider/types.ts +1 -1
  127. package/src/index.ts +97 -0
  128. package/src/utils/validateFile/validateFile.stories.tsx +49 -0
  129. package/src/utils/validateFile/validateFile.ts +39 -0
  130. package/src/validations/regex.stories.tsx +362 -0
  131. package/src/validations/regex.ts +194 -0
  132. package/src/components/SequentialConnectingBranch/components/AddBrowserModal/AddBrowserModal.scss +0 -51
  133. package/src/components/SequentialConnectingBranch/components/AddBrowserModal/AddBrowserModal.tsx +0 -107
  134. package/src/components/SequentialConnectingBranch/components/AddBrowserModal/types.ts +0 -5
  135. package/src/components/SequentialConnectingBranch/components/DatasetListModal/DatasetListModal.scss +0 -31
  136. package/src/components/SequentialConnectingBranch/components/DatasetListModal/DatasetListModal.tsx +0 -85
  137. package/src/components/SequentialConnectingBranch/components/DatasetListModal/types.ts +0 -4
  138. /package/src/assets/icons/{impactList.svg → impact_list.svg} +0 -0
@@ -0,0 +1,194 @@
1
+ // Validation Regex Collection
2
+
3
+ // Email Validation
4
+ const EMAIL_REGEX = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
5
+
6
+ // URL Validation
7
+ const URL_REGEX = /^(https?:\/\/)?([\da-z.-]+)\.([a-z.]{2,6})([\/\w.-]*)*\/?$/;
8
+
9
+ // Phone Number Validation
10
+ const PHONE_REGEX = /^\+?[\d\s\-()]{7,15}$/;
11
+
12
+ // Postal Code Validation (Generic)
13
+ const POSTAL_CODE_REGEX = /^[A-Za-z\d\s\-]{3,10}$/;
14
+
15
+ // IPv4 Address Validation
16
+ const IPV4_REGEX =
17
+ /^((25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$/;
18
+
19
+ // IPv6 Address Validation
20
+ const IPV6_REGEX = /^(?:[a-fA-F0-9]{1,4}:){7}[a-fA-F0-9]{1,4}$/;
21
+
22
+ // Hexadecimal Color Code Validation
23
+ const HEX_COLOR_REGEX = /^#([A-Fa-f0-9]{3}|[A-Fa-f0-9]{6})$/;
24
+
25
+ // Password Validation (At least 8 chars, one letter, one number)
26
+ const PASSWORD_SIMPLE_REGEX = /^(?=.*[A-Za-z])(?=.*\d)[A-Za-z\d]{8,}$/;
27
+
28
+ // Password Validation (At least 8 chars, one uppercase, one lowercase, one number, one special character)
29
+ const PASSWORD_COMPLEX_REGEX =
30
+ /^(?=.*[a-z])(?=.*[A-Z])(?=.*\d)(?=.*[@$!%*?&])[A-Za-z\d@$!%*?&]{8,}$/;
31
+
32
+ // Only Alphabets Validation
33
+ const ALPHABET_ONLY_REGEX = /^[A-Za-z]+$/;
34
+
35
+ // Only Numbers Validation
36
+ const NUMBERS_ONLY_REGEX = /^\d+$/;
37
+
38
+ // Alphanumeric Validation
39
+ const ALPHANUMERIC_REGEX = /^[A-Za-z0-9]+$/;
40
+
41
+ // Date Validation (YYYY-MM-DD)
42
+ const DATE_REGEX = /^\d{4}-\d{2}-\d{2}$/;
43
+
44
+ // Time Validation (HH:MM:SS)
45
+ const TIME_REGEX = /^\d{2}:\d{2}:\d{2}$/;
46
+
47
+ // File Extension Validation (e.g., .jpg, .png, .gif, .bmp)
48
+ const FILE_EXTENSION_REGEX = /\.(jpg|png|gif|bmp)$/i;
49
+
50
+ // MAC Address Validation
51
+ const MAC_ADDRESS_REGEX = /^([0-9A-Fa-f]{2}[:-]){5}([0-9A-Fa-f]{2})$/;
52
+
53
+ // Credit Card Number Validation (Basic)
54
+ const CREDIT_CARD_REGEX = /^\d{4}-?\d{4}-?\d{4}-?\d{4}$/;
55
+
56
+ // Social Security Number (SSN) Validation (US Format)
57
+ const SSN_REGEX = /^\d{3}-\d{2}-\d{4}$/;
58
+
59
+ // UUID Validation
60
+ const UUID_REGEX =
61
+ /^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i;
62
+
63
+ // HTML Tags Validation
64
+ const HTML_TAG_REGEX = /<\/?[\w\s=\"'\/\.:;#-]*>/g;
65
+
66
+ // Whitespace Validation (Leading or Trailing)
67
+ const WHITESPACE_REGEX = /^\s+|\s+$/g;
68
+
69
+ // US ZIP Code Validation (5 or 9 digits)
70
+ const US_ZIP_CODE_REGEX = /^\d{5}(-\d{4})?$/;
71
+
72
+ // Username Validation (Alphanumeric, underscores, 3-16 characters)
73
+ const USERNAME_REGEX = /^[a-zA-Z0-9_]{3,16}$/;
74
+
75
+ // Indian Specific Validations
76
+
77
+ // Indian Phone Number Validation
78
+ const INDIAN_PHONE_REGEX = /^[6-9]\d{9}$/;
79
+
80
+ // Indian PIN Code Validation
81
+ const INDIAN_PIN_CODE_REGEX = /^\d{6}$/;
82
+
83
+ // GSTIN Validation
84
+ const GSTIN_REGEX = /^\d{2}[A-Z]{5}\d{4}[A-Z]{1}[A-Z\d]{1}[Z]{1}[A-Z\d]{1}$/;
85
+
86
+ // PAN Card Validation
87
+ const PAN_CARD_REGEX = /^[A-Z]{5}\d{4}[A-Z]{1}$/;
88
+
89
+ // Aadhaar Number Validation
90
+ const AADHAAR_REGEX = /^\d{12}$/;
91
+
92
+ // Vehicle Registration Validation
93
+ const VEHICLE_REGISTRATION_REGEX = /^[A-Z]{2}\d{2}[A-Z]{0,2}\d{4}$/;
94
+
95
+ // Indian Currency Format Validation
96
+ const INDIAN_CURRENCY_REGEX = /^\u20B9?\s?\d{1,3}(,\d{3})*(\.\d{1,2})?$/;
97
+
98
+ // Additional Generic and Specific Validations
99
+
100
+ // International Phone Number Validation
101
+ const INTERNATIONAL_PHONE_REGEX = /^\+?[1-9]\d{1,14}$/;
102
+
103
+ // Passport Number Validation (India)
104
+ const INDIAN_PASSPORT_REGEX = /^[A-Z]{1}-?\d{7}$/;
105
+
106
+ // Driving License Validation (India)
107
+ const DRIVING_LICENSE_REGEX = /^[A-Z]{2}-\d{2}-\d{4}-\d{7}$/;
108
+
109
+ // Username with Special Characters
110
+ const USERNAME_SPECIAL_REGEX = /^[a-zA-Z0-9._-]{3,16}$/;
111
+
112
+ // Decimal Number Validation
113
+ const DECIMAL_NUMBER_REGEX = /^-?\d+(\.\d+)?$/;
114
+
115
+ // HTML Attributes Validation
116
+ const HTML_ATTRIBUTE_REGEX = /\b[a-zA-Z-]+(="[^"]*"|='[^']*'|=[^\s>]*)?/g;
117
+
118
+ // RGB Color Code Validation
119
+ const RGB_COLOR_REGEX = /^rgb\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/;
120
+
121
+ // HSL Color Code Validation
122
+ const HSL_COLOR_REGEX = /^hsl\((\d{1,3}),\s*(\d{1,3})%,\s*(\d{1,3})%\)$/;
123
+
124
+ // Base64 String Validation
125
+ const BASE64_REGEX =
126
+ /^(?:[A-Za-z0-9+\/]{4})*(?:[A-Za-z0-9+\/]{2}==|[A-Za-z0-9+\/]{3}=)?$/;
127
+
128
+ // Binary Number Validation
129
+ const BINARY_NUMBER_REGEX = /^[01]+$/;
130
+
131
+ // Hexadecimal Number Validation
132
+ const HEXADECIMAL_NUMBER_REGEX = /^[0-9A-Fa-f]+$/;
133
+
134
+ // Roman Numerals Validation
135
+ const ROMAN_NUMERALS_REGEX =
136
+ /^(?=[MDCLXVI])M*(C[MD]|D?C{0,3})(X[CL]|L?X{0,3})(I[XV]|V?I{0,3})$/;
137
+
138
+ // Currency Validation (Generic)
139
+ const CURRENCY_GENERIC_REGEX = /^[\u0024-\u20B9]?\d+(,\d{3})*(\.\d{1,2})?$/;
140
+
141
+ // LinkedIn Profile URL Validation
142
+ const LINKEDIN_PROFILE_REGEX =
143
+ /^https?:\/\/(www\.)?linkedin\.com\/in\/([a-zA-Z0-9-]{5,30})$/;
144
+
145
+ // Twitter Handle Validation
146
+ const TWITTER_HANDLE_REGEX = /^@?([a-zA-Z0-9_]{1,15})$/;
147
+
148
+ export {
149
+ EMAIL_REGEX,
150
+ URL_REGEX,
151
+ PHONE_REGEX,
152
+ POSTAL_CODE_REGEX,
153
+ IPV4_REGEX,
154
+ IPV6_REGEX,
155
+ HEX_COLOR_REGEX,
156
+ PASSWORD_SIMPLE_REGEX,
157
+ PASSWORD_COMPLEX_REGEX,
158
+ ALPHABET_ONLY_REGEX,
159
+ NUMBERS_ONLY_REGEX,
160
+ ALPHANUMERIC_REGEX,
161
+ DATE_REGEX,
162
+ TIME_REGEX,
163
+ FILE_EXTENSION_REGEX,
164
+ MAC_ADDRESS_REGEX,
165
+ CREDIT_CARD_REGEX,
166
+ SSN_REGEX,
167
+ UUID_REGEX,
168
+ HTML_TAG_REGEX,
169
+ WHITESPACE_REGEX,
170
+ US_ZIP_CODE_REGEX,
171
+ USERNAME_REGEX,
172
+ INDIAN_PHONE_REGEX,
173
+ INDIAN_PIN_CODE_REGEX,
174
+ GSTIN_REGEX,
175
+ PAN_CARD_REGEX,
176
+ AADHAAR_REGEX,
177
+ VEHICLE_REGISTRATION_REGEX,
178
+ INDIAN_CURRENCY_REGEX,
179
+ INTERNATIONAL_PHONE_REGEX,
180
+ INDIAN_PASSPORT_REGEX,
181
+ DRIVING_LICENSE_REGEX,
182
+ USERNAME_SPECIAL_REGEX,
183
+ DECIMAL_NUMBER_REGEX,
184
+ HTML_ATTRIBUTE_REGEX,
185
+ RGB_COLOR_REGEX,
186
+ HSL_COLOR_REGEX,
187
+ BASE64_REGEX,
188
+ BINARY_NUMBER_REGEX,
189
+ HEXADECIMAL_NUMBER_REGEX,
190
+ ROMAN_NUMERALS_REGEX,
191
+ CURRENCY_GENERIC_REGEX,
192
+ LINKEDIN_PROFILE_REGEX,
193
+ TWITTER_HANDLE_REGEX,
194
+ };
@@ -1,51 +0,0 @@
1
- .ff-connecting-datalist-modal-header-wrapper,
2
- .ff-connecting-modal-child-wrapper {
3
- width: 534px;
4
- padding: 0 4px;
5
- }
6
-
7
- .ff-connecting-datalist-modal-header-wrapper {
8
- border-bottom: 1px solid var(--ff-connecting-branch-modal-border);
9
- margin-bottom: 4px;
10
- }
11
-
12
- .ff-connecting-modal-child-wrapper {
13
- .ff-branch-select-input-wrapper {
14
- display: flex;
15
- align-items: center;
16
- gap: 8px;
17
-
18
- .ff-select-browser {
19
- width: 263px;
20
- }
21
-
22
- .ff-branch-input-wrapper {
23
- display: flex;
24
- align-items: flex-end;
25
- height: 38px;
26
-
27
- .ff-input-browser {
28
- width: 245px;
29
- }
30
- }
31
- }
32
- }
33
-
34
- .ff-connecting-modal-footer-wrapper {
35
- display: flex;
36
- align-items: center;
37
- justify-content: space-between;
38
- padding: 0 8px;
39
- margin-top: 8px;
40
- border-top: 1px solid var(--ff-connecting-branch-modal-border);
41
-
42
- .ff-branch-toggle-wrapper,
43
- .ff-datalist-button-wrapper {
44
- display: flex;
45
- gap: 8px;
46
- }
47
-
48
- .ff-branch-toggle-wrapper {
49
- gap: 4px;
50
- }
51
- }
@@ -1,107 +0,0 @@
1
- import { forwardRef, RefObject } from 'react';
2
- import MiniModal from '../../../MiniModal';
3
- import Typography from '../../../Typography';
4
- import './AddBrowserModal.scss';
5
- import Select from '../../../Select';
6
- import Button from '../../../Button';
7
- import Toggle from '../../../Toggle';
8
- import Input from '../../../Input/Input';
9
- import { AddBrowserModalProps } from './types';
10
-
11
- const AddBrowserModal = forwardRef<HTMLButtonElement, AddBrowserModalProps>(
12
- (props, ref) => {
13
- // TODO: WILL BE REMOVE IN THE FUTURE
14
- const selectOptions = [
15
- { label: 'Execution Environment', inputName: 'number of runs' },
16
- { label: 'Browser', inputName: 'Browser Version' },
17
- { label: 'Android Device', inputName: 'os version' },
18
- { label: 'IOS Device', inputName: 'os version-1' },
19
- ];
20
-
21
- const renderSelectOptions = () => (
22
- <div>
23
- {selectOptions.map(({ label, inputName }, index) => (
24
- <div className="ff-branch-select-input-wrapper" key={index}>
25
- <Select
26
- optionsList={[]}
27
- onChange={() => {}}
28
- label={label}
29
- className="ff-select-browser"
30
- />
31
- <div className="ff-branch-input-wrapper">
32
- <Input
33
- value="0"
34
- label="Number of Runs"
35
- type="number"
36
- onChange={() => {}}
37
- name={inputName}
38
- className="ff-input-browser"
39
- />
40
- </div>
41
- </div>
42
- ))}
43
- </div>
44
- );
45
-
46
- const renderFooterContent = () => (
47
- <div className="ff-connecting-modal-footer-wrapper">
48
- <div className="ff-branch-toggle-wrapper">
49
- <Typography as="span" lineHeight="32px">
50
- Run in Headless Mode
51
- </Typography>
52
- <Toggle />
53
- </div>
54
- <div className="ff-datalist-button-wrapper">
55
- <Button label="Cancel" variant="tertiary" />
56
- <Button label="Update" variant="primary" />
57
- </div>
58
- </div>
59
- );
60
-
61
- return (
62
- <div>
63
- <MiniModal
64
- anchorRef={ref as RefObject<HTMLButtonElement>}
65
- headerProps={
66
- <div className="ff-connecting-datalist-modal-header-wrapper">
67
- <Typography
68
- as="span"
69
- color="var(--ff-connecting-branch-modal-header)"
70
- fontWeight="semi-bold"
71
- fontSize={12}
72
- lineHeight="38px"
73
- >
74
- Add Browser / Device
75
- </Typography>
76
- </div>
77
- }
78
- childContent={
79
- <div className="ff-connecting-modal-child-wrapper">
80
- {renderSelectOptions()}
81
- </div>
82
- }
83
- footerContent={renderFooterContent()}
84
- cancelButtonProps={{
85
- text: 'Cancel',
86
-
87
- // TODO: DEMO PURPOSE AND WILL BE REMOVED IN THE FUTURE
88
- onClick: props.onUpdateAddBrowser,
89
- }}
90
- proceedButtonProps={{
91
- text: 'Proceed',
92
- // TODO: DEMO PURPOSE AND WILL BE REMOVED IN THE FUTURE
93
- onClick: props.onUpdateAddBrowser,
94
- }}
95
- modalPosition="right"
96
- isPopOver
97
- leftTopArrow
98
- extraRightSpace={{ leftTopArrow: 45 }}
99
- extraLeftSpace={{ rightAlignModal: 115 }}
100
- {...props}
101
- />
102
- </div>
103
- );
104
- }
105
- );
106
-
107
- export default AddBrowserModal;
@@ -1,5 +0,0 @@
1
- export interface AddBrowserModalProps {
2
-
3
- // TODO: DEMO PURPOSE AND WILL BE REMOVED IN THE FUTURE
4
- onUpdateAddBrowser: () => void;
5
- }
@@ -1,31 +0,0 @@
1
- .ff-datalist-modal-header-wrapper,
2
- .ff-datalist-modal-child-wrapper,
3
- .ff-datalist-modal-footer-wrapper {
4
- margin: 0 8px;
5
- }
6
-
7
- .ff-datalist-modal-header-wrapper {
8
- width: 255px;
9
- border-bottom: 1px solid var(--ff-connecting-branch-modal-border);
10
- display: flex;
11
- align-items: center;
12
- }
13
-
14
- .ff-datalist-modal-child-wrapper {
15
- .variable {
16
- margin: 8px 0;
17
- }
18
- }
19
-
20
- .ff-datalist-modal-footer-wrapper {
21
- display: flex;
22
- justify-content: space-between;
23
- border-top: 1px solid var(--ff-connecting-branch-modal-border);
24
-
25
- .datalist-button-wrapper {
26
- display: flex;
27
- gap: 10px;
28
- margin-top: 4px;
29
- justify-content: flex-end;
30
- }
31
- }
@@ -1,85 +0,0 @@
1
- import { forwardRef, RefObject } from 'react';
2
- import MiniModal from '../../../MiniModal';
3
- import Typography from '../../../Typography';
4
- import './DatasetListModal.scss';
5
- import Select from '../../../Select';
6
- import Checkbox from '../../../Checkbox';
7
- import Button from '../../../Button';
8
- import { DatasetListModalProps } from './types';
9
-
10
- const DatasetListModal = forwardRef<HTMLButtonElement, DatasetListModalProps>(
11
- (props, ref) => {
12
- const selectOptions = [
13
- { label: 'Project Environment Variable' },
14
- { label: 'Global Variables' },
15
- { label: 'Test Data Set' },
16
- ];
17
-
18
- const renderSelectOptions = () =>
19
- selectOptions.map(({ label }, idx) => (
20
- <Select
21
- key={idx}
22
- optionsList={[]}
23
- onChange={() => {}}
24
- label={label}
25
- className="variable"
26
- />
27
- ));
28
-
29
- const renderFooterContent = () => (
30
- <div className="ff-datalist-modal-footer-wrapper">
31
- <Checkbox checked={false} label="Set as Default" />
32
- <div className="datalist-button-wrapper">
33
- <Button label="Cancel" variant="tertiary" />
34
- <Button label="Update" variant="primary" />
35
- </div>
36
- </div>
37
- );
38
-
39
- return (
40
- <div>
41
- <MiniModal
42
- anchorRef={ref as RefObject<HTMLButtonElement>}
43
- headerProps={
44
- <div className="ff-datalist-modal-header-wrapper">
45
- <Typography
46
- as="span"
47
- color="var(--ff-connecting-branch-modal-header)"
48
- fontWeight="semi-bold"
49
- fontSize={12}
50
- lineHeight="38px"
51
- >
52
- Data Sets
53
- </Typography>
54
- </div>
55
- }
56
- childContent={
57
- <div className="ff-datalist-modal-child-wrapper">
58
- {renderSelectOptions()}
59
- </div>
60
- }
61
- footerContent={renderFooterContent()}
62
- cancelButtonProps={{
63
- text: 'Cancel',
64
-
65
- // TODO: DEMO PURPOSE AND WILL BE REMOVED IN THE FUTURE
66
- onClick: props?.onUpdateDatasetList,
67
- }}
68
- proceedButtonProps={{
69
- text: 'Proceed',
70
- // TODO: DEMO PURPOSE AND WILL BE REMOVED IN THE FUTURE
71
- onClick: props?.onUpdateDatasetList,
72
- }}
73
- modalPosition="right"
74
- isPopOver
75
- leftTopArrow
76
- extraRightSpace={{ leftTopArrow: 40 }}
77
- extraLeftSpace={{ rightAlignModal: 110 }}
78
- {...props}
79
- />
80
- </div>
81
- );
82
- }
83
- );
84
-
85
- export default DatasetListModal;
@@ -1,4 +0,0 @@
1
- export interface DatasetListModalProps {
2
- // TODO: DEMO PURPOSE AND WILL BE REMOVED IN THE FUTURE
3
- onUpdateDatasetList: () => void;
4
- }