Add eslint rule padding-line-between-statements (#1593)

Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com>
This commit is contained in:
Panu Horsmalahti authored and GitHub committed 2020-12-02 09:55:52 +02:00
1 parent 7b77f18376
commit dcf253e7d5
401 files changed
+2018 -40

No files matched your search

@@ -72,6 +72,7 @@ export class AddQuotaDialog extends React.Component<Props> {
const isStorage = quota.endsWith(".storage") || quota === "persistentvolumeclaims";
const isCount = quota.startsWith("count/");
const icon = isCompute ? "memory" : isStorage ? "storage" : isCount ? "looks_one" : "";
return {
label: icon ? <span className="nobr"><Icon material={icon} /> {quota}</span> : quota,
value: quota,
@@ -102,8 +103,10 @@ export class AddQuotaDialog extends React.Component<Props> {
const { quotaName, namespace } = this;
const quotas = this.quotaEntries.reduce<IResourceQuotaValues>((quotas, [name, value]) => {
quotas[name] = value;
return quotas;
}, {});
await resourceQuotaApi.create({ namespace, name: quotaName }, {
spec: {
hard: quotas
@@ -127,6 +130,7 @@ export class AddQuotaDialog extends React.Component<Props> {
render() {
const { ...dialogProps } = this.props;
const header = <h5><Trans>Create ResourceQuota</Trans></h5>;
return (
<Dialog
{...dialogProps}
@@ -58,7 +58,9 @@ function renderQuotas(quota: ResourceQuota): JSX.Element[] {
export class ResourceQuotaDetails extends React.Component<Props> {
render() {
const { object: quota } = this.props;
if (!quota) return null;
return (
<div className="ResourceQuotaDetails">
<KubeObjectMeta object={quota}/>
@@ -79,6 +81,7 @@ export class ResourceQuotaDetails extends React.Component<Props> {
{
quota.getScopeSelector().map((selector, index) => {
const { operator, scopeName, values } = selector;
return (
<TableRow key={index}>
<TableCell>{operator}</TableCell>