Renames DocumentForm to NewRelatedDocumentForm
This commit is contained in:
@@ -3,7 +3,7 @@ import { pb } from "@/lib/pocketbase";
|
|||||||
import type { Document, RelationshipType } from "@/lib/types";
|
import type { Document, RelationshipType } from "@/lib/types";
|
||||||
import { useState } from "react";
|
import { useState } from "react";
|
||||||
import { Loader } from "./Loader";
|
import { Loader } from "./Loader";
|
||||||
import { DocumentForm } from "./documents/DocumentForm";
|
import { NewRelatedDocumentForm } from "./documents/NewRelatedDocumentForm";
|
||||||
import { DocumentRow } from "./documents/DocumentRow";
|
import { DocumentRow } from "./documents/DocumentRow";
|
||||||
|
|
||||||
interface RelationshipListProps {
|
interface RelationshipListProps {
|
||||||
@@ -68,7 +68,7 @@ export function RelationshipList({
|
|||||||
error={error}
|
error={error}
|
||||||
renderRow={(document) => <DocumentRow document={document} />}
|
renderRow={(document) => <DocumentRow document={document} />}
|
||||||
newItemForm={(onSubmit) => (
|
newItemForm={(onSubmit) => (
|
||||||
<DocumentForm
|
<NewRelatedDocumentForm
|
||||||
campaignId={root.campaign}
|
campaignId={root.campaign}
|
||||||
relationshipType={relationshipType}
|
relationshipType={relationshipType}
|
||||||
onCreate={async (doc: Document) => {
|
onCreate={async (doc: Document) => {
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ function assertUnreachable(_x: never): never {
|
|||||||
/**
|
/**
|
||||||
* Renders a form for any document type depending on the relationship.
|
* Renders a form for any document type depending on the relationship.
|
||||||
*/
|
*/
|
||||||
export const DocumentForm = ({
|
export const NewRelatedDocumentForm = ({
|
||||||
campaignId,
|
campaignId,
|
||||||
relationshipType,
|
relationshipType,
|
||||||
onCreate,
|
onCreate,
|
||||||
Reference in New Issue
Block a user