Skip to content

Commit

Permalink
add doc group for form components
Browse files Browse the repository at this point in the history
  • Loading branch information
woylie committed Dec 27, 2023
1 parent aec06a4 commit 1db502b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions lib/doggo.ex
Original file line number Diff line number Diff line change
Expand Up @@ -1963,7 +1963,7 @@ defmodule Doggo do
in array fields by default, you may need to handle the additional empty string
manual in other contexts.
"""
@doc type: :component
@doc type: :form

attr :id, :any, default: nil
attr :name, :any
Expand Down Expand Up @@ -2421,7 +2421,7 @@ defmodule Doggo do
@doc """
Renders the label for an input.
"""
@doc type: :component
@doc type: :form

attr :for, :string, default: nil, doc: "The ID of the input."

Expand Down Expand Up @@ -2465,7 +2465,7 @@ defmodule Doggo do
@doc """
Renders the errors for an input.
"""
@doc type: :component
@doc type: :form

attr :for, :string, required: true, doc: "The ID of the input."
attr :errors, :list, required: true, doc: "A list of errors as strings."
Expand All @@ -2483,7 +2483,7 @@ defmodule Doggo do
@doc """
Renders the description of an input.
"""
@doc type: :component
@doc type: :form

attr :for, :string, required: true, doc: "The ID of the input."
attr :description, :any
Expand Down Expand Up @@ -2541,7 +2541,7 @@ defmodule Doggo do
<.input field={@form[:family_name]} label="Family name"/>
</fieldset>
"""
@doc type: :component
@doc type: :form

attr :class, :any,
default: [],
Expand Down
2 changes: 1 addition & 1 deletion mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ defmodule Doggo.MixProject do
skip_undefined_reference_warnings_on: ["CHANGELOG.md"],
groups_for_functions: [
Components: &(&1[:type] == :component),
Layouts: &(&1[:type] == :layout)
Form: &(&1[:type] == :form)
]
]
end
Expand Down

0 comments on commit 1db502b

Please sign in to comment.