mirror of
https://github.com/Graylog2/graylog2-server.git
synced 2026-03-13 09:32:21 +08:00
1.7 KiB
1.7 KiB
Form & Modal Submit Buttons
- Rely on the shared components
FormSubmitandModalSubmitto implement the submit and cancel button. TheFormSubmitcan be used for all forms on pages. TheModalSubmitcan be used for modals and similar element like popovers or the login dialog. - Make sure to follow the placements defined by these shared components. Currently:
- submit buttons in form are vertically aligned with the inputs. The cancel button is being placed after the submit button.
- submit buttons in modals are always placed in the right bottom corner. The cancel button is being placed before the submit button.
- When defining a name for the submit button
- Instead of
SaveorOkuse a meaningful name for the submit button likeCreate stream. - Make sure to write only the first letter uppercase and all other letter lowercase.
- Instead of
- Always use
Cancelfor the cancel button name.
EmptyEntity & NoEntitiesExist & NoSearchResults components
- These three components are closely related and maybe confusing to decide which one to use for which situation.
EmptyEntityshould be used to display a message for an entity that does not have any entries in the database yet. This components supports displaying a message explaining what the entity is and can also support including a button link to create one via the children propsNoEntitiesExistis similar toEmptyEntityexcept it is a more generic message without including the option to create a new oneNoSearchResultsshould be used in the case when a search is performed with a query and the result is no matching entries. This component should inform the user that entities still exist, just that none match the current filter.