From 47be26fbfef6b81b958ef0b8c07611d20849cf59 Mon Sep 17 00:00:00 2001 From: shumiyao <50849841+shumiyao@users.noreply.github.com> Date: Thu, 7 Nov 2019 21:25:21 +0000 Subject: [PATCH] docs: add type specification of relation widget valueField (#2446) --- website/content/docs/widgets/relation.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/content/docs/widgets/relation.md b/website/content/docs/widgets/relation.md index 9d30edb0..5a9820c0 100644 --- a/website/content/docs/widgets/relation.md +++ b/website/content/docs/widgets/relation.md @@ -13,7 +13,7 @@ The relation widget allows you to reference items from another collection. It pr - `collection`: (**required**) name of the collection being referenced (string) - `displayFields`: list of one or more names of fields in the referenced collection that will render in the autocomplete menu of the control. Defaults to `valueField`. For nested fields, separate each subfield with a `.` (E.g. `name.first`). - `searchFields`: (**required**) list of one or more names of fields in the referenced collection to search for the typed value. Syntax to reference nested fields is similar to that of *displayFields*. - - `valueField`: (**required**) name of the field from the referenced collection whose value will be stored for the relation. Syntax to reference nested fields is similar to that of *displayFields* and *searchFields*. + - `valueField`: (**required**) name of the field from the referenced collection whose value will be stored for the relation. Syntax to reference nested fields is similar to that of *displayFields* and *searchFields*. As `valueField` only allows for a single field, this parameter only accepts a string. - `multiple` : accepts a boolean, defaults to `false` - `optionsLength`: accepts integer to override number of options presented to user. Defaults to `20`. - **Example** (assuming a separate "authors" collection with "name" and "twitterHandle" fields with subfields "first" and "last" for the "name" field):