mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-17 02:51:36 -05:00
expose the resizable option for table column (#14757)
This commit is contained in:
@@ -68,6 +68,7 @@ export class AssessmentResultGrid implements vscode.Disposable {
|
|||||||
width: 10,
|
width: 10,
|
||||||
headerCssClass: headerCssClass,
|
headerCssClass: headerCssClass,
|
||||||
toolTip: localize('asmt.column.targetType', "Target Type"),
|
toolTip: localize('asmt.column.targetType', "Target Type"),
|
||||||
|
resizable: false,
|
||||||
},
|
},
|
||||||
{ value: LocalizedStrings.TARGET_COLUMN_NAME, headerCssClass: headerCssClass, width: 125 },
|
{ value: LocalizedStrings.TARGET_COLUMN_NAME, headerCssClass: headerCssClass, width: 125 },
|
||||||
{ value: LocalizedStrings.SEVERITY_COLUMN_NAME, headerCssClass: headerCssClass, width: 100 },
|
{ value: LocalizedStrings.SEVERITY_COLUMN_NAME, headerCssClass: headerCssClass, width: 100 },
|
||||||
|
|||||||
5
src/sql/azdata.proposed.d.ts
vendored
5
src/sql/azdata.proposed.d.ts
vendored
@@ -1021,6 +1021,11 @@ declare module 'azdata' {
|
|||||||
* The text to display on the column heading. 'value' property will be used, if not specified
|
* The text to display on the column heading. 'value' property will be used, if not specified
|
||||||
*/
|
*/
|
||||||
name?: string;
|
name?: string;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* whether the column is resizable. Default value is true.
|
||||||
|
*/
|
||||||
|
resizable?: boolean;
|
||||||
}
|
}
|
||||||
|
|
||||||
export interface IconColumnOptions {
|
export interface IconColumnOptions {
|
||||||
|
|||||||
@@ -135,7 +135,8 @@ export default class TableComponent extends ComponentBase<azdata.TableComponentP
|
|||||||
headerCssClass: col.headerCssClass,
|
headerCssClass: col.headerCssClass,
|
||||||
toolTip: col.toolTip,
|
toolTip: col.toolTip,
|
||||||
formatter: iconCssFormatter,
|
formatter: iconCssFormatter,
|
||||||
filterable: false
|
filterable: false,
|
||||||
|
resizable: col.resizable
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -148,7 +149,8 @@ export default class TableComponent extends ComponentBase<azdata.TableComponentP
|
|||||||
cssClass: col.cssClass,
|
cssClass: col.cssClass,
|
||||||
headerCssClass: col.headerCssClass,
|
headerCssClass: col.headerCssClass,
|
||||||
toolTip: col.toolTip,
|
toolTip: col.toolTip,
|
||||||
formatter: textFormatter
|
formatter: textFormatter,
|
||||||
|
resizable: col.resizable
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -410,7 +412,7 @@ export default class TableComponent extends ComponentBase<azdata.TableComponentP
|
|||||||
width: col.width,
|
width: col.width,
|
||||||
cssClass: col.cssClass,
|
cssClass: col.cssClass,
|
||||||
headerCssClass: col.headerCssClass,
|
headerCssClass: col.headerCssClass,
|
||||||
actionOnCheck: checkboxAction,
|
actionOnCheck: checkboxAction
|
||||||
}, index);
|
}, index);
|
||||||
|
|
||||||
this._register(this._checkboxColumns[col.value].onChange((state) => {
|
this._register(this._checkboxColumns[col.value].onChange((state) => {
|
||||||
@@ -436,7 +438,8 @@ export default class TableComponent extends ComponentBase<azdata.TableComponentP
|
|||||||
iconCssClass: icon ? this.createIconCssClassInternal(icon) : undefined,
|
iconCssClass: icon ? this.createIconCssClassInternal(icon) : undefined,
|
||||||
field: col.value,
|
field: col.value,
|
||||||
showText: col.showText,
|
showText: col.showText,
|
||||||
name: col.name
|
name: col.name,
|
||||||
|
resizable: col.resizable
|
||||||
});
|
});
|
||||||
|
|
||||||
this._register(this._buttonColumns[col.value].onClick((state) => {
|
this._register(this._buttonColumns[col.value].onClick((state) => {
|
||||||
@@ -460,7 +463,8 @@ export default class TableComponent extends ComponentBase<azdata.TableComponentP
|
|||||||
width: col.width,
|
width: col.width,
|
||||||
iconCssClass: col.icon ? this.createIconCssClassInternal(col.icon) : undefined,
|
iconCssClass: col.icon ? this.createIconCssClassInternal(col.icon) : undefined,
|
||||||
field: col.value,
|
field: col.value,
|
||||||
name: col.name
|
name: col.name,
|
||||||
|
resizable: col.resizable
|
||||||
});
|
});
|
||||||
|
|
||||||
this._hyperlinkColumns[col.value] = hyperlinkColumn;
|
this._hyperlinkColumns[col.value] = hyperlinkColumn;
|
||||||
|
|||||||
Reference in New Issue
Block a user