EmmaRamirez / nuzlocke-generator

📃 A nuzlocke template generator.
https://nuzlocke-generator.com/
28 stars 6 forks source link

Dead box doesn't match margin-top property of other boxes #309

Open EmmaRamirez opened 4 years ago

EmmaRamirez commented 4 years ago

By default, .boxed-contained .dead-container sets `margin-top: 1 rem;'. All other boxes set this to 0.5 rem, which sets the dead container lower visually. See attached json for an example.

{"box":[{"id":0,"position":0,"name":"Team"},{"id":1,"position":1,"name":"Boxed"},{"id":2,"position":2,"name":"Dead"},{"id":3,"position":2,"name":"Champs"},{"id":4,"name":"Got Away","position":5,"background":"grass-meadow","inheritFrom":"Dead"}],"checkpoints":[{"name":"Zephyr Badge","image":"zephyr-badge"},{"name":"Hive Badge","image":"hive-badge"},{"name":"Plain Badge","image":"plain-badge"},{"name":"Fog Badge","image":"fog-badge"},{"name":"Storm Badge","image":"storm-badge"},{"name":"Mineral Badge","image":"mineral-badge"},{"name":"Glacier Badge","image":"glacier-badge"},{"name":"Rising Badge","image":"rising-badge"},{"name":"Boulder Badge","image":"boulder-badge"},{"name":"Cascade Badge","image":"cascade-badge"},{"name":"Thunder Badge","image":"thunder-badge"},{"name":"Rainbow Badge","image":"rainbow-badge"},{"name":"Soul Badge","image":"soul-badge"},{"name":"Marsh Badge","image":"marsh-badge"},{"name":"Volcano Badge","image":"volcano-badge"},{"name":"Earth Badge","image":"earth-badge"}],"confirmation":true,"customMoveMap":[],"customTypes":[],"game":{"name":"SoulSilver","customName":"Soul Silver Nostalgia #2"},"nuzlockes":{"currentId":"","saves":[]},"pokemon":[{"id":"30838a61-4628-465c-815f-db53d929a4b7","position":0,"species":"Quilava","nickname":"Tyler","status":"Team","gender":"Male","level":"18","met":"New Bark Town","metLevel":"5","nature":"Adamant","ability":"Blaze","types":["Fire","Fire"],"egg":false,"moves":["Quick Attack","Ember","Smokescreen","Leer"]},{"id":"24eb0ea2-55d2-4e07-846e-60a50133ccb4","position":1,"species":"Geodude","nickname":"Genevieve","status":"Team","gender":"Female","level":"20","met":"Dark Cave","metLevel":"2","nature":"Relaxed","ability":"Rock Head","types":["Rock","Ground"],"egg":false,"gameOfOrigin":"SoulSilver","moves":["Rock Throw","Rock Polish","Magnitude","Self-Destruct"]},{"id":"66a086f2-c517-41e6-99cc-ecef73d9fa35","position":2,"species":"Sentret","nickname":"","status":"Got Away","gender":"genderless","level":"","met":"Route 29","metLevel":"3","nature":"None","ability":"","types":["Normal","Normal"],"egg":false,"gameOfOrigin":"SoulSilver","hidden":true},{"id":"bc5df235-081c-47ab-a9b4-01bdc87d8e76","position":3,"species":"Weedle","nickname":"","status":"Got Away","gender":"genderless","met":"Route 31","metLevel":"3","nature":"None","ability":"","types":["Bug","Poison"],"egg":false,"gameOfOrigin":"SoulSilver","hidden":true},{"id":"8e8d099c-310f-40ca-9a73-fede1328c87f","position":4,"species":"Weedle","nickname":"","status":"Got Away","gender":"genderless","met":"Route 30","metLevel":"3","nature":"None","ability":"","types":["Bug","Poison"],"egg":false,"gameOfOrigin":"SoulSilver","hidden":true},{"id":"4c46efa3-ba47-412e-b1f9-7d8cfa60cef3","position":5,"species":"Drowzee","nickname":"","status":"Got Away","gender":"genderless","met":"Route 34","metLevel":"10","nature":"None","ability":"","types":["Psychic","Psychic"],"egg":false,"gameOfOrigin":"SoulSilver","hidden":true},{"id":"5cab723b-b19c-40ea-96f9-8ee5d0f35834","position":6,"species":"Paras","nickname":"Princeton","status":"Dead","gender":"genderless","level":"10","met":"Ilex Forest","metLevel":"5","nature":"None","ability":"","types":["Bug","Grass"],"egg":false,"gameOfOrigin":"SoulSilver","deathTimestamp":1596458613245,"moves":["Scratch","Bullet Seed","Stun Spore","Poisonpowder"]},{"id":"b074f520-73f9-47dc-bb6f-ee5acc58e8c5","position":7,"species":"Zubat","nickname":"Count Down","status":"Team","gender":"Female","level":"17","met":"Slowpoke Well","metLevel":"6","nature":"Impish","ability":"Inner Focus","types":["Poison","Flying"],"egg":false,"gameOfOrigin":"SoulSilver","moves":["Wing Attack","Supersonic","Astonish","Bite"]},{"id":"d3027b2a-bef9-40f1-95b6-13066e8c3fa9","position":8,"species":"Ekans","nickname":"Ace","status":"Team","gender":"Female","met":"Route 32","nature":"Calm","ability":"Intimidate","types":["Poison","Poison"],"egg":false,"gameOfOrigin":"SoulSilver","level":"19","metLevel":"4","moves":["Bite","Poison Sting","Screech","Glare"]},{"id":"3e9572cf-f5fa-4318-8ff2-eac19b6212b4","position":9,"species":"Onix","nickname":"Xino","status":"Boxed","gender":"Female","level":"8","met":"Union Cave","metLevel":"8","nature":"Careful","ability":"Rock Head","types":["Rock","Ground"],"egg":false,"gameOfOrigin":"SoulSilver","moves":["Tackle","Harden","Bind","Screech"]},{"id":"cc643777-8ce6-40ea-babe-3cca9812dcba","position":10,"species":"Hoothoot","nickname":"Hooters","status":"Boxed","gender":"Female","level":"10","met":"National Park","metLevel":"10","nature":"Adamant","ability":"Keen Eye","types":["Normal","Flying"],"egg":false,"gameOfOrigin":"SoulSilver","moves":["Growl","Foresight","Hypnosis","Peck"]},{"id":"0c7edb92-4ade-4958-8aa4-fcfb6be5e469","position":11,"species":"Togepi","nickname":"Terence","status":"Boxed","gender":"Male","level":"11","met":"Violet City","metLevel":"1","nature":"Adamant","ability":"Hustle","types":["Normal","Normal"],"egg":false,"gameOfOrigin":"SoulSilver","moves":["Flash","Charm","Extrasensory","Metronome"]},{"id":"72797db7-13ef-49ab-9d69-c13c5b3573ac","position":12,"species":"Rattata","nickname":"Courtney","status":"Boxed","gender":"Female","level":"3","met":"Sprout Tower","metLevel":"3","nature":"Naughty","ability":"Run Away","types":["Normal","Normal"],"egg":false,"gameOfOrigin":"SoulSilver","moves":["Headbut","Tail Whip","Rock Smash","Cut"]},{"id":"e19cc06e-a6cc-409f-95b6-53c29a63522e","position":13,"species":"Spearow","nickname":"Kenya","status":"Boxed","gender":"Male","level":"20","met":"Route 35","metLevel":"20","nature":"Hasty","ability":"Keen Eye","types":["Normal","Flying"],"egg":false,"moves":["Leer","Fury Attack","Pursuit","Aerial Ace"]},{"id":"656d4eab-664b-43a8-959e-757ecb19fcff","position":14,"species":"Nidoran♂","nickname":"NeedNoKing","status":"Boxed","gender":"Neutral","level":"12","met":"Route 35","metLevel":"12","nature":"Modest","ability":"Rivalry","types":["Poison","Poison"],"egg":false,"moves":["Leer","Peck","Focus Energy"]}],"editor":{"minimized":false,"temtemMode":false,"showResultInMobile":false},"selectedId":"5cab723b-b19c-40ea-96f9-8ee5d0f35834","sawRelease":{"1.2.1":true},"trainer":{"badges":[{"name":"Zephyr Badge","image":"zephyr-badge"},{"name":"Hive Badge","image":"hive-badge"}]},"history":[],"rules":["Each Pokémon that faints is considered dead and must be released or permaboxed","You can only catch the first Pokemon you encounter in an area","All Pokémon must be nicknamed"],"stats":[{"id":"a-1","key":"","value":""}],"style":{"accentColor":"#111111","backgroundImage":"","bgColor":"#ad3a3a","customCSS":"","displayBadges":true,"displayRules":false,"editorDarkMode":true,"font":"Open Sans","iconsNextToTeamPokemon":false,"imageStyle":"round","itemStyle":"outer glow","pokeballStyle":"outer glow","iconRendering":"auto","grayScaleDeadPokemon":false,"minimalBoxedLayout":true,"minimalTeamLayout":false,"minimalDeadLayout":false,"movesPosition":"vertical","oldMetLocationFormat":false,"resultHeight":870,"resultWidth":1460,"scaleSprites":false,"showPokemonMoves":true,"spritesMode":false,"teamImages":"standard","teamPokemonBorder":true,"template":"Generations","tileBackground":false,"topHeaderColor":"#333333","trainerSectionOrientation":"horizonal","useSpritesForChampsPokemon":false,"boxedPokemonPerLine":6,"displayGameOriginForBoxedAndDead":false,"displayBackgroundInsteadOfBadge":false,"displayExtraData":true,"useAutoHeight":true,"usePokemonGBAFont":false,"displayItemAsText":false,"displayRulesLocation":"bottom","trainerWidth":"20%","trainerHeight":"100%","trainerAuto":true,"displayStats":false,"linkedPokemonText":"Linked To","statsOptions":{"averageLevel":false,"mostCommonKillers":false,"mostCommonTypes":false,"shiniesCaught":false}},"_persist":{"version":"1.2.1","rehydrated":true}}
Novocastrian commented 4 years ago

Edit: dead container just sets margins differently to the rest of the containers, which is why it appears slightly shunted compared to the others:

Setting image image

image

Fix: add .generations .dead-container (and any added by the user) to the element on line 372: image image