mirror of
https://github.com/Aviortheking/Neo-Store.git
synced 2025-04-23 19:32:16 +00:00
Clean up
This commit is contained in:
parent
db08d75e7b
commit
513cf39969
@ -1,7 +1,12 @@
|
||||
import android.net.Uri
|
||||
import androidx.compose.foundation.layout.Column
|
||||
import androidx.compose.runtime.Composable
|
||||
import androidx.compose.ui.res.stringResource
|
||||
import androidx.compose.ui.tooling.preview.Preview
|
||||
import com.machiav3lli.fdroid.R
|
||||
import com.machiav3lli.fdroid.entity.LinkType
|
||||
import com.machiav3lli.fdroid.ui.compose.pages.app_detail.components.AntiFeaturesGrid
|
||||
import com.machiav3lli.fdroid.ui.compose.pages.app_detail.components.LinkItem
|
||||
import com.machiav3lli.fdroid.ui.compose.pages.app_detail.components.PermissionGrid
|
||||
import com.machiav3lli.fdroid.ui.compose.pages.app_detail.components.ReleaseItem
|
||||
import com.machiav3lli.fdroid.ui.compose.theme.AppTheme
|
||||
@ -27,6 +32,20 @@ fun CustomChipPrev() {
|
||||
}
|
||||
}
|
||||
|
||||
@Preview
|
||||
@Composable
|
||||
fun LinkItemPreview() {
|
||||
AppTheme(blackTheme = false) {
|
||||
LinkItem(
|
||||
linkType = LinkType(
|
||||
R.drawable.ic_email,
|
||||
stringResource(id = R.string.author_email),
|
||||
Uri.parse("neostore@neoapps.com")
|
||||
)
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
@Preview
|
||||
@Composable
|
||||
fun ChipGridPreview() {
|
||||
|
@ -17,13 +17,9 @@ import androidx.compose.ui.Alignment
|
||||
import androidx.compose.ui.Modifier
|
||||
import androidx.compose.ui.draw.clip
|
||||
import androidx.compose.ui.res.painterResource
|
||||
import androidx.compose.ui.res.stringResource
|
||||
import androidx.compose.ui.text.style.TextOverflow
|
||||
import androidx.compose.ui.tooling.preview.Preview
|
||||
import androidx.compose.ui.unit.dp
|
||||
import com.machiav3lli.fdroid.R
|
||||
import com.machiav3lli.fdroid.entity.LinkType
|
||||
import com.machiav3lli.fdroid.ui.compose.theme.AppTheme
|
||||
|
||||
@OptIn(ExperimentalFoundationApi::class)
|
||||
@Composable
|
||||
@ -71,16 +67,3 @@ fun LinkItem(
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Preview
|
||||
@Composable
|
||||
fun LinkItemPreview() {
|
||||
AppTheme(blackTheme = false) {
|
||||
LinkItem(
|
||||
linkType = LinkType(
|
||||
R.drawable.ic_email,
|
||||
stringResource(id = R.string.author_email),
|
||||
Uri.parse("neostore@neoapps.com"))
|
||||
)
|
||||
}
|
||||
}
|
@ -25,10 +25,6 @@ import androidx.compose.ui.unit.dp
|
||||
import com.machiav3lli.fdroid.R
|
||||
import de.charlex.compose.HtmlText
|
||||
|
||||
/*
|
||||
* Annotate String in this way https://stackoverflow.com/questions/65567412/jetpack-compose-text-hyperlink-some-section-of-the-text/69549929#69549929
|
||||
* TODO REMOVE usage of HtmlText
|
||||
* */
|
||||
@Composable
|
||||
fun HtmlTextBlock(
|
||||
modifier: Modifier = Modifier,
|
||||
|
@ -178,7 +178,7 @@ class AppSheetX() : FullscreenBottomSheetDialogFragment(), Callbacks {
|
||||
}
|
||||
viewModel.downloadState.value = state
|
||||
viewModel.updateActions()
|
||||
if (downloadState is DownloadService.State.Success && !rootInstallerEnabled) { // && isResumed
|
||||
if (downloadState is DownloadService.State.Success && !rootInstallerEnabled) { // && isResumed TODO unite root and normal install calls
|
||||
withContext(Dispatchers.Default) {
|
||||
AppInstaller.getInstance(context)?.defaultInstaller?.install(downloadState.release.cacheFileName)
|
||||
}
|
||||
|
@ -31,7 +31,7 @@
|
||||
<item name="colorPrimaryInverse">@color/md_theme_light_primaryInverse</item>
|
||||
<item name="android:statusBarColor">@color/md_theme_light_surface</item>
|
||||
<item name="android:navigationBarColor">@android:color/transparent</item>
|
||||
<item name="android:windowLightStatusBar" tools:targetApi="m">true</item>
|
||||
<item name="android:windowLightStatusBar">true</item>
|
||||
<item name="categoryChipStyle">@style/Theme.Chip.Category</item>
|
||||
|
||||
<item name="bottomSheetDialogTheme">@style/Theme.Design.BottomSheetDialog</item>
|
||||
|
Loading…
x
Reference in New Issue
Block a user