1
0
Fork 0
mirror of https://github.com/anyproto/anytype-kotlin.git synced 2025-06-11 18:20:25 +09:00

Tech | Fix pack for 0.5.3 (#2101)

This commit is contained in:
Evgenii Kozlov 2022-02-10 16:40:42 +03:00 committed by GitHub
parent 21ed027f5c
commit 89a743d721
Signed by: github
GPG key ID: 4AEE18F83AFDEB23
8 changed files with 27 additions and 17 deletions

View file

@ -14,6 +14,7 @@
* Editor | Issues related to drag & drop sensitivity (#2068)
* Editor | Incorrect numbers in numbered lists when there are nested lists or blocks are grouped by sections (#2072)
* Editor | Progress bar and text should not overlap when a link-to-object block is in loading state (#2098)
* Dashboard | Removal from favorites is not synced correctly (#2075)
* Sets | Enabled auto-correct when setting name for a new object (#2067)
* Search | Optimized object search (#2095)

View file

@ -42,7 +42,13 @@ class SplashFragment : BaseFragment(R.layout.fragment_splash) {
showVersion()
viewLifecycleOwner.lifecycleScope.launch {
viewLifecycleOwner.repeatOnLifecycle(Lifecycle.State.STARTED) {
vm.commands.collect { observe(it) }
vm.commands.collect {
try {
observe(it)
} catch (e: Exception) {
toast(e.message ?: resources.getString(R.string.unknown_error))
}
}
}
}
}

View file

@ -52,7 +52,10 @@ class GalleryViewDefaultTitleIcon @JvmOverloads constructor(
ivIconEmoji.gone()
ivIconImage.setImageDrawable(null)
ivIconImage.gone()
tvAvatar.text = icon.name.first().toString()
tvAvatar.text = if (icon.name.isNotEmpty())
icon.name.first().toString()
else
resources.getString(R.string.u)
tvAvatar.visible()
}
is ObjectIcon.Task -> {

View file

@ -5,10 +5,10 @@
android:viewportHeight="13">
<path
android:pathData="M1.5,5.5L8.5,5.5A1.5,1.5 0,0 1,10 7L10,11.5A1.5,1.5 0,0 1,8.5 13L1.5,13A1.5,1.5 0,0 1,0 11.5L0,7A1.5,1.5 0,0 1,1.5 5.5z"
android:fillColor="#ABA99B"/>
android:fillColor="@color/glyph_active"/>
<path
android:pathData="M2.125,3.5C2.125,1.9122 3.4122,0.625 5,0.625C6.5878,0.625 7.875,1.9122 7.875,3.5V6.875H2.125V3.5Z"
android:strokeWidth="1.25"
android:fillColor="#00000000"
android:strokeColor="#ABA99B"/>
android:strokeColor="@color/glyph_active"/>
</vector>

View file

@ -5,13 +5,13 @@
android:viewportHeight="44">
<path
android:pathData="M8.75,10.25L35.25,10.25A0.75,0.75 0,0 1,36 11L36,11A0.75,0.75 0,0 1,35.25 11.75L8.75,11.75A0.75,0.75 0,0 1,8 11L8,11A0.75,0.75 0,0 1,8.75 10.25z"
android:fillColor="#ABA99B"/>
android:fillColor="@color/glyph_active"/>
<path
android:pathData="M8.75,32.25L35.25,32.25A0.75,0.75 0,0 1,36 33L36,33A0.75,0.75 0,0 1,35.25 33.75L8.75,33.75A0.75,0.75 0,0 1,8 33L8,33A0.75,0.75 0,0 1,8.75 32.25z"
android:fillColor="#ABA99B"/>
android:fillColor="@color/glyph_active"/>
<path
android:pathData="M11,15.25L33,15.25A2.75,2.75 0,0 1,35.75 18L35.75,26A2.75,2.75 0,0 1,33 28.75L11,28.75A2.75,2.75 0,0 1,8.25 26L8.25,18A2.75,2.75 0,0 1,11 15.25z"
android:strokeWidth="0.5"
android:fillColor="#00000000"
android:strokeColor="#ABA99B"/>
android:strokeColor="@color/glyph_active"/>
</vector>

View file

@ -5,14 +5,14 @@
android:viewportHeight="40">
<path
android:pathData="M6.75,9.25L33.25,9.25A0.75,0.75 0,0 1,34 10L34,10A0.75,0.75 0,0 1,33.25 10.75L6.75,10.75A0.75,0.75 0,0 1,6 10L6,10A0.75,0.75 0,0 1,6.75 9.25z"
android:fillColor="#ABA99B"/>
android:fillColor="@color/glyph_active"/>
<path
android:pathData="M13.75,19.25L33.25,19.25A0.75,0.75 0,0 1,34 20L34,20A0.75,0.75 0,0 1,33.25 20.75L13.75,20.75A0.75,0.75 0,0 1,13 20L13,20A0.75,0.75 0,0 1,13.75 19.25z"
android:fillColor="#ABA99B"/>
android:fillColor="@color/glyph_active"/>
<path
android:pathData="M7,18L9,18A1,1 0,0 1,10 19L10,21A1,1 0,0 1,9 22L7,22A1,1 0,0 1,6 21L6,19A1,1 0,0 1,7 18z"
android:fillColor="#ABA99B"/>
android:fillColor="@color/glyph_active"/>
<path
android:pathData="M6.75,29.25L33.25,29.25A0.75,0.75 0,0 1,34 30L34,30A0.75,0.75 0,0 1,33.25 30.75L6.75,30.75A0.75,0.75 0,0 1,6 30L6,30A0.75,0.75 0,0 1,6.75 29.25z"
android:fillColor="#ABA99B"/>
android:fillColor="@color/glyph_active"/>
</vector>

View file

@ -477,6 +477,7 @@
<string name="description">Description</string>
<string name="preview_layout">Preview layout</string>
<string name="unknown">Unknown</string>
<string name="unknown_error">Unknown error</string>
<string name="bookmark">Bookmark</string>

View file

@ -122,12 +122,11 @@ class HomeDashboardViewModel(
viewModelScope.launch {
getProfile.observe(
subscription = Subscriptions.SUBSCRIPTION_PROFILE,
keys = listOf(
Relations.ID,
Relations.NAME,
Relations.ICON_IMAGE
)
).collect {
keys = listOf(Relations.ID, Relations.NAME, Relations.ICON_IMAGE)
).catch {
Timber.e(it, "Error while observing profile on dashboard")
toast("Could not load profile: ${it.message ?: "Unknown error"}")
}.collectLatest {
profile.value = ViewState.Success(it)
}
}