@collabdt/core 0.4.4 → 0.4.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/core/components/TopNavigationBar.js +3 -3
- package/dist/core/components/TopNavigationBar.js.map +1 -1
- package/dist/core/components/ui/Sidebar.d.ts.map +1 -1
- package/dist/core/components/ui/Sidebar.js +3 -3
- package/dist/core/components/ui/Sidebar.js.map +1 -1
- package/dist/core/components/ui/ViewerSidebar/CommunicationTab.d.ts +9 -0
- package/dist/core/components/ui/ViewerSidebar/CommunicationTab.d.ts.map +1 -0
- package/dist/core/components/ui/ViewerSidebar/CommunicationTab.js +14 -0
- package/dist/core/components/ui/ViewerSidebar/CommunicationTab.js.map +1 -0
- package/dist/core/components/ui/ViewerSidebar/Header.d.ts.map +1 -0
- package/dist/core/components/ui/ViewerSidebar/Header.js.map +1 -0
- package/dist/core/components/ui/ViewerSidebar/Panel.d.ts +23 -0
- package/dist/core/components/ui/ViewerSidebar/Panel.d.ts.map +1 -0
- package/dist/core/components/ui/ViewerSidebar/Panel.js +37 -0
- package/dist/core/components/ui/ViewerSidebar/Panel.js.map +1 -0
- package/dist/core/components/ui/ViewerSidebar/SensorsTab.d.ts +4 -0
- package/dist/core/components/ui/ViewerSidebar/SensorsTab.d.ts.map +1 -0
- package/dist/core/components/ui/ViewerSidebar/SensorsTab.js +11 -0
- package/dist/core/components/ui/ViewerSidebar/SensorsTab.js.map +1 -0
- package/dist/core/components/ui/ViewerSidebar/Shell.d.ts +16 -0
- package/dist/core/components/ui/ViewerSidebar/Shell.d.ts.map +1 -0
- package/dist/core/components/ui/ViewerSidebar/Shell.js +59 -0
- package/dist/core/components/ui/ViewerSidebar/Shell.js.map +1 -0
- package/dist/core/components/ui/ViewerSidebar/TabStrip.d.ts +19 -0
- package/dist/core/components/ui/ViewerSidebar/TabStrip.d.ts.map +1 -0
- package/dist/core/components/ui/ViewerSidebar/TabStrip.js +82 -0
- package/dist/core/components/ui/ViewerSidebar/TabStrip.js.map +1 -0
- package/dist/core/components/ui/{InfoSidebar → ViewerSidebar}/index.d.ts +1 -1
- package/dist/core/components/ui/ViewerSidebar/index.d.ts.map +1 -0
- package/dist/core/components/ui/{InfoSidebar → ViewerSidebar}/index.js +2 -2
- package/dist/core/components/ui/ViewerSidebar/index.js.map +1 -0
- package/dist/core/components/ui/ViewerSidebar/sidebarTabs.d.ts +45 -0
- package/dist/core/components/ui/ViewerSidebar/sidebarTabs.d.ts.map +1 -0
- package/dist/core/components/ui/ViewerSidebar/sidebarTabs.js +30 -0
- package/dist/core/components/ui/ViewerSidebar/sidebarTabs.js.map +1 -0
- package/dist/core/components/ui/index.d.ts +1 -1
- package/dist/core/components/ui/index.d.ts.map +1 -1
- package/dist/core/components/ui/index.js +2 -2
- package/dist/core/components/ui/index.js.map +1 -1
- package/dist/core/components/viewers/Viewer.js.map +1 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/FileTab/index.d.ts.map +1 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/FileTab/index.js +4 -13
- package/dist/core/components/viewers/bim/src/BimSidebar/src/FileTab/index.js.map +1 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/LayersTab/index.js +1 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/LayersTab/index.js.map +1 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/SettingsTab/index.d.ts +1 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/SettingsTab/index.d.ts.map +1 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/SettingsTab/index.js +2 -5
- package/dist/core/components/viewers/bim/src/BimSidebar/src/SettingsTab/index.js.map +1 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/Topics/src/CollapsibleTopicItem.d.ts.map +1 -0
- package/dist/core/components/viewers/bim/src/BimSidebar/src/Topics/src/CollapsibleTopicItem.js.map +1 -0
- package/dist/core/components/viewers/bim/src/BimSidebar/src/Topics/src/CreateTopicDialog.d.ts.map +1 -0
- package/dist/core/components/viewers/bim/src/BimSidebar/src/Topics/src/CreateTopicDialog.js.map +1 -0
- package/dist/core/components/viewers/bim/src/BimSidebar/src/Topics/src/TopicsSection.d.ts.map +1 -0
- package/dist/core/components/viewers/bim/src/BimSidebar/src/Topics/src/TopicsSection.js.map +1 -0
- package/dist/core/components/viewers/bim/src/BimSidebar/src/index.d.ts.map +1 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/index.js +15 -31
- package/dist/core/components/viewers/bim/src/BimSidebar/src/index.js.map +1 -1
- package/dist/core/components/viewers/map/src/MapSidebar/index.d.ts.map +1 -1
- package/dist/core/components/viewers/map/src/MapSidebar/index.js +16 -31
- package/dist/core/components/viewers/map/src/MapSidebar/index.js.map +1 -1
- package/dist/core/components/viewers/map/src/MapSidebar/src/FileTab/index.d.ts.map +1 -1
- package/dist/core/components/viewers/map/src/MapSidebar/src/FileTab/index.js +5 -15
- package/dist/core/components/viewers/map/src/MapSidebar/src/FileTab/index.js.map +1 -1
- package/dist/core/components/viewers/map/src/MapSidebar/src/LayersTab/index.d.ts.map +1 -1
- package/dist/core/components/viewers/map/src/MapSidebar/src/LayersTab/index.js +26 -29
- package/dist/core/components/viewers/map/src/MapSidebar/src/LayersTab/index.js.map +1 -1
- package/dist/core/components/viewers/map/src/MapSidebar/src/SettingsTab/index.d.ts +1 -1
- package/dist/core/components/viewers/map/src/MapSidebar/src/SettingsTab/index.d.ts.map +1 -1
- package/dist/core/components/viewers/map/src/MapSidebar/src/SettingsTab/index.js +2 -1
- package/dist/core/components/viewers/map/src/MapSidebar/src/SettingsTab/index.js.map +1 -1
- package/dist/core/components/viewers/pointcloud/src/PointCloudSidebar/index.d.ts.map +1 -1
- package/dist/core/components/viewers/pointcloud/src/PointCloudSidebar/index.js +7 -28
- package/dist/core/components/viewers/pointcloud/src/PointCloudSidebar/index.js.map +1 -1
- package/dist/core/components/viewers/pointcloud/src/PointCloudSidebar/src/FileTab/index.d.ts.map +1 -1
- package/dist/core/components/viewers/pointcloud/src/PointCloudSidebar/src/FileTab/index.js +3 -2
- package/dist/core/components/viewers/pointcloud/src/PointCloudSidebar/src/FileTab/index.js.map +1 -1
- package/dist/core/components/viewers/pointcloud/src/PointCloudSidebar/src/SettingsTab/index.d.ts +1 -1
- package/dist/core/components/viewers/pointcloud/src/PointCloudSidebar/src/SettingsTab/index.d.ts.map +1 -1
- package/dist/core/components/viewers/pointcloud/src/PointCloudSidebar/src/SettingsTab/index.js +2 -3
- package/dist/core/components/viewers/pointcloud/src/PointCloudSidebar/src/SettingsTab/index.js.map +1 -1
- package/dist/core/hooks/ui/useCompactTabStrip.d.ts +25 -0
- package/dist/core/hooks/ui/useCompactTabStrip.d.ts.map +1 -0
- package/dist/core/hooks/ui/useCompactTabStrip.js +33 -0
- package/dist/core/hooks/ui/useCompactTabStrip.js.map +1 -0
- package/dist/core/i18n/messages/en.json +3 -3
- package/dist/core/i18n/messages/es.json +3 -3
- package/dist/core/i18n/messages/fr.json +3 -3
- package/package.json +1 -1
- package/dist/core/components/ui/InfoSidebar/Container.d.ts +0 -10
- package/dist/core/components/ui/InfoSidebar/Container.d.ts.map +0 -1
- package/dist/core/components/ui/InfoSidebar/Container.js +0 -34
- package/dist/core/components/ui/InfoSidebar/Container.js.map +0 -1
- package/dist/core/components/ui/InfoSidebar/Header.d.ts.map +0 -1
- package/dist/core/components/ui/InfoSidebar/Header.js.map +0 -1
- package/dist/core/components/ui/InfoSidebar/index.d.ts.map +0 -1
- package/dist/core/components/ui/InfoSidebar/index.js.map +0 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/CommunicationTab/index.d.ts +0 -9
- package/dist/core/components/viewers/bim/src/BimSidebar/src/CommunicationTab/index.d.ts.map +0 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/CommunicationTab/index.js +0 -14
- package/dist/core/components/viewers/bim/src/BimSidebar/src/CommunicationTab/index.js.map +0 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/CommunicationTab/src/CollapsibleTopicItem.d.ts.map +0 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/CommunicationTab/src/CollapsibleTopicItem.js.map +0 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/CommunicationTab/src/CreateTopicDialog.d.ts.map +0 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/CommunicationTab/src/CreateTopicDialog.js.map +0 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/CommunicationTab/src/TopicsSection.d.ts.map +0 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/CommunicationTab/src/TopicsSection.js.map +0 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/SensorsTab/index.d.ts +0 -9
- package/dist/core/components/viewers/bim/src/BimSidebar/src/SensorsTab/index.d.ts.map +0 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/SensorsTab/index.js +0 -10
- package/dist/core/components/viewers/bim/src/BimSidebar/src/SensorsTab/index.js.map +0 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/TabSelector.d.ts +0 -9
- package/dist/core/components/viewers/bim/src/BimSidebar/src/TabSelector.d.ts.map +0 -1
- package/dist/core/components/viewers/bim/src/BimSidebar/src/TabSelector.js +0 -32
- package/dist/core/components/viewers/bim/src/BimSidebar/src/TabSelector.js.map +0 -1
- package/dist/core/components/viewers/map/src/MapSidebar/TabSelector.d.ts +0 -9
- package/dist/core/components/viewers/map/src/MapSidebar/TabSelector.d.ts.map +0 -1
- package/dist/core/components/viewers/map/src/MapSidebar/TabSelector.js +0 -32
- package/dist/core/components/viewers/map/src/MapSidebar/TabSelector.js.map +0 -1
- package/dist/core/components/viewers/map/src/MapSidebar/src/CommunicationTab/index.d.ts +0 -9
- package/dist/core/components/viewers/map/src/MapSidebar/src/CommunicationTab/index.d.ts.map +0 -1
- package/dist/core/components/viewers/map/src/MapSidebar/src/CommunicationTab/index.js +0 -10
- package/dist/core/components/viewers/map/src/MapSidebar/src/CommunicationTab/index.js.map +0 -1
- package/dist/core/components/viewers/map/src/MapSidebar/src/SensorsTab/index.d.ts +0 -9
- package/dist/core/components/viewers/map/src/MapSidebar/src/SensorsTab/index.d.ts.map +0 -1
- package/dist/core/components/viewers/map/src/MapSidebar/src/SensorsTab/index.js +0 -10
- package/dist/core/components/viewers/map/src/MapSidebar/src/SensorsTab/index.js.map +0 -1
- package/dist/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudManagementTable.d.ts +0 -5
- package/dist/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudManagementTable.d.ts.map +0 -1
- package/dist/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudManagementTable.js +0 -30
- package/dist/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudManagementTable.js.map +0 -1
- package/dist/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudTable.d.ts +0 -8
- package/dist/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudTable.d.ts.map +0 -1
- package/dist/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudTable.js +0 -350
- package/dist/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudTable.js.map +0 -1
- package/dist/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudUploadPanel.d.ts +0 -8
- package/dist/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudUploadPanel.d.ts.map +0 -1
- package/dist/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudUploadPanel.js +0 -336
- package/dist/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudUploadPanel.js.map +0 -1
- package/dist/core/components/viewers/pointcloud/src/PointCloudSidebar/TabSelector.d.ts +0 -9
- package/dist/core/components/viewers/pointcloud/src/PointCloudSidebar/TabSelector.d.ts.map +0 -1
- package/dist/core/components/viewers/pointcloud/src/PointCloudSidebar/TabSelector.js +0 -30
- package/dist/core/components/viewers/pointcloud/src/PointCloudSidebar/TabSelector.js.map +0 -1
- /package/dist/core/components/ui/{InfoSidebar → ViewerSidebar}/Header.d.ts +0 -0
- /package/dist/core/components/ui/{InfoSidebar → ViewerSidebar}/Header.js +0 -0
- /package/dist/core/components/viewers/bim/src/BimSidebar/src/{CommunicationTab → Topics}/src/CollapsibleTopicItem.d.ts +0 -0
- /package/dist/core/components/viewers/bim/src/BimSidebar/src/{CommunicationTab → Topics}/src/CollapsibleTopicItem.js +0 -0
- /package/dist/core/components/viewers/bim/src/BimSidebar/src/{CommunicationTab → Topics}/src/CreateTopicDialog.d.ts +0 -0
- /package/dist/core/components/viewers/bim/src/BimSidebar/src/{CommunicationTab → Topics}/src/CreateTopicDialog.js +0 -0
- /package/dist/core/components/viewers/bim/src/BimSidebar/src/{CommunicationTab → Topics}/src/TopicsSection.d.ts +0 -0
- /package/dist/core/components/viewers/bim/src/BimSidebar/src/{CommunicationTab → Topics}/src/TopicsSection.js +0 -0
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/core/components/viewers/bim/src/BimSidebar/src/SensorsTab/index.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAI9B,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,oCAAoC,CAAA;AAChE,MAAM,WAAW,QAAQ;IACvB,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,EAAE,KAAK,CAAC,WAAW,CAAA;IACvB,OAAO,EAAE,OAAO,CAAA;CACjB;AAED,wBAAgB,UAAU,sBAMzB"}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsx } from "react/jsx-runtime";
|
|
3
|
-
import { SensorsSection } from "../../../../../../ui/Sensors/SensorsSection";
|
|
4
|
-
function SensorsTab() {
|
|
5
|
-
return /* @__PURE__ */ jsx("div", { className: "flex-1 flex flex-col space-y-6 py-4 overflow-hidden", children: /* @__PURE__ */ jsx(SensorsSection, {}) });
|
|
6
|
-
}
|
|
7
|
-
export {
|
|
8
|
-
SensorsTab
|
|
9
|
-
};
|
|
10
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../../../../../../src/core/components/viewers/bim/src/BimSidebar/src/SensorsTab/index.tsx"],"sourcesContent":["'use client'\r\n\r\n// SPDX-License-Identifier: AGPL-3.0-or-later\r\n// Copyright (C) 2025 Collab Digital Twins\r\n\r\nimport * as React from 'react'\r\n\r\nimport { SensorsSection } from '../../../../../../ui/Sensors/SensorsSection'\r\n\r\nimport type { DbFile } from '../../../../../../../types/dbTypes'\r\nexport interface FileItem {\r\n task: DbFile\r\n icon: React.ElementType\r\n visible: boolean\r\n}\r\n\r\nexport function SensorsTab() {\r\n return (\r\n <div className=\"flex-1 flex flex-col space-y-6 py-4 overflow-hidden\">\r\n <SensorsSection />\r\n </div>\r\n )\r\n}\r\n"],"mappings":";AAmBM;AAZN,SAAS,sBAAsB;AASxB,SAAS,aAAa;AAC3B,SACE,oBAAC,SAAI,WAAU,uDACb,8BAAC,kBAAe,GAClB;AAEJ;","names":[]}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { SidebarTabType } from '../../../../../../store/Menus/reducer';
|
|
3
|
-
interface TabSelectorProps {
|
|
4
|
-
activeTab: SidebarTabType;
|
|
5
|
-
onTabChangeAction: (tab: SidebarTabType) => void;
|
|
6
|
-
}
|
|
7
|
-
export declare function TabSelector({ activeTab, onTabChangeAction }: TabSelectorProps): React.JSX.Element;
|
|
8
|
-
export {};
|
|
9
|
-
//# sourceMappingURL=TabSelector.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"TabSelector.d.ts","sourceRoot":"","sources":["../../../../../../../../src/core/components/viewers/bim/src/BimSidebar/src/TabSelector.tsx"],"names":[],"mappings":"AAMA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAI9B,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uCAAuC,CAAA;AAE3E,UAAU,gBAAgB;IACxB,SAAS,EAAE,cAAc,CAAA;IACzB,iBAAiB,EAAE,CAAC,GAAG,EAAE,cAAc,KAAK,IAAI,CAAA;CACjD;AAED,wBAAgB,WAAW,CAAC,EAAE,SAAS,EAAE,iBAAiB,EAAE,EAAE,gBAAgB,qBAuC7E"}
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
-
import { useTranslations } from "next-intl";
|
|
4
|
-
import { Separator } from "../../../../../ui/Separator";
|
|
5
|
-
function TabSelector({ activeTab, onTabChangeAction }) {
|
|
6
|
-
const t = useTranslations("TabSelector");
|
|
7
|
-
const tabs = [
|
|
8
|
-
{ id: "file", label: t("fileLabel") },
|
|
9
|
-
{ id: "layers", label: t("layersTitle") },
|
|
10
|
-
{ id: "communication", label: t("communicationTitle") },
|
|
11
|
-
{ id: "sensors", label: t("sensorsTitle") },
|
|
12
|
-
{ id: "settings", label: t("settingsTitle") }
|
|
13
|
-
];
|
|
14
|
-
return /* @__PURE__ */ jsxs("div", { children: [
|
|
15
|
-
/* @__PURE__ */ jsx(Separator, {}),
|
|
16
|
-
/* @__PURE__ */ jsx("div", { className: "px-4 py-3", children: /* @__PURE__ */ jsx("div", { className: "flex items-center gap-1 w-full", children: tabs.map((tab) => /* @__PURE__ */ jsx(
|
|
17
|
-
"div",
|
|
18
|
-
{
|
|
19
|
-
title: tab.label,
|
|
20
|
-
className: `flex-1 min-w-0 truncate text-center px-2 py-2 rounded-md cursor-pointer transition-colors text-xs font-medium ${activeTab === tab.id ? "bg-accent text-accent-foreground" : "text-muted-foreground hover:text-foreground hover:bg-accent/50"}`,
|
|
21
|
-
onClick: () => onTabChangeAction(tab.id),
|
|
22
|
-
children: tab.label
|
|
23
|
-
},
|
|
24
|
-
tab.id
|
|
25
|
-
)) }) }),
|
|
26
|
-
/* @__PURE__ */ jsx(Separator, {})
|
|
27
|
-
] });
|
|
28
|
-
}
|
|
29
|
-
export {
|
|
30
|
-
TabSelector
|
|
31
|
-
};
|
|
32
|
-
//# sourceMappingURL=TabSelector.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../../../../../src/core/components/viewers/bim/src/BimSidebar/src/TabSelector.tsx"],"sourcesContent":["'use client'\r\n\r\n// SPDX-License-Identifier: AGPL-3.0-or-later\r\n// Copyright (C) 2025 Collab Digital Twins\r\n\r\nimport { useTranslations } from 'next-intl'\r\nimport * as React from 'react'\r\n\r\nimport { Separator } from '../../../../../ui/Separator'\r\n\r\nimport type { SidebarTabType } from '../../../../../../store/Menus/reducer'\r\n\r\ninterface TabSelectorProps {\r\n activeTab: SidebarTabType\r\n onTabChangeAction: (tab: SidebarTabType) => void\r\n}\r\n\r\nexport function TabSelector({ activeTab, onTabChangeAction }: TabSelectorProps) {\r\n // Translation\r\n const t = useTranslations('TabSelector')\r\n\r\n const tabs = [\r\n { id: 'file', label: t('fileLabel') },\r\n { id: 'layers', label: t('layersTitle') },\r\n { id: 'communication', label: t('communicationTitle') },\r\n { id: 'sensors', label: t('sensorsTitle') },\r\n { id: 'settings', label: t('settingsTitle') },\r\n\r\n ]\r\n\r\n return (\r\n <div>\r\n <Separator />\r\n\r\n <div className=\"px-4 py-3\">\r\n <div className=\"flex items-center gap-1 w-full\">\r\n {tabs.map(tab => (\r\n <div\r\n key={tab.id}\r\n title={tab.label}\r\n className={`flex-1 min-w-0 truncate text-center px-2 py-2 rounded-md cursor-pointer transition-colors text-xs font-medium ${\r\n activeTab === tab.id\r\n ? 'bg-accent text-accent-foreground'\r\n : 'text-muted-foreground hover:text-foreground hover:bg-accent/50'\r\n }`}\r\n onClick={() => onTabChangeAction(tab.id as SidebarTabType)}\r\n >\r\n {tab.label}\r\n </div>\r\n ))}\r\n </div>\r\n </div>\r\n\r\n <Separator />\r\n </div>\r\n )\r\n}\r\n"],"mappings":";AA+BI,SACE,KADF;AA1BJ,SAAS,uBAAuB;AAGhC,SAAS,iBAAiB;AASnB,SAAS,YAAY,EAAE,WAAW,kBAAkB,GAAqB;AAE9E,QAAM,IAAI,gBAAgB,aAAa;AAEvC,QAAM,OAAO;AAAA,IACX,EAAE,IAAI,QAAQ,OAAO,EAAE,WAAW,EAAE;AAAA,IACpC,EAAE,IAAI,UAAU,OAAO,EAAE,aAAa,EAAE;AAAA,IACxC,EAAE,IAAI,iBAAiB,OAAO,EAAE,oBAAoB,EAAE;AAAA,IACtD,EAAE,IAAI,WAAW,OAAO,EAAE,cAAc,EAAE;AAAA,IAC1C,EAAE,IAAI,YAAY,OAAO,EAAE,eAAe,EAAE;AAAA,EAE9C;AAEA,SACE,qBAAC,SACC;AAAA,wBAAC,aAAU;AAAA,IAEX,oBAAC,SAAI,WAAU,aACb,8BAAC,SAAI,WAAU,kCACZ,eAAK,IAAI,SACR;AAAA,MAAC;AAAA;AAAA,QAEC,OAAO,IAAI;AAAA,QACX,WAAW,iHACT,cAAc,IAAI,KACd,qCACA,gEACN;AAAA,QACA,SAAS,MAAM,kBAAkB,IAAI,EAAoB;AAAA,QAExD,cAAI;AAAA;AAAA,MATA,IAAI;AAAA,IAUX,CACD,GACH,GACF;AAAA,IAEA,oBAAC,aAAU;AAAA,KACb;AAEJ;","names":[]}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { SidebarTabType } from '../../../../../store/Menus/reducer';
|
|
3
|
-
interface TabSelectorProps {
|
|
4
|
-
activeTab: SidebarTabType;
|
|
5
|
-
onTabChangeAction: (tab: SidebarTabType) => void;
|
|
6
|
-
}
|
|
7
|
-
export declare function TabSelector({ activeTab, onTabChangeAction }: TabSelectorProps): React.JSX.Element;
|
|
8
|
-
export {};
|
|
9
|
-
//# sourceMappingURL=TabSelector.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"TabSelector.d.ts","sourceRoot":"","sources":["../../../../../../../src/core/components/viewers/map/src/MapSidebar/TabSelector.tsx"],"names":[],"mappings":"AAMA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAI9B,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAA;AAExE,UAAU,gBAAgB;IACxB,SAAS,EAAE,cAAc,CAAA;IACzB,iBAAiB,EAAE,CAAC,GAAG,EAAE,cAAc,KAAK,IAAI,CAAA;CACjD;AAED,wBAAgB,WAAW,CAAC,EAAE,SAAS,EAAE,iBAAiB,EAAE,EAAE,gBAAgB,qBAsC7E"}
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
-
import { useTranslations } from "next-intl";
|
|
4
|
-
import { Separator } from "../../../../ui/Separator";
|
|
5
|
-
function TabSelector({ activeTab, onTabChangeAction }) {
|
|
6
|
-
const t = useTranslations("TabSelector");
|
|
7
|
-
const tabs = [
|
|
8
|
-
{ id: "file", label: t("fileLabel") },
|
|
9
|
-
{ id: "layers", label: t("layersTitle") },
|
|
10
|
-
{ id: "communication", label: t("communicationTitle") },
|
|
11
|
-
{ id: "sensors", label: t("sensorsTitle") },
|
|
12
|
-
{ id: "settings", label: t("settingsTitle") }
|
|
13
|
-
];
|
|
14
|
-
return /* @__PURE__ */ jsxs("div", { children: [
|
|
15
|
-
/* @__PURE__ */ jsx(Separator, {}),
|
|
16
|
-
/* @__PURE__ */ jsx("div", { className: "px-4 py-3", children: /* @__PURE__ */ jsx("div", { className: "flex items-center gap-1 w-full", children: tabs.map((tab) => /* @__PURE__ */ jsx(
|
|
17
|
-
"div",
|
|
18
|
-
{
|
|
19
|
-
title: tab.label,
|
|
20
|
-
className: `flex-1 min-w-0 truncate text-center px-2 py-2 rounded-md cursor-pointer transition-colors text-xs font-medium ${activeTab === tab.id ? "bg-accent text-accent-foreground" : "text-muted-foreground hover:text-foreground hover:bg-accent/50"}`,
|
|
21
|
-
onClick: () => onTabChangeAction(tab.id),
|
|
22
|
-
children: tab.label
|
|
23
|
-
},
|
|
24
|
-
tab.id
|
|
25
|
-
)) }) }),
|
|
26
|
-
/* @__PURE__ */ jsx(Separator, {})
|
|
27
|
-
] });
|
|
28
|
-
}
|
|
29
|
-
export {
|
|
30
|
-
TabSelector
|
|
31
|
-
};
|
|
32
|
-
//# sourceMappingURL=TabSelector.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../../../../src/core/components/viewers/map/src/MapSidebar/TabSelector.tsx"],"sourcesContent":["'use client'\r\n\r\n// SPDX-License-Identifier: AGPL-3.0-or-later\r\n// Copyright (C) 2025 Collab Digital Twins\r\n\r\nimport { useTranslations } from 'next-intl'\r\nimport * as React from 'react'\r\n\r\nimport { Separator } from '../../../../ui/Separator'\r\n\r\nimport type { SidebarTabType } from '../../../../../store/Menus/reducer'\r\n\r\ninterface TabSelectorProps {\r\n activeTab: SidebarTabType\r\n onTabChangeAction: (tab: SidebarTabType) => void\r\n}\r\n\r\nexport function TabSelector({ activeTab, onTabChangeAction }: TabSelectorProps) {\r\n // Translation\r\n const t = useTranslations('TabSelector')\r\n\r\n const tabs = [\r\n { id: 'file', label: t('fileLabel') },\r\n { id: 'layers', label: t('layersTitle') },\r\n { id: 'communication', label: t('communicationTitle') },\r\n { id: 'sensors', label: t('sensorsTitle') },\r\n { id: 'settings', label: t('settingsTitle') },\r\n ]\r\n\r\n return (\r\n <div>\r\n <Separator />\r\n\r\n <div className=\"px-4 py-3\">\r\n <div className=\"flex items-center gap-1 w-full\">\r\n {tabs.map(tab => (\r\n <div\r\n key={tab.id}\r\n title={tab.label}\r\n className={`flex-1 min-w-0 truncate text-center px-2 py-2 rounded-md cursor-pointer transition-colors text-xs font-medium ${\r\n activeTab === tab.id\r\n ? 'bg-accent text-accent-foreground'\r\n : 'text-muted-foreground hover:text-foreground hover:bg-accent/50'\r\n }`}\r\n onClick={() => onTabChangeAction(tab.id as SidebarTabType)}\r\n >\r\n {tab.label}\r\n </div>\r\n ))}\r\n </div>\r\n </div>\r\n\r\n <Separator />\r\n </div>\r\n )\r\n}\r\n"],"mappings":";AA8BI,SACE,KADF;AAzBJ,SAAS,uBAAuB;AAGhC,SAAS,iBAAiB;AASnB,SAAS,YAAY,EAAE,WAAW,kBAAkB,GAAqB;AAE9E,QAAM,IAAI,gBAAgB,aAAa;AAEvC,QAAM,OAAO;AAAA,IACX,EAAE,IAAI,QAAQ,OAAO,EAAE,WAAW,EAAE;AAAA,IACpC,EAAE,IAAI,UAAU,OAAO,EAAE,aAAa,EAAE;AAAA,IACxC,EAAE,IAAI,iBAAiB,OAAO,EAAE,oBAAoB,EAAE;AAAA,IACtD,EAAE,IAAI,WAAW,OAAO,EAAE,cAAc,EAAE;AAAA,IAC1C,EAAE,IAAI,YAAY,OAAO,EAAE,eAAe,EAAE;AAAA,EAC9C;AAEA,SACE,qBAAC,SACC;AAAA,wBAAC,aAAU;AAAA,IAEX,oBAAC,SAAI,WAAU,aACb,8BAAC,SAAI,WAAU,kCACZ,eAAK,IAAI,SACR;AAAA,MAAC;AAAA;AAAA,QAEC,OAAO,IAAI;AAAA,QACX,WAAW,iHACT,cAAc,IAAI,KACd,qCACA,gEACN;AAAA,QACA,SAAS,MAAM,kBAAkB,IAAI,EAAoB;AAAA,QAExD,cAAI;AAAA;AAAA,MATA,IAAI;AAAA,IAUX,CACD,GACH,GACF;AAAA,IAEA,oBAAC,aAAU;AAAA,KACb;AAEJ;","names":[]}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { DbFile } from '../../../../../../../types/dbTypes';
|
|
3
|
-
export interface FileItem {
|
|
4
|
-
task: DbFile;
|
|
5
|
-
icon: React.ElementType;
|
|
6
|
-
visible: boolean;
|
|
7
|
-
}
|
|
8
|
-
export declare function CommunicationTab(): React.JSX.Element;
|
|
9
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/core/components/viewers/map/src/MapSidebar/src/CommunicationTab/index.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAI9B,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,oCAAoC,CAAA;AAChE,MAAM,WAAW,QAAQ;IACvB,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,EAAE,KAAK,CAAC,WAAW,CAAA;IACvB,OAAO,EAAE,OAAO,CAAA;CACjB;AAED,wBAAgB,gBAAgB,sBAM/B"}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsx } from "react/jsx-runtime";
|
|
3
|
-
import { CommentsSection } from "../../../../../../ui/Comments/CommentsSection";
|
|
4
|
-
function CommunicationTab() {
|
|
5
|
-
return /* @__PURE__ */ jsx("div", { className: "flex-1 flex flex-col space-y-6 py-4 overflow-hidden", children: /* @__PURE__ */ jsx(CommentsSection, {}) });
|
|
6
|
-
}
|
|
7
|
-
export {
|
|
8
|
-
CommunicationTab
|
|
9
|
-
};
|
|
10
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../../../../../../src/core/components/viewers/map/src/MapSidebar/src/CommunicationTab/index.tsx"],"sourcesContent":["'use client'\r\n\r\n// SPDX-License-Identifier: AGPL-3.0-or-later\r\n// Copyright (C) 2025 Collab Digital Twins\r\n\r\nimport * as React from 'react'\r\n\r\nimport { CommentsSection } from '../../../../../../ui/Comments/CommentsSection'\r\n\r\nimport type { DbFile } from '../../../../../../../types/dbTypes'\r\nexport interface FileItem {\r\n task: DbFile\r\n icon: React.ElementType\r\n visible: boolean\r\n}\r\n\r\nexport function CommunicationTab() {\r\n return (\r\n <div className=\"flex-1 flex flex-col space-y-6 py-4 overflow-hidden\">\r\n <CommentsSection />\r\n </div>\r\n )\r\n}\r\n"],"mappings":";AAmBM;AAZN,SAAS,uBAAuB;AASzB,SAAS,mBAAmB;AACjC,SACE,oBAAC,SAAI,WAAU,uDACb,8BAAC,mBAAgB,GACnB;AAEJ;","names":[]}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { DbFile } from '../../../../../../../types/dbTypes';
|
|
3
|
-
export interface FileItem {
|
|
4
|
-
task: DbFile;
|
|
5
|
-
icon: React.ElementType;
|
|
6
|
-
visible: boolean;
|
|
7
|
-
}
|
|
8
|
-
export declare function SensorsTab(): React.JSX.Element;
|
|
9
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/core/components/viewers/map/src/MapSidebar/src/SensorsTab/index.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAI9B,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,oCAAoC,CAAA;AAChE,MAAM,WAAW,QAAQ;IACvB,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,EAAE,KAAK,CAAC,WAAW,CAAA;IACvB,OAAO,EAAE,OAAO,CAAA;CACjB;AAED,wBAAgB,UAAU,sBAMzB"}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsx } from "react/jsx-runtime";
|
|
3
|
-
import { SensorsSection } from "../../../../../../ui/Sensors/SensorsSection";
|
|
4
|
-
function SensorsTab() {
|
|
5
|
-
return /* @__PURE__ */ jsx("div", { className: "flex-1 flex flex-col space-y-6 py-4 overflow-hidden", children: /* @__PURE__ */ jsx(SensorsSection, {}) });
|
|
6
|
-
}
|
|
7
|
-
export {
|
|
8
|
-
SensorsTab
|
|
9
|
-
};
|
|
10
|
-
//# sourceMappingURL=index.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../../../../../../src/core/components/viewers/map/src/MapSidebar/src/SensorsTab/index.tsx"],"sourcesContent":["'use client'\r\n\r\n// SPDX-License-Identifier: AGPL-3.0-or-later\r\n// Copyright (C) 2025 Collab Digital Twins\r\n\r\nimport * as React from 'react'\r\n\r\nimport { SensorsSection } from '../../../../../../ui/Sensors/SensorsSection'\r\n\r\nimport type { DbFile } from '../../../../../../../types/dbTypes'\r\nexport interface FileItem {\r\n task: DbFile\r\n icon: React.ElementType\r\n visible: boolean\r\n}\r\n\r\nexport function SensorsTab() {\r\n return (\r\n <div className=\"flex-1 flex flex-col space-y-6 py-4 overflow-hidden\">\r\n <SensorsSection />\r\n </div>\r\n )\r\n}\r\n"],"mappings":";AAmBM;AAZN,SAAS,sBAAsB;AASxB,SAAS,aAAa;AAC3B,SACE,oBAAC,SAAI,WAAU,uDACb,8BAAC,kBAAe,GAClB;AAEJ;","names":[]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"PointCloudManagementTable.d.ts","sourceRoot":"","sources":["../../../../../../../src/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudManagementTable.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAY/B,wBAAgB,yBAAyB,CAAC,EAAE,gBAAgB,EAAE,EAAE;IAAE,gBAAgB,CAAC,EAAE,MAAM,CAAA;CAAE,qBAkB5F"}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsx } from "react/jsx-runtime";
|
|
3
|
-
import * as React from "react";
|
|
4
|
-
import { PointCloudTable } from "./PointCloudTable";
|
|
5
|
-
import UploadPointCloudPage from "./PointCloudUploadPanel";
|
|
6
|
-
var PAGE = /* @__PURE__ */ ((PAGE2) => {
|
|
7
|
-
PAGE2["TABLE"] = "table";
|
|
8
|
-
PAGE2["UPLOAD"] = "upload";
|
|
9
|
-
return PAGE2;
|
|
10
|
-
})(PAGE || {});
|
|
11
|
-
function PointCloudManagementTable({ pointcloudApiUrl }) {
|
|
12
|
-
const [currentPage, setCurrentPage] = React.useState("table" /* TABLE */);
|
|
13
|
-
return /* @__PURE__ */ jsx("div", { children: currentPage == "table" /* TABLE */ ? /* @__PURE__ */ jsx(
|
|
14
|
-
PointCloudTable,
|
|
15
|
-
{
|
|
16
|
-
onUploadButtonClick: () => setCurrentPage("upload" /* UPLOAD */),
|
|
17
|
-
pointcloudApiUrl
|
|
18
|
-
}
|
|
19
|
-
) : /* @__PURE__ */ jsx(
|
|
20
|
-
UploadPointCloudPage,
|
|
21
|
-
{
|
|
22
|
-
onGoBackButtonClick: () => setCurrentPage("table" /* TABLE */),
|
|
23
|
-
pointcloudApiUrl
|
|
24
|
-
}
|
|
25
|
-
) });
|
|
26
|
-
}
|
|
27
|
-
export {
|
|
28
|
-
PointCloudManagementTable
|
|
29
|
-
};
|
|
30
|
-
//# sourceMappingURL=PointCloudManagementTable.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../../../../src/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudManagementTable.tsx"],"sourcesContent":["\"use client\";\r\n\r\n// SPDX-License-Identifier: AGPL-3.0-or-later\r\n// Copyright (C) 2025 Collab Digital Twins\r\n\r\nimport * as React from \"react\";\r\n\r\nimport { PointCloudTable } from \"./PointCloudTable\";\r\nimport UploadPointCloudPage from \"./PointCloudUploadPanel\";\r\n\r\ntype StatusFilter = \"all\" | \"uploaded\" | \"converted\" | \"not-converted\";\r\n\r\nenum PAGE {\r\n TABLE = \"table\",\r\n UPLOAD = \"upload\",\r\n}\r\n\r\nexport function PointCloudManagementTable({ pointcloudApiUrl }: { pointcloudApiUrl?: string }) {\r\n const [currentPage, setCurrentPage] = React.useState<PAGE>(PAGE.TABLE)\r\n\r\n return(\r\n <div>\r\n {currentPage == PAGE.TABLE ?\r\n <PointCloudTable\r\n onUploadButtonClick = {() => setCurrentPage(PAGE.UPLOAD)}\r\n pointcloudApiUrl={pointcloudApiUrl}\r\n />\r\n :\r\n <UploadPointCloudPage\r\n onGoBackButtonClick = {() => setCurrentPage(PAGE.TABLE)}\r\n pointcloudApiUrl={pointcloudApiUrl}\r\n />\r\n }\r\n </div>\r\n )\r\n}\r\n\r\n"],"mappings":";AAuBQ;AAlBR,YAAY,WAAW;AAEvB,SAAS,uBAAuB;AAChC,OAAO,0BAA0B;AAIjC,IAAK,OAAL,kBAAKA,UAAL;AACE,EAAAA,MAAA,WAAQ;AACR,EAAAA,MAAA,YAAS;AAFN,SAAAA;AAAA,GAAA;AAKE,SAAS,0BAA0B,EAAE,iBAAiB,GAAkC;AAC7F,QAAM,CAAC,aAAa,cAAc,IAAI,MAAM,SAAe,mBAAU;AAErE,SACE,oBAAC,SACE,yBAAe,sBACd;AAAA,IAAC;AAAA;AAAA,MACC,qBAAuB,MAAM,eAAe,qBAAW;AAAA,MACvD;AAAA;AAAA,EACF,IAEA;AAAA,IAAC;AAAA;AAAA,MACC,qBAAuB,MAAM,eAAe,mBAAU;AAAA,MACtD;AAAA;AAAA,EACF,GAEJ;AAEJ;","names":["PAGE"]}
|
package/dist/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudTable.d.ts
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import * as React from "react";
|
|
2
|
-
type PointCloudTableProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
3
|
-
onUploadButtonClick: () => void;
|
|
4
|
-
pointcloudApiUrl?: string;
|
|
5
|
-
};
|
|
6
|
-
export declare function PointCloudTable({ onUploadButtonClick, pointcloudApiUrl, ...divProps }: PointCloudTableProps): React.JSX.Element;
|
|
7
|
-
export {};
|
|
8
|
-
//# sourceMappingURL=PointCloudTable.d.ts.map
|
package/dist/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudTable.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"PointCloudTable.d.ts","sourceRoot":"","sources":["../../../../../../../src/core/components/viewers/pointcloud/src/PointCloudManagement/PointCloudTable.tsx"],"names":[],"mappings":"AAiBA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAoC/B,KAAK,oBAAoB,GAAG,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,GAAG;IAC/D,mBAAmB,EAAE,MAAM,IAAI,CAAC;IAChC,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC7B,CAAC;AAEF,wBAAgB,eAAe,CAAC,EAC5B,mBAAmB,EACnB,gBAAgB,EAChB,GAAG,QAAQ,EACd,EAAE,oBAAoB,qBAmZtB"}
|
|
@@ -1,350 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
3
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
4
|
-
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
5
|
-
var __objRest = (source, exclude) => {
|
|
6
|
-
var target = {};
|
|
7
|
-
for (var prop in source)
|
|
8
|
-
if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
|
|
9
|
-
target[prop] = source[prop];
|
|
10
|
-
if (source != null && __getOwnPropSymbols)
|
|
11
|
-
for (var prop of __getOwnPropSymbols(source)) {
|
|
12
|
-
if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
|
|
13
|
-
target[prop] = source[prop];
|
|
14
|
-
}
|
|
15
|
-
return target;
|
|
16
|
-
};
|
|
17
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
18
|
-
import {
|
|
19
|
-
Star,
|
|
20
|
-
StarOff,
|
|
21
|
-
Eye,
|
|
22
|
-
Trash2,
|
|
23
|
-
Filter,
|
|
24
|
-
RotateCcw,
|
|
25
|
-
ChevronLeft,
|
|
26
|
-
ChevronRight
|
|
27
|
-
} from "lucide-react";
|
|
28
|
-
import { useRouter, usePathname } from "next/navigation";
|
|
29
|
-
import { useTranslations } from "next-intl";
|
|
30
|
-
import * as React from "react";
|
|
31
|
-
import { toast } from "sonner";
|
|
32
|
-
import ConfirmDialog from "../../../../ConfirmDialog";
|
|
33
|
-
import { Badge, Button, Checkbox, Input, ScrollArea } from "../../../../ui";
|
|
34
|
-
import {
|
|
35
|
-
Table,
|
|
36
|
-
TableBody,
|
|
37
|
-
TableCell,
|
|
38
|
-
TableHead,
|
|
39
|
-
TableHeader,
|
|
40
|
-
TableRow
|
|
41
|
-
} from "../../../../ui/Table";
|
|
42
|
-
import { Tabs, TabsList, TabsTrigger } from "../../../../ui/Tabs";
|
|
43
|
-
var PAGE = /* @__PURE__ */ ((PAGE2) => {
|
|
44
|
-
PAGE2["TABLE"] = "table";
|
|
45
|
-
PAGE2["UPLOAD"] = "upload";
|
|
46
|
-
return PAGE2;
|
|
47
|
-
})(PAGE || {});
|
|
48
|
-
function PointCloudTable(_a) {
|
|
49
|
-
var _b = _a, {
|
|
50
|
-
onUploadButtonClick,
|
|
51
|
-
pointcloudApiUrl
|
|
52
|
-
} = _b, divProps = __objRest(_b, [
|
|
53
|
-
"onUploadButtonClick",
|
|
54
|
-
"pointcloudApiUrl"
|
|
55
|
-
]);
|
|
56
|
-
const API_BASE = pointcloudApiUrl != null ? pointcloudApiUrl : "http://localhost:5101";
|
|
57
|
-
const [pointClouds, setPointClouds] = React.useState([]);
|
|
58
|
-
const [loading, setLoading] = React.useState(false);
|
|
59
|
-
const [error, setError] = React.useState(null);
|
|
60
|
-
const [search, setSearch] = React.useState("");
|
|
61
|
-
const [statusFilter, setStatusFilter] = React.useState("all");
|
|
62
|
-
const [favorites, setFavorites] = React.useState(/* @__PURE__ */ new Set());
|
|
63
|
-
const [currentUrl, setCurrentUrl] = React.useState(null);
|
|
64
|
-
const [deleteTarget, setDeleteTarget] = React.useState(null);
|
|
65
|
-
const [isDeleting, setIsDeleting] = React.useState(false);
|
|
66
|
-
const t = useTranslations("PointCloudManagement");
|
|
67
|
-
React.useEffect(() => {
|
|
68
|
-
const url = new URL(window.location.href);
|
|
69
|
-
setCurrentUrl(url);
|
|
70
|
-
}, []);
|
|
71
|
-
const [currentPage, setCurrentPage] = React.useState("table" /* TABLE */);
|
|
72
|
-
const router = useRouter();
|
|
73
|
-
const pathname = usePathname();
|
|
74
|
-
const loadPointClouds = React.useCallback(async () => {
|
|
75
|
-
setLoading(true);
|
|
76
|
-
setError(null);
|
|
77
|
-
try {
|
|
78
|
-
const res = await fetch(`${API_BASE}/point-cloud`, {
|
|
79
|
-
headers: { "Accept": "application/json" }
|
|
80
|
-
});
|
|
81
|
-
if (!res.ok) {
|
|
82
|
-
throw new Error(`Failed to fetch point clouds (${res.status})`);
|
|
83
|
-
}
|
|
84
|
-
const data = await res.json();
|
|
85
|
-
setPointClouds(Array.isArray(data) ? data : []);
|
|
86
|
-
} catch (err) {
|
|
87
|
-
console.error(err);
|
|
88
|
-
setError(
|
|
89
|
-
err instanceof Error ? err.message : "Unknown error while loading data"
|
|
90
|
-
);
|
|
91
|
-
} finally {
|
|
92
|
-
setLoading(false);
|
|
93
|
-
}
|
|
94
|
-
}, []);
|
|
95
|
-
React.useEffect(() => {
|
|
96
|
-
loadPointClouds();
|
|
97
|
-
}, [loadPointClouds]);
|
|
98
|
-
const openViewer = (pointCloudId) => {
|
|
99
|
-
if (!pointCloudId) return;
|
|
100
|
-
const origin = window.location.origin;
|
|
101
|
-
const pathname2 = window.location.pathname;
|
|
102
|
-
const params = new URLSearchParams(currentUrl.search);
|
|
103
|
-
params.set("viewer", "pointcloud");
|
|
104
|
-
params.set("pointCloudId", pointCloudId);
|
|
105
|
-
const newurl = `${origin}${pathname2}?${params.toString()}`;
|
|
106
|
-
router.push(newurl, { scroll: false });
|
|
107
|
-
};
|
|
108
|
-
const handleDelete = async () => {
|
|
109
|
-
if (!deleteTarget) return;
|
|
110
|
-
setIsDeleting(true);
|
|
111
|
-
try {
|
|
112
|
-
const res = await fetch(`${API_BASE}/point-cloud/${deleteTarget.id}`, {
|
|
113
|
-
method: "DELETE"
|
|
114
|
-
});
|
|
115
|
-
if (!res.ok) {
|
|
116
|
-
const msg = await res.text();
|
|
117
|
-
throw new Error(msg || `Delete failed (${res.status})`);
|
|
118
|
-
}
|
|
119
|
-
setPointClouds((prev) => prev.filter((pc) => pc.id !== deleteTarget.id));
|
|
120
|
-
setFavorites((prev) => {
|
|
121
|
-
const next = new Set(prev);
|
|
122
|
-
next.delete(deleteTarget.id);
|
|
123
|
-
return next;
|
|
124
|
-
});
|
|
125
|
-
toast.success(t("deleteSuccess", { name: deleteTarget.name }));
|
|
126
|
-
} catch (err) {
|
|
127
|
-
console.error(err);
|
|
128
|
-
toast.error(
|
|
129
|
-
err instanceof Error ? t("deleteFailedWithReason", { error: err.message }) : t("deleteFailed")
|
|
130
|
-
);
|
|
131
|
-
} finally {
|
|
132
|
-
setIsDeleting(false);
|
|
133
|
-
setDeleteTarget(null);
|
|
134
|
-
}
|
|
135
|
-
};
|
|
136
|
-
const toggleFavorite = (id) => {
|
|
137
|
-
setFavorites((prev) => {
|
|
138
|
-
const next = new Set(prev);
|
|
139
|
-
if (next.has(id)) next.delete(id);
|
|
140
|
-
else next.add(id);
|
|
141
|
-
return next;
|
|
142
|
-
});
|
|
143
|
-
};
|
|
144
|
-
const filtered = React.useMemo(() => {
|
|
145
|
-
return pointClouds.filter((pc) => {
|
|
146
|
-
const matchesSearch = !search || pc.name.toLowerCase().includes(search.toLowerCase()) || pc.id.toLowerCase().includes(search.toLowerCase());
|
|
147
|
-
let matchesStatus = true;
|
|
148
|
-
if (statusFilter === "uploaded") {
|
|
149
|
-
matchesStatus = pc.point_cloud_uploaded;
|
|
150
|
-
} else if (statusFilter === "converted") {
|
|
151
|
-
matchesStatus = pc.point_cloud_potree_converted;
|
|
152
|
-
} else if (statusFilter === "not-converted") {
|
|
153
|
-
matchesStatus = pc.point_cloud_uploaded && !pc.point_cloud_potree_converted;
|
|
154
|
-
}
|
|
155
|
-
return matchesSearch && matchesStatus;
|
|
156
|
-
});
|
|
157
|
-
}, [pointClouds, search, statusFilter]);
|
|
158
|
-
return /* @__PURE__ */ jsxs("div", { className: `p-2 mt-20 ${divProps}`, children: [
|
|
159
|
-
/* @__PURE__ */ jsxs("div", { className: "flex items-start justify-between gap-4", children: [
|
|
160
|
-
/* @__PURE__ */ jsx("div", { className: "space-y-1", children: /* @__PURE__ */ jsx("h1", { className: "text-2xl font-semibold tracking-tight", children: "Point Clouds" }) }),
|
|
161
|
-
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
|
|
162
|
-
/* @__PURE__ */ jsx(
|
|
163
|
-
Input,
|
|
164
|
-
{
|
|
165
|
-
placeholder: "Search point clouds...",
|
|
166
|
-
className: "w-[240px]",
|
|
167
|
-
value: search,
|
|
168
|
-
onChange: (e) => setSearch(e.target.value)
|
|
169
|
-
}
|
|
170
|
-
),
|
|
171
|
-
/* @__PURE__ */ jsx(Button, { variant: "outline", size: "icon", title: "Filters (not wired)", children: /* @__PURE__ */ jsx(Filter, { className: "h-4 w-4" }) }),
|
|
172
|
-
/* @__PURE__ */ jsx(
|
|
173
|
-
Button,
|
|
174
|
-
{
|
|
175
|
-
variant: "outline",
|
|
176
|
-
size: "icon",
|
|
177
|
-
onClick: loadPointClouds,
|
|
178
|
-
disabled: loading,
|
|
179
|
-
title: "Refresh",
|
|
180
|
-
children: /* @__PURE__ */ jsx(RotateCcw, { className: "h-4 w-4" })
|
|
181
|
-
}
|
|
182
|
-
)
|
|
183
|
-
] })
|
|
184
|
-
] }),
|
|
185
|
-
/* @__PURE__ */ jsx(
|
|
186
|
-
Tabs,
|
|
187
|
-
{
|
|
188
|
-
value: statusFilter,
|
|
189
|
-
onValueChange: (val) => setStatusFilter(val),
|
|
190
|
-
className: "w-full mb-2",
|
|
191
|
-
children: /* @__PURE__ */ jsxs(TabsList, { className: "h-8", children: [
|
|
192
|
-
/* @__PURE__ */ jsx(TabsTrigger, { value: "all", className: "px-3", children: "All" }),
|
|
193
|
-
/* @__PURE__ */ jsx(TabsTrigger, { value: "uploaded", className: "px-3", children: "Uploaded" }),
|
|
194
|
-
/* @__PURE__ */ jsx(TabsTrigger, { value: "converted", className: "px-3", children: "Converted" }),
|
|
195
|
-
/* @__PURE__ */ jsx(TabsTrigger, { value: "not-converted", className: "px-3", children: "Needs conversion" })
|
|
196
|
-
] })
|
|
197
|
-
}
|
|
198
|
-
),
|
|
199
|
-
/* @__PURE__ */ jsxs("div", { className: "rounded-md border bg-background", children: [
|
|
200
|
-
/* @__PURE__ */ jsx(ScrollArea, { className: "max-h-[520px]", children: /* @__PURE__ */ jsxs(Table, { children: [
|
|
201
|
-
/* @__PURE__ */ jsx(TableHeader, { className: "sticky top-0 z-10 bg-background/95 backdrop-blur", children: /* @__PURE__ */ jsxs(TableRow, { children: [
|
|
202
|
-
/* @__PURE__ */ jsx(TableHead, { className: "w-[40px] pl-4", children: /* @__PURE__ */ jsx(Checkbox, { "aria-label": "Select all" }) }),
|
|
203
|
-
/* @__PURE__ */ jsx(TableHead, { className: "w-[48px]" }),
|
|
204
|
-
/* @__PURE__ */ jsx(TableHead, { className: "min-w-[220px]", children: "Name" }),
|
|
205
|
-
/* @__PURE__ */ jsx(TableHead, { className: "w-[200px]", children: "Status" }),
|
|
206
|
-
/* @__PURE__ */ jsx(TableHead, { className: "w-[220px]", children: "Created" }),
|
|
207
|
-
/* @__PURE__ */ jsx(TableHead, { className: "w-[160px]", children: "Metadata" }),
|
|
208
|
-
/* @__PURE__ */ jsx(TableHead, { className: "w-[140px] text-right pr-4", children: "Actions" })
|
|
209
|
-
] }) }),
|
|
210
|
-
/* @__PURE__ */ jsxs(TableBody, { children: [
|
|
211
|
-
loading && pointClouds.length === 0 && /* @__PURE__ */ jsx(TableRow, { children: /* @__PURE__ */ jsx(TableCell, { colSpan: 7, className: "h-24 text-center", children: "Loading point clouds\u2026" }) }),
|
|
212
|
-
!loading && error && /* @__PURE__ */ jsx(TableRow, { children: /* @__PURE__ */ jsx(TableCell, { colSpan: 7, className: "h-24 text-center", children: /* @__PURE__ */ jsx("span", { className: "text-sm text-destructive", children: error }) }) }),
|
|
213
|
-
!loading && !error && filtered.length === 0 && /* @__PURE__ */ jsx(TableRow, { children: /* @__PURE__ */ jsx(TableCell, { colSpan: 7, className: "h-24 text-center", children: /* @__PURE__ */ jsx("span", { className: "text-sm text-muted-foreground", children: "No point clouds found." }) }) }),
|
|
214
|
-
filtered.map((pc) => {
|
|
215
|
-
const isFavorite = favorites.has(pc.id);
|
|
216
|
-
return /* @__PURE__ */ jsxs(
|
|
217
|
-
TableRow,
|
|
218
|
-
{
|
|
219
|
-
className: "hover:bg-muted/50 transition-colors",
|
|
220
|
-
children: [
|
|
221
|
-
/* @__PURE__ */ jsx(TableCell, { className: "pl-4", children: /* @__PURE__ */ jsx(Checkbox, { "aria-label": `Select ${pc.name}` }) }),
|
|
222
|
-
/* @__PURE__ */ jsx(TableCell, { className: "text-center", children: /* @__PURE__ */ jsx(
|
|
223
|
-
"button",
|
|
224
|
-
{
|
|
225
|
-
type: "button",
|
|
226
|
-
onClick: () => toggleFavorite(pc.id),
|
|
227
|
-
className: "inline-flex h-6 w-6 items-center justify-center rounded-full text-muted-foreground hover:text-yellow-500",
|
|
228
|
-
"aria-label": isFavorite ? `Remove ${pc.name} from favourites` : `Add ${pc.name} to favourites`,
|
|
229
|
-
children: isFavorite ? /* @__PURE__ */ jsx(Star, { className: "h-4 w-4 fill-yellow-400" }) : /* @__PURE__ */ jsx(StarOff, { className: "h-4 w-4" })
|
|
230
|
-
}
|
|
231
|
-
) }),
|
|
232
|
-
/* @__PURE__ */ jsxs(TableCell, { children: [
|
|
233
|
-
/* @__PURE__ */ jsx("div", { className: "font-medium", children: pc.name }),
|
|
234
|
-
/* @__PURE__ */ jsx("div", { className: "text-xs text-muted-foreground", children: pc.id })
|
|
235
|
-
] }),
|
|
236
|
-
/* @__PURE__ */ jsx(TableCell, { children: /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap gap-1", children: [
|
|
237
|
-
/* @__PURE__ */ jsx(
|
|
238
|
-
Badge,
|
|
239
|
-
{
|
|
240
|
-
className: `text-xs border ${pc.point_cloud_uploaded ? "bg-emerald-50 text-emerald-700 border-emerald-200" : "bg-rose-50 text-rose-700 border-rose-200"}`,
|
|
241
|
-
children: pc.point_cloud_uploaded ? "Uploaded" : "Not uploaded"
|
|
242
|
-
}
|
|
243
|
-
),
|
|
244
|
-
/* @__PURE__ */ jsx(
|
|
245
|
-
Badge,
|
|
246
|
-
{
|
|
247
|
-
className: `text-xs border ${pc.point_cloud_potree_converted ? "bg-sky-50 text-sky-700 border-sky-200" : "bg-amber-50 text-amber-700 border-amber-200"}`,
|
|
248
|
-
children: pc.point_cloud_potree_converted ? "Ready to view" : "Needs conversion"
|
|
249
|
-
}
|
|
250
|
-
)
|
|
251
|
-
] }) }),
|
|
252
|
-
/* @__PURE__ */ jsx(TableCell, { className: "whitespace-nowrap text-sm text-muted-foreground", children: new Date(pc.createdAt).toLocaleString() }),
|
|
253
|
-
/* @__PURE__ */ jsx(TableCell, { children: pc.potree_metadata_presigned_url ? /* @__PURE__ */ jsx(
|
|
254
|
-
Button,
|
|
255
|
-
{
|
|
256
|
-
asChild: true,
|
|
257
|
-
variant: "link",
|
|
258
|
-
size: "sm",
|
|
259
|
-
className: "px-0",
|
|
260
|
-
children: /* @__PURE__ */ jsx(
|
|
261
|
-
"a",
|
|
262
|
-
{
|
|
263
|
-
href: pc.potree_metadata_presigned_url,
|
|
264
|
-
target: "_blank",
|
|
265
|
-
rel: "noreferrer",
|
|
266
|
-
children: "metadata.json"
|
|
267
|
-
}
|
|
268
|
-
)
|
|
269
|
-
}
|
|
270
|
-
) : /* @__PURE__ */ jsx("span", { className: "text-xs text-muted-foreground", children: "\u2014" }) }),
|
|
271
|
-
/* @__PURE__ */ jsx(TableCell, { className: "pr-4 text-right", children: /* @__PURE__ */ jsxs("div", { className: "flex justify-end gap-2", children: [
|
|
272
|
-
/* @__PURE__ */ jsx(
|
|
273
|
-
Button,
|
|
274
|
-
{
|
|
275
|
-
variant: "outline",
|
|
276
|
-
size: "icon",
|
|
277
|
-
disabled: !pc.potree_metadata_file_key,
|
|
278
|
-
onClick: () => openViewer(pc.id),
|
|
279
|
-
title: "Open Potree viewer",
|
|
280
|
-
children: /* @__PURE__ */ jsx(Eye, { className: "h-4 w-4" })
|
|
281
|
-
}
|
|
282
|
-
),
|
|
283
|
-
/* @__PURE__ */ jsx(
|
|
284
|
-
Button,
|
|
285
|
-
{
|
|
286
|
-
variant: "ghost",
|
|
287
|
-
size: "icon",
|
|
288
|
-
className: "text-destructive hover:text-destructive",
|
|
289
|
-
onClick: () => setDeleteTarget(pc),
|
|
290
|
-
title: t("deleteTitle"),
|
|
291
|
-
children: /* @__PURE__ */ jsx(Trash2, { className: "h-4 w-4" })
|
|
292
|
-
}
|
|
293
|
-
)
|
|
294
|
-
] }) })
|
|
295
|
-
]
|
|
296
|
-
},
|
|
297
|
-
pc.id
|
|
298
|
-
);
|
|
299
|
-
})
|
|
300
|
-
] })
|
|
301
|
-
] }) }),
|
|
302
|
-
/* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between border-t px-4 py-2 text-xs text-muted-foreground", children: [
|
|
303
|
-
/* @__PURE__ */ jsxs("div", { children: [
|
|
304
|
-
"Showing ",
|
|
305
|
-
/* @__PURE__ */ jsx("span", { className: "font-medium", children: filtered.length }),
|
|
306
|
-
" of",
|
|
307
|
-
" ",
|
|
308
|
-
/* @__PURE__ */ jsx("span", { className: "font-medium", children: pointClouds.length }),
|
|
309
|
-
" point clouds"
|
|
310
|
-
] }),
|
|
311
|
-
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-1", children: [
|
|
312
|
-
/* @__PURE__ */ jsx(Button, { variant: "ghost", size: "icon", disabled: true, children: /* @__PURE__ */ jsx(ChevronLeft, { className: "h-4 w-4" }) }),
|
|
313
|
-
/* @__PURE__ */ jsx(Button, { variant: "ghost", size: "icon", disabled: true, children: /* @__PURE__ */ jsx(ChevronRight, { className: "h-4 w-4" }) })
|
|
314
|
-
] })
|
|
315
|
-
] })
|
|
316
|
-
] }),
|
|
317
|
-
/* @__PURE__ */ jsx(
|
|
318
|
-
Button,
|
|
319
|
-
{
|
|
320
|
-
onClick: () => {
|
|
321
|
-
if (onUploadButtonClick != void 0) {
|
|
322
|
-
onUploadButtonClick();
|
|
323
|
-
}
|
|
324
|
-
},
|
|
325
|
-
className: "mt-1 flex gap-2",
|
|
326
|
-
children: "Upload point cloud \u2192"
|
|
327
|
-
}
|
|
328
|
-
),
|
|
329
|
-
/* @__PURE__ */ jsx(
|
|
330
|
-
ConfirmDialog,
|
|
331
|
-
{
|
|
332
|
-
isOpen: deleteTarget != null,
|
|
333
|
-
isDeleting,
|
|
334
|
-
onOpenChange: (open) => {
|
|
335
|
-
if (!open) setDeleteTarget(null);
|
|
336
|
-
},
|
|
337
|
-
handleConfirm: async (e) => {
|
|
338
|
-
e.preventDefault();
|
|
339
|
-
await handleDelete();
|
|
340
|
-
},
|
|
341
|
-
itemName: deleteTarget == null ? void 0 : deleteTarget.name,
|
|
342
|
-
dataType: t("pointCloudItem")
|
|
343
|
-
}
|
|
344
|
-
)
|
|
345
|
-
] });
|
|
346
|
-
}
|
|
347
|
-
export {
|
|
348
|
-
PointCloudTable
|
|
349
|
-
};
|
|
350
|
-
//# sourceMappingURL=PointCloudTable.js.map
|