| 1 |
/// <reference types="backbone" /> |
| 2 |
import { DOMWidgetView } from '@jupyter-widgets/base'; |
| 3 |
import { CoreDescriptionModel } from './widget_core'; |
| 4 |
import { DescriptionStyleModel, DescriptionView } from './widget_description'; |
| 5 |
export declare class CheckboxStyleModel extends DescriptionStyleModel { |
| 6 |
defaults(): Backbone.ObjectHash; |
| 7 |
static styleProperties: { |
| 8 |
background: { |
| 9 |
selector: string; |
| 10 |
attribute: string; |
| 11 |
default: any; |
| 12 |
}; |
| 13 |
description_width: { |
| 14 |
selector: string; |
| 15 |
attribute: string; |
| 16 |
default: any; |
| 17 |
}; |
| 18 |
}; |
| 19 |
} |
| 20 |
export declare class ToggleButtonStyleModel extends DescriptionStyleModel { |
| 21 |
defaults(): Backbone.ObjectHash; |
| 22 |
static styleProperties: { |
| 23 |
font_family: { |
| 24 |
selector: string; |
| 25 |
attribute: string; |
| 26 |
default: string; |
| 27 |
}; |
| 28 |
font_size: { |
| 29 |
selector: string; |
| 30 |
attribute: string; |
| 31 |
default: string; |
| 32 |
}; |
| 33 |
font_style: { |
| 34 |
selector: string; |
| 35 |
attribute: string; |
| 36 |
default: string; |
| 37 |
}; |
| 38 |
font_variant: { |
| 39 |
selector: string; |
| 40 |
attribute: string; |
| 41 |
default: string; |
| 42 |
}; |
| 43 |
font_weight: { |
| 44 |
selector: string; |
| 45 |
attribute: string; |
| 46 |
default: string; |
| 47 |
}; |
| 48 |
text_color: { |
| 49 |
selector: string; |
| 50 |
attribute: string; |
| 51 |
default: string; |
| 52 |
}; |
| 53 |
text_decoration: { |
| 54 |
selector: string; |
| 55 |
attribute: string; |
| 56 |
default: string; |
| 57 |
}; |
| 58 |
description_width: { |
| 59 |
selector: string; |
| 60 |
attribute: string; |
| 61 |
default: any; |
| 62 |
}; |
| 63 |
}; |
| 64 |
} |
| 65 |
export declare class BoolModel extends CoreDescriptionModel { |
| 66 |
defaults(): Backbone.ObjectHash; |
| 67 |
} |
| 68 |
export declare class CheckboxModel extends CoreDescriptionModel { |
| 69 |
defaults(): Backbone.ObjectHash; |
| 70 |
} |
| 71 |
export declare class CheckboxView extends DescriptionView { |
| 72 |
/** |
| 73 |
* Called when view is rendered. |
| 74 |
*/ |
| 75 |
render(): void; |
| 76 |
/** |
| 77 |
* Overridden from super class |
| 78 |
* |
| 79 |
* Update the description span (rather than the label) since |
| 80 |
* we want the description to the right of the checkbox. |
| 81 |
*/ |
| 82 |
updateDescription(): void; |
| 83 |
/** |
| 84 |
* Update the visibility of the label in the super class |
| 85 |
* to provide the optional indent. |
| 86 |
*/ |
| 87 |
updateIndent(): void; |
| 88 |
updateTabindex(): void; |
| 89 |
updateTooltip(): void; |
| 90 |
events(): { |
| 91 |
[e: string]: string; |
| 92 |
}; |
| 93 |
/** |
| 94 |
* Handles when the checkbox is clicked. |
| 95 |
* |
| 96 |
* Calling model.set will trigger all of the other views of the |
| 97 |
* model to update. |
| 98 |
*/ |
| 99 |
_handle_click(): void; |
| 100 |
/** |
| 101 |
* Update the contents of this view |
| 102 |
* |
| 103 |
* Called when the model is changed. The model may have been |
| 104 |
* changed by another view or by a state update from the back-end. |
| 105 |
*/ |
| 106 |
update(options?: any): void; |
| 107 |
/** |
| 108 |
* Handle message sent to the front end. |
| 109 |
* |
| 110 |
* Used to focus or blur the widget. |
| 111 |
*/ |
| 112 |
handle_message(content: any): void; |
| 113 |
checkbox: HTMLInputElement; |
| 114 |
checkboxLabel: HTMLLabelElement; |
| 115 |
descriptionSpan: HTMLSpanElement; |
| 116 |
} |
| 117 |
export declare class ToggleButtonModel extends BoolModel { |
| 118 |
defaults(): Backbone.ObjectHash; |
| 119 |
} |
| 120 |
export declare class ToggleButtonView extends DOMWidgetView { |
| 121 |
/** |
| 122 |
* Called when view is rendered. |
| 123 |
*/ |
| 124 |
render(): void; |
| 125 |
update_button_style(): void; |
| 126 |
set_button_style(): void; |
| 127 |
/** |
| 128 |
* Update the contents of this view |
| 129 |
* |
| 130 |
* Called when the model is changed. The model may have been |
| 131 |
* changed by another view or by a state update from the back-end. |
| 132 |
*/ |
| 133 |
update(options?: any): void; |
| 134 |
events(): { |
| 135 |
[e: string]: string; |
| 136 |
}; |
| 137 |
/** |
| 138 |
* Handles and validates user input. |
| 139 |
* |
| 140 |
* Calling model.set will trigger all of the other views of the |
| 141 |
* model to update. |
| 142 |
*/ |
| 143 |
_handle_click(event: MouseEvent): void; |
| 144 |
preinitialize(): void; |
| 145 |
el: HTMLButtonElement; |
| 146 |
static class_map: { |
| 147 |
primary: string[]; |
| 148 |
success: string[]; |
| 149 |
info: string[]; |
| 150 |
warning: string[]; |
| 151 |
danger: string[]; |
| 152 |
}; |
| 153 |
} |
| 154 |
export declare class ValidModel extends BoolModel { |
| 155 |
defaults(): Backbone.ObjectHash; |
| 156 |
} |
| 157 |
export declare class ValidView extends DescriptionView { |
| 158 |
/** |
| 159 |
* Called when view is rendered. |
| 160 |
*/ |
| 161 |
render(): void; |
| 162 |
/** |
| 163 |
* Update the contents of this view |
| 164 |
* |
| 165 |
* Called when the model is changed. The model may have been |
| 166 |
* changed by another view or by a state update from the back-end. |
| 167 |
*/ |
| 168 |
update(): void; |
| 169 |
readout: HTMLSpanElement; |
| 170 |
icon: HTMLElement; |
| 171 |
} |
| 172 |
//# sourceMappingURL=widget_bool.d.ts.map |