|
9 | 9 | } from "@3rdweb-sdk/react/hooks/useEngine"; |
10 | 10 | import { useResolveContractAbi } from "@3rdweb-sdk/react/hooks/useResolveContractAbi"; |
11 | 11 | import { |
12 | | - CheckboxGroup, |
13 | 12 | Collapse, |
14 | 13 | Flex, |
15 | 14 | FormControl, |
@@ -324,21 +323,22 @@ const ModalBodyInputData = ({ |
324 | 323 | <FormLabel>Processed Data</FormLabel> |
325 | 324 |
|
326 | 325 | <div className="flex flex-col gap-2"> |
327 | | - <Checkbox |
328 | | - {...form.register("processEventLogs")} |
329 | | - checked={form.getValues("processEventLogs")} |
330 | | - onCheckedChange={(val) => { |
331 | | - const checked = !!val; |
332 | | - form.setValue("processEventLogs", checked); |
333 | | - if (checked) { |
334 | | - processEventLogsDisclosure.onOpen(); |
335 | | - } else { |
336 | | - processEventLogsDisclosure.onClose(); |
337 | | - } |
338 | | - }} |
339 | | - > |
340 | | - <Text>Event Logs</Text> |
341 | | - </Checkbox> |
| 326 | + <CheckboxWithLabel> |
| 327 | + <Checkbox |
| 328 | + {...form.register("processEventLogs")} |
| 329 | + checked={form.getValues("processEventLogs")} |
| 330 | + onCheckedChange={(val) => { |
| 331 | + const checked = !!val; |
| 332 | + form.setValue("processEventLogs", checked); |
| 333 | + if (checked) { |
| 334 | + processEventLogsDisclosure.onOpen(); |
| 335 | + } else { |
| 336 | + processEventLogsDisclosure.onClose(); |
| 337 | + } |
| 338 | + }} |
| 339 | + /> |
| 340 | + <span>Event Logs</span> |
| 341 | + </CheckboxWithLabel> |
342 | 342 | {/* Shows all/specific events if processing event logs */} |
343 | 343 | <Collapse in={processEventLogsDisclosure.isOpen}> |
344 | 344 | <div className="flex flex-col gap-2 px-4"> |
@@ -394,7 +394,7 @@ const ModalBodyInputData = ({ |
394 | 394 | } |
395 | 395 | }} |
396 | 396 | /> |
397 | | - <Text>Transaction Receipts</Text> |
| 397 | + <span>Transaction Receipts</span> |
398 | 398 | </CheckboxWithLabel> |
399 | 399 | {/* Shows all/specific functions if processing transaction receipts */} |
400 | 400 | <Collapse in={processTransactionReceiptsDisclosure.isOpen}> |
@@ -546,16 +546,21 @@ const FilterSelector = ({ |
546 | 546 | </Text> |
547 | 547 | ) : ( |
548 | 548 | <div className="flex max-h-[300px] flex-col gap-2 overflow-y-auto"> |
549 | | - <CheckboxGroup |
550 | | - value={filter} |
551 | | - onChange={(selected: string[]) => setFilter(selected)} |
552 | | - > |
553 | | - {filterNames.map((name) => ( |
554 | | - <Checkbox key={name} value={name}> |
555 | | - <Text>{name}</Text> |
556 | | - </Checkbox> |
557 | | - ))} |
558 | | - </CheckboxGroup> |
| 549 | + {filterNames.map((name) => ( |
| 550 | + <CheckboxWithLabel key={name}> |
| 551 | + <Checkbox |
| 552 | + value={name} |
| 553 | + onCheckedChange={(val) => { |
| 554 | + if (val) { |
| 555 | + setFilter([...filter, name]); |
| 556 | + } else { |
| 557 | + setFilter(filter.filter((item) => item !== name)); |
| 558 | + } |
| 559 | + }} |
| 560 | + /> |
| 561 | + <span>{name}</span> |
| 562 | + </CheckboxWithLabel> |
| 563 | + ))} |
559 | 564 | </div> |
560 | 565 | )} |
561 | 566 | </Card> |
|
0 commit comments