mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-30 09:35:39 -05:00
Feature/selectable card component (#1703)
* added selectable card * creating new card type
This commit is contained in:
26
src/sql/sqlops.proposed.d.ts
vendored
26
src/sql/sqlops.proposed.d.ts
vendored
@@ -239,7 +239,7 @@ declare module 'sqlops' {
|
||||
horizontal?: boolean;
|
||||
componentWidth?: number | string;
|
||||
componentHeight?: number | string;
|
||||
titleFontSize?: number;
|
||||
titleFontSize?: number | string;
|
||||
required?: boolean;
|
||||
info?: string;
|
||||
}
|
||||
@@ -300,15 +300,22 @@ declare module 'sqlops' {
|
||||
Error = 3
|
||||
}
|
||||
|
||||
export enum CardType {
|
||||
VerticalButton = 'VerticalButton',
|
||||
Details = 'Details'
|
||||
}
|
||||
|
||||
/**
|
||||
* Properties representing the card component, can be used
|
||||
* when using ModelBuilder to create the component
|
||||
*/
|
||||
export interface CardProperties {
|
||||
export interface CardProperties extends ComponentWithIcon {
|
||||
label: string;
|
||||
value?: string;
|
||||
actions?: ActionDescriptor[];
|
||||
status?: StatusIndicator;
|
||||
selected?: boolean;
|
||||
cardType: CardType;
|
||||
}
|
||||
|
||||
export type InputBoxInputType = 'color' | 'date' | 'datetime-local' | 'email' | 'month' | 'number' | 'password' | 'range' | 'search' | 'text' | 'time' | 'url' | 'week';
|
||||
@@ -318,6 +325,12 @@ declare module 'sqlops' {
|
||||
width?: number | string;
|
||||
}
|
||||
|
||||
export interface ComponentWithIcon {
|
||||
iconPath?: string | vscode.Uri | { light: string | vscode.Uri; dark: string | vscode.Uri };
|
||||
iconHeight?: number | string;
|
||||
iconWidth?: number | string;
|
||||
}
|
||||
|
||||
export interface InputBoxProperties extends ComponentProperties {
|
||||
value?: string;
|
||||
ariaLabel?: string;
|
||||
@@ -393,20 +406,17 @@ declare module 'sqlops' {
|
||||
html?: string;
|
||||
}
|
||||
|
||||
export interface ButtonProperties extends ComponentProperties {
|
||||
export interface ButtonProperties extends ComponentProperties, ComponentWithIcon {
|
||||
label?: string;
|
||||
iconPath?: string | vscode.Uri | { light: string | vscode.Uri; dark: string | vscode.Uri };
|
||||
}
|
||||
|
||||
export interface LoadingComponentProperties {
|
||||
loading?: boolean;
|
||||
}
|
||||
|
||||
export interface CardComponent extends Component {
|
||||
label: string;
|
||||
value: string;
|
||||
actions?: ActionDescriptor[];
|
||||
export interface CardComponent extends Component, CardProperties {
|
||||
onDidActionClick: vscode.Event<ActionDescriptor>;
|
||||
onCardSelectedChanged: vscode.Event<any>;
|
||||
}
|
||||
|
||||
export interface TextComponent extends Component {
|
||||
|
||||
Reference in New Issue
Block a user