★ wanayoo — archive 1999 https://github.com/RocketChat/Rocket.Chat.iOS/pull/2432Nouvelle recherche | Portail wanayoo
Skip to content
This repository has been archived by the owner. It is now read-only.

[BLOCKED][IMPROVEMENT] Remove markdown & parse emojis in push notifications #2432

Open
wants to merge 6 commits into
base: develop
from

Conversation

@cardoso
Copy link
Collaborator

@cardoso cardoso commented Dec 14, 2018 •

@RocketChat/ios

Had to move some stuff around to share markdown code with the extension

Partially closes #1563
Blocked by RocketChat/Rocket.Chat#12956

@cardoso cardoso added this to the 3.3.0 milestone Dec 14, 2018
@@ -104,6 +104,7 @@ fileprivate extension RCMarkdownParser {
parser.strikeAttributes = [NSAttributedString.Key.strikethroughStyle.rawValue: NSNumber(value: NSUnderlineStyle.single.rawValue)]
parser.linkAttributes = [NSAttributedString.Key.foregroundColor.rawValue: UIColor.darkGray]

#if !EXCLUDE_MARKDOWN_DOWNLOAD

This comment has been minimized.

@rafaelks

rafaelks Dec 14, 2018
Contributor

I love the idea of using this kind of configuration per scheme, but what about something "pattern", like this?

ROCKETCHAT_MARKDOWN_DOWNLOAD_MEDIA

This way we:

  1. Make sure the name is actually managed by us;
  2. It's a positive checking, not negative, will be like this:
#if ROCKETCHAT_MARKDOWN_DOWNLOAD_MEDIA
...
#endif

I think it brings more clarity to the code... what do you think?

This comment has been minimized.

@cardoso

cardoso Dec 14, 2018
Author Collaborator

  1. Agreed with namespacing the flag
  2. If positive then we have to remember to add it for every build configuration in every target :/ this is very specific for the Notification Service Extension to avoid including all our download related classes.
@@ -308,3 +309,5 @@ public extension UIColor {
"YELLOWGREEN" : "9ACD32"
]
}

// swiftlint:enable all

This comment has been minimized.

@rafaelks

rafaelks Dec 14, 2018
Contributor

👀

This comment has been minimized.

@cardoso

cardoso Dec 14, 2018
Author Collaborator

I decided to treat this file as an external library. It has tons of single letter variables that prevent compiling with our linter.

Should I rewrite it? What do you think?

cardoso added 3 commits Dec 14, 2018
@cardoso cardoso changed the title [BLOCKED][IMPROVEMENT] Remove markdown from push notifications [BLOCKED][IMPROVEMENT] Remove markdown & show emojis in push notifications Dec 21, 2018
@cardoso cardoso changed the title [BLOCKED][IMPROVEMENT] Remove markdown & show emojis in push notifications [BLOCKED][IMPROVEMENT] Remove markdown & parse emojis in push notifications Dec 21, 2018
@cardoso cardoso force-pushed the imp/remove_md_pn branch from f1f214b to 04d0c50 Dec 21, 2018
@rafaelks rafaelks modified the milestones: 3.3.0, 3.5.0 Mar 22, 2019
@rafaelks rafaelks modified the milestones: 3.4.1, 3.5.0 Apr 5, 2019
@rafaelks rafaelks modified the milestones: 3.5.0, 3.6.0 May 8, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

3 participants
You can’t perform that action at this time.