status-desktop/storybook
Noelia 0ab8a62896 feat(Communities): Communities folder reorganization
- Renamed main `CommunitiesPortal` folder to `Communities`.
- Created new `layouts` folder.
- Moved layout files from chat to communities.
- Created new `helpers` folder.
- Moved helpers files from chat to communities.
- Moved `controls/community` files from chat to communities `controls`.
- Moved `panels/communities` files from chat to communities `panels`.
- Moved `popups/community` files from chat to communities `popups`.
- Moved `views/community` files from chat to communities `views`.
- Moved `CommunityBanner` file from shared to `Communities/controls`. Only used in communities context.
- Moved `CommunitySettingsView` and `CommunityColumnView` files from chat to communities `views`.
- Moved `PermissionsStore.qml` file to `shared/stores`.
- Updated imports.
- Updated storybook.

Part of #6204
2023-06-28 14:28:47 +02:00
..
pages feat(Communities): Communities folder reorganization 2023-06-28 14:28:47 +02:00
qmlTests fix(StatusQ): StatusQ is QML module (#10207) 2023-04-14 11:18:56 +03:00
src feat(Communities): Communities folder reorganization 2023-06-28 14:28:47 +02:00
stubs feat(Communities): Communities folder reorganization 2023-06-28 14:28:47 +02:00
tests feat(Storybook): Possibility to modify Figma links directly from the app 2022-11-29 22:28:57 +01:00
CMakeLists.txt fix(MessageContextMenu): Cleanup. Separate menu for profile. (#10729) 2023-05-19 19:07:50 +03:00
PagesModel.qml feat(@desktop/wallet): Wallet accounts - Account List 2023-06-23 16:55:36 +02:00
README.md chore(Storybook): Update Readme to point CMakeLists.txt as the main way to build instead of WebAssembly 2023-03-01 13:48:31 +01:00
StoryBook.pro move qzxing and SortFilterProxyModel to vendor folder 2023-03-23 12:09:19 +01:00
cachecleaner.cpp feat(Storybook): Hot reloading for pages 2022-10-20 20:34:35 +02:00
cachecleaner.h feat(Storybook): Hot reloading for pages 2022-10-20 20:34:35 +02:00
directorieswatcher.cpp chore(Storybook): add pages for InviteFriendsToCommunityPopup and related components 2022-10-25 17:03:44 +02:00
directorieswatcher.h feat(Storybook): Hot reloading for pages 2022-10-20 20:34:35 +02:00
figma.json feat(Settings/Communities): implement new communities list 2023-06-23 16:48:26 +02:00
figmadecoratormodel.cpp feat(Storybook): Figma links loaded from json file 2022-11-29 11:30:13 +01:00
figmadecoratormodel.h fix(storybook): add missing <optional> include 2022-12-05 13:47:40 +01:00
figmaio.cpp feat(Storybook): Possibility to modify Figma links directly from the app 2022-11-29 22:28:57 +01:00
figmaio.h feat(Storybook): Possibility to modify Figma links directly from the app 2022-11-29 22:28:57 +01:00
figmalinks.cpp feat(Storybook): Figma links loaded from json file 2022-11-29 11:30:13 +01:00
figmalinks.h feat(Storybook): Figma links loaded from json file 2022-11-29 11:30:13 +01:00
figmalinksmodel.cpp feat(Storybook): Figma links loaded from json file 2022-11-29 11:30:13 +01:00
figmalinksmodel.h feat(Storybook): Figma links loaded from json file 2022-11-29 11:30:13 +01:00
figmalinkssource.cpp feat(Storybook): Possibility to modify Figma links directly from the app 2022-11-29 22:28:57 +01:00
figmalinkssource.h feat(Storybook): Possibility to modify Figma links directly from the app 2022-11-29 22:28:57 +01:00
main.cpp feat(@desktop/wallet): Added transaction address component (#10665) 2023-05-19 11:51:47 +02:00
main.qml fix(Storybook): reenable inspection tool for popup pages 2023-06-17 00:58:57 +02:00
modelutils.cpp feat(Storybook): Figma links loaded from json file 2022-11-29 11:30:13 +01:00
modelutils.h feat(Storybook): Figma links loaded from json file 2022-11-29 11:30:13 +01:00
sectionsdecoratormodel.cpp feat(Storybook): Figma links loaded from json file 2022-11-29 11:30:13 +01:00
sectionsdecoratormodel.h feat(Storybook): Figma links loaded from json file 2022-11-29 11:30:13 +01:00

README.md

Building Storybook

For regular usage of Storybook it's enough to open status-desktop/storybook/CMakeLists.txt in QtCreator. Please do not use StoryBook.pro which is intended for WebAssembly builds. Please make sure that selected run target is Storybook.

Building Storybook with Webassembly and Qt 5.14

Configuring the environment

Install Emscripten v1.38.27

# Get the emsdk repo
git clone https://github.com/emscripten-core/emsdk.git

#go to emsdk folder
cd emsdk

#install Emscripten v1.38.27
./emsdk install emscripten-1.38.27

#activate emscripten-1.38.27
./emsdk activate emscripten-1.38.27

#install Fastcomp backend
./emsdk install fastcomp-clang-tag-e1.38.27-64bit

#activate Fastcomp backend
./emsdk activate fastcomp-clang-tag-e1.38.27-64bit

#add emsdk tools to env variables
#this can be done by following instructions received from previous activate command
#there are two options:

#1. Configure the env variables for the current shell only:
source emsdk_env.sh

#2. Configure the env variables using the shell startup script:
echo 'source "[path to emsdk folder]/emsdk_env.sh"' >> $HOME/.zprofile

#WARNING: this will configure the environment to use the emsdk compiler
#Ex:"which clang" command will now point to the emscripten clang instead of the system clang
#to disable the env configuration comment the source command added earlier in ~/.zprofile

#check environment
#python needs to be installed. The emsdk scripts state that it should work with pyton 2 and 3
#make sure python command can be resolved
which python
em++ --version
emcc --version
#clang should point to fastcomp-clang-tag-e1.38.27-64bit
which clang
which clang++

More documentation: https://emscripten.org/docs/getting_started/downloads.html

Configure QtCreator (optional)

Newer versions of QtCreator won't support Qt5.14 with Webassembly. Latest version found to support Qt5.14 with WebAssembly is 4.14.2 Download: https://download.qt.io/archive/qtcreator/4.14/

Adding the Emscripten compilers (emcc and em++) Details here: https://doc.qt.io/qtcreator/creator-tool-chains.html

Adding Qt version 5.14: https://doc.qt.io/qtcreator/creator-project-qmake.html

Adding Qt5.14 for Webassembly kit: https://doc.qt.io/qtcreator/creator-targets.html

Open StoryBook.pro in Qt Creator and configure it using the new kit.

Qt creator might not set the env paths correctly. In this case manually set build environment variables (Projects -> 5.14.2 kit -> Build -> Build Environment -> Batch edit). Ex:

EMSCRIPTEN=~/Repos/emsdk/emscripten/1.38.27
EMSDK=~/Repos/emsdk
EMSDK_NODE=~/Repos/emsdk/node/14.18.2_64bit/bin/node
EMSDK_PYTHON=~/Repos/emsdk/python/3.9.2_64bit/bin/python3
EM_CONFIG=~/Repos/emsdk/.emscripten
LLVM_ROOT=~/Repos/emsdk/fastcomp-clang/tag-e1.38.27/build_tag-e1.38.27_64/bin
PATH=[check echo $PATH]

Running qmake (without qt Creator)

#create build folder
mkdir buildStoryBook

#go to folder
cd buildStoryBook

#run qmake (add CONFIG+=debug CONFIG+=qml_debug to qmake command for debug build)
~/Qt/5.14.2/wasm_32/bin/qmake [path to StoryBook.pro] -spec wasm-emscripten && /usr/bin/make qmake_all

#build (add -j[nb of cores] for parallel execution)
make

#run
emrun StoryBook.html