-
Notifications
You must be signed in to change notification settings - Fork 0
chore(embedLink): new Layout #2
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
Conversation
src/index.css
Outdated
@@ -74,15 +81,21 @@ | |||
content: ""; | |||
clear: both; | |||
display: table; | |||
} | |||
} */ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tu as vraiment besoin de garder ce code commenté ?
Pareil pour tous les autres.
Principe : Ne garde pas de code mort, sauf si tu as une bonne raison (qu'il vaut mieux expliquer en commentaire)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Dans le commentaire de PR, je précisais que je laissais l'ancien code en commentaire au cas où. En cas de problème: on a l'ancien code devant les yeux, donc on peut facilement le remettre: si aucun soucis de comportement constaté à l'usage, on pourra l'enlever sereinement.
src/index.js
Outdated
@@ -502,7 +538,8 @@ export default class LinkTool { | |||
|
|||
this.hideProgress().then(() => { | |||
this.nodes.inputHolder.remove(); | |||
this.showLinkPreview(metaData); | |||
this.showLinkPreviewOverridden(metaData); | |||
// this.showLinkPreview(metaData); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Qu'est devenu showLinkPreview ? Il est utilisé ailleurs ? Faut-il le garder ? Si c'est à supprimer, pourquoi avoir fait une 2è méthode "Overridden" au lieu de modifier la méthode d'origine ?
Sur la méthode Overridden, si j'ai bien compris, tu as juste enlevé les 3 dernières lignes ? En supposant qu'il soit utile de garder la méthode d'origine (usage ailleurs), pourquoi ne pas avoir juste split en 2 la méthode, pour éviter ce gros tas de code dupliqué ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Il n'y a pas que les 3 dernières lignes qui changent étant donné que je crée un nouveau container dans lequel je place titre, description et link.
J'ai gardé la première méthode au cas où on constaterait plus tard un comportement inattendu malgré les tests que j'ai pu faire.
J'ai laissé en commentaire l'ancien code au cas où