-
-
Notifications
You must be signed in to change notification settings - Fork 171
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for Viewtype::Vcard #3829
Comments
@adbenitez what is meant with: set new core stock string "Contact" (used in summary)? |
Maybe we're going to remove this stock string at all as the contact name should be displayed instead of "Contact". And if a vCard can't be parsed, the message viewtype is changed to EDIT: Currently this stock string is used, but with deltachat/deltachat-core-rust#5619 it isn't anymore. |
* Show vcard in messages resolves #3829 * Add changelog entry * Show VCard before content not instead content - add click handler to start chat * Use import vcard before creating chat * Move VCard in own component * fix changelog entries and add pr number --------- Co-authored-by: SimonLaux <[email protected]>
deltachat/deltachat-core-rust#5536 introduces a new viewtype
Vcard
(Viewtype::Vcard
in JsonRPC,DC_MSG_VCARD
in the C FFI). In order to show it, call the JsonRPC functionparse_vcard(filePath)
wherefilePath
is the path to the message's attachment.parse_vcard()
will return a JSON struct with fieldsaddr
,display_name
,profile_image
, andcolor
(which you can use to create a placeholder image in case there is no profile_image). You can ignore the other returned fields. Note thatparse_vcard()
returns a list of contacts; simply ignore all except for the first contact.Android implements viewing Vcards here: deltachat/deltachat-android#3043
Can be done now (depends on deltachat/deltachat-core-rust#5536):
import_vcard()
(depends on feat: Add import_vcard() (#5202) deltachat-core-rust#5582)These TODO-items should be postponed:
set new core stock string "Contact"(looks like we won't keep this stock string)Preview from Android:
The text was updated successfully, but these errors were encountered: