Compare commits
8 Commits
tyiu/follo
...
tyiu/post-
| Author | SHA1 | Date | |
|---|---|---|---|
|
4d333907bd
|
|||
| 422167f7aa | |||
|
|
de84456a57 | ||
|
|
b70bf1f647 | ||
|
|
3db77a16a0 | ||
|
|
2256e2e625 | ||
|
|
a641f972ff | ||
|
|
c5846008f2 |
18
CHANGELOG.md
18
CHANGELOG.md
@@ -1,3 +1,21 @@
|
||||
## [1.5-5] - 2023-06-24
|
||||
|
||||
### Fixed
|
||||
|
||||
- Remove note zaps to fit apples appstore guidelines
|
||||
- Fix zap sheet popping (William Casarin)
|
||||
- Fix CustomizeZapView from randomly disappearing (William Casarin)
|
||||
- Fix "zapped your profile" strings to say "zapped you" (Terry Yiu)
|
||||
- Fix reconnect loop issues on iOS17 (William Casarin)
|
||||
- Fix some more thread jankiness (William Casarin)
|
||||
- Fix spelling of Nostr to use Titlecase instead of lowercase (Terry Yiu)
|
||||
- Rename all usages of the term Post as a noun to Note to conform to the Nostr spec (Terry Yiu)
|
||||
- Fix text cutoff on login with npub (gladiusKatana)
|
||||
- Fix hangs due to video player (William Casarin)
|
||||
|
||||
|
||||
[1.5-5]: https://github.com/damus-io/damus/releases/tag/v1.5-5
|
||||
|
||||
## [1.5-2] - 2023-05-30
|
||||
|
||||
### Added
|
||||
|
||||
@@ -2236,7 +2236,7 @@
|
||||
CLANG_ENABLE_MODULES = YES;
|
||||
CODE_SIGN_ENTITLEMENTS = damus/damus.entitlements;
|
||||
CODE_SIGN_STYLE = Automatic;
|
||||
CURRENT_PROJECT_VERSION = 4;
|
||||
CURRENT_PROJECT_VERSION = 6;
|
||||
DEVELOPMENT_ASSET_PATHS = "\"damus/Preview Content\"";
|
||||
DEVELOPMENT_TEAM = XK7H4JAB3D;
|
||||
ENABLE_PREVIEWS = YES;
|
||||
@@ -2284,7 +2284,7 @@
|
||||
CLANG_ENABLE_MODULES = YES;
|
||||
CODE_SIGN_ENTITLEMENTS = damus/damus.entitlements;
|
||||
CODE_SIGN_STYLE = Automatic;
|
||||
CURRENT_PROJECT_VERSION = 4;
|
||||
CURRENT_PROJECT_VERSION = 6;
|
||||
DEVELOPMENT_ASSET_PATHS = "\"damus/Preview Content\"";
|
||||
DEVELOPMENT_TEAM = XK7H4JAB3D;
|
||||
ENABLE_PREVIEWS = YES;
|
||||
|
||||
@@ -310,13 +310,14 @@ struct ContentView: View {
|
||||
if selected_timeline == .search {
|
||||
Button(action: {
|
||||
//isFilterVisible.toggle()
|
||||
self.active_sheet = .filter
|
||||
present_sheet(.filter)
|
||||
}) {
|
||||
// checklist, checklist.checked, lisdt.bullet, list.bullet.circle, line.3.horizontal.decrease..., line.3.horizontail.decrease
|
||||
Label(NSLocalizedString("Filter", comment: "Button label text for filtering relay servers."), image: "filter")
|
||||
.foregroundColor(.gray)
|
||||
//.contentShape(Rectangle())
|
||||
}
|
||||
.buttonStyle(.plain)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -425,7 +425,7 @@ enum UrlType {
|
||||
case .image(let url):
|
||||
return url
|
||||
case .video:
|
||||
return url
|
||||
return nil
|
||||
}
|
||||
case .link:
|
||||
return nil
|
||||
|
||||
@@ -79,13 +79,27 @@ struct PostView: View {
|
||||
|
||||
post.enumerateAttributes(in: NSRange(location: 0, length: post.length), options: []) { attributes, range, stop in
|
||||
if let link = attributes[.link] as? String {
|
||||
post.replaceCharacters(in: range, with: link)
|
||||
let normalized_link: String
|
||||
if link.hasPrefix("damus:nostr:") {
|
||||
// Replace damus:nostr: URI prefix with nostr: since the former is for internal navigation and not meant to be posted.
|
||||
normalized_link = String(link.dropFirst(6))
|
||||
} else {
|
||||
normalized_link = link
|
||||
}
|
||||
|
||||
// Add zero-width space in case text preceding the mention is not a whitespace.
|
||||
// In the case where the character preceding the mention is a whitespace, the added zero-width space will be stripped out.
|
||||
post.replaceCharacters(in: range, with: "\u{200B}\(normalized_link)\u{200B}")
|
||||
}
|
||||
}
|
||||
|
||||
var content = self.post.string
|
||||
// If two zero-width spaces are next to each other, normalize it to just one zero-width space.
|
||||
.replacingOccurrences(of: "\u{200B}\u{200B}", with: "\u{200B}")
|
||||
// If zero-width space is next to an actual whitespace, remove the zero-width space.
|
||||
.replacingOccurrences(of: " \u{200B}", with: " ")
|
||||
.replacingOccurrences(of: "\u{200B} ", with: " ")
|
||||
.trimmingCharacters(in: CharacterSet.whitespacesAndNewlines)
|
||||
.replacingOccurrences(of: "\u{200B}", with: "") // these characters are added when adding mentions.
|
||||
|
||||
let imagesString = uploadedMedias.map { $0.uploadedURL.absoluteString }.joined(separator: " ")
|
||||
|
||||
|
||||
@@ -63,7 +63,8 @@ struct UserSearch: View {
|
||||
|
||||
let tagAttributedString = NSMutableAttributedString(string: tagString,
|
||||
attributes: [NSAttributedString.Key.font: UIFont.systemFont(ofSize: 18.0),
|
||||
NSAttributedString.Key.link: "nostr:\(pk)"])
|
||||
// Add damus: URI so that taps within the post creation view redirect internally within Damus instead of redirecting to a different Nostr client. The damus: prefix will be stripped out prior to sending the note to relays.
|
||||
NSAttributedString.Key.link: "damus:nostr:\(pk)"])
|
||||
tagAttributedString.removeAttribute(.link, range: NSRange(location: tagAttributedString.length - 2, length: 2))
|
||||
tagAttributedString.addAttributes([NSAttributedString.Key.foregroundColor: UIColor.label], range: NSRange(location: tagAttributedString.length - 2, length: 2))
|
||||
|
||||
|
||||
@@ -30,12 +30,10 @@ struct TimelineView: View {
|
||||
.redacted(reason: loading ? .placeholder : [])
|
||||
.shimmer(loading)
|
||||
.disabled(loading)
|
||||
/*
|
||||
.background(GeometryReader { proxy -> Color in
|
||||
handle_scroll_queue(proxy, queue: self.events)
|
||||
return Color.clear
|
||||
})
|
||||
*/
|
||||
}
|
||||
.buttonStyle(BorderlessButtonStyle())
|
||||
.coordinateSpace(name: "scroll")
|
||||
|
||||
Reference in New Issue
Block a user