mirror of
https://github.com/ascribe/onion.git
synced 2024-12-22 09:23:13 +01:00
Update multiline destructuring format based on style guide
This commit is contained in:
parent
821fe79461
commit
e5cae3fc34
@ -45,8 +45,7 @@ let AccordionListItemPiece = React.createClass({
|
||||
},
|
||||
|
||||
render() {
|
||||
const {
|
||||
artistName,
|
||||
const { artistName,
|
||||
badge,
|
||||
buttons,
|
||||
children,
|
||||
|
@ -44,8 +44,7 @@ export default function ({ action, displayName, title, tooltip }) {
|
||||
},
|
||||
|
||||
render() {
|
||||
const {
|
||||
availableAcls,
|
||||
const { availableAcls,
|
||||
buttonAcceptClassName,
|
||||
currentUser,
|
||||
email,
|
||||
|
@ -32,8 +32,7 @@ const DetailProperty = React.createClass({
|
||||
},
|
||||
|
||||
render() {
|
||||
const {
|
||||
children,
|
||||
const { children,
|
||||
className,
|
||||
ellipsis,
|
||||
label,
|
||||
|
@ -51,8 +51,7 @@ let Edition = React.createClass({
|
||||
},
|
||||
|
||||
render() {
|
||||
const {
|
||||
actionPanelButtonListType,
|
||||
const { actionPanelButtonListType,
|
||||
coaError,
|
||||
currentUser,
|
||||
edition,
|
||||
|
@ -95,10 +95,9 @@ let EditionActionPanel = React.createClass({
|
||||
},
|
||||
|
||||
render() {
|
||||
const {
|
||||
actionPanelButtonListType: ActionPanelButtonListType,
|
||||
edition,
|
||||
currentUser } = this.props;
|
||||
const { actionPanelButtonListType: ActionPanelButtonListType,
|
||||
currentUser,
|
||||
edition } = this.props;
|
||||
|
||||
if (edition &&
|
||||
edition.notifications &&
|
||||
|
@ -53,8 +53,7 @@ let AclFormFactory = React.createClass({
|
||||
},
|
||||
|
||||
render() {
|
||||
const {
|
||||
action,
|
||||
const { action,
|
||||
autoFocusProperty,
|
||||
pieceOrEditions,
|
||||
currentUser,
|
||||
|
@ -62,8 +62,7 @@ let ConsignForm = React.createClass({
|
||||
|
||||
render() {
|
||||
const { email } = this.state;
|
||||
const {
|
||||
autoFocusProperty,
|
||||
const { autoFocusProperty,
|
||||
createPublicContractAgreement,
|
||||
email: defaultEmail,
|
||||
handleSuccess,
|
||||
|
@ -118,8 +118,7 @@ let LoanForm = React.createClass({
|
||||
|
||||
render() {
|
||||
const { email } = this.state;
|
||||
const {
|
||||
children,
|
||||
const { children,
|
||||
createPublicContractAgreement,
|
||||
email: defaultEmail,
|
||||
handleSuccess,
|
||||
|
@ -144,13 +144,11 @@ const InputContractAgreementCheckbox = React.createClass({
|
||||
const contractAgreement = this.getContractAgreement();
|
||||
|
||||
if (contractAgreement) {
|
||||
const {
|
||||
datetime_accepted: datetimeAccepted,
|
||||
contract: {
|
||||
const { contract: {
|
||||
issuer: contractIssuer,
|
||||
blob: { url_safe: contractUrl }
|
||||
}
|
||||
} = contractAgreement;
|
||||
},
|
||||
datetime_accepted: datetimeAccepted } = contractAgreement;
|
||||
|
||||
if (datetimeAccepted) {
|
||||
return (
|
||||
@ -168,10 +166,7 @@ const InputContractAgreementCheckbox = React.createClass({
|
||||
</div>
|
||||
);
|
||||
} else {
|
||||
const {
|
||||
name,
|
||||
disabled,
|
||||
style } = this.props;
|
||||
const { disabled, name, style } = this.props;
|
||||
|
||||
return (
|
||||
<InputCheckbox
|
||||
|
@ -98,8 +98,7 @@ const InputFineUploader = React.createClass({
|
||||
},
|
||||
|
||||
render() {
|
||||
const {
|
||||
areAssetsDownloadable,
|
||||
const { areAssetsDownloadable,
|
||||
enableLocalHashing,
|
||||
createBlobRoutine,
|
||||
disabled,
|
||||
|
@ -127,19 +127,18 @@ let FileDragAndDrop = React.createClass({
|
||||
},
|
||||
|
||||
render: function () {
|
||||
const {
|
||||
filesToUpload,
|
||||
dropzoneInactive,
|
||||
className,
|
||||
hashingProgress,
|
||||
handleCancelHashing,
|
||||
multiple,
|
||||
enableLocalHashing,
|
||||
uploadMethod,
|
||||
fileClassToUpload,
|
||||
const { allowedExtensions,
|
||||
areAssetsDownloadable,
|
||||
areAssetsEditable,
|
||||
allowedExtensions } = this.props;
|
||||
className,
|
||||
dropzoneInactive,
|
||||
enableLocalHashing,
|
||||
fileClassToUpload,
|
||||
filesToUpload,
|
||||
handleCancelHashing,
|
||||
hashingProgress,
|
||||
multiple,
|
||||
uploadMethod } = this.props;
|
||||
|
||||
// has files only is true if there are files that do not have the status deleted or canceled
|
||||
let hasFiles = filesToUpload.filter((file) => file.status !== 'deleted' && file.status !== 'canceled' && file.size !== -1).length > 0;
|
||||
|
@ -35,13 +35,12 @@ let FileDragAndDropDialog = React.createClass({
|
||||
},
|
||||
|
||||
render() {
|
||||
const {
|
||||
const { enableLocalHashing,
|
||||
fileClassToUpload,
|
||||
hasFiles,
|
||||
multipleFiles,
|
||||
enableLocalHashing,
|
||||
uploadMethod,
|
||||
fileClassToUpload,
|
||||
onClick } = this.props;
|
||||
onClick,
|
||||
uploadMethod } = this.props;
|
||||
|
||||
if (hasFiles) {
|
||||
return null;
|
||||
|
@ -145,9 +145,7 @@ export default function UploadButton({ className = 'btn btn-default btn-sm' } =
|
||||
},
|
||||
|
||||
render() {
|
||||
const {
|
||||
multiple,
|
||||
allowedExtensions } = this.props;
|
||||
const { allowedExtensions, multiple } = this.props;
|
||||
const { disabled } = this.state;
|
||||
|
||||
|
||||
|
@ -53,11 +53,10 @@ let GlobalNotification = React.createClass({
|
||||
},
|
||||
|
||||
renderNotification() {
|
||||
const {
|
||||
notificationQueue: [notification],
|
||||
notificationStatus,
|
||||
const { containerWidth,
|
||||
notificationsPaused,
|
||||
containerWidth } = this.state;
|
||||
notificationQueue: [notification],
|
||||
notificationStatus } = this.state;
|
||||
|
||||
const notificationClasses = [];
|
||||
|
||||
|
@ -259,8 +259,7 @@ let PieceList = React.createClass({
|
||||
},
|
||||
|
||||
render() {
|
||||
const {
|
||||
accordionListItemType: AccordionListItemType,
|
||||
const { accordionListItemType: AccordionListItemType,
|
||||
bulkModalButtonListType: BulkModalButtonListType,
|
||||
customSubmitButton,
|
||||
customThumbnailPlaceholder,
|
||||
|
@ -33,8 +33,7 @@ let WalletPieceContainer = React.createClass({
|
||||
},
|
||||
|
||||
render() {
|
||||
const {
|
||||
children,
|
||||
const { children,
|
||||
currentUser,
|
||||
handleDeleteSuccess,
|
||||
loadPiece,
|
||||
|
@ -53,8 +53,7 @@ let MarketSubmitButton = React.createClass({
|
||||
|
||||
canEditionBeSubmitted(edition) {
|
||||
if (edition && edition.extra_data && edition.other_data) {
|
||||
const {
|
||||
extra_data: {
|
||||
const { extra_data: {
|
||||
artist_bio: artistBio,
|
||||
display_instructions: displayInstructions,
|
||||
technology_details: technologyDetails,
|
||||
|
@ -107,8 +107,7 @@ let MarketAdditionalDataForm = React.createClass({
|
||||
},
|
||||
|
||||
render() {
|
||||
const {
|
||||
editable,
|
||||
const { editable,
|
||||
extraData = {},
|
||||
isInline,
|
||||
handleSuccess,
|
||||
|
@ -51,8 +51,7 @@ let MarketPieceList = React.createClass({
|
||||
|
||||
render() {
|
||||
const { customThumbnailPlaceholder, location } = this.props;
|
||||
const {
|
||||
currentUser: { email: userEmail },
|
||||
const { currentUser: { email: userEmail },
|
||||
whitelabel: {
|
||||
name: whitelabelName = 'Market',
|
||||
user: whitelabelAdminEmail
|
||||
|
@ -112,8 +112,7 @@ let MarketRegisterPiece = React.createClass({
|
||||
|
||||
render() {
|
||||
const { location } = this.props;
|
||||
const {
|
||||
piece,
|
||||
const { piece,
|
||||
step,
|
||||
whitelabel: {
|
||||
name: whitelabelName = 'Market'
|
||||
|
Loading…
Reference in New Issue
Block a user