robotopia-x / robotopia

:robot: Introducing kids to coding with tiny virtual robots!
https://robotopia-x.github.io/
MIT License
511 stars 56 forks source link

Tutorial Levels arranged into a 2D structure #102

Closed H3rby7 closed 7 years ago

H3rby7 commented 7 years ago

looks like this:

tutorials = [
  {
    categoryName: 'sampleCategory',
    levels: [
      require('./someLevel.js'),
      require('./someOtherLevel.js')
    ]
  }
]

This changes the routing for tutorials again: localhost:9966/#tutorial/CATEGORY/LEVEL. Levels start with index 1.

Would be nice for the Overview page something like this:

<h1>Category</h1>
<div class="levels">
  <div style="display: inline-block">
    <img src="linkToImageOfLevel1">
  </div>
  <div style="display: inline-block">
    <img src="linkToImageOfLevel2">
  </div>
  <div style="display: inline-block">
    <img src="linkToImageOfLevel3">
  </div>
</div>
timgrossmann commented 7 years ago

@H3rby7 Could be please not use inline If-Conditions at all?

timgrossmann commented 7 years ago

To keep it consistent, i would recommend changing 'ID' to 'Id' in e.g. tileId.