Details

    • Sub-task
    • Status: Closed
    • Major
    • Resolution: Done
    • None
    • 3.6.0
    • JMAP
    • None

    Description

      As a user i want to be able to for a value in any text part of a mail body

      body: String Looks for the text in one of the body parts of the message. The server MAY exclude MIME body parts with content media types other than text/* and message/* from consideration in search matching. Care should be taken to match based on the text content actually presented to an end user by viewers for that media type or otherwise identified as appropriate for search indexing. Matching document metadata uninteresting to an end user (e.g., markup tag and attribute names) is undesirable.
      
          1. Why

      As an user i want to be able to select the mail by searching for a text in those text body parts like this :

      [[ "Email/query",{
        "accountId": "ue150411c",
        "filter":  {
           "body": "james"
      }
      }, "0" ]]
      

      should return the emails containing 'james' in any text/* parts of its body. For text/html parts it should only return text exposed to the user.
      No attributes or tags name.

          1. HOW
      • accept a simple FilterCondition with an optional 'body' field
      • filter the query with those parameters. It don't need to be an exact match. For the result to appear any fields should contains the value : .value. in the text exposed to the user.

      The exact semantics for matching String fields is deliberately not defined to allow for flexibility in indexing implementation, subject to the following:

          Any syntactically correct encoded sections [@!RFC2047] of header fields with a known encoding SHOULD be decoded before attempting to match text.
          When searching inside a text/html body part, any text considered markup rather than content SHOULD be ignored, including HTML tags and most attributes, anything inside the <head> tag, Cascading Style Sheets (CSS) and JavaScript. Attribute content intended for presentation to the user such as “alt” and “title” SHOULD be considered in the search.
          Text SHOULD be matched in a case-insensitive manner.
      
          Text contained in either (but matched) single (‘) or double (“) quotes SHOULD be treated as a phrase search; that is, a match is required for that exact word or sequence of words, excluding the surrounding quotation marks.
      
          1. Definition of Done
      • write integration demonstrating that a user can filter the email with a value contained in a text/plain part of the body
      • write integration demonstrating that a user can filter the email with a value contained in a text/html part of the body
      • write integration demonstrating that a user cannot filter the email with a value contained in an attribute name of a text/html part of the body
      • write integration demonstrating that a user cannot filter the email with a value contained in a tag name of a text/html part of the body
      • write integration demonstrating that a user can filter the email with a value contained in a text part of a multipart mail

      Attachments

        Activity

          People

            Unassigned Unassigned
            btellier Benoit Tellier
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: