Commit Graph

375 Commits

Author SHA1 Message Date
dependabot[bot] 411776b767 Bump agp from 8.12.1 to 8.12.2 (#230) 2025-08-31 10:23:46 +00:00
melod1n 8cb3ed8784 some improvements, new feature 2025-08-27 05:17:40 +03:00
melod1n 4677e484d9 move strings in core/ui module
disable generating android resources everywhere except core/ui module
replace UiR with R
2025-08-27 04:53:46 +03:00
melod1n 799ed820e3 feat: audio message preview 2025-08-26 09:36:55 +03:00
dependabot[bot] 3fd679e65d Bump actions/setup-java from 4 to 5 (#227) 2025-08-23 01:38:06 +00:00
dependabot[bot] 6b95deb7bf Bump agp from 8.12.0 to 8.12.1 (#226) 2025-08-19 21:36:23 +00:00
melod1n 47c1f623f0 Refactor: Introduce video message record mode
This commit refactors the `ActionMode` sealed class into an enum and adds a new `RECORD_VIDEO` state. This allows for distinct actions for recording audio and video messages.

Specifically, the following changes were made:
- Converted `ActionMode` from a sealed class to an enum.
- Added `RECORD_VIDEO` to `ActionMode`.
- Updated `MessagesHistoryInputBar` to:
    - Animate the action button icon change between record modes.
    - Remove the shake animation from emoji, attachment, and mic buttons.
- Updated `MessagesHistoryViewModel` to toggle between `RECORD_AUDIO` and `RECORD_VIDEO` when the action button is clicked in a record mode.
- Added support for displaying `VIDEO_MESSAGE` attachments in `Attachments.kt`, including an animated circular preview.
- Updated `MessageBubble` to render video messages without a background, similar to stickers.
- Added `image` property to `VkVideoMessageDomain` to hold the URL for the video message preview.
- Added a new drawable `rounded_photo_camera_24` for the video record button.
- Updated `VkVideoMessageData` to parse and provide the square preview image URL to the domain model.
2025-08-20 00:31:33 +03:00
melod1n 600aed40e7 Refactor: Make FullScreenDialog dismissible
This commit introduces a dismiss functionality to the `FullScreenDialog`.

The `FullScreenDialog` now accepts an `onDismiss` lambda parameter.
This `onDismiss` lambda is invoked when a dismiss request is made for the dialog.

In `PhotoViewScreen`, the `onDismiss` lambda passed to `FullScreenDialog` is now the `onDismiss` lambda received by the `PhotoViewScreen` itself.
2025-08-19 23:15:37 +03:00
melod1n 22e8a5c09e Prevent PhotoViewer share/copy while loading
This commit prevents the share and copy actions in the PhotoViewer
from being triggered if the content is still loading.
2025-08-19 22:58:13 +03:00
melod1n 252f6ec21e Refactor: Use Dialog for PhotoViewScreen
This commit refactors the PhotoViewScreen to be displayed as a Dialog instead of a separate navigation destination.

Key changes:
- Introduced `PhotoViewDialog` composable that wraps `PhotoViewRoute` in a `FullScreenDialog`.
- Modified `RootScreen` to use `PhotoViewDialog` for displaying images.
- Updated `PhotoViewViewModelImpl` to handle loading state and display a loader while downloading images.
- Made `Loader` and `ContainedLoader` colors configurable.
- Adjusted `PhotoViewScreen` UI:
    - Set background to translucent black.
    - Updated TopAppBar background color and icon tints.
    - Improved vertical drag gesture for dismissing the viewer.
- Made `VkUserData.LastSeen.platform` nullable.
- Removed unused navigation functions related to the old PhotoViewScreen.
2025-08-19 22:54:38 +03:00
melod1n 7e25bc3a8d Update target and compile SDK to 36
Bumps various dependencies:
- Haze from 1.6.9 to 1.6.10
- Kotlin from 2.2.0 to 2.2.10
- KSP from 2.2.0-2.0.2 to 2.2.10-2.0.2
- Compose BOM from 2025.07.01 to 2025.08.00
- Core KTX from 1.16.0 to 1.17.0
- Nanokt from 1.2.0 to 1.3.0
2025-08-17 07:19:39 +03:00
dependabot[bot] 7b0f6fe2a6 Bump actions/checkout from 4 to 5 (#220) 2025-08-17 04:07:36 +00:00
dependabot[bot] 6d5b09ef81 Bump haze from 1.6.8 to 1.6.9 (#218) 2025-08-08 22:14:19 +00:00
dependabot[bot] 268e0a8beb Bump agp from 8.11.1 to 8.12.0 (#219) 2025-08-08 22:14:15 +00:00
dependabot[bot] 9e67ad0834 Bump lifecycle from 2.9.1 to 2.9.2 (#213) 2025-07-31 19:49:49 +00:00
dependabot[bot] 34ea8ef944 Bump chucker from 4.1.0 to 4.2.0 (#211) 2025-07-31 19:49:34 +00:00
dependabot[bot] 3d0c310575 Bump haze from 1.6.7 to 1.6.8 (#212) 2025-07-31 19:49:28 +00:00
dependabot[bot] 602cf8f18b Bump androidx.compose:compose-bom-alpha from 2025.06.02 to 2025.07.01 (#217) 2025-07-31 19:49:24 +00:00
dependabot[bot] 1b3581fcfd Bump androidx.navigation:navigation-compose from 2.9.1 to 2.9.3 (#216) 2025-07-31 19:49:19 +00:00
dependabot[bot] 4b254d7d41 Bump agp from 8.11.0 to 8.11.1 (#210) 2025-07-14 09:27:25 +00:00
dependabot[bot] d98dca83f1 Bump haze from 1.6.6 to 1.6.7 (#209) 2025-07-09 17:54:25 +00:00
melod1n 9e6b079bf6 ability to import/export auth data and some refactoring 2025-07-09 17:29:51 +03:00
dependabot[bot] d2aaac68e2 Bump org.jetbrains.kotlinx:kotlinx-serialization-json (#202)
Bumps [org.jetbrains.kotlinx:kotlinx-serialization-json](https://github.com/Kotlin/kotlinx.serialization) from 1.8.1 to 1.9.0.
- [Release notes](https://github.com/Kotlin/kotlinx.serialization/releases)
- [Changelog](https://github.com/Kotlin/kotlinx.serialization/blob/master/CHANGELOG.md)
- [Commits](https://github.com/Kotlin/kotlinx.serialization/compare/v1.8.1...v1.9.0)

---
updated-dependencies:
- dependency-name: org.jetbrains.kotlinx:kotlinx-serialization-json
  dependency-version: 1.9.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-09 13:49:55 +03:00
dependabot[bot] ada9c13947 Bump androidx.navigation:navigation-compose from 2.9.0 to 2.9.1 (#206) 2025-07-09 10:48:11 +00:00
dependabot[bot] cd4c1d6d76 Bump haze from 1.6.4 to 1.6.6 (#203) 2025-07-09 08:43:00 +00:00
dependabot[bot] fab92d50d6 Bump androidx.compose:compose-bom-alpha from 2025.06.01 to 2025.06.02 (#205) 2025-07-09 08:42:52 +00:00
dependabot[bot] 9e4521c3a0 Bump com.squareup.okhttp3:logging-interceptor (#208) 2025-07-09 08:42:41 +00:00
melod1n 70b552412c Enhance PhotoViewer with share and open-in actions, improve reply UI
This commit introduces "Share" and "Open in..." actions to the `PhotoViewScreen`, allowing users to share images via other apps or open them in external viewers.

**Key changes:**

- **PhotoViewer:**
    - Added "Share" and "Open in..." options to the `PhotoViewScreen` dropdown menu.
    - `PhotoViewViewModel`:
        - Implemented `onShareClicked()` and `onOpenInClicked()` to handle these new actions.
        - Added `shareRequest` StateFlow to manage image sharing intents.
        - Introduced `downloadAndStoreImageToCache()` to download and cache images for sharing.
        - `onImageShared()` resets `shareRequest` after sharing.
    - Updated `TopBar` to include the new menu items.
    - Added string resources for "Open in…" and "Share".
- **Reply UI:**
    - `Reply.kt`: Title and summary text now use `TextOverflow.Ellipsis` to prevent long text from breaking the layout.
- **API Model:**
    - `MessagesResponse.kt`: Added `MessagesMarkAsImportantResponse` data class to handle the response for marking messages as important.
- **Data Layer:**
    - `MessagesRepositoryImpl`: Updated `markAsImportant` to correctly map the API response using `MessagesMarkAsImportantResponse`.
- **Minor:**
    - `README.md`: Updated feature checklist for external viewer.
    - `ApplicationModule.kt`: Added experimental Coil API opt-in.
2025-06-26 20:46:53 +03:00
dependabot[bot] a7307e7862 Bump agp from 8.10.1 to 8.11.0 (#197) 2025-06-26 16:54:50 +00:00
melod1n 60a30b9422 feat: Display stickers in messages (#200)
This commit introduces the ability to display stickers within message bubbles.

Key changes:
- `Attachments.kt`: Added handling for `AttachmentType.STICKER`. If an attachment type is unsupported, a placeholder text is now displayed.
- `Sticker.kt`: New composable created to render `VkStickerDomain` using `AsyncImage`.
- `MessageBubble.kt`:
    - Adjusted background alpha for sticker messages to make the bubble transparent.
    - Minor refactoring of `minDateContainerWidth` and `dateContainerWidth` initialization.
- `VkStickerDomain.kt`: Added `getUrl()` function to construct sticker image URLs, with options for specifying width and background.
2025-06-26 19:54:33 +03:00
melod1n 93d81f1e9e Refactor: Rename addTextContextMenuComponents to appendTextContextMenuComponents
This commit also updates the Compose BOM version to `2025.06.01`.
2025-06-25 09:36:00 +03:00
melod1n 5be101deec Refactor: Move versioning to build files, update dependencies
This commit moves the `minSdk`, `targetSdk`, `compileSdk`, `versionCode`, and `versionName` definitions from `gradle/libs.versions.toml` directly into the relevant build files (`app/build.gradle.kts` and convention plugins).

Additionally, the following dependencies were updated:
- Gradle wrapper from 8.12 to 8.14.2
- KSP from 2.1.21-2.0.2 to 2.2.0-2.0.2
- ModuleGraph from 2.8.0 to 2.9.0

The `fast-android-test` and `fast-jvm-library` plugin aliases were also commented out in `gradle/libs.versions.toml`.
2025-06-25 09:33:26 +03:00
melod1n 76dd1e2ce7 Reply attachment (#195) 2025-06-25 09:04:50 +03:00
dependabot[bot] 56683bea96 Bump kotlin from 2.1.21 to 2.2.0 (#194) 2025-06-24 11:46:37 +00:00
melod1n 3dae1fe101 Refactor: Introduce FullScreenContainedLoader and use rememberUpdatedState
This commit introduces `FullScreenContainedLoader` and replaces usages of `FullScreenLoader` where appropriate.

It also updates several composables to use `rememberUpdatedState` for lambda parameters to ensure the latest versions are used.

Additionally, the following changes are included:
- Add a setting to show/hide the attachment button in the chat input bar.
- Implement navigation to `PhotoViewScreen` when a photo attachment is clicked in a message.
- Add "Copy link" and "Copy image" actions to `PhotoViewScreen`.
- Remove unused settings and their corresponding logic from `SettingsViewModel` and `UserSettings`.
2025-06-24 14:44:51 +03:00
melod1n c1e76e1c60 improvements 2025-06-23 20:49:14 +03:00
melod1n c14ee45d53 improvements 2025-06-23 19:50:28 +03:00
melod1n 9d4e3f50ea split MessagesHistoryScreen.kt in separated composables.
Added "regular" to text field in messages history screen - for clearing formatting
2025-06-23 17:36:02 +03:00
melod1n 17b5c944ac m3 expressive theme and full screen loader
revert pre-loading non-main screens
2025-06-20 21:55:17 +03:00
melod1n 5aa1f21183 switch to compose-bom-alpha 2025-06-20 21:25:17 +03:00
dependabot[bot] a916dc649c Bump room from 2.7.1 to 2.7.2 (#191) 2025-06-20 16:09:23 +00:00
dependabot[bot] 7e0b9d49ba Bump androidx.compose:compose-bom from 2025.06.00 to 2025.06.01 (#192) 2025-06-20 16:09:18 +00:00
dependabot[bot] d525a1573c Bump koin from 4.0.4 to 4.1.0 (#189) 2025-06-16 22:36:35 +00:00
dependabot[bot] 091a88dd45 Bump ksp from 2.1.21-2.0.1 to 2.1.21-2.0.2 (#190) 2025-06-16 22:36:31 +00:00
melod1n a3a970115a Bump deps 2025-06-09 13:29:36 +03:00
dependabot[bot] e36c1ea0ca Bump haze from 1.6.2 to 1.6.3 (#185) 2025-06-03 00:10:25 +00:00
dependabot[bot] f2437f67cb Bump com.squareup.okhttp3:logging-interceptor (#184) 2025-05-30 08:10:27 +00:00
dependabot[bot] 049bcfd2da Bump agp from 8.10.0 to 8.10.1 (#183) 2025-05-30 08:10:21 +00:00
dependabot[bot] d5e24214ce Bump haze from 1.6.1 to 1.6.2 (#182) 2025-05-21 18:48:06 +00:00
dependabot[bot] c94e128e64 Bump androidx.compose:compose-bom from 2025.05.00 to 2025.05.01 (#181) 2025-05-20 21:24:10 +00:00