From d8cdd82bf8a69e1db385b6d4e239d57ce20a900e Mon Sep 17 00:00:00 2001 From: Badlop Date: Fri, 29 Mar 2024 16:36:47 +0100 Subject: [PATCH] Rewrite vcard example configuration to not require extended format --- src/mod_http_upload.erl | 31 ++++++++++++++++--------------- src/mod_muc.erl | 31 ++++++++++++++++--------------- src/mod_proxy65.erl | 31 ++++++++++++++++--------------- src/mod_pubsub.erl | 31 ++++++++++++++++--------------- src/mod_vcard.erl | 33 ++++++++++++++++++--------------- 5 files changed, 82 insertions(+), 75 deletions(-) diff --git a/src/mod_http_upload.erl b/src/mod_http_upload.erl index f40fc8945..cf5facb56 100644 --- a/src/mod_http_upload.erl +++ b/src/mod_http_upload.erl @@ -367,21 +367,22 @@ mod_doc() -> "of vCard. Since the representation has no attributes, " "the mapping is straightforward."), example => - [{?T("For example, the following XML representation of vCard:"), - ["", - " Conferences", - " ", - " ", - " Elm Street", - " ", - ""]}, - {?T("will be translated to:"), - ["vcard:", - " fn: Conferences", - " adr:", - " -", - " work: true", - " street: Elm Street"]}]}}], + ["# This XML representation of vCard:", + "# ", + "# Conferences", + "# ", + "# ", + "# Elm Street", + "# ", + "# ", + "# ", + "# is translated to:", + "vcard:", + " fn: Conferences", + " adr:", + " -", + " work: true", + " street: Elm Street"]}}], example => ["listen:", " -", diff --git a/src/mod_muc.erl b/src/mod_muc.erl index 216c1277b..e297d866f 100644 --- a/src/mod_muc.erl +++ b/src/mod_muc.erl @@ -1654,21 +1654,22 @@ mod_doc() -> "of vCard. Since the representation has no attributes, " "the mapping is straightforward."), example => - [{?T("For example, the following XML representation of vCard:"), - ["", - " Conferences", - " ", - " ", - " Elm Street", - " ", - ""]}, - {?T("will be translated to:"), - ["vcard:", - " fn: Conferences", - " adr:", - " -", - " work: true", - " street: Elm Street"]}]}}, + ["# This XML representation of vCard:", + "# ", + "# Conferences", + "# ", + "# ", + "# Elm Street", + "# ", + "# ", + "# ", + "# is translated to:", + "vcard:", + " fn: Conferences", + " adr:", + " -", + " work: true", + " street: Elm Street"]}}, {cleanup_affiliations_on_start, #{value => "true | false", note => "added in 22.05", diff --git a/src/mod_proxy65.erl b/src/mod_proxy65.erl index e606260ea..9768e9535 100644 --- a/src/mod_proxy65.erl +++ b/src/mod_proxy65.erl @@ -239,21 +239,22 @@ mod_doc() -> "of vCard. Since the representation has no attributes, " "the mapping is straightforward."), example => - [{?T("For example, the following XML representation of vCard:"), - ["", - " Conferences", - " ", - " ", - " Elm Street", - " ", - ""]}, - {?T("will be translated to:"), - ["vcard:", - " fn: Conferences", - " adr:", - " -", - " work: true", - " street: Elm Street"]}]}}], + ["# This XML representation of vCard:", + "# ", + "# Conferences", + "# ", + "# ", + "# Elm Street", + "# ", + "# ", + "# ", + "# is translated to:", + "vcard:", + " fn: Conferences", + " adr:", + " -", + " work: true", + " street: Elm Street"]}}], example => ["acl:", " admin:", diff --git a/src/mod_pubsub.erl b/src/mod_pubsub.erl index 1c6de26df..0fd73cf39 100644 --- a/src/mod_pubsub.erl +++ b/src/mod_pubsub.erl @@ -4504,21 +4504,22 @@ mod_doc() -> "representation of vCard. Since the representation has " "no attributes, the mapping is straightforward."), example => - [{?T("The following XML representation of vCard:"), - ["", - " PubSub Service", - " ", - " ", - " Elm Street", - " ", - ""]}, - {?T("will be translated to:"), - ["vcard:", - " fn: PubSub Service", - " adr:", - " -", - " work: true", - " street: Elm Street"]}]}} + ["# This XML representation of vCard:", + "# ", + "# Conferences", + "# ", + "# ", + "# Elm Street", + "# ", + "# ", + "# ", + "# is translated to:", + "vcard:", + " fn: Conferences", + " adr:", + " -", + " work: true", + " street: Elm Street"]}} ], example => [{?T("Example of configuration that uses flat nodes as default, " diff --git a/src/mod_vcard.erl b/src/mod_vcard.erl index 43721e38d..9a6a42b23 100644 --- a/src/mod_vcard.erl +++ b/src/mod_vcard.erl @@ -667,18 +667,21 @@ mod_doc() -> "of vCard. Since the representation has no attributes, " "the mapping is straightforward."), example => - [{?T("For example, the following XML representation of vCard:"), - ["", - " Conferences", - " ", - " ", - " Elm Street", - " ", - ""]}, - {?T("will be translated to:"), - ["vcard:", - " fn: Conferences", - " adr:", - " -", - " work: true", - " street: Elm Street"]}]}}]}. + ["# This XML representation of vCard:", + "# ", + "# ", + "# Conferences", + "# ", + "# ", + "# Elm Street", + "# ", + "# ", + "# ", + "# is translated to:", + "# ", + "vcard:", + " fn: Conferences", + " adr:", + " -", + " work: true", + " street: Elm Street"]}}]}.