How to use the ipyvue.register_component_from_file function in ipyvue

To help you get started, we’ve selected a few ipyvue examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github glue-viz / glue-jupyter / glue_jupyter / app.py View on Github external
from glue.core.command import ApplySubsetState
from glue.core.edit_subset_mode import (NewMode, ReplaceMode, AndMode, OrMode,
                                        XorMode, AndNotMode)

from glue_jupyter.utils import _update_not_none, validate_data_argument
from glue_jupyter.widgets.subset_select_vuetify import SubsetSelect
from glue_jupyter.widgets.subset_mode_vuetify import SelectionModeMenu

__all__ = ['JupyterApplication']

# TODO: move this to glue-core so that the subset mode can be set ot a string
# there too
SUBSET_MODES = {'new': NewMode, 'replace': ReplaceMode, 'and': AndMode,
                'or': OrMode, 'xor': XorMode, 'not': AndNotMode}

ipyvue.register_component_from_file(
    None, 'glue-float-field', os.path.join(os.path.dirname(__file__), 'widgets',
                                           'glue_float_field.vue'))


class JupyterApplication(Application):
    """
    The main Glue application object for the Jupyter environment.

    This is used as the primary way to interact with glue, including loading
    data, creating viewers, and adding links.

    Parameters
    ----------
    data_collection : `~glue.core.data_collection.DataCollection`
        A pre-existing data collection. By default, a new data collection is
        created.

ipyvue

Jupyter widgets base for Vue libraries

MIT
Latest version published 1 month ago

Package Health Score

70 / 100
Full package analysis

Similar packages