feat: Convert all app files to JS

This commit is contained in:
Faruk AYDIN
2024-01-05 17:44:21 +01:00
parent b95478b635
commit 43dba351c3
1030 changed files with 5114 additions and 6436 deletions

View File

@@ -0,0 +1,3 @@
import newChat from './new-chat/index.js';
export default [newChat];

View File

@@ -1,3 +0,0 @@
import newChat from './new-chat';
export default [newChat];

View File

@@ -1,5 +1,5 @@
import FormData from 'form-data';
import defineAction from '../../../../helpers/define-action';
import defineAction from '../../../../helpers/define-action.js';
export default defineAction({
name: 'New chat',
@@ -9,7 +9,7 @@ export default defineAction({
{
label: 'Input',
key: 'input',
type: 'string' as const,
type: 'string',
required: true,
description: 'Prompt to start the chat with.',
variables: true,
@@ -18,7 +18,7 @@ export default defineAction({
async run($) {
const formData = new FormData();
formData.append('input', $.step.parameters.input as string);
formData.append('input', $.step.parameters.input);
formData.append('mode', 'inference');
formData.append('type', 'text');