From b3f34519b616ccd30f69903b831f81377375b786 Mon Sep 17 00:00:00 2001 From: David Leoni Date: Thu, 10 Sep 2020 16:58:36 +0200 Subject: [PATCH] proper organism tab #19: display warning upon reaching tree limit --- docs/performance-test.sb3 | Bin 0 -> 6888 bytes src/components/botch/botch-life-tree.jsx | 10 ++++++++++ src/containers/botch-organism-tab.jsx | 2 +- 3 files changed, 11 insertions(+), 1 deletion(-) create mode 100644 docs/performance-test.sb3 diff --git a/docs/performance-test.sb3 b/docs/performance-test.sb3 new file mode 100644 index 0000000000000000000000000000000000000000..98c408dbd5fa2abd6dfeb495621683b2d3b8b752 GIT binary patch literal 6888 zcma)>bxd4qx5ft;rh~h?mf|unIK|x^O7X$9xE6;(p|}@!cXzkqUYwQ!#jO;(obS8I zxu?lZ&VKj%$4>TolJ#com1qB!iaY`k82|u)0pYfcsz~$2FdZNO@Q4ZkJl_CEX9sI@ zQx{h2cMkR)Nr&32JhSl6;@=P}0&(fQ(CBL!39~bD!qqFh z5jy==_Z?cEYQ_?^o|>*4FCY6h8b0opa;nc<1Edp!b4tRkbmy&O%HDHX9k)%7F%X0s zK{nn6+|6?1%Zkk|6TI1NS+_$eK^8YB3UL+^l~z-0kcY6+^IT@jGfxI^MC=SV+Km<9 z50KO4M0Qu0a^k?@&YDR zf$Q2-EhJn*c5uJ3Q_DYO%8eky?|40}#;*89U~*5`AhonML}VOkV$7By%?uvm(?QBE zHeeO4mP(Zg@j)bBS16AhQGttve+SD~8jzKGb$papub(iGjGqxxhB8k`!@Bp4;ha@2 zRpD537X<~ymYdb7{gKH4DU1Zsj=-kEa8QbslR3PG0x85hlU1<>hKOBbJ5cR#=#Za5Ezxmb8Jeyu}fv)O0dLu@Ro4b-rrSX+o*c!<00@*~0 zFLh>woZ7_Wuo!z;m`p_&kMNthyI}A_$ffAIGpoC6fRCbX@_yRl$+BVe6CeNaqvlWF zPH{gkr+RhgAg<6ullS_Iz^691_5-w=LH*5nd*+7oDYS>5k(0$a~p7E>O2?DQj9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x2ptge5iyN1Br; zQz8x(KM!-!%E9N5GK%Ja-<0+!0LobqF}h^FRM1^PohYW_8MIer1hZ-qqTv%UBEd}_ z;Gbq0qX@olq&$1=_X!x?N}nxh(Ag}WSAH0T7cPOASIbTai$Dsctg>D>LjV=h3O+ikk^p>MG1CTm=eeX<#Jq7aOQNyWl#)@mNadhfN zAFwu7+tl!iUbjq;DE3CTJT2o#iR{U`V#$mN2v*s!K3v%ScqMsg^%@V;EN(g=4XYvP zf>BzjF5~9Fc0eu|2dscm9=uEKrv=#~(~C$lLSl<}s|PR0z<3(eG7^7Ehs*Rb%P8+W z%^OfGSjEvzjFwUvbfRZ>+Ych16Jy2fu7J!8wnWtkN!dp)aEeF0tBxgu6W(M25nYhl zT$Zsk7H_>mDV`Z8v-{K?G+XmBd7`$D!#w21RI>+2RT3hl=`08)oFp@{a|G)cUX7`v zHgg-ZertG7MkV>t%k(Z=p}E4UQA@X|7J=Ulx+viD(o+trFM7%uHGmk_LQ60)02E+s zN*fGGY*nw@a@NNhK#yxsjf3YkN;je`%fI~c_$h6bV%p#kocLxQOdSpI9(4grYn3bu z>I}q@taz7V!I<+XSd{y}BHd!_ilL;j5XlUx2B7Wh0*`8O2vPsKlx)ZdD?pnnIb{#5*v2mP)1<=L7vd_{pD&f4Zl?6(z6$fPdqqROAt#&j$biJ+HZE^7Tmg*VF$1kF6&; literal 0 HcmV?d00001 diff --git a/src/components/botch/botch-life-tree.jsx b/src/components/botch/botch-life-tree.jsx index 58f00a08589..a9a1c6df12d 100644 --- a/src/components/botch/botch-life-tree.jsx +++ b/src/components/botch/botch-life-tree.jsx @@ -13,6 +13,8 @@ import styles from './botch-life-tree.css'; import BotchLifeTreeItem from './botch-life-tree-item.jsx'; import log from '../../lib/log.js'; +/* global BOTCH */ + const messages = defineMessages({ filterPlaceholder: { id: 'gui.library.filterPlaceholder', @@ -296,6 +298,14 @@ class BotchLifeTree extends React.Component { ))} + {Object.keys(fl).length >= BOTCH.constructor.MAX_STORAGE ? + {`TREE IS FULL ! To empty it, click on the green flag!`} : + null} ); } diff --git a/src/containers/botch-organism-tab.jsx b/src/containers/botch-organism-tab.jsx index 639bd77fab8..76aa2811296 100644 --- a/src/containers/botch-organism-tab.jsx +++ b/src/containers/botch-organism-tab.jsx @@ -173,7 +173,7 @@ class BotchOrganismTab extends React.Component { const layout = {}; - // fictitious node, outside viewport on purpose + // fictitious node, outside viewBox on purpose const p0 = {}; p0.generation = 0;