Skip to content

Commit

Permalink
Merge branch 'main' into hashtags
Browse files Browse the repository at this point in the history
# Conflicts:
#	CHANGELOG.md
  • Loading branch information
joshuatbrown committed Dec 3, 2024
2 parents 72bce96 + bf0ef24 commit c12a6e2
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 21 deletions.
6 changes: 4 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,18 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Release Notes
- Nos now publishes the hashtags it finds in your note when you post. This means it works the way you’ve always expected it to work. [#44](https://github.com/verse-pbc/issues/issues/44)
- Fixed galleries expanding past the width of the screen when there are lots of links or images. [#24](https://github.com/verse-pbc/issues/issues/24)
- Added support for user setting and displaying pronouns.
- Added display of website urls for user profiles.
- Updated note header UI to make it more readable. [#23](https://github.com/verse-pbc/issues/issues/23)
- Fixed galleries expanding past the width of the screen when there are lots of links or images. [#24](https://github.com/verse-pbc/issues/issues/24)
- Fix quoted note composer does not expand to fit mention. [#25](https://github.com/verse-pbc/issues/issues/25)

## [1.0.2] - 2024-11-26Z

### Release Notes
- Fix typo in minimum age warning
- Fix crash when tapping Post button on macOS. [#1687](https://github.com/planetary-social/nos/issues/1687)
- Fix tapping follower notification not opening follower profile. [#11](https://github.com/verse-pbc/issues/issues/11)
- Adjusted note header UI to make it more readable. [#23](https://github.com/verse-pbc/issues/issues/23)

### Internal Changes
- minor strings simplifications
Expand Down
3 changes: 3 additions & 0 deletions Nos/Controller/NoteEditorController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,9 @@ import UIKit
textView.attributedText = attributedString
textView.selectedRange.location = range.location + link.length
isEmpty = false

// Update the textview height after inserting text
updateIntrinsicHeight(view: textView)
}

/// Takes the same arguments as `textView(_:shouldChangeTextIn:replacementText:)` and detects the case where the
Expand Down
25 changes: 6 additions & 19 deletions Nos/Views/Components/Media/GalleryView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -185,31 +185,18 @@ fileprivate struct GalleryIndexView: View {
/// Calculates the scale factor for a circle at a given index.
///
/// - Parameter index: The index of the page to evaluate.
/// - Returns: A scale factor based on the distance from `currentIndex`.
/// - Returns: A scale factor based on whether it's the current index, and if not, whether it's on the edge.
private func scaleFor(_ index: Int) -> CGFloat {
// Show all circles at full size if there are 6 or fewer pages
if numberOfPages <= maxNumberOfCircles {
return 1.0
}

if index == currentIndex {
return 1.0
}
if displayRange.lowerBound > 0 {
if index == displayRange.lowerBound {
return 0.5
} else if index == displayRange.lowerBound + 1 {
return 0.75
}
if displayRange.lowerBound > 0 && index == displayRange.lowerBound {
return 0.5
}
if displayRange.upperBound < numberOfPages - 1 {
if index == displayRange.upperBound {
return 0.5
} else if index == displayRange.upperBound - 1 {
return 0.75
}
if displayRange.upperBound < numberOfPages - 1 && index == displayRange.upperBound {
return 0.5
}
return 1.0
return 0.75
}
}

Expand Down

0 comments on commit c12a6e2

Please sign in to comment.