borderStyle method
NikuButton
borderStyle({
- BorderStyle base = BorderStyle.solid,
- BorderStyle disabled = BorderStyle.solid,
- BorderStyle dragged = BorderStyle.solid,
- BorderStyle error = BorderStyle.solid,
- BorderStyle focused = BorderStyle.solid,
- BorderStyle hovered = BorderStyle.solid,
- BorderStyle pressed = BorderStyle.solid,
- BorderStyle selected = BorderStyle.solid,
Apply BorderStyle to border
Implementation
NikuButton borderStyle({
BorderStyle base = BorderStyle.solid,
BorderStyle disabled = BorderStyle.solid,
BorderStyle dragged = BorderStyle.solid,
BorderStyle error = BorderStyle.solid,
BorderStyle focused = BorderStyle.solid,
BorderStyle hovered = BorderStyle.solid,
BorderStyle pressed = BorderStyle.solid,
BorderStyle selected = BorderStyle.solid,
}) {
this._side.update(
base: BorderSide(
width: this._side.base?.width ?? 1,
style: base,
color: this._side.base?.color ?? Colors.black12,
),
disabled: BorderSide(
width: this._side.disabled?.width ?? 1,
style: disabled,
color: this._side.disabled?.color ?? Colors.black12,
),
dragged: BorderSide(
width: this._side.dragged?.width ?? 1,
style: dragged,
color: this._side.dragged?.color ?? Colors.black12,
),
error: BorderSide(
width: this._side.error?.width ?? 1,
style: error,
color: this._side.error?.color ?? Colors.black12,
),
focused: BorderSide(
width: this._side.focused?.width ?? 1,
style: focused,
color: this._side.focused?.color ?? Colors.black12,
),
hovered: BorderSide(
width: this._side.hovered?.width ?? 1,
style: hovered,
color: this._side.hovered?.color ?? Colors.black12,
),
pressed: BorderSide(
width: this._side.pressed?.width ?? 1,
style: pressed,
color: this._side.pressed?.color ?? Colors.black12,
),
selected: BorderSide(
width: this._side.selected?.width ?? 1,
style: selected,
color: this._side.selected?.color ?? Colors.black12,
),
);
return this;
}