mirror of
https://github.com/heygen-com/hyperframes.git
synced 2026-11-02 19:57:13 +00:00
refactor(studio): name the map form instead of commenting it
This commit is contained in:
@@ -105,11 +105,10 @@ export function useDomEditTextCommits({
|
||||
persistDomEditOperations,
|
||||
});
|
||||
|
||||
// One property, or a map saved as one patch and one undo step.
|
||||
const handleDomStyleCommitForSelection = useCallback(
|
||||
(
|
||||
selection: DomEditSelection,
|
||||
property: string | Record<string, string>,
|
||||
propertyOrStylesAsOnePatch: string | Record<string, string>,
|
||||
value = "",
|
||||
): Promise<DomEditCommitOutcome> =>
|
||||
commitDomStyles(
|
||||
@@ -123,7 +122,9 @@ export function useDomEditTextCommits({
|
||||
resync: refreshDomEditSelectionFromPreview,
|
||||
},
|
||||
selection,
|
||||
typeof property === "string" ? { [property]: value } : property,
|
||||
typeof propertyOrStylesAsOnePatch === "string"
|
||||
? { [propertyOrStylesAsOnePatch]: value }
|
||||
: propertyOrStylesAsOnePatch,
|
||||
),
|
||||
[
|
||||
activeCompPath,
|
||||
|
||||
Reference in New Issue
Block a user