Skip to content

Commit a630a64

Browse files
committed
feat: add onClickLogin on the main GUI component
Allows overriding what happens when the Login button in the header is clicked. In some cases we want to be able to open a popup, not just render a user/pass dialog as in current Scratch.
1 parent 9a14ef1 commit a630a64

File tree

1 file changed

+3
-0
lines changed
  • packages/scratch-gui/src/components/gui

1 file changed

+3
-0
lines changed

packages/scratch-gui/src/components/gui/gui.jsx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,7 @@ const GUIComponent = props => {
9999
onClickAccountNav,
100100
onCloseAccountNav,
101101
onLogOut,
102+
onClickLogin,
102103
onOpenRegistration,
103104
onToggleLoginOpen,
104105
onActivateCostumesTab,
@@ -274,6 +275,7 @@ const GUIComponent = props => {
274275
onClickLogo={onClickLogo}
275276
onCloseAccountNav={onCloseAccountNav}
276277
onLogOut={onLogOut}
278+
onClickLogin={onClickLogin}
277279
onOpenRegistration={onOpenRegistration}
278280
onProjectTelemetryEvent={onProjectTelemetryEvent}
279281
onSeeCommunity={onSeeCommunity}
@@ -463,6 +465,7 @@ GUIComponent.propTypes = {
463465
onLogOut: PropTypes.func,
464466
onNewSpriteClick: PropTypes.func,
465467
onNewLibraryCostumeClick: PropTypes.func,
468+
onClickLogin: PropTypes.func,
466469
onOpenRegistration: PropTypes.func,
467470
onRequestCloseBackdropLibrary: PropTypes.func,
468471
onRequestCloseCostumeLibrary: PropTypes.func,

0 commit comments

Comments
 (0)