Merge branch 'main' into rtViz
This commit is contained in:
@@ -26,9 +26,14 @@ const Templates = () => {
|
||||
templateData();
|
||||
}, []);
|
||||
|
||||
const handleDeleteTemplate = async (id: string) => {
|
||||
const handleDeleteTemplate = async (
|
||||
e: React.MouseEvent<HTMLButtonElement>,
|
||||
id: string
|
||||
) => {
|
||||
try {
|
||||
e.stopPropagation();
|
||||
const email = localStorage.getItem("email") || "";
|
||||
|
||||
const organization = email?.split("@")[1]?.split(".")[0];
|
||||
let deleteTemplate = {
|
||||
organization: organization,
|
||||
@@ -49,7 +54,6 @@ const Templates = () => {
|
||||
const handleLoadTemplate = async (template: any) => {
|
||||
try {
|
||||
if (selectedZone.zoneName === "") return;
|
||||
|
||||
const email = localStorage.getItem("email") || "";
|
||||
const organization = email?.split("@")[1]?.split(".")[0];
|
||||
|
||||
@@ -108,7 +112,7 @@ const Templates = () => {
|
||||
<RenameInput value={`Template ${index + 1}`} />
|
||||
</div>
|
||||
<button
|
||||
onClick={() => handleDeleteTemplate(template.id)}
|
||||
onClick={(e) => handleDeleteTemplate(e, template.id)}
|
||||
className="delete-button"
|
||||
aria-label="Delete template"
|
||||
>
|
||||
|
||||
@@ -33,7 +33,7 @@ const WidgetsFloating = () => {
|
||||
};
|
||||
|
||||
return (
|
||||
<div className="floatingWidgets-wrapper">
|
||||
<div className="floatingWidgets-wrapper widgets-wrapper">
|
||||
{/* {widgets.map((widget) => (
|
||||
<div
|
||||
key={widget.id}
|
||||
|
||||
Reference in New Issue
Block a user