2023-03-30 21:52:55 +08:00
|
|
|
|
import QtQuick
|
|
|
|
|
import FluentUI
|
2023-03-10 18:08:32 +08:00
|
|
|
|
|
|
|
|
|
Rectangle {
|
|
|
|
|
|
|
|
|
|
default property alias content: container.data
|
|
|
|
|
property int paddings : 0
|
|
|
|
|
property int leftPadding : 0
|
|
|
|
|
property int rightPadding : 0
|
|
|
|
|
property int topPadding : 0
|
|
|
|
|
property int bottomPadding : 0
|
|
|
|
|
|
2023-03-27 18:24:35 +08:00
|
|
|
|
radius: 4
|
2023-03-28 21:37:10 +08:00
|
|
|
|
color: FluTheme.dark ? Qt.rgba(39/255,39/255,39/255,1) : Qt.rgba(251/255,251/255,253/255,1)
|
|
|
|
|
border.color: FluTheme.dark ? Qt.rgba(45/255,45/255,45/255,1) : Qt.rgba(226/255,229/255,234/255,1)
|
2023-03-27 18:24:35 +08:00
|
|
|
|
border.width: 1
|
|
|
|
|
implicitHeight: height
|
|
|
|
|
implicitWidth: width
|
|
|
|
|
|
2023-03-10 18:08:32 +08:00
|
|
|
|
Item {
|
|
|
|
|
id: container
|
|
|
|
|
anchors.fill: parent
|
|
|
|
|
anchors.leftMargin: Math.max(paddings,leftPadding)
|
|
|
|
|
anchors.rightMargin: Math.max(paddings,rightPadding)
|
|
|
|
|
anchors.topMargin: Math.max(paddings,topPadding)
|
|
|
|
|
anchors.bottomMargin: Math.max(paddings,bottomPadding)
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|