react-validate-component 0.0.1 → 0.0.2-0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import * as React from 'react';
2
2
  import { VINPUT_PARAMS } from './types/vinput';
3
- export declare const VText: ({ maxLength, value, className, props, }: VINPUT_PARAMS) => React.JSX.Element;
3
+ export declare const VText: ({ maxLength, value, className, }: VINPUT_PARAMS) => React.JSX.Element;
4
4
  export declare const VCheckbox: () => React.JSX.Element;
5
5
  export declare const VRadio: () => React.JSX.Element;
6
6
  export declare const VDate: () => React.JSX.Element;
@@ -8,15 +8,15 @@ var React = require('react');
8
8
  var VText = function VText(_ref) {
9
9
  var maxLength = _ref.maxLength,
10
10
  value = _ref.value,
11
- className = _ref.className,
12
- props = _ref.props;
13
- return React.createElement("input", Object.assign({
14
- type: "text"
15
- }, props, {
11
+ className = _ref.className;
12
+ return React.createElement("input", {
13
+ type: "text",
14
+ // {...props}
16
15
  className: className,
17
16
  maxLength: maxLength,
18
- value: value
19
- }));
17
+ value: value,
18
+ placeholder: "this is react-validate-component test."
19
+ });
20
20
  };
21
21
  // Checkbox
22
22
  var VCheckbox = function VCheckbox() {
@@ -1 +1 @@
1
- {"version":3,"file":"react-validate-component.cjs.development.js","sources":["../src/index.tsx"],"sourcesContent":["import * as React from 'react';\nimport { VINPUT_PARAMS } from './types/vinput';\n\n// Text\nexport const VText = ({\n maxLength,\n value,\n className,\n props,\n}: VINPUT_PARAMS) => {\n return (\n <input\n type=\"text\"\n {...props}\n className={className}\n maxLength={maxLength}\n value={value}\n />\n );\n};\n\n// Checkbox\nexport const VCheckbox = () => {\n return <input type=\"checkbox\" />;\n};\n\n// Radio\nexport const VRadio = () => {\n return <input type=\"radio\" />;\n};\n\n// Date\nexport const VDate = () => {\n return <input type=\"date\" />;\n};\n\n// Color\nexport const VColor = () => {\n return <input type=\"color\" />;\n};\n\n// Email\nexport const VEmail = () => {\n return <input type=\"email\" />;\n};\n\n// Range\nexport const VRange = () => {\n return <input type=\"range\" />;\n};\n\n// Url\nexport const VUrl = () => {\n return <input type=\"url\" />;\n};\n"],"names":["VText","_ref","maxLength","value","className","props","React","type","VCheckbox","VRadio","VDate","VColor","VEmail","VRange","VUrl"],"mappings":";;;;;;AAGA;IACaA,KAAK,GAAG,SAARA,KAAKA,CAAAC,IAAA;MAChBC,SAAS,GAAAD,IAAA,CAATC,SAAS;IACTC,KAAK,GAAAF,IAAA,CAALE,KAAK;IACLC,SAAS,GAAAH,IAAA,CAATG,SAAS;IACTC,KAAK,GAAAJ,IAAA,CAALI,KAAK;EAEL,OACEC;IACEC,IAAI,EAAC;KACDF,KAAK;IACTD,SAAS,EAAEA,SAAS;IACpBF,SAAS,EAAEA,SAAS;IACpBC,KAAK,EAAEA;KACP;AAEN;AAEA;IACaK,SAAS,GAAG,SAAZA,SAASA;EACpB,OAAOF;IAAOC,IAAI,EAAC;IAAa;AAClC;AAEA;IACaE,MAAM,GAAG,SAATA,MAAMA;EACjB,OAAOH;IAAOC,IAAI,EAAC;IAAU;AAC/B;AAEA;IACaG,KAAK,GAAG,SAARA,KAAKA;EAChB,OAAOJ;IAAOC,IAAI,EAAC;IAAS;AAC9B;AAEA;IACaI,MAAM,GAAG,SAATA,MAAMA;EACjB,OAAOL;IAAOC,IAAI,EAAC;IAAU;AAC/B;AAEA;IACaK,MAAM,GAAG,SAATA,MAAMA;EACjB,OAAON;IAAOC,IAAI,EAAC;IAAU;AAC/B;AAEA;IACaM,MAAM,GAAG,SAATA,MAAMA;EACjB,OAAOP;IAAOC,IAAI,EAAC;IAAU;AAC/B;AAEA;IACaO,IAAI,GAAG,SAAPA,IAAIA;EACf,OAAOR;IAAOC,IAAI,EAAC;IAAQ;AAC7B;;;;;;;;;;;"}
1
+ {"version":3,"file":"react-validate-component.cjs.development.js","sources":["../src/index.tsx"],"sourcesContent":["import * as React from 'react';\nimport { VINPUT_PARAMS } from './types/vinput';\n\n// Text\nexport const VText = ({\n maxLength,\n value,\n className,\n}: // props,\nVINPUT_PARAMS) => {\n return (\n <input\n type=\"text\"\n // {...props}\n className={className}\n maxLength={maxLength}\n value={value}\n placeholder=\"this is react-validate-component test.\"\n />\n );\n};\n\n// Checkbox\nexport const VCheckbox = () => {\n return <input type=\"checkbox\" />;\n};\n\n// Radio\nexport const VRadio = () => {\n return <input type=\"radio\" />;\n};\n\n// Date\nexport const VDate = () => {\n return <input type=\"date\" />;\n};\n\n// Color\nexport const VColor = () => {\n return <input type=\"color\" />;\n};\n\n// Email\nexport const VEmail = () => {\n return <input type=\"email\" />;\n};\n\n// Range\nexport const VRange = () => {\n return <input type=\"range\" />;\n};\n\n// Url\nexport const VUrl = () => {\n return <input type=\"url\" />;\n};\n"],"names":["VText","_ref","maxLength","value","className","React","type","placeholder","VCheckbox","VRadio","VDate","VColor","VEmail","VRange","VUrl"],"mappings":";;;;;;AAGA;IACaA,KAAK,GAAG,SAARA,KAAKA,CAAAC,IAAA;MAChBC,SAAS,GAAAD,IAAA,CAATC,SAAS;IACTC,KAAK,GAAAF,IAAA,CAALE,KAAK;IACLC,SAAS,GAAAH,IAAA,CAATG,SAAS;EAGT,OACEC;IACEC,IAAI,EAAC,MAAM;;IAEXF,SAAS,EAAEA,SAAS;IACpBF,SAAS,EAAEA,SAAS;IACpBC,KAAK,EAAEA,KAAK;IACZI,WAAW,EAAC;IACZ;AAEN;AAEA;IACaC,SAAS,GAAG,SAAZA,SAASA;EACpB,OAAOH;IAAOC,IAAI,EAAC;IAAa;AAClC;AAEA;IACaG,MAAM,GAAG,SAATA,MAAMA;EACjB,OAAOJ;IAAOC,IAAI,EAAC;IAAU;AAC/B;AAEA;IACaI,KAAK,GAAG,SAARA,KAAKA;EAChB,OAAOL;IAAOC,IAAI,EAAC;IAAS;AAC9B;AAEA;IACaK,MAAM,GAAG,SAATA,MAAMA;EACjB,OAAON;IAAOC,IAAI,EAAC;IAAU;AAC/B;AAEA;IACaM,MAAM,GAAG,SAATA,MAAMA;EACjB,OAAOP;IAAOC,IAAI,EAAC;IAAU;AAC/B;AAEA;IACaO,MAAM,GAAG,SAATA,MAAMA;EACjB,OAAOR;IAAOC,IAAI,EAAC;IAAU;AAC/B;AAEA;IACaQ,IAAI,GAAG,SAAPA,IAAIA;EACf,OAAOT;IAAOC,IAAI,EAAC;IAAQ;AAC7B;;;;;;;;;;;"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react");exports.VCheckbox=function(){return e.createElement("input",{type:"checkbox"})},exports.VColor=function(){return e.createElement("input",{type:"color"})},exports.VDate=function(){return e.createElement("input",{type:"date"})},exports.VEmail=function(){return e.createElement("input",{type:"email"})},exports.VRadio=function(){return e.createElement("input",{type:"radio"})},exports.VRange=function(){return e.createElement("input",{type:"range"})},exports.VText=function(t){return e.createElement("input",Object.assign({type:"text"},t.props,{className:t.className,maxLength:t.maxLength,value:t.value}))},exports.VUrl=function(){return e.createElement("input",{type:"url"})};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react");exports.VCheckbox=function(){return e.createElement("input",{type:"checkbox"})},exports.VColor=function(){return e.createElement("input",{type:"color"})},exports.VDate=function(){return e.createElement("input",{type:"date"})},exports.VEmail=function(){return e.createElement("input",{type:"email"})},exports.VRadio=function(){return e.createElement("input",{type:"radio"})},exports.VRange=function(){return e.createElement("input",{type:"range"})},exports.VText=function(t){return e.createElement("input",{type:"text",className:t.className,maxLength:t.maxLength,value:t.value,placeholder:"this is react-validate-component test."})},exports.VUrl=function(){return e.createElement("input",{type:"url"})};
2
2
  //# sourceMappingURL=react-validate-component.cjs.production.min.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"react-validate-component.cjs.production.min.js","sources":["../src/index.tsx"],"sourcesContent":["import * as React from 'react';\nimport { VINPUT_PARAMS } from './types/vinput';\n\n// Text\nexport const VText = ({\n maxLength,\n value,\n className,\n props,\n}: VINPUT_PARAMS) => {\n return (\n <input\n type=\"text\"\n {...props}\n className={className}\n maxLength={maxLength}\n value={value}\n />\n );\n};\n\n// Checkbox\nexport const VCheckbox = () => {\n return <input type=\"checkbox\" />;\n};\n\n// Radio\nexport const VRadio = () => {\n return <input type=\"radio\" />;\n};\n\n// Date\nexport const VDate = () => {\n return <input type=\"date\" />;\n};\n\n// Color\nexport const VColor = () => {\n return <input type=\"color\" />;\n};\n\n// Email\nexport const VEmail = () => {\n return <input type=\"email\" />;\n};\n\n// Range\nexport const VRange = () => {\n return <input type=\"range\" />;\n};\n\n// Url\nexport const VUrl = () => {\n return <input type=\"url\" />;\n};\n"],"names":["React","type","_ref","props","className","maxLength","value"],"mappings":"6GAsByB,WACvB,OAAOA,yBAAOC,KAAK,6BAcC,WACpB,OAAOD,yBAAOC,KAAK,yBANA,WACnB,OAAOD,yBAAOC,KAAK,yBASC,WACpB,OAAOD,yBAAOC,KAAK,0BAhBC,WACpB,OAAOD,yBAAOC,KAAK,0BAmBC,WACpB,OAAOD,yBAAOC,KAAK,yBA5CA,SAAHC,GAMhB,OACEF,uCACEC,KAAK,QAJJC,EAALC,OAMIC,UAPKF,EAATE,UAQIC,UAVKH,EAATG,UAWIC,MAVCJ,EAALI,uBA8CkB,WAClB,OAAON,yBAAOC,KAAK"}
1
+ {"version":3,"file":"react-validate-component.cjs.production.min.js","sources":["../src/index.tsx"],"sourcesContent":["import * as React from 'react';\nimport { VINPUT_PARAMS } from './types/vinput';\n\n// Text\nexport const VText = ({\n maxLength,\n value,\n className,\n}: // props,\nVINPUT_PARAMS) => {\n return (\n <input\n type=\"text\"\n // {...props}\n className={className}\n maxLength={maxLength}\n value={value}\n placeholder=\"this is react-validate-component test.\"\n />\n );\n};\n\n// Checkbox\nexport const VCheckbox = () => {\n return <input type=\"checkbox\" />;\n};\n\n// Radio\nexport const VRadio = () => {\n return <input type=\"radio\" />;\n};\n\n// Date\nexport const VDate = () => {\n return <input type=\"date\" />;\n};\n\n// Color\nexport const VColor = () => {\n return <input type=\"color\" />;\n};\n\n// Email\nexport const VEmail = () => {\n return <input type=\"email\" />;\n};\n\n// Range\nexport const VRange = () => {\n return <input type=\"range\" />;\n};\n\n// Url\nexport const VUrl = () => {\n return <input type=\"url\" />;\n};\n"],"names":["React","type","_ref","className","maxLength","value","placeholder"],"mappings":"6GAuByB,WACvB,OAAOA,yBAAOC,KAAK,6BAcC,WACpB,OAAOD,yBAAOC,KAAK,yBANA,WACnB,OAAOD,yBAAOC,KAAK,yBASC,WACpB,OAAOD,yBAAOC,KAAK,0BAhBC,WACpB,OAAOD,yBAAOC,KAAK,0BAmBC,WACpB,OAAOD,yBAAOC,KAAK,yBA7CA,SAAHC,GAMhB,OACEF,yBACEC,KAAK,OAELE,UAPKD,EAATC,UAQIC,UAVKF,EAATE,UAWIC,MAVCH,EAALG,MAWIC,YAAY,yDAoCE,WAClB,OAAON,yBAAOC,KAAK"}
@@ -4,15 +4,15 @@ import { createElement } from 'react';
4
4
  var VText = function VText(_ref) {
5
5
  var maxLength = _ref.maxLength,
6
6
  value = _ref.value,
7
- className = _ref.className,
8
- props = _ref.props;
9
- return createElement("input", Object.assign({
10
- type: "text"
11
- }, props, {
7
+ className = _ref.className;
8
+ return createElement("input", {
9
+ type: "text",
10
+ // {...props}
12
11
  className: className,
13
12
  maxLength: maxLength,
14
- value: value
15
- }));
13
+ value: value,
14
+ placeholder: "this is react-validate-component test."
15
+ });
16
16
  };
17
17
  // Checkbox
18
18
  var VCheckbox = function VCheckbox() {
@@ -1 +1 @@
1
- {"version":3,"file":"react-validate-component.esm.js","sources":["../src/index.tsx"],"sourcesContent":["import * as React from 'react';\nimport { VINPUT_PARAMS } from './types/vinput';\n\n// Text\nexport const VText = ({\n maxLength,\n value,\n className,\n props,\n}: VINPUT_PARAMS) => {\n return (\n <input\n type=\"text\"\n {...props}\n className={className}\n maxLength={maxLength}\n value={value}\n />\n );\n};\n\n// Checkbox\nexport const VCheckbox = () => {\n return <input type=\"checkbox\" />;\n};\n\n// Radio\nexport const VRadio = () => {\n return <input type=\"radio\" />;\n};\n\n// Date\nexport const VDate = () => {\n return <input type=\"date\" />;\n};\n\n// Color\nexport const VColor = () => {\n return <input type=\"color\" />;\n};\n\n// Email\nexport const VEmail = () => {\n return <input type=\"email\" />;\n};\n\n// Range\nexport const VRange = () => {\n return <input type=\"range\" />;\n};\n\n// Url\nexport const VUrl = () => {\n return <input type=\"url\" />;\n};\n"],"names":["VText","_ref","maxLength","value","className","props","React","type","VCheckbox","VRadio","VDate","VColor","VEmail","VRange","VUrl"],"mappings":";;AAGA;IACaA,KAAK,GAAG,SAARA,KAAKA,CAAAC,IAAA;MAChBC,SAAS,GAAAD,IAAA,CAATC,SAAS;IACTC,KAAK,GAAAF,IAAA,CAALE,KAAK;IACLC,SAAS,GAAAH,IAAA,CAATG,SAAS;IACTC,KAAK,GAAAJ,IAAA,CAALI,KAAK;EAEL,OACEC;IACEC,IAAI,EAAC;KACDF,KAAK;IACTD,SAAS,EAAEA,SAAS;IACpBF,SAAS,EAAEA,SAAS;IACpBC,KAAK,EAAEA;KACP;AAEN;AAEA;IACaK,SAAS,GAAG,SAAZA,SAASA;EACpB,OAAOF;IAAOC,IAAI,EAAC;IAAa;AAClC;AAEA;IACaE,MAAM,GAAG,SAATA,MAAMA;EACjB,OAAOH;IAAOC,IAAI,EAAC;IAAU;AAC/B;AAEA;IACaG,KAAK,GAAG,SAARA,KAAKA;EAChB,OAAOJ;IAAOC,IAAI,EAAC;IAAS;AAC9B;AAEA;IACaI,MAAM,GAAG,SAATA,MAAMA;EACjB,OAAOL;IAAOC,IAAI,EAAC;IAAU;AAC/B;AAEA;IACaK,MAAM,GAAG,SAATA,MAAMA;EACjB,OAAON;IAAOC,IAAI,EAAC;IAAU;AAC/B;AAEA;IACaM,MAAM,GAAG,SAATA,MAAMA;EACjB,OAAOP;IAAOC,IAAI,EAAC;IAAU;AAC/B;AAEA;IACaO,IAAI,GAAG,SAAPA,IAAIA;EACf,OAAOR;IAAOC,IAAI,EAAC;IAAQ;AAC7B;;;;"}
1
+ {"version":3,"file":"react-validate-component.esm.js","sources":["../src/index.tsx"],"sourcesContent":["import * as React from 'react';\nimport { VINPUT_PARAMS } from './types/vinput';\n\n// Text\nexport const VText = ({\n maxLength,\n value,\n className,\n}: // props,\nVINPUT_PARAMS) => {\n return (\n <input\n type=\"text\"\n // {...props}\n className={className}\n maxLength={maxLength}\n value={value}\n placeholder=\"this is react-validate-component test.\"\n />\n );\n};\n\n// Checkbox\nexport const VCheckbox = () => {\n return <input type=\"checkbox\" />;\n};\n\n// Radio\nexport const VRadio = () => {\n return <input type=\"radio\" />;\n};\n\n// Date\nexport const VDate = () => {\n return <input type=\"date\" />;\n};\n\n// Color\nexport const VColor = () => {\n return <input type=\"color\" />;\n};\n\n// Email\nexport const VEmail = () => {\n return <input type=\"email\" />;\n};\n\n// Range\nexport const VRange = () => {\n return <input type=\"range\" />;\n};\n\n// Url\nexport const VUrl = () => {\n return <input type=\"url\" />;\n};\n"],"names":["VText","_ref","maxLength","value","className","React","type","placeholder","VCheckbox","VRadio","VDate","VColor","VEmail","VRange","VUrl"],"mappings":";;AAGA;IACaA,KAAK,GAAG,SAARA,KAAKA,CAAAC,IAAA;MAChBC,SAAS,GAAAD,IAAA,CAATC,SAAS;IACTC,KAAK,GAAAF,IAAA,CAALE,KAAK;IACLC,SAAS,GAAAH,IAAA,CAATG,SAAS;EAGT,OACEC;IACEC,IAAI,EAAC,MAAM;;IAEXF,SAAS,EAAEA,SAAS;IACpBF,SAAS,EAAEA,SAAS;IACpBC,KAAK,EAAEA,KAAK;IACZI,WAAW,EAAC;IACZ;AAEN;AAEA;IACaC,SAAS,GAAG,SAAZA,SAASA;EACpB,OAAOH;IAAOC,IAAI,EAAC;IAAa;AAClC;AAEA;IACaG,MAAM,GAAG,SAATA,MAAMA;EACjB,OAAOJ;IAAOC,IAAI,EAAC;IAAU;AAC/B;AAEA;IACaI,KAAK,GAAG,SAARA,KAAKA;EAChB,OAAOL;IAAOC,IAAI,EAAC;IAAS;AAC9B;AAEA;IACaK,MAAM,GAAG,SAATA,MAAMA;EACjB,OAAON;IAAOC,IAAI,EAAC;IAAU;AAC/B;AAEA;IACaM,MAAM,GAAG,SAATA,MAAMA;EACjB,OAAOP;IAAOC,IAAI,EAAC;IAAU;AAC/B;AAEA;IACaO,MAAM,GAAG,SAATA,MAAMA;EACjB,OAAOR;IAAOC,IAAI,EAAC;IAAU;AAC/B;AAEA;IACaQ,IAAI,GAAG,SAAPA,IAAIA;EACf,OAAOT;IAAOC,IAAI,EAAC;IAAQ;AAC7B;;;;"}
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "0.0.1",
2
+ "version": "0.0.2-0",
3
3
  "license": "MIT",
4
4
  "main": "dist/index.js",
5
5
  "typings": "dist/index.d.ts",
package/src/index.tsx CHANGED
@@ -6,15 +6,16 @@ export const VText = ({
6
6
  maxLength,
7
7
  value,
8
8
  className,
9
- props,
10
- }: VINPUT_PARAMS) => {
9
+ }: // props,
10
+ VINPUT_PARAMS) => {
11
11
  return (
12
12
  <input
13
13
  type="text"
14
- {...props}
14
+ // {...props}
15
15
  className={className}
16
16
  maxLength={maxLength}
17
17
  value={value}
18
+ placeholder="this is react-validate-component test."
18
19
  />
19
20
  );
20
21
  };