Result of locking one tweak into an authored JSX/TSX source string. More...
#include <jsx_lock.hpp>
Public Member Functions | |
| bool | mutated () const |
| True when the lock changed the source text. | |
| bool | ok () const |
| True when the element + prop were located and the source carries the value (already_current counts — the value is already there). | |
Public Attributes | |
| JsxLockStatus | status = JsxLockStatus::anchor_not_found |
| std::string | source |
| The (possibly patched) source text. | |
| std::string | property |
| The resolved style / prop key the path mapped to (camelCase, e.g. | |
| std::string | message |
| Human-readable summary, suitable for CLI / inspector display. | |
| int | line = 0 |
| 1-based line number of the patched value, or 0 when nothing was patched. | |
Result of locking one tweak into an authored JSX/TSX source string.
|
inline |
True when the lock changed the source text.
|
inline |
True when the element + prop were located and the source carries the value (already_current counts — the value is already there).
| int pulp::view::JsxLockResult::line = 0 |
1-based line number of the patched value, or 0 when nothing was patched.
Useful for a "jump to source" / diff-preview affordance.
| std::string pulp::view::JsxLockResult::message |
Human-readable summary, suitable for CLI / inspector display.
On too_dynamic this carries the specific reason.
| std::string pulp::view::JsxLockResult::property |
The resolved style / prop key the path mapped to (camelCase, e.g.
"backgroundColor", "padding"). Empty when the path was unsupported.
| std::string pulp::view::JsxLockResult::source |
The (possibly patched) source text.
On any non-patched status this equals the input verbatim.
| JsxLockStatus pulp::view::JsxLockResult::status = JsxLockStatus::anchor_not_found |