Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@khanacademy/perseus-core

Package Overview
Dependencies
Maintainers
1
Versions
282
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@khanacademy/perseus-core - npm Package Compare versions

Comparing version 0.0.0-PR686-20230822002019 to 0.0.0-PR719-20230911225354

14

CHANGELOG.md
# @khanacademy/perseus-core
## 0.0.0-PR686-20230822002019
## 0.0.0-PR719-20230911225354
### Minor Changes
- 2556e800: Added new analytics event "perseus:expression-focused"
## 1.0.0
### Major Changes
- 2af4f9fa: Switch from using ProvideKeypad in ArticleRenderer to passing the keypad element down instead
## 0.2.0
### Minor Changes
- dd800c22: Rename analytics prop from onEvent to onAnalyticsEvent

@@ -8,0 +20,0 @@

export type VirtualKeypadVersion = "PERSEUS_MATH_INPUT" | "MATH_INPUT_KEYPAD_V1" | "MATH_INPUT_KEYPAD_V2" | "REACT_NATIVE_KEYPAD";
/**
* A type union of all the events that any package in the Perseus ecosystem can
* send.
*/
export type PerseusAnalyticsEvent = {

@@ -9,2 +13,5 @@ type: "perseus:expression-evaluated";

} | {
type: "perseus:expression-focused";
payload: null;
} | {
type: "math-input:keypad-closed";

@@ -11,0 +18,0 @@ payload: {

2

dist/index.d.ts
export type { PerseusAnalyticsEvent, AnalyticsEventHandlerFn } from "./analytics";
export type { KEScore, RendererInterface } from "./types";
export type { KEScore, KeypadContextRendererInterface, RendererInterface, } from "./types";

@@ -0,1 +1,4 @@

export interface KeypadContextRendererInterface {
blur(): void;
}
type State = any;

@@ -2,0 +5,0 @@ export interface RendererInterface {

@@ -6,3 +6,3 @@ {

"license": "MIT",
"version": "0.0.0-PR686-20230822002019",
"version": "0.0.0-PR719-20230911225354",
"publishConfig": {

@@ -13,3 +13,4 @@ "access": "public"

"type": "git",
"url": "https://github.com/Khan/perseus.git"
"url": "https://github.com/Khan/perseus.git",
"directory": "packages/perseus-core"
},

@@ -16,0 +17,0 @@ "bugs": {

@@ -7,4 +7,6 @@ export type VirtualKeypadVersion =

// A type union of all the events that any package in the Perseus ecosystem can
// send.
/**
* A type union of all the events that any package in the Perseus ecosystem can
* send.
*/
export type PerseusAnalyticsEvent =

@@ -19,2 +21,6 @@ | {

| {
type: "perseus:expression-focused";
payload: null;
}
| {
type: "math-input:keypad-closed";

@@ -34,2 +40,6 @@ payload: {

// | {type: "b"; payload: {name: string}};
//
// Event types should be formatted as "package-name:event-name" (where the
// package name is the name of the package that emits the event without the
// `@khanacademy/` prefix and then the name of the event.)

@@ -36,0 +46,0 @@ /** A function that is called when Perseus emits an analytics event. */

export type {PerseusAnalyticsEvent, AnalyticsEventHandlerFn} from "./analytics";
export type {KEScore, RendererInterface} from "./types";
export type {
KEScore,
KeypadContextRendererInterface,
RendererInterface,
} from "./types";
// Types that can be shared between Perseus packages
// ideally without causing circular dependencies
// Used by KeypadContext to pass around a renderer reference
export interface KeypadContextRendererInterface {
blur(): void;
}
// TODO: this should be typed

@@ -8,4 +13,3 @@ type State = any;

// Interfact currently only implemented by
// ServerItemRenderer and used by KeypadContext
// to pass around a renderer reference
// ServerItemRenderer
export interface RendererInterface {

@@ -12,0 +16,0 @@ getSerializedState(): State;

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc