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

@amalto/code-editor

Package Overview
Dependencies
Maintainers
3
Versions
174
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@amalto/code-editor - npm Package Compare versions

Comparing version 1.4.5 to 1.4.6

2

build/index.d.ts

@@ -94,3 +94,3 @@ /// <reference types="react" />

/** Code editor onchange event handler. */
editorOnChange?: (session: AceSession) => void;
editorOnChange?: (value: string) => void;
/** Save ace session after each update. */

@@ -97,0 +97,0 @@ saveSession?: (session: AceSession) => void;

@@ -217,3 +217,3 @@ "use strict";

//save current session
this.props.saveSession($.extend({}, this.getAceSession(this._editor), { cursorPosition: this._cursorLastPosition }));
this.props.saveSession && this.props.saveSession($.extend({}, this.getAceSession(this._editor), { cursorPosition: this._cursorLastPosition }));
clearInterval(this._clearTimeout);

@@ -273,3 +273,3 @@ //destroy the editor

editor.getSession().setMode(props.mode && "ace/mode/" + props.mode || 'ace/mode/javascript');
editor.getSession().on('change', function (e) {
editor.getSession().on('changeCursor', function (e) {
if (_this._firstChangeTime <= props.loadTime) {

@@ -280,4 +280,12 @@ _this._firstChangeTime = new Date().getTime();

_this._cursorLastPosition = e.end;
_this.props.editorOnChange($.extend(_this.getAceSession(_this._editor), { cursorPosition: _this._cursorLastPosition }));
_this.props.editorOnChange(_this._editor.getValue());
});
// editor.getSession().on( 'change', e => {
// if ( this._firstChangeTime <= props.loadTime ) {
// this._firstChangeTime = new Date().getTime()
// }
// this._canUpdate = true
// this._cursorLastPosition = e.end
// this.props.editorOnChange(this._editor.getValue())
// } )
this._firstChangeTime = props.loadTime;

@@ -284,0 +292,0 @@ };

@@ -5,3 +5,3 @@ {

"description": "Customizable code editor (non-form version).",
"version": "1.4.5",
"version": "1.4.6",
"license": "MIT",

@@ -8,0 +8,0 @@ "repository": {

Sorry, the diff of this file is not supported yet

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