-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
playground: Add tab menu and format button
- Change tab dropdown to menu so we can have more than 1 type of action - Remove tab-dropdown specific properties since we don't need them anymore. - Add option to the menu component so we can disable the overlay - Add menu-tab specific styling - Render tab menu with optional title and optional format button: when both languages & actions are present both menus show a title to clarify the difference. If only one of them is configured the title is not shown and only the items are shown. - Handle events for language option selection: close menu & call change option function - Add format option for input tabs & enable when selected language is cue (for now) - Handle format button click: close menu & call format function - Fix issue onLoad which always loaded the default-example, even though workspace policy was selected in the url. - TODO: How can we use the WASM API to format the code? To test: - Click on the arrow next to the input tab name - Enable the policy-mode to test language selection in combination with the format option: src/config/workspaces/policy.ts > set enabled to true and click on the input dropdown. Fixes: cue-lang/cue#2996 Signed-off-by: Jorinde Reijnierse <[email protected]> Change-Id: I5a2fe31cc69b7f3cb8313ad94f27f172c2b7ffd4 Dispatch-Trailer: {"type":"trybot","CL":1205272,"patchset":2,"ref":"refs/changes/72/1205272/2","targetBranch":"master"}
- Loading branch information
1 parent
597542b
commit b009a89
Showing
9 changed files
with
345 additions
and
80 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.