kaskada.formatters
Module Contents
Functions
Checks to see if running in an iPython environment |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Creates a tab-panel for the passed content list. |
Outputs our custom css and javascript to the current cell |
|
Based on the environment that the code is running inside of, the cell output may be |
|
|
Outputs our custom css and javascript to the cell output if the output for the cell |
|
Attributes
- tab_panel(content_list, title_to_set_active='')[source]
Creates a tab-panel for the passed content list.
- Parameters:
content_list (list of tuple of (str, Any)) – A list of tuples, where the the first value
title (in the tuple is the tab) –
contents. (and the second is the tab) –
str (title_to_set_active) – The name of the tab title to set active when the panel loads. If
unset –
active. (the first tab will be set) –
- Returns:
A div html element wrapping the tabs and content. Pass this value to str() to get the string html output.
- Return type:
domonic.html.div
- output_custom_css_and_javascript()[source]
Outputs our custom css and javascript to the current cell
- cell_output_is_wrapped_in_iframe()[source]
Based on the environment that the code is running inside of, the cell output may be automatically wrapped in an iFrame. For example, in google colab: “the output of each cell is hosted in a separate iframe sandbox with limited access to the global notebook environment” In enviroments like these, we need to include our custom css & javascript in every output.
- Returns:
True if the environment will automatically wrap the cell output in an iFrame, otherwise False.
- Return type: