New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

polyfire-js

Package Overview
Dependencies
Maintainers
3
Versions
59
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

polyfire-js - npm Package Compare versions

Comparing version 0.2.35 to 0.2.36

2

components/AutoCompleteInput.d.ts
import React, { CSSProperties } from "react";
export interface AutoCompleteInputProps extends React.InputHTMLAttributes<HTMLInputElement> {
completionColor?: CSSProperties["color"];
containerStyle?: CSSProperties;
containerClassName?: string;
}
export declare function AutoCompleteInput(props: AutoCompleteInputProps): React.ReactElement;

17

components/AutoCompleteInput.js

@@ -89,3 +89,2 @@ "use strict";

maxWidth: "100%",
border: "1px solid #ccc",
minHeight: "2rem",

@@ -104,4 +103,4 @@ position: "relative",

paddingBottom: "0",
border: "none",
overflow: "hidden",
border: "1px solid #ccc",
};

@@ -125,8 +124,8 @@ var completionStyle = {

var _this = this;
var _a = props.completionColor, completionColor = _a === void 0 ? "grey" : _a, _b = props.className, className = _b === void 0 ? "" : _b, inputProps = __rest(props, ["completionColor", "className"]);
var _c = (0, hooks_1.usePolyfire)(), status = _c.auth.status, generate = _c.models.generate;
var _d = (0, react_1.useState)(""), prompt = _d[0], setPrompt = _d[1];
var _e = (0, react_1.useState)(""), completion = _e[0], setCompletion = _e[1];
var _a = props.completionColor, completionColor = _a === void 0 ? "grey" : _a, inputProps = __rest(props, ["completionColor"]);
var _b = (0, hooks_1.usePolyfire)(), status = _b.auth.status, generate = _b.models.generate;
var _c = (0, react_1.useState)(""), prompt = _c[0], setPrompt = _c[1];
var _d = (0, react_1.useState)(""), completion = _d[0], setCompletion = _d[1];
// This state is used to wait for the user to start typing again before initiating a new completion
var _f = (0, react_1.useState)(false), completionUsed = _f[0], setCompletionUsed = _f[1];
var _e = (0, react_1.useState)(false), completionUsed = _e[0], setCompletionUsed = _e[1];
var inputRef = (0, react_1.useRef)(null);

@@ -213,4 +212,4 @@ var hiddenSizerRef = (0, react_1.useRef)(null);

}, [completion]);
return (react_1.default.createElement("div", { style: containerStyle, className: className },
react_1.default.createElement("input", __assign({}, inputProps, { ref: inputRef, value: prompt, onChange: onChange, onKeyDown: onKeyDown, style: inputStyle, className: className })),
return (react_1.default.createElement("div", { style: __assign(__assign({}, containerStyle), props.containerStyle), className: props.containerClassName },
react_1.default.createElement("input", __assign({}, inputProps, { ref: inputRef, value: prompt, onChange: onChange, onKeyDown: onKeyDown, style: __assign(__assign({}, inputStyle), props.style), className: props.className })),
react_1.default.createElement("span", { ref: hiddenSizerRef, style: hiddenSizerStyle }),

@@ -217,0 +216,0 @@ react_1.default.createElement("span", { ref: completionRef, style: __assign(__assign({}, completionStyle), { color: completionColor }) }, completion)));

{
"name": "polyfire-js",
"version": "0.2.35",
"version": "0.2.36",
"main": "index.js",

@@ -5,0 +5,0 @@ "types": "index.d.ts",

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