Skip to content

Commit a309068

Browse files
committed
Fix: removed useless exports
1 parent fa40455 commit a309068

File tree

1 file changed

+6
-10
lines changed

1 file changed

+6
-10
lines changed

src/utils/transformer.ts

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
import { ElementType } from "@/components/workspace/elements";
2-
import { dataAttributes, selectors } from "@/constants";
2+
import { dataAttributes } from "@/constants";
33
import { store } from "@/store";
44
import { ISTKData, ISeat } from "@/types";
55
import { rgbToHex } from ".";
66
import { default as d3Extended } from "./d3";
77

8-
export const domSeatsToJSON = (seats: ISeat[]) => {
8+
const domSeatsToJSON = (seats: ISeat[]) => {
99
return d3Extended.selectAll(`[${dataAttributes.elementType}="${ElementType.Seat}"]`).map((seat) => {
1010
const id = seat.attr("id");
1111
const square = (seat.node() as any)?.nodeName === "rect";
@@ -23,7 +23,7 @@ export const domSeatsToJSON = (seats: ISeat[]) => {
2323
});
2424
};
2525

26-
export const domTextToJSON = () => {
26+
const domTextToJSON = () => {
2727
return d3Extended.selectAll(`[${dataAttributes.elementType}="${ElementType.Text}"]`).map((text) => {
2828
return {
2929
id: text.attr("id"),
@@ -40,7 +40,7 @@ export const domTextToJSON = () => {
4040
});
4141
};
4242

43-
export const domShapesToJSON = () => {
43+
const domShapesToJSON = () => {
4444
return d3Extended.selectAll(`[${dataAttributes.elementType}="${ElementType.Shape}"]`).map((shape) => {
4545
return {
4646
id: shape.attr("id"),
@@ -57,7 +57,7 @@ export const domShapesToJSON = () => {
5757
});
5858
};
5959

60-
export const domPolylineToJSON = () => {
60+
const domPolylineToJSON = () => {
6161
return d3Extended
6262
.selectAll(`[${dataAttributes.elementType}="${ElementType.Polyline}"]`)
6363
.map((polyline) => {
@@ -79,7 +79,7 @@ export const domPolylineToJSON = () => {
7979
.filter((polyline) => polyline.points.length > 1);
8080
};
8181

82-
export const domImagesToJSON = () => {
82+
const domImagesToJSON = () => {
8383
return d3Extended.selectAll(`[${dataAttributes.elementType}="${ElementType.Image}"]`).map((image) => {
8484
return {
8585
id: image.attr("id"),
@@ -94,10 +94,6 @@ export const domImagesToJSON = () => {
9494
});
9595
};
9696

97-
export const domTransform = () => {
98-
return d3Extended.zoomTransform(document.querySelector(selectors.workspaceGroup));
99-
};
100-
10197
export const stateToJSON = (): ISTKData => {
10298
const state = store.getState().editor;
10399
return {

0 commit comments

Comments
 (0)