mirror of
https://github.com/wassname/talk.git
synced 2026-09-09 11:38:08 +08:00
Merge branch 'next-edit' of github.com:coralproject/talk into next-profile
* 'next-edit' of github.com:coralproject/talk: Implement SetActiveTabMutation Change translation strings Add activeTab to local state Move files into tab structure
This commit is contained in:
@@ -5,17 +5,9 @@ import { PropTypesOf } from "talk-framework/types";
|
|||||||
|
|
||||||
import App from "./App";
|
import App from "./App";
|
||||||
|
|
||||||
it("renders stream", () => {
|
it("renders comments", () => {
|
||||||
const props: PropTypesOf<typeof App> = {
|
const props: PropTypesOf<typeof App> = {
|
||||||
showPermalinkView: false,
|
activeTab: "COMMENTS",
|
||||||
};
|
|
||||||
const wrapper = shallow(<App {...props} />);
|
|
||||||
expect(wrapper).toMatchSnapshot();
|
|
||||||
});
|
|
||||||
|
|
||||||
it("renders permalink view", () => {
|
|
||||||
const props: PropTypesOf<typeof App> = {
|
|
||||||
showPermalinkView: true,
|
|
||||||
};
|
};
|
||||||
const wrapper = shallow(<App {...props} />);
|
const wrapper = shallow(<App {...props} />);
|
||||||
expect(wrapper).toMatchSnapshot();
|
expect(wrapper).toMatchSnapshot();
|
||||||
|
|||||||
@@ -3,20 +3,22 @@ import { StatelessComponent } from "react";
|
|||||||
|
|
||||||
import { Flex } from "talk-ui/components";
|
import { Flex } from "talk-ui/components";
|
||||||
|
|
||||||
import PermalinkViewQuery from "../queries/PermalinkViewQuery";
|
import CommentsPaneContainer from "../tabs/comments/containers/CommentsPaneContainer";
|
||||||
import StreamQuery from "../queries/StreamQuery";
|
|
||||||
import * as styles from "./App.css";
|
import * as styles from "./App.css";
|
||||||
|
|
||||||
export interface AppProps {
|
export interface AppProps {
|
||||||
showPermalinkView: boolean;
|
activeTab: "COMMENTS" | "%future added value";
|
||||||
}
|
}
|
||||||
|
|
||||||
const App: StatelessComponent<AppProps> = props => {
|
const App: StatelessComponent<AppProps> = props => {
|
||||||
const view = props.showPermalinkView ? (
|
let view: React.ReactElement<any>;
|
||||||
<PermalinkViewQuery />
|
switch (props.activeTab) {
|
||||||
) : (
|
case "COMMENTS":
|
||||||
<StreamQuery />
|
view = <CommentsPaneContainer />;
|
||||||
);
|
break;
|
||||||
|
default:
|
||||||
|
throw new Error(`Unknown tab ${props.activeTab}`);
|
||||||
|
}
|
||||||
return (
|
return (
|
||||||
<Flex justifyContent="center" className={styles.root}>
|
<Flex justifyContent="center" className={styles.root}>
|
||||||
{view}
|
{view}
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ const UserBoxAuthenticated: StatelessComponent<
|
|||||||
return (
|
return (
|
||||||
<Flex itemGutter="half" wrap>
|
<Flex itemGutter="half" wrap>
|
||||||
<Localized
|
<Localized
|
||||||
id="comments-userBoxAuthenticated-signedInAs"
|
id="general-userBoxAuthenticated-signedInAs"
|
||||||
username={<Username />}
|
username={<Username />}
|
||||||
>
|
>
|
||||||
<Typography variant="bodyCopy" container="div">
|
<Typography variant="bodyCopy" container="div">
|
||||||
@@ -28,7 +28,7 @@ const UserBoxAuthenticated: StatelessComponent<
|
|||||||
</Typography>
|
</Typography>
|
||||||
</Localized>
|
</Localized>
|
||||||
<Localized
|
<Localized
|
||||||
id="comments-userBoxAuthenticated-notYou"
|
id="general-userBoxAuthenticated-notYou"
|
||||||
button={
|
button={
|
||||||
<Button
|
<Button
|
||||||
color="primary"
|
color="primary"
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ const UserBoxUnauthenticated: StatelessComponent<
|
|||||||
return (
|
return (
|
||||||
<Flex itemGutter alignItems="center">
|
<Flex itemGutter alignItems="center">
|
||||||
<MatchMedia gteWidth="sm">
|
<MatchMedia gteWidth="sm">
|
||||||
<Localized id="comments-userBoxUnauthenticated-joinTheConversation">
|
<Localized id="general-userBoxUnauthenticated-joinTheConversation">
|
||||||
<Typography
|
<Typography
|
||||||
className={styles.joinText}
|
className={styles.joinText}
|
||||||
variant="bodyCopyBold"
|
variant="bodyCopyBold"
|
||||||
@@ -30,7 +30,7 @@ const UserBoxUnauthenticated: StatelessComponent<
|
|||||||
|
|
|
|
||||||
</Typography>
|
</Typography>
|
||||||
</MatchMedia>
|
</MatchMedia>
|
||||||
<Localized id="comments-userBoxUnauthenticated-signIn">
|
<Localized id="general-userBoxUnauthenticated-signIn">
|
||||||
<Button
|
<Button
|
||||||
color="primary"
|
color="primary"
|
||||||
size="small"
|
size="small"
|
||||||
@@ -40,7 +40,7 @@ const UserBoxUnauthenticated: StatelessComponent<
|
|||||||
Sign in
|
Sign in
|
||||||
</Button>
|
</Button>
|
||||||
</Localized>
|
</Localized>
|
||||||
<Localized id="comments-userBoxUnauthenticated-register">
|
<Localized id="general-userBoxUnauthenticated-register">
|
||||||
<Button
|
<Button
|
||||||
color="primary"
|
color="primary"
|
||||||
size="small"
|
size="small"
|
||||||
|
|||||||
@@ -1,19 +1,10 @@
|
|||||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||||
|
|
||||||
exports[`renders permalink view 1`] = `
|
exports[`renders comments 1`] = `
|
||||||
<withPropsOnChange(Flex)
|
<withPropsOnChange(Flex)
|
||||||
className="App-root"
|
className="App-root"
|
||||||
justifyContent="center"
|
justifyContent="center"
|
||||||
>
|
>
|
||||||
<withContext(withLocalStateContainer(PermalinkViewQuery)) />
|
<withContext(withLocalStateContainer(CommentsPaneContainer)) />
|
||||||
</withPropsOnChange(Flex)>
|
|
||||||
`;
|
|
||||||
|
|
||||||
exports[`renders stream 1`] = `
|
|
||||||
<withPropsOnChange(Flex)
|
|
||||||
className="App-root"
|
|
||||||
justifyContent="center"
|
|
||||||
>
|
|
||||||
<withContext(withLocalStateContainer(StreamQuery)) />
|
|
||||||
</withPropsOnChange(Flex)>
|
</withPropsOnChange(Flex)>
|
||||||
`;
|
`;
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ exports[`renders correctly 1`] = `
|
|||||||
wrap={true}
|
wrap={true}
|
||||||
>
|
>
|
||||||
<Localized
|
<Localized
|
||||||
id="comments-userBoxAuthenticated-signedInAs"
|
id="general-userBoxAuthenticated-signedInAs"
|
||||||
username={<Username />}
|
username={<Username />}
|
||||||
>
|
>
|
||||||
<withPropsOnChange(Typography)
|
<withPropsOnChange(Typography)
|
||||||
@@ -25,7 +25,7 @@ exports[`renders correctly 1`] = `
|
|||||||
variant="underlined"
|
variant="underlined"
|
||||||
/>
|
/>
|
||||||
}
|
}
|
||||||
id="comments-userBoxAuthenticated-notYou"
|
id="general-userBoxAuthenticated-notYou"
|
||||||
>
|
>
|
||||||
<withPropsOnChange(Typography)
|
<withPropsOnChange(Typography)
|
||||||
container={[Function]}
|
container={[Function]}
|
||||||
|
|||||||
+3
-3
@@ -9,7 +9,7 @@ exports[`renders correctly 1`] = `
|
|||||||
gteWidth="sm"
|
gteWidth="sm"
|
||||||
>
|
>
|
||||||
<Localized
|
<Localized
|
||||||
id="comments-userBoxUnauthenticated-joinTheConversation"
|
id="general-userBoxUnauthenticated-joinTheConversation"
|
||||||
>
|
>
|
||||||
<withPropsOnChange(Typography)
|
<withPropsOnChange(Typography)
|
||||||
className="UserBoxUnauthenticated-joinText"
|
className="UserBoxUnauthenticated-joinText"
|
||||||
@@ -27,7 +27,7 @@ exports[`renders correctly 1`] = `
|
|||||||
</withPropsOnChange(Typography)>
|
</withPropsOnChange(Typography)>
|
||||||
</MatchMediaWithContext>
|
</MatchMediaWithContext>
|
||||||
<Localized
|
<Localized
|
||||||
id="comments-userBoxUnauthenticated-signIn"
|
id="general-userBoxUnauthenticated-signIn"
|
||||||
>
|
>
|
||||||
<withPropsOnChange(Button)
|
<withPropsOnChange(Button)
|
||||||
color="primary"
|
color="primary"
|
||||||
@@ -39,7 +39,7 @@ exports[`renders correctly 1`] = `
|
|||||||
</withPropsOnChange(Button)>
|
</withPropsOnChange(Button)>
|
||||||
</Localized>
|
</Localized>
|
||||||
<Localized
|
<Localized
|
||||||
id="comments-userBoxUnauthenticated-register"
|
id="general-userBoxUnauthenticated-register"
|
||||||
>
|
>
|
||||||
<withPropsOnChange(Button)
|
<withPropsOnChange(Button)
|
||||||
color="primary"
|
color="primary"
|
||||||
|
|||||||
@@ -11,15 +11,15 @@ interface InnerProps {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const AppContainer: StatelessComponent<InnerProps> = ({
|
const AppContainer: StatelessComponent<InnerProps> = ({
|
||||||
local: { commentID },
|
local: { activeTab },
|
||||||
}) => {
|
}) => {
|
||||||
return <App showPermalinkView={!!commentID} />;
|
return <App activeTab={activeTab} />;
|
||||||
};
|
};
|
||||||
|
|
||||||
const enhanced = withLocalStateContainer(
|
const enhanced = withLocalStateContainer(
|
||||||
graphql`
|
graphql`
|
||||||
fragment AppContainerLocal on Local {
|
fragment AppContainerLocal on Local {
|
||||||
commentID
|
activeTab
|
||||||
}
|
}
|
||||||
`
|
`
|
||||||
)(AppContainer);
|
)(AppContainer);
|
||||||
|
|||||||
@@ -18,7 +18,8 @@ exports[`init local state 1`] = `
|
|||||||
},
|
},
|
||||||
\\"authPopup\\": {
|
\\"authPopup\\": {
|
||||||
\\"__ref\\": \\"client:root.local.authPopup\\"
|
\\"__ref\\": \\"client:root.local.authPopup\\"
|
||||||
}
|
},
|
||||||
|
\\"activeTab\\": \\"COMMENTS\\"
|
||||||
},
|
},
|
||||||
\\"client:root.local.network\\": {
|
\\"client:root.local.network\\": {
|
||||||
\\"__id\\": \\"client:root.local.network\\",
|
\\"__id\\": \\"client:root.local.network\\",
|
||||||
|
|||||||
@@ -75,5 +75,8 @@ export default async function initLocalState(
|
|||||||
authPopupRecord.setValue(false, "focus");
|
authPopupRecord.setValue(false, "focus");
|
||||||
authPopupRecord.setValue("", "href");
|
authPopupRecord.setValue("", "href");
|
||||||
localRecord.setLinkedRecord(authPopupRecord, "authPopup");
|
localRecord.setLinkedRecord(authPopupRecord, "authPopup");
|
||||||
|
|
||||||
|
// Set active tab
|
||||||
|
localRecord.setValue("COMMENTS", "activeTab");
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,6 +9,10 @@ enum View {
|
|||||||
FORGOT_PASSWORD
|
FORGOT_PASSWORD
|
||||||
}
|
}
|
||||||
|
|
||||||
|
enum Tab {
|
||||||
|
COMMENTS
|
||||||
|
}
|
||||||
|
|
||||||
type AuthPopup {
|
type AuthPopup {
|
||||||
open: Boolean!
|
open: Boolean!
|
||||||
focus: Boolean!
|
focus: Boolean!
|
||||||
@@ -26,6 +30,7 @@ type Local {
|
|||||||
commentID: String
|
commentID: String
|
||||||
authPopup: AuthPopup!
|
authPopup: AuthPopup!
|
||||||
authToken: String
|
authToken: String
|
||||||
|
activeTab: Tab!
|
||||||
}
|
}
|
||||||
|
|
||||||
extend type Query {
|
extend type Query {
|
||||||
|
|||||||
@@ -0,0 +1,21 @@
|
|||||||
|
import { Environment, RecordSource } from "relay-runtime";
|
||||||
|
|
||||||
|
import { LOCAL_ID } from "talk-framework/lib/relay";
|
||||||
|
import { createRelayEnvironment } from "talk-framework/testHelpers";
|
||||||
|
|
||||||
|
import { commit } from "./SetActiveTabMutation";
|
||||||
|
|
||||||
|
let environment: Environment;
|
||||||
|
const source: RecordSource = new RecordSource();
|
||||||
|
|
||||||
|
beforeAll(() => {
|
||||||
|
environment = createRelayEnvironment({
|
||||||
|
source,
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
it("Sets activeTab", () => {
|
||||||
|
const tab = "COMMENTS";
|
||||||
|
commit(environment, { tab });
|
||||||
|
expect(source.get(LOCAL_ID)!.activeTab).toEqual(tab);
|
||||||
|
});
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
import { commitLocalUpdate, Environment } from "relay-runtime";
|
||||||
|
|
||||||
|
import { createMutationContainer, LOCAL_ID } from "talk-framework/lib/relay";
|
||||||
|
|
||||||
|
export interface SetActiveTabInput {
|
||||||
|
tab: "COMMENTS";
|
||||||
|
}
|
||||||
|
|
||||||
|
export type SetActiveTabMutation = (input: SetActiveTabInput) => Promise<void>;
|
||||||
|
|
||||||
|
export async function commit(
|
||||||
|
environment: Environment,
|
||||||
|
input: SetActiveTabInput
|
||||||
|
) {
|
||||||
|
return commitLocalUpdate(environment, store => {
|
||||||
|
const record = store.get(LOCAL_ID)!;
|
||||||
|
record.setValue(input.tab, "activeTab");
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
export const withSetActiveTabMutation = createMutationContainer(
|
||||||
|
"setActiveTab",
|
||||||
|
commit
|
||||||
|
);
|
||||||
@@ -26,3 +26,7 @@ export {
|
|||||||
withSetAuthPopupStateMutation,
|
withSetAuthPopupStateMutation,
|
||||||
SetAuthPopupStateMutation,
|
SetAuthPopupStateMutation,
|
||||||
} from "./SetAuthPopupStateMutation";
|
} from "./SetAuthPopupStateMutation";
|
||||||
|
export {
|
||||||
|
withSetActiveTabMutation,
|
||||||
|
SetActiveTabMutation,
|
||||||
|
} from "./SetActiveTabMutation";
|
||||||
|
|||||||
+2
-2
@@ -1,11 +1,11 @@
|
|||||||
import React, { StatelessComponent } from "react";
|
import React, { StatelessComponent } from "react";
|
||||||
|
|
||||||
|
import HTMLContent from "talk-stream/components/HTMLContent";
|
||||||
|
import Timestamp from "talk-stream/components/Timestamp";
|
||||||
import { Flex } from "talk-ui/components";
|
import { Flex } from "talk-ui/components";
|
||||||
|
|
||||||
import * as styles from "./Comment.css";
|
import * as styles from "./Comment.css";
|
||||||
import EditedMarker from "./EditedMarker";
|
import EditedMarker from "./EditedMarker";
|
||||||
import HTMLContent from "./HTMLContent";
|
|
||||||
import Timestamp from "./Timestamp";
|
|
||||||
import TopBarLeft from "./TopBarLeft";
|
import TopBarLeft from "./TopBarLeft";
|
||||||
import Username from "./Username";
|
import Username from "./Username";
|
||||||
|
|
||||||
-1
@@ -1,4 +1,3 @@
|
|||||||
export { default, default as IndentedComment } from "./IndentedComment";
|
export { default, default as IndentedComment } from "./IndentedComment";
|
||||||
export { default as TopBarLeft } from "./TopBarLeft";
|
export { default as TopBarLeft } from "./TopBarLeft";
|
||||||
export { default as Username } from "./Username";
|
export { default as Username } from "./Username";
|
||||||
export { default as Timestamp } from "./Timestamp";
|
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
import { shallow } from "enzyme";
|
||||||
|
import React from "react";
|
||||||
|
|
||||||
|
import { PropTypesOf } from "talk-framework/types";
|
||||||
|
|
||||||
|
import CommentsPane from "./CommentsPane";
|
||||||
|
|
||||||
|
it("renders stream", () => {
|
||||||
|
const props: PropTypesOf<typeof CommentsPane> = {
|
||||||
|
showPermalinkView: false,
|
||||||
|
};
|
||||||
|
const wrapper = shallow(<CommentsPane {...props} />);
|
||||||
|
expect(wrapper).toMatchSnapshot();
|
||||||
|
});
|
||||||
|
|
||||||
|
it("renders permalink view", () => {
|
||||||
|
const props: PropTypesOf<typeof CommentsPane> = {
|
||||||
|
showPermalinkView: true,
|
||||||
|
};
|
||||||
|
const wrapper = shallow(<CommentsPane {...props} />);
|
||||||
|
expect(wrapper).toMatchSnapshot();
|
||||||
|
});
|
||||||
@@ -0,0 +1,15 @@
|
|||||||
|
import * as React from "react";
|
||||||
|
import { StatelessComponent } from "react";
|
||||||
|
|
||||||
|
import PermalinkViewQuery from "../queries/PermalinkViewQuery";
|
||||||
|
import StreamQuery from "../queries/StreamQuery";
|
||||||
|
|
||||||
|
export interface CommentsPaneProps {
|
||||||
|
showPermalinkView: boolean;
|
||||||
|
}
|
||||||
|
|
||||||
|
const CommentsPane: StatelessComponent<CommentsPaneProps> = props => {
|
||||||
|
return props.showPermalinkView ? <PermalinkViewQuery /> : <StreamQuery />;
|
||||||
|
};
|
||||||
|
|
||||||
|
export default CommentsPane;
|
||||||
+2
-1
@@ -10,6 +10,7 @@ import { Field, Form } from "react-final-form";
|
|||||||
|
|
||||||
import { OnSubmit } from "talk-framework/lib/form";
|
import { OnSubmit } from "talk-framework/lib/form";
|
||||||
import { required } from "talk-framework/lib/validation";
|
import { required } from "talk-framework/lib/validation";
|
||||||
|
import Timestamp from "talk-stream/components/Timestamp";
|
||||||
import {
|
import {
|
||||||
AriaInfo,
|
AriaInfo,
|
||||||
Button,
|
Button,
|
||||||
@@ -22,7 +23,7 @@ import {
|
|||||||
ValidationMessage,
|
ValidationMessage,
|
||||||
} from "talk-ui/components";
|
} from "talk-ui/components";
|
||||||
|
|
||||||
import { Timestamp, TopBarLeft, Username } from "./Comment";
|
import { TopBarLeft, Username } from "./Comment";
|
||||||
import RTE from "./RTE";
|
import RTE from "./RTE";
|
||||||
|
|
||||||
interface FormProps {
|
interface FormProps {
|
||||||
+1
-1
@@ -3,12 +3,12 @@ import * as React from "react";
|
|||||||
import { StatelessComponent } from "react";
|
import { StatelessComponent } from "react";
|
||||||
|
|
||||||
import { PropTypesOf } from "talk-framework/types";
|
import { PropTypesOf } from "talk-framework/types";
|
||||||
|
import UserBoxContainer from "talk-stream/containers/UserBoxContainer";
|
||||||
import { Button, HorizontalGutter } from "talk-ui/components";
|
import { Button, HorizontalGutter } from "talk-ui/components";
|
||||||
|
|
||||||
import CommentContainer from "../containers/CommentContainer";
|
import CommentContainer from "../containers/CommentContainer";
|
||||||
import PostCommentFormContainer from "../containers/PostCommentFormContainer";
|
import PostCommentFormContainer from "../containers/PostCommentFormContainer";
|
||||||
import ReplyListContainer from "../containers/ReplyListContainer";
|
import ReplyListContainer from "../containers/ReplyListContainer";
|
||||||
import UserBoxContainer from "../containers/UserBoxContainer";
|
|
||||||
import PostCommentFormFake from "./PostCommentFormFake";
|
import PostCommentFormFake from "./PostCommentFormFake";
|
||||||
import * as styles from "./Stream.css";
|
import * as styles from "./Stream.css";
|
||||||
|
|
||||||
+5
@@ -0,0 +1,5 @@
|
|||||||
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||||
|
|
||||||
|
exports[`renders permalink view 1`] = `<withContext(withLocalStateContainer(PermalinkViewQuery)) />`;
|
||||||
|
|
||||||
|
exports[`renders stream 1`] = `<withContext(withLocalStateContainer(StreamQuery)) />`;
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
import * as React from "react";
|
||||||
|
import { StatelessComponent } from "react";
|
||||||
|
|
||||||
|
import { graphql, withLocalStateContainer } from "talk-framework/lib/relay";
|
||||||
|
import { CommentsPaneContainerLocal as Local } from "talk-stream/__generated__/CommentsPaneContainerLocal.graphql";
|
||||||
|
|
||||||
|
import CommentsPane from "../components/CommentsPane";
|
||||||
|
|
||||||
|
interface InnerProps {
|
||||||
|
local: Local;
|
||||||
|
}
|
||||||
|
|
||||||
|
const CommentsPaneContainer: StatelessComponent<InnerProps> = ({
|
||||||
|
local: { commentID },
|
||||||
|
}) => {
|
||||||
|
return <CommentsPane showPermalinkView={!!commentID} />;
|
||||||
|
};
|
||||||
|
|
||||||
|
const enhanced = withLocalStateContainer(
|
||||||
|
graphql`
|
||||||
|
fragment CommentsPaneContainerLocal on Local {
|
||||||
|
commentID
|
||||||
|
}
|
||||||
|
`
|
||||||
|
)(CommentsPaneContainer);
|
||||||
|
|
||||||
|
export default enhanced;
|
||||||
+4
-1
@@ -9,11 +9,14 @@ import { withFragmentContainer } from "talk-framework/lib/relay";
|
|||||||
import { PropTypesOf } from "talk-framework/types";
|
import { PropTypesOf } from "talk-framework/types";
|
||||||
|
|
||||||
import { EditCommentFormContainer_comment as CommentData } from "talk-stream/__generated__/EditCommentFormContainer_comment.graphql";
|
import { EditCommentFormContainer_comment as CommentData } from "talk-stream/__generated__/EditCommentFormContainer_comment.graphql";
|
||||||
|
import {
|
||||||
|
EditCommentMutation,
|
||||||
|
withEditCommentMutation,
|
||||||
|
} from "talk-stream/mutations";
|
||||||
|
|
||||||
import EditCommentForm, {
|
import EditCommentForm, {
|
||||||
EditCommentFormProps,
|
EditCommentFormProps,
|
||||||
} from "../components/EditCommentForm";
|
} from "../components/EditCommentForm";
|
||||||
import { EditCommentMutation, withEditCommentMutation } from "../mutations";
|
|
||||||
|
|
||||||
interface InnerProps {
|
interface InnerProps {
|
||||||
editComment: EditCommentMutation;
|
editComment: EditCommentMutation;
|
||||||
+4
-1
@@ -5,10 +5,13 @@ import { BadUserInputError } from "talk-framework/lib/errors";
|
|||||||
import { PromisifiedStorage } from "talk-framework/lib/storage";
|
import { PromisifiedStorage } from "talk-framework/lib/storage";
|
||||||
import { PropTypesOf } from "talk-framework/types";
|
import { PropTypesOf } from "talk-framework/types";
|
||||||
|
|
||||||
|
import {
|
||||||
|
CreateCommentMutation,
|
||||||
|
withCreateCommentMutation,
|
||||||
|
} from "talk-stream/mutations";
|
||||||
import PostCommentForm, {
|
import PostCommentForm, {
|
||||||
PostCommentFormProps,
|
PostCommentFormProps,
|
||||||
} from "../components/PostCommentForm";
|
} from "../components/PostCommentForm";
|
||||||
import { CreateCommentMutation, withCreateCommentMutation } from "../mutations";
|
|
||||||
|
|
||||||
interface InnerProps {
|
interface InnerProps {
|
||||||
createComment: CreateCommentMutation;
|
createComment: CreateCommentMutation;
|
||||||
+4
-1
@@ -9,11 +9,14 @@ import { PromisifiedStorage } from "talk-framework/lib/storage";
|
|||||||
import { PropTypesOf } from "talk-framework/types";
|
import { PropTypesOf } from "talk-framework/types";
|
||||||
import { ReplyCommentFormContainer_asset as AssetData } from "talk-stream/__generated__/ReplyCommentFormContainer_asset.graphql";
|
import { ReplyCommentFormContainer_asset as AssetData } from "talk-stream/__generated__/ReplyCommentFormContainer_asset.graphql";
|
||||||
import { ReplyCommentFormContainer_comment as CommentData } from "talk-stream/__generated__/ReplyCommentFormContainer_comment.graphql";
|
import { ReplyCommentFormContainer_comment as CommentData } from "talk-stream/__generated__/ReplyCommentFormContainer_comment.graphql";
|
||||||
|
import {
|
||||||
|
CreateCommentMutation,
|
||||||
|
withCreateCommentMutation,
|
||||||
|
} from "talk-stream/mutations";
|
||||||
|
|
||||||
import ReplyCommentForm, {
|
import ReplyCommentForm, {
|
||||||
ReplyCommentFormProps,
|
ReplyCommentFormProps,
|
||||||
} from "../components/ReplyCommentForm";
|
} from "../components/ReplyCommentForm";
|
||||||
import { CreateCommentMutation, withCreateCommentMutation } from "../mutations";
|
|
||||||
|
|
||||||
interface InnerProps {
|
interface InnerProps {
|
||||||
createComment: CreateCommentMutation;
|
createComment: CreateCommentMutation;
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user