1.0.10 • Published 3 years ago

react-label-editable v1.0.10

Weekly downloads
11
License
MIT
Repository
-
Last release
3 years ago

react-label-editable

React Component to create Field Input/Label that is editable easily.

Install

npm i react-label-editable --save
yarn add react-label-editable

react-label-editable package

Example

example

Usage

import LabelEditable from 'react-label-editable';
import React, { useState } from 'react';

export default function FieldEditable(){
  const [ email, changeEmail ] = useState("");

  return (
    <div className="field">
      <label className="label" for="email">E-mail</label>
      <LabelEditable 
        value={email} //value that start label
        onChange={changeEmail} //changing email value
        startWithInput={false} //start with input or label
      />
    </div>
  );
}

CSS EDIT

  .LabelEditable { }   /* Container in the component */

  .LabelEditable .label-editable { } /* Only Label Element */

  .LabelEditable .input-editable { } /* Only Input Element */
1.0.10

3 years ago

1.0.9

3 years ago

1.0.8

3 years ago

1.0.7

3 years ago

1.0.6

3 years ago

1.0.5

3 years ago

1.0.4

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago