worked on scanners, database, tracks, some moving around and cleaning up files.
diff --git a/src/utils/createPageIndicator.ts b/src/utils/createPageIndicator.ts
index 4ddbae2..29ea83b 100644
--- a/src/utils/createPageIndicator.ts
+++ b/src/utils/createPageIndicator.ts
@@ -21,4 +21,23 @@
return out;
}
+export const verticalTrackIndicator = (position: number, active: string | boolean, size: number, disabled: string | boolean) => {
+ active = active ? "ACTIVE" : "INACTIVE";
+ disabled = disabled ? "GREY." : "";
+ if (position === 0 && size === 1) return "TRACKS.SINGLE." + disabled + active;
+ if (position === size - 1) return "TRACKS.VERTICAL.BOTTOM." + disabled + active;
+ if (position === 0) return "TRACKS.VERTICAL.TOP." + disabled + active;
+ return "TRACKS.VERTICAL.MIDDLE." + disabled + active;
+};
+
+export const createVerticalTrack = (items: string[], active: boolean[], disabled?: boolean[]) => {
+ let out = "";
+ if (!disabled) disabled = new Array(items.length).fill(false);
+ for (let i = 0; i < items.length; i++) {
+ out += getEmojiByName(verticalTrackIndicator(i, active[i] ?? false, items.length, disabled[i] ?? false));
+ out += items[i] + "\n";
+ }
+ return out;
+}
+
export default pageIndicator;