package com.pixelized.desktop.lwa.utils.preview

import androidx.compose.foundation.layout.Box
import androidx.compose.foundation.layout.PaddingValues
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.padding
import androidx.compose.material.Surface
import androidx.compose.runtime.Composable
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import com.pixelized.desktop.lwa.ui.theme.LwaTheme

@Composable
fun ContentPreview(
    modifier: Modifier = Modifier,
    paddingValues: PaddingValues = PaddingValues(),
    content: @Composable () -> Unit,
) {
    LwaTheme {
        Surface {
            Box(
                modifier = Modifier
                    .fillMaxSize()
                    .padding(paddingValues = paddingValues)
                    .then(other = modifier),
                contentAlignment = Alignment.Center,
                content = { content() },
            )
        }
    }
}