Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Diagrama Dinamico - Canvas size, booleans and collections #67

Merged
merged 2 commits into from
Jun 11, 2023

Conversation

ivojawer
Copy link
Contributor

fixes: #66 #64 #56

El siguiente codigo:

object pepita {
  var property energia = 100

  var property colores = ["rojo", "amarillo", "azul", manolo]

  var property esLoMejorQueHay = true

  var property esFuncional = false
  
  method vola(kms) {
    energia -= kms * 4
  }
}

object manolo {
  var property coloresPreferidos = ["naranja", "rojo", "verde"]
}

Genera este diagrama:

diagrama-dinamico

@ivojawer
Copy link
Contributor Author

ivojawer commented Jun 11, 2023

No viene al caso pero me pareceria mas amigable que en vez de decir List# diga "a List" o "un/a List". Ademas era como se mostraba en XText

Copy link
Contributor

@PalumboN PalumboN left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

HAARRrrrmoso 🌟

Mergeo y abro issue con mejoras

Comment on lines +9 to +10
width: 100vw;
height: 100vh;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Esto qué onda? Se adapta a la pantalla? Podemos dejar un comentario?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sip, v = viewport w/h = width/height

Comment on lines 277 to 289
{ data: { id: `${id}_${obj.get(name)?.id}`, label: name, source: id, target: obj.get(name)?.id } },
...elementFromObject(obj.get(name)!, [...alreadyVisited, id]),
]),
...obj.innerCollection ?
obj.innerCollection.flatMap(item =>
[
{ data: { id: `${id}_${item.id}`, source: id, target: item.id } },
...elementFromObject(item, [...alreadyVisited, id] ),
]
)
: [],
]
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Esta función está heavy :P

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

le falta un refactor urgente, lo de las colecciones quedo medio repetida la logica

@PalumboN PalumboN merged commit b083cca into master Jun 11, 2023
@PalumboN PalumboN deleted the dinamic-diagram-collections-and-booleans branch June 11, 2023 18:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants