package com.pixelized.biblib.utils.extention.modifier

import androidx.compose.foundation.clickable
import androidx.compose.runtime.Stable
import androidx.compose.ui.Modifier
import com.pixelized.biblib.utils.DisableInteractionSource

@Stable
fun Modifier.unclickable(
    disable: Boolean
): Modifier = if (disable) this.clickable(
    interactionSource = DisableInteractionSource(),
    indication = null,
    onClick = { },
) else this