Skip to content

Instantly share code, notes, and snippets.

@lucadegasperi
Last active September 22, 2020 09:56
Show Gist options
  • Save lucadegasperi/f3d6ce07a7ce6d5dea886ab34ae595d8 to your computer and use it in GitHub Desktop.
Save lucadegasperi/f3d6ce07a7ce6d5dea886ab34ae595d8 to your computer and use it in GitHub Desktop.
Some ui design thoughts

My Design Thoughts as of 30/01/2020

Tooltips Modals and Alerts

  • tooltips should exist outside the context of the element they are attached to. This is to prevent style leaks or hidden overflows on the element they are attached to
  • Same principle applies to modals / alerts and so forth they should live inside a portal

Spacing

  • Spacing between components should be given by a parent component.
  • A component should not have any knowledge about its sorroundings.
  • A Text node should never be left alone with other non text nodes (it should always be wrapped in a )
  • Useful elements to achieve this might be layout components (grid) or other types of components (HSpacing / VSpacing)
  • If in doubt ask mark dalgleish
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment