From 214c1d7e5194d1a720d9a827f8ee200af858be33 Mon Sep 17 00:00:00 2001 From: TheoryOfNekomata Date: Sun, 19 Mar 2023 18:18:48 +0800 Subject: [PATCH] Update data binding Handle data binding for keyframes. --- .../app/components/Button/index.tsx | 16 + .../app/components/FileButton/index.tsx | 23 ++ tools/animation-workbench/app/root.tsx | 2 +- .../animation-workbench/app/routes/index.tsx | 289 +++++++++++++++--- 4 files changed, 282 insertions(+), 48 deletions(-) create mode 100644 tools/animation-workbench/app/components/Button/index.tsx create mode 100644 tools/animation-workbench/app/components/FileButton/index.tsx diff --git a/tools/animation-workbench/app/components/Button/index.tsx b/tools/animation-workbench/app/components/Button/index.tsx new file mode 100644 index 0000000..ff51de8 --- /dev/null +++ b/tools/animation-workbench/app/components/Button/index.tsx @@ -0,0 +1,16 @@ +import {forwardRef, HTMLProps, ReactNode} from 'react'; + +export interface ButtonProps extends Omit, 'type'> { + type?: 'button' | 'reset' | 'submit'; +} + +export const Button = forwardRef(({ + className, + ...etcProps +}, ref) => ( + +
{loadedFileName}
@@ -334,7 +478,7 @@ const IndexPage = () => { { { isNewAnimationId && ( <> - - - + ) } @@ -375,8 +519,24 @@ const IndexPage = () => {
-
-
+
+
+
+
+
+
{ Array.isArray(svgGroups) && ( <> @@ -390,8 +550,10 @@ const IndexPage = () => { {group.name}
-
-
-
- - - + Update Current Time +
)