refactor: sqleditorleftbar to typescript (#17926)

* Creating draft PR to address bug

* Still working on solving re rendering bug

* Cleaning up in preparation for push

* Starting conversion to TypeScript

* Working on conversion

* Continued working on typescript conversion, referenced other files for different types, still a rough version of final product

* Added type assertion to actions in props, and added types to some component functions

* Progress on typescript conversion

* Fixed typing issue on collapseStyles

* Fixed styling on div, child of StyledScrollbarContainer

* Attempting to address issues with the actions passed into the TableElement

* Resolved typescript warning on actions of the TableElement component

* Made changes suggested by Arash

* Tested the component without dbId, cleaned up lingering comments

* Made more changes suggested by Arash, removed offline from the SqlEditorLeftBarProps interface

* Made change suggested by Hugh

* Changed the expanded type from any to boolean
This commit is contained in:
Josue Lugaro
2022-01-28 14:07:32 -06:00
committed by GitHub
parent 2dfcbdb08c
commit a06e043d7f
2 changed files with 54 additions and 45 deletions

View File

@@ -37,7 +37,7 @@ interface Column {
type: string;
}
interface Table {
export interface Table {
id: string;
name: string;
partitions?: {
@@ -53,7 +53,7 @@ interface Table {
columns: Column[];
}
interface TableElementProps {
export interface TableElementProps {
table: Table;
actions: {
removeDataPreview: (table: Table) => void;