fix(Storybook): mock for DotherSide types added

Additionally `ui/imports/shared/views/chat/qmldir` fixed.

Closes: #7932
This commit is contained in:
Michał Cieślak 2022-10-17 16:30:35 +02:00 committed by Iuri Matias
parent 440d0a9017
commit de4ef7daf0
6 changed files with 17 additions and 6 deletions

View File

@ -20,7 +20,7 @@ find_package(
COMPONENTS Core Quick QuickControls2
REQUIRED)
file(GLOB_RECURSE QML_FILES "stubs/*.qml" "Storybook/*.qml" "../ui/StatusQ/*.qml" "../ui/app/*.qml")
file(GLOB_RECURSE QML_FILES "stubs/*.qml" "mocks/*.qml" "Storybook/*.qml" "../ui/StatusQ/*.qml" "../ui/app/*.qml")
file(GLOB_RECURSE JS_FILES "../ui/StatusQ/*.js" "../ui/app/*.js")
add_executable(

View File

@ -11,6 +11,9 @@ QtObject {
}
function getUniqueValuesFromModel(model, prop) {
if (!model)
return []
const values = []
for (let i = 0; i < model.count; i++)
values.push(model.get(i)[prop])

View File

@ -19,6 +19,7 @@ int main(int argc, char *argv[])
engine.addImportPath(SRC_DIR + QStringLiteral("/../ui/app"));
engine.addImportPath(SRC_DIR + QStringLiteral("/../ui/imports"));
engine.addImportPath(SRC_DIR + QStringLiteral("/stubs"));
engine.addImportPath(SRC_DIR + QStringLiteral("/mocks"));
const QUrl url(QStringLiteral("qrc:/main.qml"));
QObject::connect(&engine, &QQmlApplicationEngine::objectCreated,

View File

@ -0,0 +1,5 @@
import QtQuick 2.14
QtObject {
property var quickTextDocument
}

View File

@ -0,0 +1 @@
StatusSyntaxHighlighter 0.1 StatusSyntaxHighlighter.qml

View File

@ -1,10 +1,11 @@
AcceptTransactionView 1.0 AcceptTransactionView.qml
ChannelIdentifierView 1.0 ChannelIdentifierView.qml
ChatTextView 1.0 ChatTextView.qml
MessageView 1.0 MessageView.qml
TransactionBubbleView 1.0 TransactionBubbleView.qml
LinksMessageView 1.0 LinksMessageView.qml
InvitationBubbleView 1.0 InvitationBubbleView.qml
NormalMessageView 1.0 NormalMessageView.qml
CompactMessageView 1.0 CompactMessageView.qml
InvitationBubbleView 1.0 InvitationBubbleView.qml
LinksMessageView 1.0 LinksMessageView.qml
MessageContextMenuView 1.0 MessageContextMenuView.qml
MessageView 1.0 MessageView.qml
NormalMessageView 1.0 NormalMessageView.qml
ProfileHeaderContextMenuView 1.0 ProfileHeaderContextMenuView.qml
TransactionBubbleView 1.0 TransactionBubbleView.qml