mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Enforce semicolons in eslint
Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com>
This commit is contained in:
1 parent
0f3f5611ba
commit
1477bb8274
531 files changed
+3979
-3975
No files matched your search
@@ -1,5 +1,5 @@
|
||||
export * from './table'
|
||||
export * from './table-head'
|
||||
export * from './table-row'
|
||||
export * from './table-cell'
|
||||
export * from './table';
|
||||
export * from './table-head';
|
||||
export * from './table-row';
|
||||
export * from './table-cell';
|
||||
|
||||
@@ -46,14 +46,14 @@ export class TableCell extends React.Component<TableCellProps> {
|
||||
className={cssNames("sortIcon", { enabled: sortActive })}
|
||||
material={sortIconName}
|
||||
/>
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
renderCheckbox() {
|
||||
const { checkbox, isChecked } = this.props;
|
||||
const showCheckbox = isChecked !== undefined;
|
||||
if (checkbox && showCheckbox) {
|
||||
return <Checkbox value={isChecked} />
|
||||
return <Checkbox value={isChecked} />;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -64,13 +64,13 @@ export class TableCell extends React.Component<TableCellProps> {
|
||||
nowrap: _nowrap,
|
||||
sorting: this.isSortable,
|
||||
});
|
||||
const content = displayBooleans(displayBoolean, title || children)
|
||||
const content = displayBooleans(displayBoolean, title || children);
|
||||
return (
|
||||
<div {...cellProps} id={className} className={classNames} onClick={this.onClick}>
|
||||
{this.renderCheckbox()}
|
||||
{_nowrap ? <div className="content">{content}</div> : content}
|
||||
{this.renderSortIcon()}
|
||||
</div>
|
||||
)
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -27,6 +27,6 @@ export class TableHead extends React.Component<TableHeadProps> {
|
||||
<div className={classNames} {...headProps}>
|
||||
{children}
|
||||
</div>
|
||||
)
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -24,6 +24,6 @@ export class TableRow extends React.Component<TableRowProps> {
|
||||
<div className={classNames} {...rowProps}>
|
||||
{children}
|
||||
</div>
|
||||
)
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -9,7 +9,7 @@ import { TableHead, TableHeadElem, TableHeadProps } from "./table-head";
|
||||
import { TableCellElem } from "./table-cell";
|
||||
import { VirtualList } from "../virtual-list";
|
||||
import { navigation, setQueryParams } from "../../navigation";
|
||||
import orderBy from "lodash/orderBy"
|
||||
import orderBy from "lodash/orderBy";
|
||||
import { ItemObject } from "../../item.store";
|
||||
|
||||
// todo: refactor + decouple search from location
|
||||
@@ -57,8 +57,8 @@ export class Table extends React.Component<TableProps> {
|
||||
|
||||
@computed get sortParams(): Partial<TableSortParams> {
|
||||
if (this.props.sortSyncWithUrl) {
|
||||
const sortBy = navigation.searchParams.get("sortBy")
|
||||
const orderBy = navigation.searchParams.get("orderBy")
|
||||
const sortBy = navigation.searchParams.get("sortBy");
|
||||
const orderBy = navigation.searchParams.get("orderBy");
|
||||
return { sortBy, orderBy };
|
||||
}
|
||||
return this.sortParamsLocal || {};
|
||||
@@ -86,7 +86,7 @@ export class Table extends React.Component<TableProps> {
|
||||
_sort: this.sort,
|
||||
_sorting: this.sortParams,
|
||||
_nowrap: headElem.props.nowrap,
|
||||
})
|
||||
});
|
||||
})
|
||||
});
|
||||
}
|
||||
@@ -108,13 +108,13 @@ export class Table extends React.Component<TableProps> {
|
||||
protected onSort(params: TableSortParams) {
|
||||
const { sortSyncWithUrl, onSort } = this.props;
|
||||
if (sortSyncWithUrl) {
|
||||
setQueryParams(params)
|
||||
setQueryParams(params);
|
||||
}
|
||||
else {
|
||||
this.sortParamsLocal = params;
|
||||
}
|
||||
if (onSort) {
|
||||
onSort(params)
|
||||
onSort(params);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -139,8 +139,8 @@ export class Table extends React.Component<TableProps> {
|
||||
sortedItems = this.getSorted(sortedItems);
|
||||
if (rows.length) {
|
||||
rows = sortedItems.map(item => rows.find(row => {
|
||||
return item == row.props.sortItem
|
||||
}))
|
||||
return item == row.props.sortItem;
|
||||
}));
|
||||
}
|
||||
}
|
||||
if (!rows.length && !items.length && noItems) {
|
||||
@@ -179,6 +179,6 @@ export class Table extends React.Component<TableProps> {
|
||||
{this.renderHead()}
|
||||
{this.renderRows()}
|
||||
</div>
|
||||
)
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user