mirror of
https://github.com/usatiuk/writer.git
synced 2025-10-28 16:07:49 +01:00
prettier fixes
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
import * as React from "react";
|
||||
|
||||
import { shallow } from "enzyme";
|
||||
import { AccountComponent } from "../Account";
|
||||
|
||||
describe("<Account />", () => {
|
||||
it("should say hello", () => {
|
||||
const wrapper = shallow(<AccountComponent />);
|
||||
|
||||
expect(wrapper.text()).toBe("Hello");
|
||||
});
|
||||
});
|
||||
import * as React from "react";
|
||||
|
||||
import { shallow } from "enzyme";
|
||||
import { AccountComponent } from "../Account";
|
||||
|
||||
describe("<Account />", () => {
|
||||
it("should say hello", () => {
|
||||
const wrapper = shallow(<AccountComponent />);
|
||||
|
||||
expect(wrapper.text()).toBe("Hello");
|
||||
});
|
||||
});
|
||||
|
||||
@@ -10,7 +10,7 @@ export interface IDocumentListProps {
|
||||
}
|
||||
|
||||
export function DocumentsList(props: IDocumentListProps) {
|
||||
const cards = props.docs.map(doc => (
|
||||
const cards = props.docs.map((doc) => (
|
||||
<DocumentCard key={doc.id} doc={doc} />
|
||||
));
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
// keeps the breadcrumbs from taking all the space
|
||||
max-width: 70%;
|
||||
}
|
||||
|
||||
|
||||
* {
|
||||
transition: 0.3s;
|
||||
}
|
||||
@@ -50,4 +50,4 @@
|
||||
.bp3-navbar {
|
||||
transition: 0.3s;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -53,7 +53,7 @@ export const docsReducer: Reducer<IDocsState, DocsAction> = (
|
||||
return { ...defaultDocsState, fetching: true };
|
||||
case DocsTypes.DOCS_FETCH_SUCCESS: {
|
||||
const all: { [key: number]: IDocumentEntry } = {};
|
||||
action.payload.all.forEach(doc => {
|
||||
action.payload.all.forEach((doc) => {
|
||||
all[doc.id] = { ...doc, remote: doc, dirty: false };
|
||||
});
|
||||
return { ...defaultDocsState, all };
|
||||
@@ -90,7 +90,7 @@ export const docsReducer: Reducer<IDocsState, DocsAction> = (
|
||||
}
|
||||
case DocsTypes.DOCS_UPLOAD_SUCCESS: {
|
||||
const all: { [key: number]: IDocumentEntry } = { ...state.all };
|
||||
action.payload.all.forEach(doc => {
|
||||
action.payload.all.forEach((doc) => {
|
||||
if (isDocDirty(all[doc.id], doc)) {
|
||||
all[doc.id] = { ...all[doc.id], remote: doc, dirty: true };
|
||||
} else {
|
||||
@@ -130,7 +130,7 @@ export const docsReducer: Reducer<IDocsState, DocsAction> = (
|
||||
shared: payload.shared,
|
||||
dirty: false,
|
||||
};
|
||||
const dirtyDocs = Object.values(all).filter(e => e.dirty);
|
||||
const dirtyDocs = Object.values(all).filter((e) => e.dirty);
|
||||
dirty = dirtyDocs.length > 0;
|
||||
}
|
||||
return { ...state, all, dirty };
|
||||
|
||||
@@ -139,7 +139,7 @@ function* docsUploadStart(action: IDocsUploadStartAction) {
|
||||
const allDocs = state.docs.all;
|
||||
|
||||
const changedDocs: IDocumentJSON[] = Object.values(allDocs).filter(
|
||||
e => e.dirty,
|
||||
(e) => e.dirty,
|
||||
);
|
||||
|
||||
const updatedDocs: IDocumentJSON[] = [];
|
||||
|
||||
Reference in New Issue
Block a user