From 064708ec835e873c016af78ccf44578a6cfc9cba Mon Sep 17 00:00:00 2001
From: bobzel <zzzman@gmail.com>
Date: Tue, 12 Apr 2022 00:09:46 -0400
Subject: cleaned up pileView to feel somewhat usable by tweaking icon sizes,
 and making icon<->doc toggleable by just clicking.

---
 .../collectionFreeForm/CollectionFreeFormLayoutEngines.tsx  | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)

(limited to 'src/client/views/collections/collectionFreeForm/CollectionFreeFormLayoutEngines.tsx')

diff --git a/src/client/views/collections/collectionFreeForm/CollectionFreeFormLayoutEngines.tsx b/src/client/views/collections/collectionFreeForm/CollectionFreeFormLayoutEngines.tsx
index 9fed82dae..f9345e33f 100644
--- a/src/client/views/collections/collectionFreeForm/CollectionFreeFormLayoutEngines.tsx
+++ b/src/client/views/collections/collectionFreeForm/CollectionFreeFormLayoutEngines.tsx
@@ -113,16 +113,17 @@ export function computerStarburstLayout(
 ) {
     const docMap = new Map<string, PoolData>();
     const burstRadius = [NumCast(pivotDoc._starburstRadius, panelDim[0]), NumCast(pivotDoc._starburstRadius, panelDim[1])];
-    const docScale = NumCast(pivotDoc._starburstDocScale);
-    const docSize = docScale * 100; // assume a icon sized at 100
+    const docSize = 75; // assume a icon sized at 100
     const scaleDim = [burstRadius[0] + docSize, burstRadius[1] + docSize];
     childPairs.forEach(({ layout, data }, i) => {
+        const docSize = layout.layoutKey === "layout_icon" ? 75 : 400; // assume a icon sized at 100
         const deg = i / childPairs.length * Math.PI * 2;
         docMap.set(layout[Id], {
-            x: Math.cos(deg) * (burstRadius[0] / 3) - docScale * layout[WidthSym]() / 2,
-            y: Math.sin(deg) * (burstRadius[1] / 3) - docScale * layout[HeightSym]() / 2,
-            width: docScale * layout[WidthSym](),
-            height: docScale * layout[HeightSym](),
+            x: Math.cos(deg) * (burstRadius[0] / 3) - docSize / 2,
+            y: Math.sin(deg) * (burstRadius[1] / 3) - docSize * layout[HeightSym]() / layout[WidthSym]() / 2,
+            width: docSize,//layout[WidthSym](),
+            height: docSize * layout[HeightSym]() / layout[WidthSym](),
+            zIndex: NumCast(layout.zIndex),
             pair: { layout, data },
             replica: ""
         });
-- 
cgit v1.2.3-70-g09d2

