temporal potentially working variant (bot not building
This commit is contained in:
features
auth
client
common
client
src
jsMain
kotlin
dev
inmo
postssystem
features
common
common
content
binary
client
src
jsMain
kotlin
dev
inmo
postssystem
features
content
binary
client
src
jsMain
kotlin
dev
inmo
postssystem
features
content
client
text
client
src
jsMain
kotlin
dev
inmo
postssystem
features
content
text
posts
common
src
commonMain
kotlin
dev
inmo
postssystem
features
posts
common
roles
client
src
commonMain
kotlin
dev
inmo
postssystem
features
services/posts/client/src
commonMain
kotlin
dev
inmo
postssystem
services
jsMain
kotlin
dev
inmo
postssystem
services
posts
client
@ -1,12 +1,15 @@
|
||||
package dev.inmo.postssystem.features.content.binary.client
|
||||
|
||||
import androidx.compose.runtime.*
|
||||
import dev.inmo.jsuikit.elements.DefaultButton
|
||||
import dev.inmo.jsuikit.elements.*
|
||||
import dev.inmo.jsuikit.modifiers.UIKitWidth
|
||||
import dev.inmo.micro_utils.common.selectFile
|
||||
import dev.inmo.micro_utils.mime_types.KnownMimeTypes
|
||||
import dev.inmo.postssystem.features.common.common.*
|
||||
import dev.inmo.postssystem.features.content.client.ContentClientProvider
|
||||
import dev.inmo.postssystem.features.content.common.*
|
||||
import org.jetbrains.compose.web.dom.Img
|
||||
import org.jetbrains.compose.web.dom.Text
|
||||
import org.koin.core.module.Module
|
||||
|
||||
object LoadingClientModule : ModuleLoader {
|
||||
@ -41,4 +44,23 @@ object BinaryContentClientProvider : ContentClientProvider {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Composable
|
||||
override fun renderPreview(content: Content): Boolean {
|
||||
if (content is BinaryContent) {
|
||||
Tile {
|
||||
Card(
|
||||
header = {
|
||||
CardTitle {
|
||||
Text(content.filename.name)
|
||||
}
|
||||
}
|
||||
) {}
|
||||
}
|
||||
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user