From 30a46d50640adfb3d792a0f2fc757f4b40728fba Mon Sep 17 00:00:00 2001 From: hzhang Date: Mon, 12 May 2025 09:59:23 +0100 Subject: [PATCH] add: markdown template to json schema --- src/components/Modals/JsonSchemaModal.js | 42 +++++ .../Navigations/SideTabs/TemplateTab.js | 146 ++++++++++++++++-- 2 files changed, 171 insertions(+), 17 deletions(-) create mode 100644 src/components/Modals/JsonSchemaModal.js diff --git a/src/components/Modals/JsonSchemaModal.js b/src/components/Modals/JsonSchemaModal.js new file mode 100644 index 0000000..f6d4017 --- /dev/null +++ b/src/components/Modals/JsonSchemaModal.js @@ -0,0 +1,42 @@ +import React from 'react'; + +const JsonSchemaModal = ({ isActive, onClose, schema }) => { + const handleCopy = () => { + navigator.clipboard.writeText(JSON.stringify(schema, null, 2)); + }; + + return ( +
+
+
+
+

JSON Schema

+ +
+
+
+
+