From 2bd8d579e56c1373a4b8851d367ce80669b688a8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=A6=8C=EA=A6=AB=EA=A6=B6=EA=A6=8F=EA=A7=80=EA=A6=A6?= =?UTF-8?q?=EA=A6=BF=EA=A6=A7=EA=A6=AE=EA=A6=91=EA=A6=A9=EA=A6=AD=EA=A7=80?= Date: Thu, 30 Mar 2023 13:54:52 +0800 Subject: Header cart button --- Header.ui.qml | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) (limited to 'Header.ui.qml') diff --git a/Header.ui.qml b/Header.ui.qml index bf76de1..4cc507d 100644 --- a/Header.ui.qml +++ b/Header.ui.qml @@ -9,6 +9,7 @@ import "Label" as Lbl ToolBar { property alias logo: logo + property alias cart: cart property alias profile: profile property string imageSource: "https://eduport.webestica.com/assets/images/avatar/01.jpg" property alias menu: menu @@ -77,6 +78,50 @@ ToolBar { } } + ToolButton { + id: cart + padding: 0 + width: 40 + height: 40 + anchors { + right: profile.left + rightMargin: 12 + verticalCenter: parent.verticalCenter + } + layer { + enabled: true + effect: OpacityMask { + maskSource: Rectangle { + width: 40 + height: 40 + radius: 40 + } + } + } + contentItem: Item { + + Image { + anchors.centerIn: parent + source: "Bootstrap/icons/cart3.svg" + sourceSize.width: 18 + fillMode: Image.PreserveAspectFit + + ColorOverlay { + color: Eduport.bsGray900 + source: parent + anchors.fill: parent + } + } + } + background: Rectangle { + color: Eduport.bsLight + border { + color: Eduport.bsLight + width: 1 + } + } + } + ToolButton { id: profile padding: 0 -- cgit v1.2.3