SheetContent constructor
SheetContent({
- ScanbotColor? sheetColor,
- ScanbotColor? dividerColor,
- bool manualCountChangeEnabled = true,
- ScanbotColor? manualCountOutlineColor,
- ScanbotColor? manualCountChangeColor,
- StyledText? title,
- ButtonConfiguration? clearAllButton,
- StyledText? barcodeItemTitle,
- StyledText? barcodeItemSubtitle,
- bool barcodeItemImageVisible = true,
- ButtonConfiguration? submitButton,
- ButtonConfiguration? startScanningButton,
- StyledText? placeholderTitle,
- StyledText? placeholderSubtitle,
- ScanbotColor? placeholderIconBackground,
- IconStyle? placeholderIcon,
- SwipeToDelete? swipeToDelete,
Implementation
SheetContent({
ScanbotColor? sheetColor,
ScanbotColor? dividerColor,
this.manualCountChangeEnabled = true,
ScanbotColor? manualCountOutlineColor,
ScanbotColor? manualCountChangeColor,
StyledText? title,
ButtonConfiguration? clearAllButton,
StyledText? barcodeItemTitle,
StyledText? barcodeItemSubtitle,
this.barcodeItemImageVisible = true,
ButtonConfiguration? submitButton,
ButtonConfiguration? startScanningButton,
StyledText? placeholderTitle,
StyledText? placeholderSubtitle,
ScanbotColor? placeholderIconBackground,
IconStyle? placeholderIcon,
SwipeToDelete? swipeToDelete,
}) : sheetColor = sheetColor ?? ScanbotColor("?sbColorSurface"),
dividerColor = dividerColor ?? ScanbotColor("?sbColorOutline"),
manualCountOutlineColor =
manualCountOutlineColor ?? ScanbotColor("?sbColorOutline"),
manualCountChangeColor =
manualCountChangeColor ?? ScanbotColor("?sbColorPrimary"),
title = title ??
StyledText(
text: "%d items", color: ScanbotColor("?sbColorOnSurface")),
clearAllButton = clearAllButton ??
ButtonConfiguration(
visible: true,
text: "Clear all",
background: BackgroundStyle(
strokeColor: ScanbotColor("#00000000"),
fillColor: ScanbotColor("#00000000"),
strokeWidth: 1.0),
foreground: ForegroundStyle(
iconVisible: false,
color: ScanbotColor("?sbColorOnSurface"),
useShadow: false)),
barcodeItemTitle = barcodeItemTitle ??
StyledText(
visible: true,
text: "BARCODE_TITLE",
color: ScanbotColor("?sbColorOnSurface"),
useShadow: false),
barcodeItemSubtitle = barcodeItemSubtitle ??
StyledText(
text: "BARCODE_SUBTITLE",
color: ScanbotColor("?sbColorOnSurfaceVariant")),
submitButton = submitButton ??
ButtonConfiguration(
visible: true,
text: "Submit",
background: BackgroundStyle(
strokeColor: ScanbotColor("#00000000"),
fillColor: ScanbotColor("#00000000"),
strokeWidth: 1.0),
foreground: ForegroundStyle(
iconVisible: false,
color: ScanbotColor("?sbColorOnSurface"),
useShadow: false)),
startScanningButton = startScanningButton ??
ButtonConfiguration(
visible: true,
text: "Start scanning",
background: BackgroundStyle(
strokeColor: ScanbotColor("?sbColorPrimary"),
fillColor: ScanbotColor("?sbColorPrimary"),
strokeWidth: 1.0),
foreground: ForegroundStyle(
iconVisible: true,
color: ScanbotColor("?sbColorOnPrimary"),
useShadow: false)),
placeholderTitle = placeholderTitle ??
StyledText(
text: "No barcodes here!",
color: ScanbotColor("?sbColorOnSurface")),
placeholderSubtitle = placeholderSubtitle ??
StyledText(
text:
"The barcode list is currently empty. Close this sheet and scan your items to add them.",
color: ScanbotColor("?sbColorOnSurfaceVariant")),
placeholderIconBackground =
placeholderIconBackground ?? ScanbotColor("?sbColorOutline"),
placeholderIcon = placeholderIcon ??
IconStyle(visible: true, color: ScanbotColor("?sbColorOnSurface")),
swipeToDelete = swipeToDelete ??
SwipeToDelete(
enabled: true,
backgroundColor: ScanbotColor("?sbColorNegative"),
iconColor: ScanbotColor("?sbColorOnPrimary"));