MCPcopy Create free account
hub / github.com/bytebase/bytebase / handleInput

Function handleInput

frontend/src/react/components/sql-editor/FolderForm.tsx:79–92  ·  view source on GitHub ↗
(raw: string)

Source from the content-addressed store, hash-verified

77 })();
78
79 const handleInput = (raw: string) => {
80 let changedVal = raw;
81 if (changedVal.endsWith(" /")) {
82 changedVal = changedVal.slice(0, -2);
83 }
84 if (changedVal.endsWith(".")) {
85 changedVal = changedVal.slice(0, -1);
86 }
87 const rawPath = changedVal
88 .split("/")
89 .map((p) => p.trim())
90 .join("/");
91 setFolderPath(rawPath);
92 };
93
94 // User explicitly clicked a row. Set the folder and close the popover.
95 const handleUserClick = (id: string) => {

Callers 1

FolderFormFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected