@vonage/vivid-react
Version:
Vivid wrapped for easy React usage & IDE autocomplete support & typescript typings
342 lines (337 loc) • 6.46 kB
JavaScript
/*
* DO NOT EDIT THIS FILE. IT IS GENERATED
*/
/*
Code in this file were generated using following JSON:
{
"kind": "class",
"description": "",
"name": "Toggletip",
"slots": [
{
"description": "The content to display in the toggletip.",
"name": ""
},
{
"description": "Used to set the anchor element for the toggletip.",
"name": "anchor"
},
{
"description": "The content to display in the toggletip action items.",
"name": "action-items"
}
],
"members": [
{
"kind": "field",
"name": "#originalAriaLabel",
"privacy": "private",
"type": {
"text": "string | null"
},
"default": "null"
},
{
"kind": "field",
"name": "headline",
"type": {
"text": "string | undefined"
},
"description": "the optional title of the toggletip",
"privacy": "public"
},
{
"kind": "field",
"name": "alternate",
"type": {
"text": "boolean"
},
"default": "false",
"description": "toggle color scheme",
"privacy": "public"
},
{
"kind": "field",
"name": "placement",
"type": {
"text": "Placement | undefined"
},
"default": "'right'",
"description": "placement of the toggletip",
"privacy": "public"
},
{
"kind": "field",
"name": "open",
"type": {
"text": "boolean"
},
"default": "false",
"description": "indicates whether the toggletip is open",
"privacy": "public"
},
{
"kind": "method",
"name": "openChanged",
"return": {
"type": {
"text": "void"
}
},
"parameters": [
{
"name": "oldValue",
"type": {
"text": "boolean"
}
},
{
"name": "newValue",
"type": {
"text": "boolean"
}
}
]
},
{
"kind": "method",
"name": "#setupAnchor",
"parameters": [
{
"name": "a",
"type": {
"text": "HTMLElement"
}
}
]
},
{
"kind": "method",
"name": "#updateAnchor",
"parameters": [
{
"name": "a",
"type": {
"text": "HTMLElement"
}
}
]
},
{
"kind": "method",
"name": "#cleanupAnchor",
"parameters": [
{
"name": "a",
"type": {
"text": "HTMLElement"
}
}
]
},
{
"kind": "field",
"name": "#openIfClosed",
"privacy": "private"
},
{
"kind": "method",
"name": "#updateListeners"
},
{
"kind": "field",
"name": "#closeOnClickOutside",
"privacy": "private"
},
{
"kind": "field",
"name": "#closeOnEscape",
"privacy": "private"
},
{
"kind": "field",
"name": "anchor",
"type": {
"text": "AnchorType | undefined"
},
"description": "ID or direct reference to the component's anchor element.",
"privacy": "public",
"inheritedFrom": {
"name": "Anchored",
"module": "src/shared/patterns/anchored.ts"
}
},
{
"kind": "field",
"name": "#updateAnchorEl",
"privacy": "private",
"inheritedFrom": {
"name": "Anchored",
"module": "src/shared/patterns/anchored.ts"
}
},
{
"kind": "field",
"name": "#observer",
"privacy": "private",
"type": {
"text": "MutationObserver | undefined"
},
"inheritedFrom": {
"name": "Anchored",
"module": "src/shared/patterns/anchored.ts"
}
},
{
"kind": "field",
"name": "#observeMissingAnchor",
"privacy": "private",
"inheritedFrom": {
"name": "Anchored",
"module": "src/shared/patterns/anchored.ts"
}
},
{
"kind": "field",
"name": "#cleanupObserverIfNeeded",
"privacy": "private",
"inheritedFrom": {
"name": "Anchored",
"module": "src/shared/patterns/anchored.ts"
}
},
{
"kind": "field",
"name": "VIVID_VERSION",
"static": true,
"default": "__PACKAGE_VERSION__",
"description": "The current version of the Vivid library, which is useful for debugging.\nIt can be accessed from any Vivid element via `<el>.constructor.VIVID_VERSION`.",
"type": {
"text": "string"
},
"inheritedFrom": {
"name": "VividElement",
"module": "src/shared/foundation/vivid-element/vivid-element.ts"
}
},
{
"kind": "field",
"name": "componentName",
"type": {
"text": "string"
},
"static": true,
"description": "Core component name, without prefix",
"inheritedFrom": {
"name": "VividElement",
"module": "src/shared/foundation/vivid-element/vivid-element.ts"
}
}
],
"attributes": [
{
"name": "headline",
"type": {
"text": "string | undefined"
},
"description": "the optional title of the toggletip",
"fieldName": "headline"
},
{
"name": "alternate",
"type": {
"text": "boolean"
},
"default": "false",
"description": "toggle color scheme",
"fieldName": "alternate"
},
{
"name": "placement",
"type": {
"text": "Placement | undefined"
},
"default": "'right'",
"description": "placement of the toggletip",
"fieldName": "placement"
},
{
"name": "open",
"type": {
"text": "boolean"
},
"default": "false",
"description": "indicates whether the toggletip is open",
"fieldName": "open"
},
{
"name": "anchor",
"type": {
"text": "AnchorType | undefined"
},
"description": "ID or direct reference to the component's anchor element.",
"fieldName": "anchor",
"inheritedFrom": {
"name": "Anchored",
"module": "src/shared/patterns/anchored.ts"
}
}
],
"mixins": [
{
"name": "Localized",
"module": "/src/shared/patterns"
},
{
"name": "Anchored",
"module": "/src/shared/patterns/anchored"
}
],
"superclass": {
"name": "VividElement",
"module": "/src/shared/foundation/vivid-element/vivid-element"
},
"vividComponent": {
"public": true,
"name": "toggletip"
},
"vividTesting": {
"selectors": [
{
"name": "byHeadline",
"args": [
"byHeadline"
]
}
],
"actions": [],
"queries": [
{
"name": "open",
"args": [
"open",
"true"
]
},
{
"name": "closed",
"args": [
"open",
"false"
]
}
],
"refs": []
}
}
*/
import wrapper from '@vonage/vivid-react-wrapper'
import { registerToggletip } from '@vonage/vivid'
registerToggletip('vvd3')
const VwcToggletip = wrapper(`vvd3-toggletip`, {
events: [],
attributes: [],
properties: ['anchor', 'headline', 'alternate', 'placement', 'open', 'anchor', 'VIVID_VERSION', 'componentName']
})
VwcToggletip.displayName = 'VwcToggletip'
export default VwcToggletip