npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@sigmacomputing/embed-sdk

v0.5.0

Published

JavaScript SDK to interact with Sigma Computing's Embed API

Downloads

312

Maintainers

john.yorkejohn.yorkegsanfordgsanfordfoxhatleofoxhatleobohan_sigmabohan_sigmaray.chen.sigmaray.chen.sigmaminhnleminhnlencurraultncurraultguyatsigmaguyatsigmajonathanzhang53jonathanzhang53dinkarkhattardinkarkhattarsigma-nathan-healeysigma-nathan-healeypeternanderssonpeternanderssonvandit-sigmavandit-sigmaashnaryaashnaryaashishcha9211ashishcha9211yashsvisharmayashsvisharmaestellakaruniaestellakaruniarobinpillerobinpillelinusmtlinusmtmatei_the_sigmanautmatei_the_sigmanautsamhv0samhv0aakashpathakaakashpathakazule-luxazule-luxpballaipballaidmadelyndmadelynowen-sigmacomputingowen-sigmacomputingpat-haimbaughpat-haimbaughwil-sigmawil-sigmajustineyuanjustineyuanmfpekalamfpekalasiyaosigmasiyaosigmaacholmesacholmesvaibagravaibagramorriswanmorriswansigma-sherwinsigma-sherwinvoidd7voidd7ardaakmannardaakmannpa7-sigmapa7-sigmacurtiscastrocurtiscastromontefernmontefernasingh888asingh888jackatsigmajackatsigmasahilsalim99sahilsalim99abeljohnsigmaabeljohnsigmading-harrisonding-harrisonsigma-integrationssigma-integrationsangshuman-sigmaangshuman-sigmajschererererjscherererersmoirsmoirolcawthorneolcawthornematt-bierman-sigmamatt-bierman-sigmarohan322rohan322asadakramasadakramtravisdickeysigmatravisdickeysigmajcheung-sigmajcheung-sigmapurvilmehtapurvilmehtaangelafanangelafancgreyboshcgreyboshgary-sigmagary-sigmafanfan-sigmafanfan-sigmajadefleishhackerjadefleishhackeraileensigmaaileensigmaslequarslequarmaximus-sigmamaximus-sigmatedbrakobtedbrakobchristophermourichristophermouritinocaersigmatinocaersigmaobashawobashawdaisywangdaisywangsivadheeraj2sivadheeraj2nathansigmanathansigmagsharoyagsharoyahiranmayahiranmayachukamattahchukamattahrgduttargduttarobarnoldrobarnoldmjones-sigmamjones-sigmamiguelsigmamiguelsigmaliz425liz425tifntifnsamirapatelsamirapatelryankwongryankwongrajsigmarajsigmarounaksalim95rounaksalim95wenxuan5wenxuan5ayman-sigmaayman-sigmawessigmawessigmacharlesnelson-sigmacharlesnelson-sigmahaoxu-sigmahaoxu-sigmareitmrreitmrvjeyaramvjeyaramaaron-sigmaaaron-sigmayusufsigmayusufsigmamwong-sigmamwong-sigmadiego-sigmadiego-sigmaborissigmaborissigmaalexbibaalexbibajhu_sigmajhu_sigmamdevsigmamdevsigmabrett_b_at_sigmabrett_b_at_sigmahannahsigmahannahsigmajaredspickardjaredspickardnicholaschandlernicholaschandlermuralisigmamuralisigmamooneromoonerocynthiashencynthiashensinanunansinanunanmansa_pabbarajumansa_pabbarajuezimanyi-sigmaezimanyi-sigmayuchristinayuchristinasharvilnsharvilnaarshinovaaarshinovamunteanuicmunteanuicyi-sigmayi-sigmapearce-sigmapearce-sigmaankita.shankarankita.shankarterence.wilsterence.wilsphillipwhite99phillipwhite99kevinphamkevinphammadisonchamberlainmadisonchamberlainrwoollenrwoollenjlgalejlgalejfrantyjfrantysigmacisigmaciktruongktruongdonhcddonhcdmaxseidenmaxseidenjmhainjmhaingreg-at-sigmagreg-at-sigmatureseturesewtgjxjwtgjxjalexisjohnsonalexisjohnsonadityasigmacomputingadityasigmacomputingbenjixdbenjixddbronnikdbronnikericbannatyne-sigmaericbannatyne-sigmaanandnarayanananandnarayananmtoadermtoadereranatsigmaeranatsigmadyoung_nccdyoung_nccczhang_sigmacomputingczhang_sigmacomputingrudysigmarudysigmamessercmessercrjsigmarjsigmayifeng-sigmayifeng-sigma

Readme

Getting Started

To use the embed-sdk in your project, you can install it using your node package manager.

Using npm:

npm install @sigmacomputing/embed-sdk

yarn:

yarn add @sigmacomputing/embed-sdk

pnpm:

pnpm add @sigmacomputing/embed-sdk

Documentation

Listeners

These are functions that can be used to listen for events from the embed, and react to them.

workbookLoadedListener

Listen for a workbook loaded event, and execute the given callback when it occurs.

workbookLoadedListener(event: MessageEvent, iframe: HTMLIFrameElement, onLoaded: (event: WorkbookLoadedEvent) => void)

workbookErrorListener

Listen for a workbook error event, and execute the given callback when it occurs.

workbookErrorListener(event: MessageEvent, iframe: HTMLIFrameElement, onError: (event: WorkbookErrorEvent) => void)

workbookVariableChangeListener

Listen for a workbook variable change event, and execute the given callback when it occurs.

workbookVariableChangeListener(event: MessageEvent, iframe: HTMLIFrameElement, onVariable: (event: WorkbookVariableOnChangeEvent) => void)

workbookVariableCurrentListener

Listen for a workbook variable current event, and execute the given callback when it occurs.

workbookVariableCurrentListener(event: MessageEvent, iframe: HTMLIFrameElement, onVariable: (event: WorkbookVariableCurrentEvent) => void)

workbookLinkSharingUpdateListener

Listen for a workbook sharing link update event, and execute the given callback when it occurs.

workbookLinkSharingUpdateListener(event: MessageEvent, iframe: HTMLIFrameElement, onVariable: (event: WorkbookSharingLinkUpdateEvent) => void)

workbookTableCellSelectListener

Listen for a table cell select event, and execute the given callback when it occurs.

workbookTableCellSelectListener(event: MessageEvent, iframe: HTMLIFrameElement, onTableCellSelect: (event: WorkbookTableCellSelectEvent) => void)

workbookPublishedListener

Listen for a workbook published event, and execute the given callback when it occurs.

workbookPublishedListener(event: MessageEvent, iframe: HTMLIFrameElement, onPublished: (event: WorkbookPublishedEvent) => void)

workbookFullScreenListener

Listen for a workbook full screen event, and execute the given callback when it occurs.

workbookFullScreenListener(event: MessageEvent, iframe: HTMLIFrameElement, onFullScreen: (event: WorkbookFullScreenEvent) => void)

workbookPageHeightListener

Listen for a workbook page height event, and execute the given callback when it occurs. Needs to be used with the responsive_height URL Parameter.

workbookPageHeightListener(event: MessageEvent, iframe: HTMLIFrameElement, onPageHeight: (event: WorkbookPageHeightEvent) => void)

workbookSelectedNodeListener

Listen for a workbook selected node event, and execute the given callback when it occurs.

workbookSelectedNodeListener(event: MessageEvent, iframe: HTMLIFrameElement, onPageSelectedNode: (event: WorkbookSelectedNodeEvent) => void)

workbookPivotTableCellSelectListener

Listen for a pivot table cell select event, and execute the given callback when it occurs.

workbookPivotTableCellSelectListener(event: MessageEvent, iframe: HTMLIFrameElement, onPivotTableCellSelect: (event: WorkbookPivotTableCellSelectEvent) => void)

workbookChartValueSelectListener

Listen for a chart value select event, and execute the given callback when it occurs.

workbookChartValueSelectListener(event: MessageEvent, iframe: HTMLIFrameElement, onChartValueSelect: (event: WorkbookChartValueSelectEvent) => void)

workbookCurrentVariablesListener

Listen for a workbook current variables event, and execute the given callback when it occurs. This is to be used when workbookVariablesList is called.

workbookCurrentVariablesListener(event: MessageEvent, iframe: HTMLIFrameElement, onCurrentVariables: (event: WorkbookCurrentVariablesEvent) => void)

workbookBookmarkCreateListener

Listen for a workbook bookmark create event, and execute the given callback when it occurs.

workbookBookmarkCreateListener(event: MessageEvent, iframe: HTMLIFrameElement, onBookmarkCreate: (event: WorkbookBookmarkOnCreateEvent) => void)

workbookDataLoadedListener

Listen for a workbook data loaded event, and execute the given callback when it occurs.

workbookDataLoadedListener(event: MessageEvent, iframe: HTMLIFrameElement, onWorkbookDataLoaded: (event: WorkbookDataLoadedEvent) => void)

workbookChartErrorListener

Listen for a workbook chart error event, and execute the given callback when it occurs.

workbookChartErrorListener(event: MessageEvent, iframe: HTMLIFrameElement, onChartError: (event: WorkbookChartErrorEvent) => void)

workbookExploreKeyOnChangeListener

Listen for a workbook explore key change event, and execute the given callback when it occurs.

workbookExploreKeyOnChangeListener(event: MessageEvent, iframe: HTMLIFrameElement, onExploreKeyOnChange: (event: WorkbookExploreKeyOnChangeEvent) => void)

workbookBookmarkOnChangeListener

Listen for a workbook bookmark change event, and execute the given callback when it occurs.

workbookBookmarkOnChangeListener(event: MessageEvent, iframe: HTMLIFrameElement, onBookmarkChange: (event: WorkbookBookmarkOnChangeEvent) => void)

urlOnChangeListener

Listen for a url change event, and execute the given callback when it occurs.

urlOnChangeListener(event: MessageEvent, iframe: HTMLIFrameElement, onUrlChange: (event: UrlOnChangeEvent) => void)

workbookIdOnChangeListener

Listen for a workbook id change event, and execute the given callback when it occurs.

workbookIdOnChangeListener(event: MessageEvent, iframe: HTMLIFrameElement, onWorkbookIdChange: (event: WorkbookIdOnChangeEvent) => void)

Mutations

These are functions that can be used to send messages to the embed. They may cause an event to be emitted from the embed.

workbookVariablesList

Send a message to the embed to list the current variables. This will cause a workbook:variables:current event to be emitted from the embed, and can be used with the workbookCurrentVariablesListener function.

workbookVariablesList(iframe: HTMLIFrameElement)

workbookVariablesUpdate

Send a message to the embed to update the variables.

workbookVariablesUpdate(iframe: HTMLIFrameElement, variables: Record<string, string>)

workbookSharingLinkUpdate

Send a message to the embed to update the sharing link.

workbookSharingLinkUpdate(iframe: HTMLIFrameElement, sharingLink: string | null, sharingExplorationLink?: string | null)

workbookBookmarkCreate

Send a message to the embed to create a bookmark.

workbookBookmarkCreate(iframe: HTMLIFrameElement, bookmark: WorkbookBookmarkCreateEvent)

workbookBookmarkUpdate

Send a message to the embed to update the current bookmark.

workbookBookmarkUpdate(iframe: HTMLIFrameElement)

workbookFullscreenUpdate

Send a message to the embed to toggle the fullscreen state of the given element.

workbookFullscreenUpdate(iframe: HTMLIFrameElement, nodeId: string | null)

workbookSelectedNodeIdUpdate

Send a message to the embed to update the selected element. Can be a pageId or elementId.

workbookSelectedNodeIdUpdate(iframe: HTMLIFrameElement, nodeId: string, nodeType: "element" | "page")