Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Port] Fix Notebook toolbar and cell toolbar dropdown alignment #23874

Merged
merged 1 commit into from
Jul 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -358,7 +358,7 @@ export class ToggleAddCellActionViewItem extends DropdownMenuActionViewItem {
{
actionRunner,
classNames: ToggleAddCellDropdownAction.ICON,
anchorAlignmentProvider: () => AnchorAlignment.RIGHT
anchorAlignmentProvider: () => AnchorAlignment.LEFT
});
this.setActionContext(cellContext);
}
Expand Down Expand Up @@ -392,7 +392,7 @@ export class CellToggleMoreActionViewItem extends DropdownMenuActionViewItem {
{
actionRunner,
classNames: CellToggleMoreAction.ICON,
anchorAlignmentProvider: () => AnchorAlignment.RIGHT
anchorAlignmentProvider: () => AnchorAlignment.LEFT
});
this.setActionContext(this._cellContext);
this._actions = [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ import { KeyCode } from 'vs/base/common/keyCodes';
import { debounce } from 'vs/base/common/decorators';
import { ToggleAddCellDropdownAction } from 'sql/workbench/contrib/notebook/browser/cellToolbarActions';
import { defaultButtonStyles } from 'vs/platform/theme/browser/defaultStyles';
import { AnchorAlignment } from 'vs/base/browser/ui/contextview/contextview';

export const NOTEBOOK_SELECTOR: string = 'notebook-component';
const PRIORITY = 105;
Expand Down Expand Up @@ -551,7 +552,7 @@ export class NotebookComponent extends AngularDisposable implements OnInit, OnDe
undefined,
'codicon masked-pseudo masked-pseudo-after add-new dropdown-arrow',
localize('addCell', "Cell"),
undefined
() => AnchorAlignment.LEFT
);
dropdownMenuActionViewItem.render(buttonDropdownContainer);
dropdownMenuActionViewItem.setActionContext(this._notebookParams.notebookUri);
Expand All @@ -572,7 +573,7 @@ export class NotebookComponent extends AngularDisposable implements OnInit, OnDe
undefined,
'codicon notebook-button masked-pseudo masked-pseudo-after icon-dashboard-view dropdown-arrow',
localize('editor', "Editor"),
undefined
() => AnchorAlignment.LEFT
);
viewsDropdownMenuActionViewItem.render(viewsDropdownContainer);
viewsDropdownMenuActionViewItem.setActionContext(this._notebookParams.notebookUri);
Expand Down