-
This commit is contained in:
20
ui/components/separator.slint
Normal file
20
ui/components/separator.slint
Normal file
@@ -0,0 +1,20 @@
|
||||
import { Theme } from "../theme/theme.slint";
|
||||
|
||||
export enum Orientation {
|
||||
horizontal,
|
||||
vertical,
|
||||
}
|
||||
|
||||
export component Separator {
|
||||
in property <Orientation> orientation: Orientation.horizontal;
|
||||
|
||||
if orientation == Orientation.horizontal: Rectangle {
|
||||
height: 1px;
|
||||
background: Theme.colors.border;
|
||||
}
|
||||
|
||||
if orientation == Orientation.vertical: Rectangle {
|
||||
width: 1px;
|
||||
background: Theme.colors.border;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user