Commit graph

119 commits

Author SHA1 Message Date
Nigel Breslaw
0357e2e0c4 live-preview: Fix broken header icons (#9587) 2025-10-02 10:38:59 +02:00
Olivier Goffart
0796bb1db4 live-preview: Simplify the code of the property editor
Put the NameLabel outside of the typed property widget
2025-10-02 10:38:59 +02:00
Olivier Goffart
9a882dd17f live-preview: Only show the "Select an Element" text if there is no element selected
Some checks failed
CI / build_and_test (--exclude bevy-example, ubuntu-22.04, 1.85) (push) Has been cancelled
CI / build_and_test (--exclude ffmpeg --exclude gstreamer-player, --exclude bevy-example, windows-2022, 1.85) (push) Has been cancelled
CI / build_and_test (--exclude ffmpeg --exclude gstreamer-player, macos-14, stable) (push) Has been cancelled
CI / build_and_test (--exclude ffmpeg --exclude gstreamer-player, windows-2022, beta) (push) Has been cancelled
CI / build_and_test (--exclude ffmpeg --exclude gstreamer-player, windows-2022, stable) (push) Has been cancelled
CI / build_and_test (ubuntu-22.04, nightly) (push) Has been cancelled
CI / node_test (macos-14) (push) Has been cancelled
CI / node_test (ubuntu-22.04) (push) Has been cancelled
CI / node_test (windows-2022) (push) Has been cancelled
CI / cpp_test_driver (macos-13) (push) Has been cancelled
CI / cpp_test_driver (ubuntu-22.04) (push) Has been cancelled
CI / cpp_test_driver (windows-2022) (push) Has been cancelled
CI / cpp_cmake (macos-14, 1.85) (push) Has been cancelled
CI / cpp_cmake (ubuntu-22.04, stable) (push) Has been cancelled
CI / cpp_cmake (windows-2022, nightly) (push) Has been cancelled
CI / cpp_package_test (push) Has been cancelled
CI / vsce_build_test (push) Has been cancelled
CI / mcu (pico-st7789, thumbv6m-none-eabi) (push) Has been cancelled
CI / mcu (pico2-st7789, thumbv8m.main-none-eabihf) (push) Has been cancelled
CI / mcu (stm32h735g, thumbv7em-none-eabihf) (push) Has been cancelled
CI / mcu-embassy (push) Has been cancelled
CI / ffi_32bit_build (push) Has been cancelled
CI / docs (push) Has been cancelled
CI / wasm (push) Has been cancelled
CI / updater_test (0.3.0) (push) Has been cancelled
CI / fmt_test (push) Has been cancelled
CI / esp-idf-quick (push) Has been cancelled
CI / android (push) Has been cancelled
CI / miri (push) Has been cancelled
CI / test-figma-inspector (push) Has been cancelled
The property list can be empty if there is a search term that doesn't match
2025-09-12 17:25:40 +02:00
Olivier Goffart
dfbd2bda6c live-preview: search line edit in property list 2025-09-12 17:25:40 +02:00
szecket
7e66df5d28
live-preview: match outline item edge to item (#9365)
Some checks are pending
CI / build_and_test (--exclude ffmpeg --exclude gstreamer-player, macos-14, stable) (push) Blocked by required conditions
CI / build_and_test (--exclude ffmpeg --exclude gstreamer-player, windows-2022, beta) (push) Blocked by required conditions
CI / build_and_test (--exclude ffmpeg --exclude gstreamer-player, windows-2022, stable) (push) Blocked by required conditions
CI / build_and_test (ubuntu-22.04, nightly) (push) Blocked by required conditions
CI / node_test (macos-14) (push) Blocked by required conditions
CI / node_test (ubuntu-22.04) (push) Blocked by required conditions
CI / node_test (windows-2022) (push) Blocked by required conditions
CI / python_test (macos-14) (push) Blocked by required conditions
CI / python_test (ubuntu-22.04) (push) Blocked by required conditions
CI / cpp_test_driver (macos-13) (push) Blocked by required conditions
CI / cpp_test_driver (ubuntu-22.04) (push) Blocked by required conditions
CI / cpp_test_driver (windows-2022) (push) Blocked by required conditions
CI / cpp_cmake (macos-14, 1.85) (push) Blocked by required conditions
CI / cpp_cmake (ubuntu-22.04, stable) (push) Blocked by required conditions
CI / cpp_cmake (windows-2022, nightly) (push) Blocked by required conditions
CI / cpp_package_test (push) Blocked by required conditions
CI / vsce_build_test (push) Blocked by required conditions
CI / wasm_demo (push) Blocked by required conditions
CI / mcu (pico-st7789, thumbv6m-none-eabi) (push) Blocked by required conditions
CI / mcu (pico2-st7789, thumbv8m.main-none-eabihf) (push) Blocked by required conditions
CI / wasm (push) Blocked by required conditions
CI / android (push) Blocked by required conditions
CI / mcu (stm32h735g, thumbv7em-none-eabihf) (push) Blocked by required conditions
CI / mcu-embassy (push) Blocked by required conditions
CI / ffi_32bit_build (push) Blocked by required conditions
CI / docs (push) Blocked by required conditions
CI / fmt_test (push) Blocked by required conditions
CI / esp-idf-quick (push) Blocked by required conditions
CI / miri (push) Blocked by required conditions
CI / test-figma-inspector (push) Blocked by required conditions
2025-09-08 22:33:42 +02:00
szecket
7c0b9b31a3
live-preview: added a component-name (#9364)
Some checks are pending
CI / build_and_test (ubuntu-22.04, nightly) (push) Blocked by required conditions
CI / node_test (macos-14) (push) Blocked by required conditions
CI / node_test (ubuntu-22.04) (push) Blocked by required conditions
CI / node_test (windows-2022) (push) Blocked by required conditions
CI / python_test (macos-14) (push) Blocked by required conditions
CI / python_test (ubuntu-22.04) (push) Blocked by required conditions
CI / python_test (windows-2022) (push) Blocked by required conditions
CI / cpp_test_driver (macos-13) (push) Blocked by required conditions
CI / cpp_test_driver (ubuntu-22.04) (push) Blocked by required conditions
CI / cpp_test_driver (windows-2022) (push) Blocked by required conditions
CI / cpp_cmake (macos-14, 1.85) (push) Blocked by required conditions
CI / cpp_cmake (ubuntu-22.04, stable) (push) Blocked by required conditions
CI / cpp_cmake (windows-2022, nightly) (push) Blocked by required conditions
CI / cpp_package_test (push) Blocked by required conditions
CI / vsce_build_test (push) Blocked by required conditions
CI / mcu (pico-st7789, thumbv6m-none-eabi) (push) Blocked by required conditions
CI / mcu (pico2-st7789, thumbv8m.main-none-eabihf) (push) Blocked by required conditions
CI / mcu (stm32h735g, thumbv7em-none-eabihf) (push) Blocked by required conditions
CI / mcu-embassy (push) Blocked by required conditions
CI / ffi_32bit_build (push) Blocked by required conditions
CI / docs (push) Blocked by required conditions
CI / wasm (push) Blocked by required conditions
CI / wasm_demo (push) Blocked by required conditions
CI / tree-sitter (push) Blocked by required conditions
CI / updater_test (0.3.0) (push) Blocked by required conditions
CI / fmt_test (push) Blocked by required conditions
CI / esp-idf-quick (push) Blocked by required conditions
CI / android (push) Blocked by required conditions
CI / miri (push) Blocked by required conditions
CI / test-figma-inspector (push) Blocked by required conditions
2025-09-08 20:02:29 +02:00
Olivier Goffart
27497dffbf live-preview: Remove the search on the properties panel for now 2025-09-08 17:46:55 +02:00
szecket
75c5ec7763 live-preview: update library search
- updating search
 - integrated search and ViewHeader into Library
 - fix up header to accomodate other views
2025-09-08 17:46:55 +02:00
Olivier Goffart
8ba3dde08f live-preview: WIP: search within the library 2025-09-08 17:46:55 +02:00
Olivier Goffart
db85a0b786 live-preview: hide the "id" line edit for the root 2025-09-08 16:53:57 +02:00
szecket
ae38d763e6 style id to match other properties 2025-09-08 16:53:57 +02:00
szecket
983a544a47
live-preview: adjusted data-widget to match the other widgets. header + scroll 2025-08-23 11:18:56 +02:00
szecket
43a3b9a6b3
live-preview: split out the data tab and used menus for widgets (#9148) 2025-08-21 16:11:22 +02:00
Olivier Goffart
0ef33a097f Outline: do a compile-check before allowing drag
Closes #9196 (replaces it)
2025-08-21 15:37:38 +02:00
szecket
5c438ec7d9
implement MenuBar so we have undo/redo and move the rest over (#9096)
Some checks are pending
CI / cpp_cmake (macos-14, 1.85) (push) Blocked by required conditions
CI / cpp_cmake (ubuntu-22.04, stable) (push) Blocked by required conditions
CI / cpp_cmake (windows-2022, nightly) (push) Blocked by required conditions
CI / cpp_package_test (push) Blocked by required conditions
CI / vsce_build_test (push) Blocked by required conditions
CI / mcu (pico-st7789, thumbv6m-none-eabi) (push) Blocked by required conditions
CI / mcu (pico2-st7789, thumbv8m.main-none-eabihf) (push) Blocked by required conditions
CI / mcu (stm32h735g, thumbv7em-none-eabihf) (push) Blocked by required conditions
CI / mcu-embassy (push) Blocked by required conditions
CI / ffi_32bit_build (push) Blocked by required conditions
CI / docs (push) Blocked by required conditions
CI / build_and_test (ubuntu-22.04, nightly) (push) Blocked by required conditions
CI / node_test (macos-14) (push) Blocked by required conditions
CI / node_test (ubuntu-22.04) (push) Blocked by required conditions
CI / node_test (windows-2022) (push) Blocked by required conditions
CI / python_test (macos-14) (push) Blocked by required conditions
CI / python_test (ubuntu-22.04) (push) Blocked by required conditions
CI / python_test (windows-2022) (push) Blocked by required conditions
CI / cpp_test_driver (macos-13) (push) Blocked by required conditions
CI / cpp_test_driver (ubuntu-22.04) (push) Blocked by required conditions
CI / cpp_test_driver (windows-2022) (push) Blocked by required conditions
CI / wasm (push) Blocked by required conditions
CI / wasm_demo (push) Blocked by required conditions
CI / tree-sitter (push) Blocked by required conditions
CI / updater_test (0.3.0) (push) Blocked by required conditions
CI / fmt_test (push) Blocked by required conditions
CI / esp-idf-quick (push) Blocked by required conditions
CI / android (push) Blocked by required conditions
CI / miri (push) Blocked by required conditions
CI / test-figma-inspector (push) Blocked by required conditions
2025-08-08 01:43:56 +02:00
Olivier Goffart
d9a0fa8964 live-preview: implement undo-redo 2025-08-06 09:42:56 +02:00
szecket
416c6d0f34
visual-editor: clean up property and data display (#9049) 2025-08-02 13:47:44 +02:00
szecket
e0f0088980
visual editor: display hierarchy more clearly 2025-08-02 13:46:08 +02:00
Olivier Goffart
c673a74f9f preview: Fix highlighted elements not following items
Some checks are pending
CI / build_and_test (--exclude ffmpeg --exclude gstreamer-player, macos-14, stable) (push) Blocked by required conditions
CI / build_and_test (--exclude ffmpeg --exclude gstreamer-player, windows-2022, beta) (push) Blocked by required conditions
CI / build_and_test (--exclude ffmpeg --exclude gstreamer-player, windows-2022, stable) (push) Blocked by required conditions
CI / build_and_test (ubuntu-22.04, nightly) (push) Blocked by required conditions
CI / node_test (macos-14) (push) Blocked by required conditions
CI / node_test (ubuntu-22.04) (push) Blocked by required conditions
CI / node_test (windows-2022) (push) Blocked by required conditions
CI / python_test (macos-14) (push) Blocked by required conditions
CI / python_test (ubuntu-22.04) (push) Blocked by required conditions
CI / cpp_test_driver (macos-13) (push) Blocked by required conditions
CI / cpp_test_driver (ubuntu-22.04) (push) Blocked by required conditions
CI / cpp_test_driver (windows-2022) (push) Blocked by required conditions
CI / cpp_cmake (macos-14, 1.85) (push) Blocked by required conditions
CI / cpp_cmake (windows-2022, nightly) (push) Blocked by required conditions
CI / cpp_package_test (push) Blocked by required conditions
CI / vsce_build_test (push) Blocked by required conditions
CI / mcu (pico-st7789, thumbv6m-none-eabi) (push) Blocked by required conditions
CI / mcu (stm32h735g, thumbv7em-none-eabihf) (push) Blocked by required conditions
CI / mcu-embassy (push) Blocked by required conditions
CI / ffi_32bit_build (push) Blocked by required conditions
CI / docs (push) Blocked by required conditions
CI / wasm (push) Blocked by required conditions
CI / wasm_demo (push) Blocked by required conditions
CI / tree-sitter (push) Blocked by required conditions
CI / updater_test (0.3.0) (push) Blocked by required conditions
CI / fmt_test (push) Blocked by required conditions
CI / esp-idf-quick (push) Blocked by required conditions
CI / android (push) Blocked by required conditions
CI / miri (push) Blocked by required conditions
CI / test-figma-inspector (push) Blocked by required conditions
Rely on the fact that `component_instance.component_positions` read
properties and do the property tracking for us. By accessing it from a
callback we get free dirty notification.
2025-08-01 18:56:37 +02:00
Olivier Goffart
1c9aba2d3b Outline: split the type and the id in the datastructure 2025-08-01 18:28:36 +02:00
Olivier Goffart
9fceeb4dcc preview: replace a int with an enum 2025-08-01 18:25:40 +02:00
Olivier Goffart
831969409b Fix typo 2025-08-01 18:25:40 +02:00
szecket
4c8e1d436f Outline: Design cleanup 2025-08-01 18:25:40 +02:00
Olivier Goffart
489e0b8729 Live-preview: Outline 2025-08-01 18:25:40 +02:00
Tasuku Suzuki
9bdcc2a3dc
Live-Preview: Show "<click> unselect" only when selection exists (#8942)
Some checks are pending
CI / docs (push) Blocked by required conditions
CI / wasm (push) Blocked by required conditions
CI / wasm_demo (push) Blocked by required conditions
CI / tree-sitter (push) Blocked by required conditions
CI / python_test (macos-14) (push) Blocked by required conditions
CI / build_and_test (--exclude bevy-example, ubuntu-22.04, 1.85) (push) Blocked by required conditions
CI / build_and_test (--exclude ffmpeg --exclude gstreamer-player, --exclude bevy-example, windows-2022, 1.85) (push) Blocked by required conditions
CI / build_and_test (--exclude ffmpeg --exclude gstreamer-player, macos-14, stable) (push) Blocked by required conditions
CI / build_and_test (--exclude ffmpeg --exclude gstreamer-player, windows-2022, beta) (push) Blocked by required conditions
CI / build_and_test (--exclude ffmpeg --exclude gstreamer-player, windows-2022, stable) (push) Blocked by required conditions
CI / build_and_test (ubuntu-22.04, nightly) (push) Blocked by required conditions
CI / node_test (macos-14) (push) Blocked by required conditions
CI / node_test (ubuntu-22.04) (push) Blocked by required conditions
CI / node_test (windows-2022) (push) Blocked by required conditions
CI / cpp_test_driver (macos-13) (push) Blocked by required conditions
CI / cpp_test_driver (ubuntu-22.04) (push) Blocked by required conditions
CI / cpp_test_driver (windows-2022) (push) Blocked by required conditions
CI / cpp_cmake (macos-14, 1.85) (push) Blocked by required conditions
CI / python_test (ubuntu-22.04) (push) Blocked by required conditions
CI / files-changed (push) Waiting to run
CI / cpp_cmake (ubuntu-22.04, stable) (push) Blocked by required conditions
CI / cpp_cmake (windows-2022, nightly) (push) Blocked by required conditions
CI / cpp_package_test (push) Blocked by required conditions
CI / vsce_build_test (push) Blocked by required conditions
CI / updater_test (0.3.0) (push) Blocked by required conditions
CI / fmt_test (push) Blocked by required conditions
CI / esp-idf-quick (push) Blocked by required conditions
CI / android (push) Blocked by required conditions
CI / miri (push) Blocked by required conditions
CI / test-figma-inspector (push) Blocked by required conditions
2025-07-20 10:48:44 +02:00
Olivier Goffart
a74e5484b0 Live-Preview: use DragArea and DropArea 2025-06-26 15:39:18 +02:00
Nigel Breslaw
2da6bf4add
live-preview data tab floating table editor (#8123)
Adds a table editor based on the color picker floating draggable panel.

This includes behaviours that keep the panel inside the bounds of the live preview window and light / dark mode.
2025-04-13 14:57:50 +03:00
Tobias Hunger
e1b85bbb93 component-container: Accept focus
So that we can pass the focus into the container when it first
shows.

I thought this would be super complex to do property! What a
nice surprise:-)

Fixes: #4055
2025-04-09 09:37:28 +02:00
Nigel Breslaw
063678b29c
Stop live-preview checkerboard shifting as window resizes (#7932) 2025-03-24 15:08:50 +02:00
Tobias Hunger
ee61df3d7e live-preview: janitor work: Split up the property-widgets.slint file
It got *WAY* to big.
2025-03-21 18:11:45 +01:00
Nigel Breslaw
fd330b655e
live-preview: Don't let unselect work when clicking on live content (#7897) 2025-03-20 17:05:18 +02:00
Tobias Hunger
bd20cb5a19 live-preview: Polish: Do not expand empty Property Groups
Those contain only one element informing about there not being any
properties to show. While I think it is important to show
that information so users have a chance to figure out how to
actually use the live data tab, it is not that important that
we need to always show it.
2025-03-06 16:51:54 +01:00
Tobias Hunger
3703005557
live-preview: Show why no live data is present (#7783)
* live-preview: Show why no live data is present

Always list all elements that *could* have live
data, add a Text about "no properties" into empty
ones.

Co-authored-by: Simon Hausmann <hausmann@gmail.com>
2025-03-04 10:41:05 +01:00
Tobias Hunger
8fd18b66fd
live-preview: Remove bottons and then fix the fallout caused by all the layouts around us f-ing up all of a sudden (#7734)
* live-preview: Disable Code and Reset buttons in live data mode

They make no sense there.

* live-preview: Fix up breakage due to hiding the buttons

* live-preview: Improve input handling for preview data

* Ignore changes while editing
* Apply chanegs once editing is done

* live-preview: Bring back the CodeWidget in PropertyEditor

* live-preview: Fix Code and Reset button in ColorWidget

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2025-02-25 18:32:14 +01:00
Tobias Hunger
15955cca75 Avoid if in PropertyValueWidget
This prevents the widgets from being re-generated all the
time, which in turn makes them loose their state.
2025-02-24 19:08:08 +01:00
autofix-ci[bot]
03b80df515 [autofix.ci] apply automated fixes 2025-02-21 16:25:05 +01:00
szecket
d9fb96b18e fixed the component display
some strange focus issue remains
2025-02-21 16:25:05 +01:00
Tobias Hunger
0909397b7a live-preview: Polish: A container should not contain components
A PropertyContainer should not contain component_name and component_id.
Rename those to container_name and container_id.
2025-02-20 18:12:54 +01:00
Tobias Hunger
2b59df1355 live-preview: Simple Data edit mode
We can now set all the properties exposed to the
business logic of a UI we are previewing.

Simple properties only so far, everything else falls
back to JSON data.

Next step is to add more sophisticated UI to actually
edit more complex data like arrays more graphically.
2025-02-20 09:43:24 +01:00
szecket
28f83c64e2 live-preview: fixed indicator and made it show up when control is focused also
The indicator used to collapse secondary parts of the
property edit widgets did not work. Fix that.
2025-02-19 17:40:23 +01:00
Tobias Hunger
4b8287bd0f live-preview: Make property widgets use less information
Make the property widgets work with less information avaiable to
them. I hope I can reuse them for runtime widget state as well that
way.

Unexport the individual widgets and wrap them into a `PropertyValueWidget`
that switches between them as needed -- and fills in the extra information
needed to keep the existing functionality in place.

This makes the PropertyView so much cleaner ;-)
2025-02-06 16:59:05 +01:00
autofix-ci[bot]
b040e9450a [autofix.ci] apply automated fixes 2025-02-05 14:26:29 +01:00
Tobias Hunger
595b571f99 live-preview: Make ExpandableGroup more re-usable
I want to use this for runtime properties later.
2025-02-05 14:26:29 +01:00
Tobias Hunger
25f3bfd95c live-preview: Move widgets out of property-view
Move the widgets used for showing property values out
of the property-view itself, so we can reuse them later.
2025-02-05 14:26:29 +01:00
Tasuku Suzuki
346d1c2df3 Fix typos
Ran `typos .` and fixed all typos that do make sense.
https://crates.io/crates/typos
2025-01-13 08:35:20 +01:00
Olivier Goffart
3e94bd2167 Janitor: Remove trailing whitespaces from all files
`git grep -I -l -O'sed -i "s/[[:space:]]*$//"' -e ''`
2025-01-10 13:23:22 +01:00
szecket
275483b39e
the instructions for interaction at bottom were sometimes inconsistent (#7184) 2024-12-20 10:19:37 -05:00
szecket
97809846ef added faded sidebars on out-of-date preview 2024-12-10 12:23:05 +01:00
Tobias Hunger
d154cde14c live-preview: Disable property editor when preview is not current 2024-12-09 13:26:41 +01:00
Tobias Hunger
498ef2a53c live-preview: Do not allow to drop anything onto an outdated preview 2024-12-09 13:26:41 +01:00