@openfin/workspace-platform
TypeScript icon, indicating that this package has built-in type declarations

17.2.14 • Public • Published

Workspace Platform API

The Workspace Platform Client APIs allow integrators to create their own Workspace platforms.

Installation

Run npm i -E @openfin/workspace-platform.

Workspace Platform API documentation

Code examples

Initialize a Workspace Platform

import * as WorkspacePlatform from '@openfin/workspace-platform';

const customThemes: WorkspacePlatform.CustomThemes = [
    {
        label: "OpenFin's Custom Theme",
        palette: {
            brandPrimary: '#F51F63', // required
            brandSecondary: '#1FF58A', // required
            backgroundPrimary: '#F8E71C', // required - hex, rgb/rgba, hsl/hsla only - no string colors: ‘red’
            background2: '#7D808A' // any of the optional colors
        }
    }
];

const overrideCallback: WorkspacePlatform.WorkspacePlatformOverrideCallback = async (WorkspacePlatformProvider) => {
    class Override extends WorkspacePlatformProvider {
        async quit(payload, callerIdentity) {
            return super.quit(payload, callerIdentity);
        }
    }
    return new Override();
};

await WorkspacePlatform.init({
    browser: {
        title: 'My Browser'
    },
    overrideCallback,
    theme: customThemes
});

Package Sidebar

Install

npm i @openfin/workspace-platform

Weekly Downloads

362

Version

17.2.14

License

SEE LICENSE IN LICENSE.MD

Unpacked Size

2.34 MB

Total Files

189

Last publish

Collaborators

  • ameet-openfin
  • jmransegnola
  • marek_openfin
  • yoge-openfin
  • nil.ffej
  • gilesstevenson-openfin
  • eheyder
  • newaz.sharif
  • efraim-herstic
  • royhafin
  • openfincolinhu
  • openfin-johans
  • alan15008
  • openfin-ci-gh
  • hina-khalid
  • ife-dev1
  • mjosling
  • elliott.burr
  • vsaw3
  • gallak-openfin
  • galim.kaudinov
  • hzhi0209
  • andy.westacott
  • __tomasz__
  • cameronopenfin
  • jennrondeau
  • dhilan
  • benstubbington
  • davidcoxon-of
  • openfin-jeff
  • gouthamc
  • hannahmcmillen
  • xyopenfin
  • smocarski
  • eugeneross-openfin
  • imansuri
  • manamiueda
  • sakibahmad
  • shahossain
  • openfinbrandon
  • pierrebaize
  • noyangunday
  • michaelmcoates
  • johnmandia-openfin
  • rdepena
  • tgoc99
  • wenjunche
  • harsimran.openfin.singh
  • luiemilio
  • licui3936
  • connormccafferty
  • adam.saland
  • openfin-ci
  • chrishobsonexpero
  • richbrowne-openfin
  • azizyok
  • openfin-gavin
  • oblarg