$listitem-color: dynamic($dataitem-color);
$listitem-hovered-color: dynamic($dataitem-hovered-color);
$listitem-selected-color: dynamic($dataitem-selected-color);
$listitem-pressed-color: dynamic($dataitem-pressed-color);
$listitem-pinned-color: dynamic(null);
$listitem-background-color: dynamic($dataitem-background-color);
$listitem-alt-background-color: dynamic($dataitem-alt-background-color);
$listitem-hovered-background-color: dynamic($dataitem-hovered-background-color);
$listitem-selected-background-color: dynamic($dataitem-selected-background-color);
$listitem-pressed-background-color: dynamic($dataitem-pressed-background-color);
$listitem-pinned-background-color: dynamic(null);
$listitem-border-width: dynamic(1px 0);
$listitem-border-style: dynamic(solid);
$listitem-border-color: dynamic($neutral-highlight-color);
$listitem-hovered-border-color: dynamic($listitem-hovered-background-color);
$listitem-selected-border-color: dynamic($listitem-selected-background-color);
$listitem-pressed-border-color: dynamic($listitem-pressed-background-color);
$listitem-pinned-border-color: dynamic(null);
$listitem-focused-outline-width: dynamic($dataitem-focused-outline-width);
$listitem-focused-outline-style: dynamic($dataitem-focused-outline-style);
$listitem-focused-outline-color: dynamic($dataitem-focused-outline-color);
$listitem-focused-outline-offset: dynamic($dataitem-focused-outline-offset);
$listitem-pinned-box-shadow: dynamic(0 2px 4px 0 rgba(0, 0, 0, .2));
$listitem-pinned-bottom-box-shadow: dynamic(invert-shadow($listitem-pinned-box-shadow, y));
$listitem-font-weight: dynamic($dataitem-font-weight);
$listitem-font-size: dynamic($dataitem-font-size);
$listitem-font-size-big: dynamic($dataitem-font-size-big);
$listitem-line-height: dynamic($dataitem-line-height);
$listitem-line-height-big: dynamic($dataitem-line-height-big);
$listitem-font-family: dynamic($dataitem-font-family);
$listitem-padding: dynamic(4px 8px);
$listitem-padding-big: dynamic(7px 15px);
@mixin listitem-ui(
$ui: null,
$xtype: listitem,
$color: null,
$hovered-color: null,
$selected-color: null,
$pressed-color: null,
$pinned-color: null,
$background-color: null,
$alt-background-color: null,
$hovered-background-color: null,
$selected-background-color: null,
$pressed-background-color: null,
$pinned-background-color: null,
$border-width: null,
$border-style: null,
$border-color: null,
$hovered-border-color: null,
$selected-border-color: null,
$pressed-border-color: null,
$pinned-border-color: null,
$focused-outline-width: null,
$focused-outline-style: null,
$focused-outline-color: null,
$focused-outline-offset: null,
$pinned-box-shadow: null,
$pinned-bottom-box-shadow: null,
$font-weight: null,
$font-size: null,
$font-size-big: null,
$line-height: null,
$line-height-big: null,
$font-family: null,
$padding: null,
$padding-big: null
) {
$ui-suffix: ui-suffix($ui);
$arguments: intersect-arguments(listitem-ui, listitem-base);
.#{$prefix}#{$xtype}#{$ui-suffix} {
@include listitem-base($arguments...);
@include font($font-weight, $font-size, $line-height, $font-family);
@if $enable-big {
.#{$prefix}big & {
font-size: $font-size-big;
line-height: $line-height-big;
}
}
&.#{$prefix}focused {
.#{$prefix}keyboard-mode & {
@include outline(
$width: $focused-outline-width,
$style: $focused-outline-style,
$color: $focused-outline-color,
$offset: $focused-outline-offset,
$border-width: $border-width
);
}
}
}
@include toolable-ui(
$ui: $ui,
$xtype: $xtype,
$padding: $padding,
$padding-big: $padding-big,
$anchor: inner-el
);
}
@mixin listitem-base(
$color: null,
$hovered-color: null,
$selected-color: null,
$pressed-color: null,
$pinned-color: null,
$background-color: null,
$alt-background-color: null,
$hovered-background-color: null,
$selected-background-color: null,
$pressed-background-color: null,
$pinned-background-color: null,
$border-width: null,
$border-style: null,
$border-color: null,
$hovered-border-color: null,
$selected-border-color: null,
$pressed-border-color: null,
$pinned-border-color: null,
$pinned-box-shadow: null,
$pinned-bottom-box-shadow: null
) {
color: $color;
background-color: $background-color;
@include border($border-width, $border-style, $border-color);
margin-bottom: -(bottom($border-width));
+ .#{$prefix}scrolldock-end {
margin-top: bottom($border-width)
}
&:first-child {
border-top-color: $background-color;
}
&.#{$prefix}odd {
background-color: $alt-background-color;
}
&.#{$prefix}hovered {
background-color: $hovered-background-color;
color: $hovered-color;
border-color: $hovered-border-color;
}
&.#{$prefix}selected {
.#{$prefix}show-selection > & {
background-color: $selected-background-color;
color: $selected-color;
border-color: $selected-border-color;
}
}
&.#{$prefix}pressed {
background-color: $pressed-background-color;
color: $pressed-color;
border-color: $pressed-border-color;
}
&.#{$prefix}pinned {
background-color: $pinned-background-color;
color: $pinned-color;
border-color: $pinned-border-color;
box-shadow: $pinned-box-shadow;
}
&.#{$prefix}pinned-bottom {
box-shadow: $pinned-bottom-box-shadow;
}
}