mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-16 18:46:40 -05:00
fix dropdown alignment (#23870)
This commit is contained in:
@@ -358,7 +358,7 @@ export class ToggleAddCellActionViewItem extends DropdownMenuActionViewItem {
|
|||||||
{
|
{
|
||||||
actionRunner,
|
actionRunner,
|
||||||
classNames: ToggleAddCellDropdownAction.ICON,
|
classNames: ToggleAddCellDropdownAction.ICON,
|
||||||
anchorAlignmentProvider: () => AnchorAlignment.RIGHT
|
anchorAlignmentProvider: () => AnchorAlignment.LEFT
|
||||||
});
|
});
|
||||||
this.setActionContext(cellContext);
|
this.setActionContext(cellContext);
|
||||||
}
|
}
|
||||||
@@ -392,7 +392,7 @@ export class CellToggleMoreActionViewItem extends DropdownMenuActionViewItem {
|
|||||||
{
|
{
|
||||||
actionRunner,
|
actionRunner,
|
||||||
classNames: CellToggleMoreAction.ICON,
|
classNames: CellToggleMoreAction.ICON,
|
||||||
anchorAlignmentProvider: () => AnchorAlignment.RIGHT
|
anchorAlignmentProvider: () => AnchorAlignment.LEFT
|
||||||
});
|
});
|
||||||
this.setActionContext(this._cellContext);
|
this.setActionContext(this._cellContext);
|
||||||
this._actions = [
|
this._actions = [
|
||||||
|
|||||||
@@ -59,6 +59,7 @@ import { KeyCode } from 'vs/base/common/keyCodes';
|
|||||||
import { debounce } from 'vs/base/common/decorators';
|
import { debounce } from 'vs/base/common/decorators';
|
||||||
import { ToggleAddCellDropdownAction } from 'sql/workbench/contrib/notebook/browser/cellToolbarActions';
|
import { ToggleAddCellDropdownAction } from 'sql/workbench/contrib/notebook/browser/cellToolbarActions';
|
||||||
import { defaultButtonStyles } from 'vs/platform/theme/browser/defaultStyles';
|
import { defaultButtonStyles } from 'vs/platform/theme/browser/defaultStyles';
|
||||||
|
import { AnchorAlignment } from 'vs/base/browser/ui/contextview/contextview';
|
||||||
|
|
||||||
export const NOTEBOOK_SELECTOR: string = 'notebook-component';
|
export const NOTEBOOK_SELECTOR: string = 'notebook-component';
|
||||||
const PRIORITY = 105;
|
const PRIORITY = 105;
|
||||||
@@ -551,7 +552,7 @@ export class NotebookComponent extends AngularDisposable implements OnInit, OnDe
|
|||||||
undefined,
|
undefined,
|
||||||
'codicon masked-pseudo masked-pseudo-after add-new dropdown-arrow',
|
'codicon masked-pseudo masked-pseudo-after add-new dropdown-arrow',
|
||||||
localize('addCell', "Cell"),
|
localize('addCell', "Cell"),
|
||||||
undefined
|
() => AnchorAlignment.LEFT
|
||||||
);
|
);
|
||||||
dropdownMenuActionViewItem.render(buttonDropdownContainer);
|
dropdownMenuActionViewItem.render(buttonDropdownContainer);
|
||||||
dropdownMenuActionViewItem.setActionContext(this._notebookParams.notebookUri);
|
dropdownMenuActionViewItem.setActionContext(this._notebookParams.notebookUri);
|
||||||
@@ -572,7 +573,7 @@ export class NotebookComponent extends AngularDisposable implements OnInit, OnDe
|
|||||||
undefined,
|
undefined,
|
||||||
'codicon notebook-button masked-pseudo masked-pseudo-after icon-dashboard-view dropdown-arrow',
|
'codicon notebook-button masked-pseudo masked-pseudo-after icon-dashboard-view dropdown-arrow',
|
||||||
localize('editor', "Editor"),
|
localize('editor', "Editor"),
|
||||||
undefined
|
() => AnchorAlignment.LEFT
|
||||||
);
|
);
|
||||||
viewsDropdownMenuActionViewItem.render(viewsDropdownContainer);
|
viewsDropdownMenuActionViewItem.render(viewsDropdownContainer);
|
||||||
viewsDropdownMenuActionViewItem.setActionContext(this._notebookParams.notebookUri);
|
viewsDropdownMenuActionViewItem.setActionContext(this._notebookParams.notebookUri);
|
||||||
|
|||||||
Reference in New Issue
Block a user