/*!
 *
 * Copyright (c) 2021-2024 Diality Inc. - All Rights Reserved.
 * \copyright
 * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN
 * WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER.
 *
 * \file    DiagnosticsDialog.qml
 * \author  (last)      Dara Navaei
 * \date    (last)      05-Mar-2024
 * \author  (original)  Behrouz NematiPour
 * \date    (original)  11-May-2021
 *
 */

// Qt
import QtQuick 2.12

// Project
//  Qml imports
import "qrc:/globals"
import "qrc:/components"

/*!
 * \brief   Diagnostics is the screen
 */
ModalDialog { id: _root

    width           : Variables.applicationWidth
    height          : Variables.applicationHeight - 60

    DiagnosticsSwipe { id: _diagnosticsSwipe
        anchors.fill: parent
    }

    Rectangle {
        anchors.centerIn: _closeButton
        border.color    : Colors.white
        color           : Colors.transparent
        border.width    : Variables.borderWidth
        width           : _closeButton.width + 10
        height          : width
        radius          : width
    }

    CloseButton { id    : _closeButton
        anchors.left    : undefined
        anchors.right   : parent.right
        anchors.top     : undefined
        anchors.bottom  : parent.bottom
        anchors.margins : 10
        onClicked       : {
            _root.close()
            console.log("close clicked")
        }
    }

}
