File tree Expand file tree Collapse file tree 3 files changed +8
-4
lines changed
Expand file tree Collapse file tree 3 files changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -416,7 +416,8 @@ def get_title_list(s: str) -> list:
416416 title = "{}" .format (type )
417417
418418 f2 .write (title + "\n " + "=" * len (title ) + "\n \n " )
419- f2 .write (".. autoclass:: pyrogram.types.{}()" .format (type ))
419+ f2 .write (".. autoclass:: pyrogram.types.{}()\n " .format (type ))
420+ f2 .write (" :members:\n " )
420421
421422 f .write (template .format (** fmt_keys ))
422423
Original file line number Diff line number Diff line change @@ -245,9 +245,6 @@ class Message(Object, Update):
245245 Messages sent from yourself to other chats are outgoing (*outgoing* is True).
246246 An exception is made for your own personal chat; messages sent there will be incoming.
247247
248- link (``str``):
249- A link to the message, only for groups and channels.
250-
251248 matches (List of regex Matches, *optional*):
252249 A list containing all `Match Objects <https://docs.python.org/3/library/re.html#match-objects>`_ that match
253250 the text of this message. Only applicable when using :obj:`Filters.regex <pyrogram.Filters.regex>`.
@@ -675,6 +672,7 @@ async def _parse(
675672
676673 @property
677674 def link (self ) -> str :
675+ """Generate a link to this message, only for groups and channels."""
678676 if self .chat .type in ("group" , "supergroup" , "channel" ) and self .chat .username :
679677 return f"https://t.me/{ self .chat .username } /{ self .message_id } "
680678 else :
Original file line number Diff line number Diff line change @@ -192,6 +192,11 @@ def __init__(
192192
193193 @property
194194 def mention (self ):
195+ """Generate a text mention for this user.
196+
197+ You can use ``user.mention()`` to mention the user using their first name (styled using html), or
198+ ``user.mention("another name")`` for a custom name. To choose a different style
199+ ("html" or "md"/"markdown") use ``user.mention(style="md")``."""
195200 return Link (f"tg://user?id={ self .id } " , self .first_name , self ._client .parse_mode )
196201
197202 @staticmethod
You can’t perform that action at this time.
0 commit comments