From 812f60ec777e4fdff4338162ee35c8e534c71e24 Mon Sep 17 00:00:00 2001 From: Michael Shanks Date: Thu, 5 Mar 2020 14:55:34 +0000 Subject: [PATCH] prettier --- .../materialdesign-components/rollup.config.js | 4 +--- .../src/Templates/recordForm.js | 15 +++++++++------ .../materialdesign-components/src/Test/props.js | 2 +- 3 files changed, 11 insertions(+), 10 deletions(-) diff --git a/packages/materialdesign-components/rollup.config.js b/packages/materialdesign-components/rollup.config.js index 263ee81d66..a11693cbf0 100644 --- a/packages/materialdesign-components/rollup.config.js +++ b/packages/materialdesign-components/rollup.config.js @@ -17,9 +17,7 @@ const postcssOptions = () => ({ ], }) -const coreExternal = [ - "shortid", -] +const coreExternal = ["shortid"] export default { input: "src/index.js", diff --git a/packages/materialdesign-components/src/Templates/recordForm.js b/packages/materialdesign-components/src/Templates/recordForm.js index a7e404e76e..70354a5e4d 100644 --- a/packages/materialdesign-components/src/Templates/recordForm.js +++ b/packages/materialdesign-components/src/Templates/recordForm.js @@ -32,10 +32,13 @@ const heading = record => ({ const field = (record, f) => { if (f.type === "bool") return checkbox(record, f) - if (f.type === "string" - && f.typeOptions - && f.typeOptions.values - && f.typeOptions.values.length > 0) return select(record, f) + if ( + f.type === "string" && + f.typeOptions && + f.typeOptions.values && + f.typeOptions.values.length > 0 + ) + return select(record, f) return textField(record, f) } @@ -64,8 +67,8 @@ const select = (record, f) => ({ _children: f.typeOptions.values.map(val => ({ _component: "@budibase/materialdesign-components/ListItem", value: val, - text: val - })) + text: val, + })), }) const fieldValueBinding = (record, f) => `state.${record.name}.${f.name}` diff --git a/packages/materialdesign-components/src/Test/props.js b/packages/materialdesign-components/src/Test/props.js index aa55c680fb..6b857b8c5f 100644 --- a/packages/materialdesign-components/src/Test/props.js +++ b/packages/materialdesign-components/src/Test/props.js @@ -4,7 +4,7 @@ const templateOptions = { indexes: [ { name: "customers", - nodeKey: () => "/customers" + nodeKey: () => "/customers", }, ], helpers: {