%= form_with model: note, url: note.new_record? ? aircraft_notes_path(aircraft) : aircraft_note_path(aircraft, note), class: "card card-body space-y-4 max-w-2xl" do |f| %> <%= f.errors_summary %> <%= f.field :text, as: :textarea, label: "Note", rows: 5, autofocus: true %> <%= f.field :public, as: :checkbox, label: "Show on share links" %>