-
Notifications
You must be signed in to change notification settings - Fork 74
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* POC: plugin API hints demo * store plugin state in metadata "history" * button to toggle API hints (only hooked up for gaussian smooth for now) * implement to_script method * might want to move to the UI side if we want to control the order and have a copy button * include data definition and write to script in metadata * rename show_api_hints > api_hints * improved styling and connect add_to_viewer * rename api_hints > api_hints_enabled * generalize and implement across multiple plugins * codestyle and fix rebase * .ignore-api-hint > explicitly set .api-hint * use plugin-switch component for visibility switches in plot options * implement for moment maps and specviz2d spec extract * tooltip for toggle button * fix behavior for switches * separate component for slider header * fix styling for editable select * brief mention in docs * changelog entry * don't show toggle button when not in notebook/lab * defer to_script functionality * implement/update additional plugins * partial implementation for dq plugin * plugin-color-picker and plugin-slider components
- Loading branch information
Showing
45 changed files
with
1,153 additions
and
472 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
<template> | ||
<div> | ||
<plugin-input-header | ||
v-if="label && !label_inline" | ||
:label="label" | ||
:api_hint="api_hint + value" | ||
:api_hints_enabled="api_hints_enabled" | ||
></plugin-input-header> | ||
<v-menu> | ||
<template v-slot:activator="{ on }"> | ||
<span class="color-menu" | ||
:style="`background:${value}; cursor: pointer`" | ||
@click.stop="on.click" | ||
> </span> | ||
</template> | ||
<div @click.stop="" style="text-align: end; background-color: white"> | ||
<v-color-picker :value="value" | ||
@update:color="$emit('color-update', $event)"></v-color-picker> | ||
</div> | ||
</v-menu> | ||
<span | ||
v-if="label && label_inline" | ||
style="padding-left: 12px; padding-top: 3px" | ||
:class="api_hints_enabled ? 'api-hint' : null" | ||
> | ||
{{ api_hints_enabled ? | ||
api_hint + value | ||
: | ||
label | ||
}} | ||
</span> | ||
</div> | ||
</template> | ||
|
||
<script> | ||
module.exports = { | ||
props: ['label', 'label_inline', 'api_hint', 'api_hints_enabled', 'value'], | ||
}; | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<template> | ||
<v-subheader | ||
:class="api_hints_enabled ? 'pl-0 slider-label api-hint' : 'pl-0 slider-label'" | ||
style="height: 12px" | ||
> | ||
{{ api_hints_enabled && api_hint ? | ||
api_hint | ||
: | ||
label | ||
}} | ||
</v-subheader> | ||
</template> | ||
|
||
<script> | ||
module.exports = { | ||
props: ['label', 'api_hint', 'api_hints_enabled'], | ||
}; | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.