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

@flywire/react-headlessui

Package Overview
Dependencies
Maintainers
11
Versions
73
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@flywire/react-headlessui - npm Package Compare versions

Comparing version 0.0.11 to 0.0.12

4

dist/cjs/hooks/useMaskInput/useMaskInput.js

@@ -10,7 +10,7 @@ "use strict";

const NO_VALUE = '';
function useMaskInput({ mask, onChange = () => {
function useMaskInput({ initialValue = NO_VALUE, mask, onChange = () => {
// does nothing
}, ...rest }) {
const inputRef = (0, react_1.useRef)(null);
const [value, setValue] = (0, react_1.useState)(NO_VALUE);
const [value, setValue] = (0, react_1.useState)(initialValue);
const runAfterUpdate = (0, useRunAfterUpdate_1.default)();

@@ -17,0 +17,0 @@ function handleInputChange(evt) {

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

const afterPaintRef = (0, react_1.useRef)();
(0, react_1.useLayoutEffect)(() => {
(0, react_1.useEffect)(() => {
var _a;

@@ -9,0 +9,0 @@ if (afterPaintRef.current) {

import { ChangeEvent, InputHTMLAttributes } from 'react';
interface Props extends InputHTMLAttributes<HTMLInputElement> {
initialValue?: string;
mask: string;
}
declare function useMaskInput({ mask, onChange, ...rest }: Props): {
declare function useMaskInput({ initialValue, mask, onChange, ...rest }: Props): {
inputProps: {

@@ -7,0 +8,0 @@ accept?: string | undefined;

@@ -5,7 +5,7 @@ import { useRef, useState } from 'react';

const NO_VALUE = '';
function useMaskInput({ mask, onChange = () => {
function useMaskInput({ initialValue = NO_VALUE, mask, onChange = () => {
// does nothing
}, ...rest }) {
const inputRef = useRef(null);
const [value, setValue] = useState(NO_VALUE);
const [value, setValue] = useState(initialValue);
const runAfterUpdate = useRunAfterUpdate();

@@ -12,0 +12,0 @@ function handleInputChange(evt) {

@@ -1,5 +0,5 @@

import { useRef, useLayoutEffect } from 'react';
import { useRef, useEffect } from 'react';
function useRunAfterUpdate() {
const afterPaintRef = useRef();
useLayoutEffect(() => {
useEffect(() => {
var _a;

@@ -6,0 +6,0 @@ if (afterPaintRef.current) {

import { ChangeEvent, InputHTMLAttributes } from 'react';
interface Props extends InputHTMLAttributes<HTMLInputElement> {
initialValue?: string;
mask: string;
}
declare function useMaskInput({ mask, onChange, ...rest }: Props): {
declare function useMaskInput({ initialValue, mask, onChange, ...rest }: Props): {
inputProps: {

@@ -7,0 +8,0 @@ accept?: string | undefined;

@@ -19,7 +19,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {

const NO_VALUE = '';
function useMaskInput({ mask, onChange = () => {
function useMaskInput({ initialValue = NO_VALUE, mask, onChange = () => {
// does nothing
}, ...rest }) {
const inputRef = (0, react_1.useRef)(null);
const [value, setValue] = (0, react_1.useState)(NO_VALUE);
const [value, setValue] = (0, react_1.useState)(initialValue);
const runAfterUpdate = (0, useRunAfterUpdate_1.default)();

@@ -26,0 +26,0 @@ function handleInputChange(evt) {

@@ -15,3 +15,3 @@ (function (factory) {

const afterPaintRef = (0, react_1.useRef)();
(0, react_1.useLayoutEffect)(() => {
(0, react_1.useEffect)(() => {
var _a;

@@ -18,0 +18,0 @@ if (afterPaintRef.current) {

import { ChangeEvent, InputHTMLAttributes } from 'react';
interface Props extends InputHTMLAttributes<HTMLInputElement> {
initialValue?: string;
mask: string;
}
declare function useMaskInput({ mask, onChange, ...rest }: Props): {
declare function useMaskInput({ initialValue, mask, onChange, ...rest }: Props): {
inputProps: {

@@ -7,0 +8,0 @@ accept?: string | undefined;

{
"name": "@flywire/react-headlessui",
"version": "0.0.11",
"version": "0.0.12",
"description": "Headless UI components",

@@ -5,0 +5,0 @@ "main": "./dist/umd/index.js",

@@ -5,9 +5,6 @@ # @flywire/react-headlessui

## Components
## Documentation
- [Input](src/components/Field/README.md)
The documentation and examples are hosted in [https://flywire-ui-docs.flywire.com](https://flywire-ui-docs.flywire.com).
## Wiki
If you want to collaborate and contribute ideas, use the [Wiki](https://gitlab.flywire.tech/flywire/development/react-headlessui/-/wikis/react-headlessui)
## Installation

@@ -26,3 +23,3 @@

```bash
git clone git@github.com:peertransfer/react-headlessui.git
git clone git@git.gitlab.flywire.tech:flywire/development/react-headlessui.git
```

@@ -29,0 +26,0 @@

Sorry, the diff of this file is not supported yet

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