If the viewport height is smaller than 660, shrink the margin above &
below the telemetry modal.
If the viewport height is smaller than 540, also remove the image banner
at the top of the telemetry modal.
This indicates the current state, lets the user exit without changing
state, and lets the user change state any time they want.
This change also improves RTL support in the telemetry modal.
If `onClickAbout` is a callback, or is not provided, then behavior is
the same as it was before this change. If the value is an array of
objects with `title` and `onClick` properties, the "About" button will
now open a menu with those items.
TODO: support `FormattedMessage` for the menu item titles.
The Stage component will sometimes have a color picker background,
which darkens the entire screen when the color picker loupe is active.
This color picker background element should appear in the same level as
the stage's wrapper, not inside of it. Previously, this was done by
wrapping both the stage's wrapper and color picker background in a div.
Now, they're both wrapped in a React.Fragment to avoid a completely
unnecessary div wrapper.
This makes the layout behavior for stage overlays much more consistent.
Items whose overflow *should* be contained within the stage, like the
monitors and color picker loupe, are now placed within the "stage"
element directly.
Items whose overflow should *not* be contained within the stage, like
the target highlight box and dragged sprite, are now inside a "stage
overlays" container element, which is properly positioned (taking into
account the stage's border width) and sized.
This is made possible by unifying stage layout across both fullscreen &
non-fullscreen modes via moving the fullscreen overlay styles to the
StageWrapper component. Whereas previously, the stage overlays were
positioned *outside* of the stage in fullscreen and had to reposition
themselves correctly, they are now positioned the same in both
fullscreen and regular modes.
The stage + target pane wrapper's width must be constrained to that of
the stage, even when there are lots of sprite tiles. Otherwise, once you
add enough sprites, it'll grow horizontally past the stage size. The old
code set its maximum width explicitly to stop that from happening, but
it can also be done more elegantly with the flex-basis property.
This also has the benefit of taking the stage border width into account.
draft of refactor to make custom confirm modal work for upload; need to further edit sb-file-uploader
Add support for custom confirm modal to sb-file-uploader
Show custom confirm modal when confirming project upload
got custom upload refactor of file upload working, and tested failure case
cleaned up debug code, make project file upload work
simplified logic around canceling file upload
removed old sb-file-uploader.jsx; fixed linter errors
reverted two components to use old strings, not shared
(can do that refactor another time)
removed unnecessary confirm container
removed stray comment
moved, updated sb file uploader tests, related project state tests
removed custom modal, to reduce scope of changes
sb file uploader test uses intl