Skip to content

Commit

Permalink
Improve FeedbackDialog yardocs
Browse files Browse the repository at this point in the history
* Replaces `@param` tags that are actually documenting method calls.
* Minor punctuation fixes.
  • Loading branch information
myabc committed Jan 13, 2025
1 parent 08ccb8b commit 1738319
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions app/components/primer/open_project/feedback_dialog.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,20 @@ module OpenProject
class FeedbackDialog < Primer::Component
status :open_project

# A feedback message with some defaults that are necessary for rendering nicely
# A feedback message with some defaults that are necessary for rendering nicely.
#
# To render the message heading (required), call the `with_heading` method, which accepts a `:tag` argument, along with the arguments accepted by <%= link_to_component(Primer::Beta::Heading) %>.
#
# To render the message description, call the `with_description` method, which accepts <%= link_to_system_arguments_docs %>
#
# @param heading [String] the heading for the success message
# @param description [String] the description for the success message
# @param icon_arguments [Hash] the system_arguments for the icon
# @param system_arguments [Hash] <%= link_to_system_arguments_docs %>
renders_one :feedback_message, lambda { |icon_arguments: {}, **system_arguments|
system_arguments[:border] = false
Primer::OpenProject::FeedbackMessage.new(icon_arguments: icon_arguments, **system_arguments)
}

# Optional additional_details like a form input or toast.
# Optional additional details, like a form input or toast.
#
# @param system_arguments [Hash] <%= link_to_system_arguments_docs %>
renders_one :additional_details, lambda { |**system_arguments|
Expand Down

0 comments on commit 1738319

Please sign in to comment.