mirror of
https://github.com/filecoin-project/slate.git
synced 2025-01-09 02:47:35 +03:00
fixed namings
This commit is contained in:
parent
374866e9af
commit
b15dd5c5f8
@ -101,7 +101,7 @@ export const hydrate = async () => {
|
||||
return JSON.parse(JSON.stringify(response.data));
|
||||
};
|
||||
|
||||
export const fromatPastedImages = ({ clipboardItems }) => {
|
||||
export const formatPastedImages = ({ clipboardItems }) => {
|
||||
let files = [];
|
||||
let fileLoading = {};
|
||||
for (let i = 0; i < clipboardItems.length; i++) {
|
||||
|
@ -122,7 +122,7 @@ export default class ApplicationPage extends React.Component {
|
||||
window.addEventListener("online", this._handleOnlineStatus);
|
||||
window.addEventListener("offline", this._handleOnlineStatus);
|
||||
window.addEventListener("resize", this._handleWindowResize);
|
||||
window.addEventListener("paste", this._handleUploadingFromClipboard);
|
||||
window.addEventListener("paste", this._handleUploadFromClipboard);
|
||||
window.onpopstate = this._handleBackForward;
|
||||
|
||||
if (this.state.viewer) {
|
||||
@ -140,7 +140,7 @@ export default class ApplicationPage extends React.Component {
|
||||
window.removeEventListener("online", this._handleOnlineStatus);
|
||||
window.removeEventListener("offline", this._handleOnlineStatus);
|
||||
window.removeEventListener("resize", this._handleWindowResize);
|
||||
window.removeEventListener("paste", this._handleUploadingFromClipboard);
|
||||
window.removeEventListener("paste", this._handleUploadFromClipboard);
|
||||
|
||||
mounted = false;
|
||||
|
||||
@ -150,11 +150,11 @@ export default class ApplicationPage extends React.Component {
|
||||
}
|
||||
}
|
||||
|
||||
_handleUploadingFromClipboard = (e) => {
|
||||
_handleUploadFromClipboard = (e) => {
|
||||
const clipboardItems = e.clipboardData.items || [];
|
||||
if (!clipboardItems) return;
|
||||
|
||||
const { fileLoading, toUpload } = UserBehaviors.fromatPastedImages({
|
||||
const { fileLoading, toUpload } = UserBehaviors.formatPastedImages({
|
||||
clipboardItems,
|
||||
});
|
||||
|
||||
|
@ -510,7 +510,7 @@ export default class DataView extends React.Component {
|
||||
style={{ marginLeft: 8, color: Constants.system.white }}
|
||||
onClick={() => this._handleDelete()}
|
||||
>
|
||||
Delete file{numChecked > 1 ? "s" : ""}
|
||||
{Strings.pluralize("Delete file", numChecked)}
|
||||
</ButtonWarning>
|
||||
<div
|
||||
css={STYLES_ICON_BOX}
|
||||
|
@ -1770,7 +1770,7 @@ export class SlateLayout extends React.Component {
|
||||
style={{ marginLeft: 8, color: Constants.system.white }}
|
||||
onClick={this._handleDeleteFiles}
|
||||
>
|
||||
Delete file{numChecked > 1 ? "s" : ""}
|
||||
{Strings.pluralize("Delete file", numChecked)}
|
||||
</ButtonWarning>
|
||||
<div css={STYLES_ICON_BOX} onClick={() => this.setState({ checked: {} })}>
|
||||
<SVG.Dismiss height="20px" style={{ color: Constants.system.darkGray }} />
|
||||
|
Loading…
Reference in New Issue
Block a user