componenteshospitais 1.3.0 → 1.3.2
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/cjs/index.js +9 -4
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/index.js +9 -4
- package/dist/esm/index.js.map +1 -1
- package/dist/types/components/CardImage.d.ts +2 -0
- package/dist/types/components/InputField.d.ts +2 -0
- package/package.json +1 -1
- package/src/components/CardImage.tsx +12 -3
- package/src/components/InputField.tsx +16 -12
package/dist/cjs/index.js
CHANGED
|
@@ -79,12 +79,17 @@ var styles$5 = {"botaoCert":"cardImage-module_botaoCert__Rs0fg","iconeOna":"card
|
|
|
79
79
|
styleInject(css_248z$5);
|
|
80
80
|
|
|
81
81
|
var CardImage = function (_a) {
|
|
82
|
-
var img = _a.img, href = _a.href, texto = _a.texto, empresa = _a.empresa, largura = _a.largura, altura = _a.altura, externo = _a.externo;
|
|
82
|
+
var img = _a.img, href = _a.href, texto = _a.texto, empresa = _a.empresa, largura = _a.largura, altura = _a.altura, externo = _a.externo, funcao = _a.funcao, parametro = _a.parametro;
|
|
83
83
|
var empresaClass = styles$5["empresa".concat(empresa)];
|
|
84
|
+
var handleActionClick = function () {
|
|
85
|
+
if (funcao && parametro) {
|
|
86
|
+
funcao(parametro);
|
|
87
|
+
}
|
|
88
|
+
};
|
|
84
89
|
var content = (React.createElement(React.Fragment, null,
|
|
85
90
|
React.createElement("img", { src: img, alt: img, className: styles$5.iconeOna }),
|
|
86
91
|
texto && (React.createElement("span", { className: styles$5.cardText, dangerouslySetInnerHTML: { __html: texto } }))));
|
|
87
|
-
return (React.createElement("div", { className: "".concat(empresaClass) }, href ? (React.createElement("a", { href: href, target: externo ? "_blank" : "_self", rel: externo ? "noopener noreferrer" : undefined, className: "".concat(styles$5.botaoCert, " empresa").concat(empresa), title: href, style: { width: largura ? "".concat(largura) : '', height: altura ? "".concat(altura) : '' } }, content)) : (React.createElement("div", { className: "".concat(styles$5.botaoCert, " empresa").concat(empresa), style: { width: largura ? "".concat(largura) : '', height: altura ? "".concat(altura) : '' } }, content))));
|
|
92
|
+
return (React.createElement("div", { className: "".concat(empresaClass) }, href ? (React.createElement("a", { href: href, target: externo ? "_blank" : "_self", rel: externo ? "noopener noreferrer" : undefined, className: "".concat(styles$5.botaoCert, " empresa").concat(empresa), title: href, style: { width: largura ? "".concat(largura) : '', height: altura ? "".concat(altura) : '' } }, content)) : (React.createElement("div", { className: "".concat(styles$5.botaoCert, " empresa").concat(empresa), onClick: handleActionClick, style: { width: largura ? "".concat(largura) : '', height: altura ? "".concat(altura) : '' } }, content))));
|
|
88
93
|
};
|
|
89
94
|
|
|
90
95
|
var css_248z$4 = ".input-module_inputSubmit__21-Pj{align-self:center;border:none;border-radius:20px;color:#fff;cursor:pointer;font-size:15px;padding:10px;width:10rem}.input-module_inputPadrao__jypjY{border:1px solid #ccc;border-radius:.5rem;font-style:italic;padding:.8rem 0 .8rem 1rem;width:100%}.input-module_inputPadrao__jypjY:focus{outline:none}.input-module_empresa1__bxBov .input-module_inputSubmit__21-Pj{background-color:var(--blue)}.input-module_empresa1__bxBov .input-module_inputSubmit__21-Pj:hover{background-color:var(--red)}.input-module_empresa3__RU89A .input-module_inputSubmit__21-Pj{background-color:var(--green)}.input-module_empresa3__RU89A .input-module_inputSubmit__21-Pj:hover{background-color:var(--lightblue)}.input-module_empresa4__rWmWH .input-module_inputSubmit__21-Pj{background-color:var(--red)}.input-module_empresa4__rWmWH .input-module_inputSubmit__21-Pj:hover{background-color:var(--blue)}";
|
|
@@ -98,10 +103,10 @@ var Button = function (_a) {
|
|
|
98
103
|
};
|
|
99
104
|
|
|
100
105
|
var InputField = function (_a) {
|
|
101
|
-
var type = _a.type, id = _a.id, placeholder = _a.placeholder, onChange = _a.onChange, value = _a.value, label = _a.label, largura = _a.largura;
|
|
106
|
+
var type = _a.type, id = _a.id, placeholder = _a.placeholder, onChange = _a.onChange, value = _a.value, label = _a.label, largura = _a.largura, readonly = _a.readonly, disabled = _a.disabled;
|
|
102
107
|
return (React.createElement(React.Fragment, null,
|
|
103
108
|
label && React.createElement("label", { htmlFor: id }, label),
|
|
104
|
-
React.createElement("input", { type: type, id: id, name: id, value: value, placeholder: placeholder, onChange: onChange, className: styles$4.inputPadrao, style: { width: largura ? "".concat(largura) : '' } })));
|
|
109
|
+
React.createElement("input", { type: type, id: id, name: id, value: value, placeholder: placeholder, onChange: onChange, className: styles$4.inputPadrao, style: { width: largura ? "".concat(largura) : '' }, readOnly: readonly, disabled: disabled })));
|
|
105
110
|
};
|
|
106
111
|
|
|
107
112
|
var css_248z$3 = ".textPage-module_container__GBEF6{align-items:center;display:flex;flex-direction:column;justify-content:center;padding:20px}.textPage-module_content__CpD68{display:flex;text-align:justify}.textPage-module_imageCabecalho__J6YFH{border-radius:8px}.textPage-module_imageCabecalho__J6YFH img{border-radius:8px;height:100%;object-fit:cover;width:100%}.textPage-module_contentWithLateralImage__-f5pQ{flex-direction:row}.textPage-module_imageLateral__Dy9Kx{align-self:flex-start;height:230px;margin-right:20px;margin-top:15px;width:300px}.textPage-module_imageLateral__Dy9Kx img{border-radius:8px;height:100%;object-fit:cover;width:100%}.textPage-module_text__3pwuU{color:#5d5d5d;flex:2;line-height:1.8;text-align:justify}.textPage-module_text__3pwuU p{line-height:1.6;margin:10px 0}.textPage-module_text__3pwuU .textPage-module_coordenacao__UypV-,.textPage-module_text__3pwuU .textPage-module_direcao__x5psb{font-weight:700;margin-top:20px}";
|
package/dist/cjs/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../node_modules/style-inject/dist/style-inject.es.js"],"sourcesContent":["function styleInject(css, ref) {\r\n if ( ref === void 0 ) ref = {};\r\n var insertAt = ref.insertAt;\r\n\r\n if (!css || typeof document === 'undefined') { return; }\r\n\r\n var head = document.head || document.getElementsByTagName('head')[0];\r\n var style = document.createElement('style');\r\n style.type = 'text/css';\r\n\r\n if (insertAt === 'top') {\r\n if (head.firstChild) {\r\n head.insertBefore(style, head.firstChild);\r\n } else {\r\n head.appendChild(style);\r\n }\r\n } else {\r\n head.appendChild(style);\r\n }\r\n\r\n if (style.styleSheet) {\r\n style.styleSheet.cssText = css;\r\n } else {\r\n style.appendChild(document.createTextNode(css));\r\n }\r\n}\r\n\r\nexport default styleInject;\r\n"],"names":[],"mappings":";;;;AAAA,SAAS,WAAW,CAAC,GAAG,EAAE,GAAG,EAAE;AAC/B,EAAE,KAAK,GAAG,KAAK,KAAK,CAAC,GAAG,GAAG,GAAG,EAAE,CAAC;AACjC,EAAE,IAAI,QAAQ,GAAG,GAAG,CAAC,QAAQ,CAAC;AAC9B;AACA,EAAE,IAAI,CAAC,GAAG,IAAI,OAAO,QAAQ,KAAK,WAAW,EAAE,EAAE,OAAO,EAAE;AAC1D;AACA,EAAE,IAAI,IAAI,GAAG,QAAQ,CAAC,IAAI,IAAI,QAAQ,CAAC,oBAAoB,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;AACvE,EAAE,IAAI,KAAK,GAAG,QAAQ,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;AAC9C,EAAE,KAAK,CAAC,IAAI,GAAG,UAAU,CAAC;AAC1B;AACA,EAAE,IAAI,QAAQ,KAAK,KAAK,EAAE;AAC1B,IAAI,IAAI,IAAI,CAAC,UAAU,EAAE;AACzB,MAAM,IAAI,CAAC,YAAY,CAAC,KAAK,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;AAChD,KAAK,MAAM;AACX,MAAM,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AAC9B,KAAK;AACL,GAAG,MAAM;AACT,IAAI,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AAC5B,GAAG;AACH;AACA,EAAE,IAAI,KAAK,CAAC,UAAU,EAAE;AACxB,IAAI,KAAK,CAAC,UAAU,CAAC,OAAO,GAAG,GAAG,CAAC;AACnC,GAAG,MAAM;AACT,IAAI,KAAK,CAAC,WAAW,CAAC,QAAQ,CAAC,cAAc,CAAC,GAAG,CAAC,CAAC,CAAC;AACpD,GAAG;AACH
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../node_modules/style-inject/dist/style-inject.es.js"],"sourcesContent":["function styleInject(css, ref) {\r\n if ( ref === void 0 ) ref = {};\r\n var insertAt = ref.insertAt;\r\n\r\n if (!css || typeof document === 'undefined') { return; }\r\n\r\n var head = document.head || document.getElementsByTagName('head')[0];\r\n var style = document.createElement('style');\r\n style.type = 'text/css';\r\n\r\n if (insertAt === 'top') {\r\n if (head.firstChild) {\r\n head.insertBefore(style, head.firstChild);\r\n } else {\r\n head.appendChild(style);\r\n }\r\n } else {\r\n head.appendChild(style);\r\n }\r\n\r\n if (style.styleSheet) {\r\n style.styleSheet.cssText = css;\r\n } else {\r\n style.appendChild(document.createTextNode(css));\r\n }\r\n}\r\n\r\nexport default styleInject;\r\n"],"names":[],"mappings":";;;;AAAA,SAAS,WAAW,CAAC,GAAG,EAAE,GAAG,EAAE;AAC/B,EAAE,KAAK,GAAG,KAAK,KAAK,CAAC,GAAG,GAAG,GAAG,EAAE,CAAC;AACjC,EAAE,IAAI,QAAQ,GAAG,GAAG,CAAC,QAAQ,CAAC;AAC9B;AACA,EAAE,IAAI,CAAC,GAAG,IAAI,OAAO,QAAQ,KAAK,WAAW,EAAE,EAAE,OAAO,EAAE;AAC1D;AACA,EAAE,IAAI,IAAI,GAAG,QAAQ,CAAC,IAAI,IAAI,QAAQ,CAAC,oBAAoB,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;AACvE,EAAE,IAAI,KAAK,GAAG,QAAQ,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;AAC9C,EAAE,KAAK,CAAC,IAAI,GAAG,UAAU,CAAC;AAC1B;AACA,EAAE,IAAI,QAAQ,KAAK,KAAK,EAAE;AAC1B,IAAI,IAAI,IAAI,CAAC,UAAU,EAAE;AACzB,MAAM,IAAI,CAAC,YAAY,CAAC,KAAK,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;AAChD,KAAK,MAAM;AACX,MAAM,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AAC9B,KAAK;AACL,GAAG,MAAM;AACT,IAAI,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AAC5B,GAAG;AACH;AACA,EAAE,IAAI,KAAK,CAAC,UAAU,EAAE;AACxB,IAAI,KAAK,CAAC,UAAU,CAAC,OAAO,GAAG,GAAG,CAAC;AACnC,GAAG,MAAM;AACT,IAAI,KAAK,CAAC,WAAW,CAAC,QAAQ,CAAC,cAAc,CAAC,GAAG,CAAC,CAAC,CAAC;AACpD,GAAG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[0]}
|
package/dist/esm/index.js
CHANGED
|
@@ -77,12 +77,17 @@ var styles$5 = {"botaoCert":"cardImage-module_botaoCert__Rs0fg","iconeOna":"card
|
|
|
77
77
|
styleInject(css_248z$5);
|
|
78
78
|
|
|
79
79
|
var CardImage = function (_a) {
|
|
80
|
-
var img = _a.img, href = _a.href, texto = _a.texto, empresa = _a.empresa, largura = _a.largura, altura = _a.altura, externo = _a.externo;
|
|
80
|
+
var img = _a.img, href = _a.href, texto = _a.texto, empresa = _a.empresa, largura = _a.largura, altura = _a.altura, externo = _a.externo, funcao = _a.funcao, parametro = _a.parametro;
|
|
81
81
|
var empresaClass = styles$5["empresa".concat(empresa)];
|
|
82
|
+
var handleActionClick = function () {
|
|
83
|
+
if (funcao && parametro) {
|
|
84
|
+
funcao(parametro);
|
|
85
|
+
}
|
|
86
|
+
};
|
|
82
87
|
var content = (React.createElement(React.Fragment, null,
|
|
83
88
|
React.createElement("img", { src: img, alt: img, className: styles$5.iconeOna }),
|
|
84
89
|
texto && (React.createElement("span", { className: styles$5.cardText, dangerouslySetInnerHTML: { __html: texto } }))));
|
|
85
|
-
return (React.createElement("div", { className: "".concat(empresaClass) }, href ? (React.createElement("a", { href: href, target: externo ? "_blank" : "_self", rel: externo ? "noopener noreferrer" : undefined, className: "".concat(styles$5.botaoCert, " empresa").concat(empresa), title: href, style: { width: largura ? "".concat(largura) : '', height: altura ? "".concat(altura) : '' } }, content)) : (React.createElement("div", { className: "".concat(styles$5.botaoCert, " empresa").concat(empresa), style: { width: largura ? "".concat(largura) : '', height: altura ? "".concat(altura) : '' } }, content))));
|
|
90
|
+
return (React.createElement("div", { className: "".concat(empresaClass) }, href ? (React.createElement("a", { href: href, target: externo ? "_blank" : "_self", rel: externo ? "noopener noreferrer" : undefined, className: "".concat(styles$5.botaoCert, " empresa").concat(empresa), title: href, style: { width: largura ? "".concat(largura) : '', height: altura ? "".concat(altura) : '' } }, content)) : (React.createElement("div", { className: "".concat(styles$5.botaoCert, " empresa").concat(empresa), onClick: handleActionClick, style: { width: largura ? "".concat(largura) : '', height: altura ? "".concat(altura) : '' } }, content))));
|
|
86
91
|
};
|
|
87
92
|
|
|
88
93
|
var css_248z$4 = ".input-module_inputSubmit__21-Pj{align-self:center;border:none;border-radius:20px;color:#fff;cursor:pointer;font-size:15px;padding:10px;width:10rem}.input-module_inputPadrao__jypjY{border:1px solid #ccc;border-radius:.5rem;font-style:italic;padding:.8rem 0 .8rem 1rem;width:100%}.input-module_inputPadrao__jypjY:focus{outline:none}.input-module_empresa1__bxBov .input-module_inputSubmit__21-Pj{background-color:var(--blue)}.input-module_empresa1__bxBov .input-module_inputSubmit__21-Pj:hover{background-color:var(--red)}.input-module_empresa3__RU89A .input-module_inputSubmit__21-Pj{background-color:var(--green)}.input-module_empresa3__RU89A .input-module_inputSubmit__21-Pj:hover{background-color:var(--lightblue)}.input-module_empresa4__rWmWH .input-module_inputSubmit__21-Pj{background-color:var(--red)}.input-module_empresa4__rWmWH .input-module_inputSubmit__21-Pj:hover{background-color:var(--blue)}";
|
|
@@ -96,10 +101,10 @@ var Button = function (_a) {
|
|
|
96
101
|
};
|
|
97
102
|
|
|
98
103
|
var InputField = function (_a) {
|
|
99
|
-
var type = _a.type, id = _a.id, placeholder = _a.placeholder, onChange = _a.onChange, value = _a.value, label = _a.label, largura = _a.largura;
|
|
104
|
+
var type = _a.type, id = _a.id, placeholder = _a.placeholder, onChange = _a.onChange, value = _a.value, label = _a.label, largura = _a.largura, readonly = _a.readonly, disabled = _a.disabled;
|
|
100
105
|
return (React.createElement(React.Fragment, null,
|
|
101
106
|
label && React.createElement("label", { htmlFor: id }, label),
|
|
102
|
-
React.createElement("input", { type: type, id: id, name: id, value: value, placeholder: placeholder, onChange: onChange, className: styles$4.inputPadrao, style: { width: largura ? "".concat(largura) : '' } })));
|
|
107
|
+
React.createElement("input", { type: type, id: id, name: id, value: value, placeholder: placeholder, onChange: onChange, className: styles$4.inputPadrao, style: { width: largura ? "".concat(largura) : '' }, readOnly: readonly, disabled: disabled })));
|
|
103
108
|
};
|
|
104
109
|
|
|
105
110
|
var css_248z$3 = ".textPage-module_container__GBEF6{align-items:center;display:flex;flex-direction:column;justify-content:center;padding:20px}.textPage-module_content__CpD68{display:flex;text-align:justify}.textPage-module_imageCabecalho__J6YFH{border-radius:8px}.textPage-module_imageCabecalho__J6YFH img{border-radius:8px;height:100%;object-fit:cover;width:100%}.textPage-module_contentWithLateralImage__-f5pQ{flex-direction:row}.textPage-module_imageLateral__Dy9Kx{align-self:flex-start;height:230px;margin-right:20px;margin-top:15px;width:300px}.textPage-module_imageLateral__Dy9Kx img{border-radius:8px;height:100%;object-fit:cover;width:100%}.textPage-module_text__3pwuU{color:#5d5d5d;flex:2;line-height:1.8;text-align:justify}.textPage-module_text__3pwuU p{line-height:1.6;margin:10px 0}.textPage-module_text__3pwuU .textPage-module_coordenacao__UypV-,.textPage-module_text__3pwuU .textPage-module_direcao__x5psb{font-weight:700;margin-top:20px}";
|
package/dist/esm/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../node_modules/style-inject/dist/style-inject.es.js"],"sourcesContent":["function styleInject(css, ref) {\r\n if ( ref === void 0 ) ref = {};\r\n var insertAt = ref.insertAt;\r\n\r\n if (!css || typeof document === 'undefined') { return; }\r\n\r\n var head = document.head || document.getElementsByTagName('head')[0];\r\n var style = document.createElement('style');\r\n style.type = 'text/css';\r\n\r\n if (insertAt === 'top') {\r\n if (head.firstChild) {\r\n head.insertBefore(style, head.firstChild);\r\n } else {\r\n head.appendChild(style);\r\n }\r\n } else {\r\n head.appendChild(style);\r\n }\r\n\r\n if (style.styleSheet) {\r\n style.styleSheet.cssText = css;\r\n } else {\r\n style.appendChild(document.createTextNode(css));\r\n }\r\n}\r\n\r\nexport default styleInject;\r\n"],"names":[],"mappings":";;AAAA,SAAS,WAAW,CAAC,GAAG,EAAE,GAAG,EAAE;AAC/B,EAAE,KAAK,GAAG,KAAK,KAAK,CAAC,GAAG,GAAG,GAAG,EAAE,CAAC;AACjC,EAAE,IAAI,QAAQ,GAAG,GAAG,CAAC,QAAQ,CAAC;AAC9B;AACA,EAAE,IAAI,CAAC,GAAG,IAAI,OAAO,QAAQ,KAAK,WAAW,EAAE,EAAE,OAAO,EAAE;AAC1D;AACA,EAAE,IAAI,IAAI,GAAG,QAAQ,CAAC,IAAI,IAAI,QAAQ,CAAC,oBAAoB,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;AACvE,EAAE,IAAI,KAAK,GAAG,QAAQ,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;AAC9C,EAAE,KAAK,CAAC,IAAI,GAAG,UAAU,CAAC;AAC1B;AACA,EAAE,IAAI,QAAQ,KAAK,KAAK,EAAE;AAC1B,IAAI,IAAI,IAAI,CAAC,UAAU,EAAE;AACzB,MAAM,IAAI,CAAC,YAAY,CAAC,KAAK,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;AAChD,KAAK,MAAM;AACX,MAAM,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AAC9B,KAAK;AACL,GAAG,MAAM;AACT,IAAI,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AAC5B,GAAG;AACH;AACA,EAAE,IAAI,KAAK,CAAC,UAAU,EAAE;AACxB,IAAI,KAAK,CAAC,UAAU,CAAC,OAAO,GAAG,GAAG,CAAC;AACnC,GAAG,MAAM;AACT,IAAI,KAAK,CAAC,WAAW,CAAC,QAAQ,CAAC,cAAc,CAAC,GAAG,CAAC,CAAC,CAAC;AACpD,GAAG;AACH
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../node_modules/style-inject/dist/style-inject.es.js"],"sourcesContent":["function styleInject(css, ref) {\r\n if ( ref === void 0 ) ref = {};\r\n var insertAt = ref.insertAt;\r\n\r\n if (!css || typeof document === 'undefined') { return; }\r\n\r\n var head = document.head || document.getElementsByTagName('head')[0];\r\n var style = document.createElement('style');\r\n style.type = 'text/css';\r\n\r\n if (insertAt === 'top') {\r\n if (head.firstChild) {\r\n head.insertBefore(style, head.firstChild);\r\n } else {\r\n head.appendChild(style);\r\n }\r\n } else {\r\n head.appendChild(style);\r\n }\r\n\r\n if (style.styleSheet) {\r\n style.styleSheet.cssText = css;\r\n } else {\r\n style.appendChild(document.createTextNode(css));\r\n }\r\n}\r\n\r\nexport default styleInject;\r\n"],"names":[],"mappings":";;AAAA,SAAS,WAAW,CAAC,GAAG,EAAE,GAAG,EAAE;AAC/B,EAAE,KAAK,GAAG,KAAK,KAAK,CAAC,GAAG,GAAG,GAAG,EAAE,CAAC;AACjC,EAAE,IAAI,QAAQ,GAAG,GAAG,CAAC,QAAQ,CAAC;AAC9B;AACA,EAAE,IAAI,CAAC,GAAG,IAAI,OAAO,QAAQ,KAAK,WAAW,EAAE,EAAE,OAAO,EAAE;AAC1D;AACA,EAAE,IAAI,IAAI,GAAG,QAAQ,CAAC,IAAI,IAAI,QAAQ,CAAC,oBAAoB,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC;AACvE,EAAE,IAAI,KAAK,GAAG,QAAQ,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;AAC9C,EAAE,KAAK,CAAC,IAAI,GAAG,UAAU,CAAC;AAC1B;AACA,EAAE,IAAI,QAAQ,KAAK,KAAK,EAAE;AAC1B,IAAI,IAAI,IAAI,CAAC,UAAU,EAAE;AACzB,MAAM,IAAI,CAAC,YAAY,CAAC,KAAK,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;AAChD,KAAK,MAAM;AACX,MAAM,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AAC9B,KAAK;AACL,GAAG,MAAM;AACT,IAAI,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;AAC5B,GAAG;AACH;AACA,EAAE,IAAI,KAAK,CAAC,UAAU,EAAE;AACxB,IAAI,KAAK,CAAC,UAAU,CAAC,OAAO,GAAG,GAAG,CAAC;AACnC,GAAG,MAAM;AACT,IAAI,KAAK,CAAC,WAAW,CAAC,QAAQ,CAAC,cAAc,CAAC,GAAG,CAAC,CAAC,CAAC;AACpD,GAAG;AACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[0]}
|
package/package.json
CHANGED
|
@@ -9,11 +9,19 @@ interface CardImageProps {
|
|
|
9
9
|
largura?: string;
|
|
10
10
|
altura?: string;
|
|
11
11
|
externo?: boolean;
|
|
12
|
+
funcao?: (parametro: string) => void;
|
|
13
|
+
parametro?: string;
|
|
12
14
|
}
|
|
13
15
|
|
|
14
|
-
const CardImage: React.FC<CardImageProps> = ({ img, href, texto, empresa, largura, altura, externo }) => {
|
|
16
|
+
const CardImage: React.FC<CardImageProps> = ({ img, href, texto, empresa, largura, altura, externo, funcao, parametro }) => {
|
|
15
17
|
const empresaClass = styles[`empresa${empresa}`];
|
|
16
18
|
|
|
19
|
+
const handleActionClick = () => {
|
|
20
|
+
if (funcao && parametro) {
|
|
21
|
+
funcao(parametro);
|
|
22
|
+
}
|
|
23
|
+
};
|
|
24
|
+
|
|
17
25
|
const content = (
|
|
18
26
|
<>
|
|
19
27
|
<img src={img} alt={img} className={styles.iconeOna} />
|
|
@@ -32,14 +40,15 @@ const CardImage: React.FC<CardImageProps> = ({ img, href, texto, empresa, largur
|
|
|
32
40
|
rel={externo ? "noopener noreferrer" : undefined}
|
|
33
41
|
className={`${styles.botaoCert} empresa${empresa}`}
|
|
34
42
|
title={href}
|
|
35
|
-
style={{ width: largura ? `${largura}` : '', height: altura ? `${altura}` : '' }}
|
|
43
|
+
style={{ width: largura ? `${largura}` : '', height: altura ? `${altura}` : '' }}
|
|
36
44
|
>
|
|
37
45
|
{content}
|
|
38
46
|
</a>
|
|
39
47
|
) : (
|
|
40
48
|
<div
|
|
41
49
|
className={`${styles.botaoCert} empresa${empresa}`}
|
|
42
|
-
|
|
50
|
+
onClick={handleActionClick}
|
|
51
|
+
style={{ width: largura ? `${largura}` : '', height: altura ? `${altura}` : '' }}
|
|
43
52
|
>
|
|
44
53
|
{content}
|
|
45
54
|
</div>
|
|
@@ -9,22 +9,26 @@ interface InputFieldProps {
|
|
|
9
9
|
value: string;
|
|
10
10
|
onChange: (e: ChangeEvent<HTMLInputElement>) => void;
|
|
11
11
|
largura?: string;
|
|
12
|
+
readonly?: boolean;
|
|
13
|
+
disabled?: boolean;
|
|
12
14
|
}
|
|
13
15
|
|
|
14
|
-
const InputField: React.FC<InputFieldProps> = ({ type, id, placeholder, onChange, value, label, largura }) => {
|
|
16
|
+
const InputField: React.FC<InputFieldProps> = ({ type, id, placeholder, onChange, value, label, largura, readonly, disabled }) => {
|
|
15
17
|
return (
|
|
16
18
|
<>
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
19
|
+
{label && <label htmlFor={id}>{label}</label>}
|
|
20
|
+
<input
|
|
21
|
+
type={type}
|
|
22
|
+
id={id}
|
|
23
|
+
name={id}
|
|
24
|
+
value={value}
|
|
25
|
+
placeholder={placeholder}
|
|
26
|
+
onChange={onChange}
|
|
27
|
+
className={styles.inputPadrao}
|
|
28
|
+
style={{ width: largura ? `${largura}` : '' }}
|
|
29
|
+
readOnly={readonly}
|
|
30
|
+
disabled={disabled}
|
|
31
|
+
/>
|
|
28
32
|
</>
|
|
29
33
|
);
|
|
30
34
|
};
|