-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2506945
commit 0c5bafd
Showing
5 changed files
with
185 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
41 changes: 41 additions & 0 deletions
41
src/dashboard/Data/Browser/ExportSelectedRowsDialog.react.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
/* | ||
* Copyright (c) 2016-present, Parse, LLC | ||
* All rights reserved. | ||
* | ||
* This source code is licensed under the license found in the LICENSE file in | ||
* the root directory of this source tree. | ||
*/ | ||
import Modal from 'components/Modal/Modal.react'; | ||
import React from 'react'; | ||
|
||
export default class ExportSelectedRowsDialog extends React.Component { | ||
constructor() { | ||
super(); | ||
|
||
this.state = { | ||
confirmation: '' | ||
}; | ||
} | ||
|
||
valid() { | ||
return true; | ||
} | ||
|
||
render() { | ||
let selectionLength = Object.keys(this.props.selection).length; | ||
return ( | ||
<Modal | ||
type={Modal.Types.INFO} | ||
icon='warn-outline' | ||
title={this.props.selection['*'] ? 'Export all rows?' : (selectionLength === 1 ? `Export 1 selected row?` : `Export ${selectionLength} selected rows?`)} | ||
subtitle={this.props.selection['*'] ? 'Note: Exporting is limited to the first 10,000 rows.' : ''} | ||
disabled={!this.valid()} | ||
confirmText={'Yes export'} | ||
cancelText={'Never mind, don\u2019t.'} | ||
onCancel={this.props.onCancel} | ||
onConfirm={this.props.onConfirm}> | ||
{} | ||
</Modal> | ||
); | ||
} | ||
} |