@activecollab/components 1.0.64 → 1.0.65
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/components/Button/Button.js +2 -1
- package/dist/cjs/components/Button/Button.js.map +1 -1
- package/dist/cjs/components/Input/Input.js +5 -2
- package/dist/cjs/components/Input/Input.js.map +1 -1
- package/dist/cjs/components/Input/Styles.js +5 -1
- package/dist/cjs/components/Input/Styles.js.map +1 -1
- package/dist/esm/components/Button/Button.d.ts +1 -1
- package/dist/esm/components/Button/Button.d.ts.map +1 -1
- package/dist/esm/components/Button/Button.js +2 -1
- package/dist/esm/components/Button/Button.js.map +1 -1
- package/dist/esm/components/ComboBox/Styles.d.ts +1 -1
- package/dist/esm/components/ComboBox/Styles.d.ts.map +1 -1
- package/dist/esm/components/Input/Input.d.ts +5 -1
- package/dist/esm/components/Input/Input.d.ts.map +1 -1
- package/dist/esm/components/Input/Input.js +5 -2
- package/dist/esm/components/Input/Input.js.map +1 -1
- package/dist/esm/components/Input/Styles.d.ts +4 -1
- package/dist/esm/components/Input/Styles.d.ts.map +1 -1
- package/dist/esm/components/Input/Styles.js +5 -1
- package/dist/esm/components/Input/Styles.js.map +1 -1
- package/dist/esm/components/Select/Styles.d.ts +1 -1
- package/dist/esm/components/Select/Styles.d.ts.map +1 -1
- package/dist/index.js +12 -4
- package/dist/index.js.map +1 -1
- package/dist/index.min.js +1 -1
- package/dist/index.min.js.map +1 -1
- package/package.json +1 -1
|
@@ -34,7 +34,8 @@ var Button = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
|
|
|
34
34
|
var children = _ref.children,
|
|
35
35
|
_ref$variant = _ref.variant,
|
|
36
36
|
variant = _ref$variant === void 0 ? "contained" : _ref$variant,
|
|
37
|
-
size = _ref.size,
|
|
37
|
+
_ref$size = _ref.size,
|
|
38
|
+
size = _ref$size === void 0 ? "medium" : _ref$size,
|
|
38
39
|
_ref$disabled = _ref.disabled,
|
|
39
40
|
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
40
41
|
className = _ref.className,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../src/components/Button/Button.tsx"],"names":["Button","ref","children","variant","size","disabled","className","args","Object","Array","map","value","index","displayName"],"mappings":";;;;;;;;;AAAA;;AACA;;AAKA;;;;;;;;;;;;;;;;AAyBA;AACA;AACA;AACO,IAAMA,MAAM,gBAAG,uBACpB,gBASEC,GATF,EAUK;AAAA,MARDC,QAQC,QARDA,QAQC;AAAA,0BAPDC,OAOC;AAAA,MAPDA,OAOC,6BAPS,WAOT;AAAA,
|
|
1
|
+
{"version":3,"sources":["../../../../src/components/Button/Button.tsx"],"names":["Button","ref","children","variant","size","disabled","className","args","Object","Array","map","value","index","displayName"],"mappings":";;;;;;;;;AAAA;;AACA;;AAKA;;;;;;;;;;;;;;;;AAyBA;AACA;AACA;AACO,IAAMA,MAAM,gBAAG,uBACpB,gBASEC,GATF,EAUK;AAAA,MARDC,QAQC,QARDA,QAQC;AAAA,0BAPDC,OAOC;AAAA,MAPDA,OAOC,6BAPS,WAOT;AAAA,uBANDC,IAMC;AAAA,MANDA,IAMC,0BANM,QAMN;AAAA,2BALDC,QAKC;AAAA,MALDA,QAKC,8BALU,KAKV;AAAA,MAJDC,SAIC,QAJDA,SAIC;AAAA,MAHEC,IAGF;;AACH,sBACE,6BAAC,oBAAD;AACE,IAAA,QAAQ,EAAEF,QADZ;AAEE,IAAA,SAAS,EAAE,yBAAW,OAAX,EAAoBC,SAApB,EAA+B;AACxC,0BAAoBH,OAAO,KAAK,SAAZ,IAAyBA,OAAO,KAAK,WADjB;AAExC,yBAAmBA,OAAO,KAAK,WAAZ,IAA2BA,OAAO,KAAK,UAFlB;AAGxC,6BACEA,OAAO,KAAK,UAAZ,IAA0BA,OAAO,KAAK,cAJA;AAKxC,0BAAoBA,OAAO,KAAK,QAAZ,IAAwBA,OAAO,KAAK,WALhB;AAMxC,iCAA2BA,OAAO,KAAK,kBANC;AAOxC,8BAAwBA,OAAO,KAAK,eAPI;AAQxC,oBAAcC,IAAI,KAAK,KARiB;AASxC,sBAAgBA,IAAI,KAAK,OATe;AAUxC,0BACEF,QAAQ,YAAYM,MAApB,IAA8B,EAAEN,QAAQ,YAAYO,KAAtB;AAXQ,KAA/B,CAFb;AAeE,IAAA,QAAQ,EAAEP,QAAQ,YAAYM,MAApB,IAA8B,EAAEN,QAAQ,YAAYO,KAAtB,CAf1C;AAgBE,IAAA,OAAO,EAAEN,OAhBX;AAiBE,IAAA,IAAI,EAAEC;AAjBR,KAkBMG,IAlBN;AAmBE,IAAA,GAAG,EAAEN;AAnBP,MAqBGC,QAAQ,YAAYO,KAApB,gBACC,6BAAC,4BAAD;AAAsB,IAAA,SAAS,EAAC;AAAhC,KACGP,QAAQ,CAACQ,GAAT,CAAa,UAACC,KAAD,EAAQC,KAAR;AAAA,WACZD,KAAK,gBACH,6BAAC,2BAAD;AACE,MAAA,SAAS,EAAC,0BADZ;AAEE,MAAA,GAAG,EAAEC;AAFP,OAIGD,KAJH,CADG,GAOD,IARQ;AAAA,GAAb,CADH,CADD,GAcCT,QAnCJ,CADF;AAwCD,CApDmB,CAAf;;AAuDPF,MAAM,CAACa,WAAP,GAAqB,QAArB","sourcesContent":["import React, { ReactNode, forwardRef } from \"react\";\nimport {\n StyledButton,\n StyledButtonElement,\n StyledButtonElements,\n} from \"./Styles\";\nimport classnames from \"classnames\";\n\nexport interface IButtonProps extends React.ComponentPropsWithoutRef<\"button\"> {\n /** Children type of node or string */\n children: ReactNode;\n /** Variant Buttons */\n variant?:\n | \"primary\"\n | \"secondary\"\n | \"tertiary\"\n | \"option\"\n | \"contained\"\n | \"outlined\"\n | \"text colored\"\n | \"text gray\"\n | \"dark transparent\"\n | \"circle raised\";\n /** Button size can be big, medium or small */\n size?: \"big\" | \"small\" | \"medium\";\n /** Disabled prop */\n disabled?: boolean;\n /** CSS classes */\n className?: string;\n}\n\n/**\n * Button component\n */\nexport const Button = forwardRef<HTMLButtonElement, IButtonProps>(\n (\n {\n children,\n variant = \"contained\",\n size = \"medium\",\n disabled = false,\n className,\n ...args\n },\n ref\n ) => {\n return (\n <StyledButton\n disabled={disabled}\n className={classnames(\"c-btn\", className, {\n \"c-btn--contained\": variant === \"primary\" || variant === \"contained\",\n \"c-btn--outlined\": variant === \"secondary\" || variant === \"outlined\",\n \"c-btn--text_colored\":\n variant === \"tertiary\" || variant === \"text colored\",\n \"c-btn--text_gray\": variant === \"option\" || variant === \"text gray\",\n \"c-btn--dark_transparent\": variant === \"dark transparent\",\n \"c-btn--circle-raised\": variant === \"circle raised\",\n \"c-btn--big\": size === \"big\",\n \"c-btn--small\": size === \"small\",\n \"c-btn--icon-only\":\n children instanceof Object && !(children instanceof Array),\n })}\n iconOnly={children instanceof Object && !(children instanceof Array)}\n variant={variant}\n size={size}\n {...args}\n ref={ref}\n >\n {children instanceof Array ? (\n <StyledButtonElements className=\"c-btn__elements\">\n {children.map((value, index) =>\n value ? (\n <StyledButtonElement\n className=\"c-btn__elements__element\"\n key={index}\n >\n {value}\n </StyledButtonElement>\n ) : null\n )}\n </StyledButtonElements>\n ) : (\n children\n )}\n </StyledButton>\n );\n }\n);\n\nButton.displayName = \"Button\";\n"],"file":"Button.js"}
|
|
@@ -13,7 +13,7 @@ var _classnames = _interopRequireDefault(require("classnames"));
|
|
|
13
13
|
|
|
14
14
|
var _Styles = require("./Styles");
|
|
15
15
|
|
|
16
|
-
var _excluded = ["className", "type", "disabled"];
|
|
16
|
+
var _excluded = ["className", "type", "disabled", "size"];
|
|
17
17
|
|
|
18
18
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
19
19
|
|
|
@@ -34,13 +34,16 @@ var Input = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
|
|
|
34
34
|
type = _ref$type === void 0 ? "text" : _ref$type,
|
|
35
35
|
_ref$disabled = _ref.disabled,
|
|
36
36
|
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
37
|
+
_ref$size = _ref.size,
|
|
38
|
+
size = _ref$size === void 0 ? "regular" : _ref$size,
|
|
37
39
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
38
40
|
|
|
39
41
|
return /*#__PURE__*/_react.default.createElement(_Styles.StyledInput, _extends({
|
|
40
42
|
ref: ref,
|
|
41
43
|
type: type,
|
|
42
44
|
disabled: disabled,
|
|
43
|
-
className: (0, _classnames.default)("c-input", className)
|
|
45
|
+
className: (0, _classnames.default)("c-input", className),
|
|
46
|
+
$size: size
|
|
44
47
|
}, rest));
|
|
45
48
|
});
|
|
46
49
|
exports.Input = Input;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../src/components/Input/Input.tsx"],"names":["Input","ref","className","type","disabled","rest","displayName"],"mappings":";;;;;;;;;AAAA;;AACA;;AACA;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"sources":["../../../../src/components/Input/Input.tsx"],"names":["Input","ref","className","type","disabled","size","rest","displayName"],"mappings":";;;;;;;;;AAAA;;AACA;;AACA;;;;;;;;;;;;;;;;AAQO,IAAMA,KAAK,gBAAG,uBAInB,gBAQEC,GARF,EASK;AAAA,4BAPDC,SAOC;AAAA,MAPDA,SAOC,+BAPW,EAOX;AAAA,uBANDC,IAMC;AAAA,MANDA,IAMC,0BANM,MAMN;AAAA,2BALDC,QAKC;AAAA,MALDA,QAKC,8BALU,KAKV;AAAA,uBAJDC,IAIC;AAAA,MAJDA,IAIC,0BAJM,SAIN;AAAA,MAHEC,IAGF;;AACH,sBACE,6BAAC,mBAAD;AACE,IAAA,GAAG,EAAEL,GADP;AAEE,IAAA,IAAI,EAAEE,IAFR;AAGE,IAAA,QAAQ,EAAEC,QAHZ;AAIE,IAAA,SAAS,EAAE,yBAAW,SAAX,EAAsBF,SAAtB,CAJb;AAKE,IAAA,KAAK,EAAEG;AALT,KAMMC,IANN,EADF;AAUD,CAxBkB,CAAd;;AA2BPN,KAAK,CAACO,WAAN,GAAoB,OAApB","sourcesContent":["import React, { forwardRef } from \"react\";\nimport classnames from \"classnames\";\nimport { StyledInput } from \"./Styles\";\n\nexport type InputSize = \"small\" | \"regular\" | \"big\";\nexport interface InputProps {\n /** Velicina inputa koja definse font-size i border radius */\n size?: InputSize;\n}\n\nexport const Input = forwardRef<\n HTMLInputElement,\n InputProps & Omit<React.ComponentPropsWithoutRef<\"input\">, keyof InputProps>\n>(\n (\n {\n className = \"\",\n type = \"text\",\n disabled = false,\n size = \"regular\",\n ...rest\n },\n ref\n ) => {\n return (\n <StyledInput\n ref={ref}\n type={type}\n disabled={disabled}\n className={classnames(\"c-input\", className)}\n $size={size}\n {...rest}\n />\n );\n }\n);\n\nInput.displayName = \"Input\";\n"],"file":"Input.js"}
|
|
@@ -20,7 +20,11 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
|
|
|
20
20
|
var StyledInput = _styledComponents.default.input.withConfig({
|
|
21
21
|
displayName: "Styles__StyledInput",
|
|
22
22
|
componentId: "sc-ce8kcp-0"
|
|
23
|
-
})(["border:1px solid var(--border-primary);border-radius:10px;color:var(--color-theme-900);font-size:14px;padding:4px 10px 6px 8px;height:32px;background-color:var(--input-background-color);transition:all 0.3s ease;width:360px;outline:none;", " ", " ", " &::placeholder{color:var(--color-theme-600);}"], _FontStyle.FontStyle, _BoxSizingStyle.BoxSizingStyle, function (props) {
|
|
23
|
+
})(["border:1px solid var(--border-primary);border-radius:10px;color:var(--color-theme-900);font-size:14px;padding:4px 10px 6px 8px;height:32px;background-color:var(--input-background-color);transition:all 0.3s ease;width:360px;outline:none;", " ", " ", " ", " ", " &::placeholder{color:var(--color-theme-600);}"], _FontStyle.FontStyle, _BoxSizingStyle.BoxSizingStyle, function (props) {
|
|
24
|
+
return props.$size === "small" && (0, _styledComponents.css)(["border-radius:6px;height:24px;"]);
|
|
25
|
+
}, function (props) {
|
|
26
|
+
return props.$size === "big" && (0, _styledComponents.css)(["height:40px;font-size:16px;"]);
|
|
27
|
+
}, function (props) {
|
|
24
28
|
return props.disabled ? (0, _styledComponents.css)(["", ""], {
|
|
25
29
|
"cursor": "not-allowed",
|
|
26
30
|
"opacity": "0.5",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../src/components/Input/Styles.ts"],"names":["StyledInput","styled","input","FontStyle","BoxSizingStyle","props","
|
|
1
|
+
{"version":3,"sources":["../../../../src/components/Input/Styles.ts"],"names":["StyledInput","styled","input","FontStyle","BoxSizingStyle","props","$size","css","disabled","displayName"],"mappings":";;;;;;;;;AAAA;;AAGA;;AACA;;;;;;AAEO,IAAMA,WAAW,GAAGC,0BAAOC,KAAV;AAAA;AAAA;AAAA,2TAcpBC,oBAdoB,EAepBC,8BAfoB,EAiBpB,UAACC,KAAD;AAAA,SACAA,KAAK,CAACC,KAAN,KAAgB,OAAhB,QACAC,qBADA,qCADA;AAAA,CAjBoB,EAwBpB,UAACF,KAAD;AAAA,SACAA,KAAK,CAACC,KAAN,KAAgB,KAAhB,QACAC,qBADA,kCADA;AAAA,CAxBoB,EA+BpB,UAACF,KAAD;AAAA,SACAA,KAAK,CAACG,QAAN,OACID,qBADJ,YAEU;AAAA;AAAA;AAAA;AAAA,GAFV,QAIIA,qBAJJ,gDAMY;AAAA;AAAA,GANZ,EAUY;AAAA;AAAA,GAVZ,EAcY;AAAA;AAAA,GAdZ,CADA;AAAA,CA/BoB,CAAjB;;;AAuDPP,WAAW,CAACS,WAAZ,GAA0B,aAA1B","sourcesContent":["import styled, { css } from \"styled-components\";\nimport tw from \"twin.macro\";\nimport { InputSize } from \"./Input\";\nimport { BoxSizingStyle } from \"../BoxSizingStyle\";\nimport { FontStyle } from \"../FontStyle\";\n\nexport const StyledInput = styled.input<{\n $size?: InputSize;\n}>`\n border: 1px solid var(--border-primary);\n border-radius: 10px;\n color: var(--color-theme-900);\n font-size: 14px;\n padding: 4px 10px 6px 8px;\n height: 32px;\n background-color: var(--input-background-color);\n transition: all 0.3s ease;\n width: 360px;\n outline: none;\n\n ${FontStyle}\n ${BoxSizingStyle}\n\n ${(props) =>\n props.$size === \"small\" &&\n css`\n border-radius: 6px;\n height: 24px;\n `}\n\n ${(props) =>\n props.$size === \"big\" &&\n css`\n height: 40px;\n font-size: 16px;\n `}\n\n ${(props) =>\n props.disabled\n ? css`\n ${tw`tw-cursor-not-allowed tw-opacity-50 tw-border-theme-400`}\n `\n : css`\n &:hover {\n ${tw`tw-border-primary`}\n }\n\n &:active {\n ${tw`tw-border-primary`}\n }\n\n &:focus {\n ${tw`tw-border-primary`}\n }\n `}\n\n &::placeholder {\n color: var(--color-theme-600);\n }\n`;\n\nStyledInput.displayName = \"StyledInput\";\n"],"file":"Styles.js"}
|
|
@@ -2,7 +2,7 @@ import React, { ReactNode } from "react";
|
|
|
2
2
|
export interface IButtonProps extends React.ComponentPropsWithoutRef<"button"> {
|
|
3
3
|
children: ReactNode;
|
|
4
4
|
variant?: "primary" | "secondary" | "tertiary" | "option" | "contained" | "outlined" | "text colored" | "text gray" | "dark transparent" | "circle raised";
|
|
5
|
-
size?: "big" | "small";
|
|
5
|
+
size?: "big" | "small" | "medium";
|
|
6
6
|
disabled?: boolean;
|
|
7
7
|
className?: string;
|
|
8
8
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Button.d.ts","sourceRoot":"","sources":["../../../../src/components/Button/Button.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAc,MAAM,OAAO,CAAC;AAQrD,MAAM,WAAW,YAAa,SAAQ,KAAK,CAAC,wBAAwB,CAAC,QAAQ,CAAC;IAE5E,QAAQ,EAAE,SAAS,CAAC;IAEpB,OAAO,CAAC,EACJ,SAAS,GACT,WAAW,GACX,UAAU,GACV,QAAQ,GACR,WAAW,GACX,UAAU,GACV,cAAc,GACd,WAAW,GACX,kBAAkB,GAClB,eAAe,CAAC;IAEpB,IAAI,CAAC,EAAE,KAAK,GAAG,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"Button.d.ts","sourceRoot":"","sources":["../../../../src/components/Button/Button.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAc,MAAM,OAAO,CAAC;AAQrD,MAAM,WAAW,YAAa,SAAQ,KAAK,CAAC,wBAAwB,CAAC,QAAQ,CAAC;IAE5E,QAAQ,EAAE,SAAS,CAAC;IAEpB,OAAO,CAAC,EACJ,SAAS,GACT,WAAW,GACX,UAAU,GACV,QAAQ,GACR,WAAW,GACX,UAAU,GACV,cAAc,GACd,WAAW,GACX,kBAAkB,GAClB,eAAe,CAAC;IAEpB,IAAI,CAAC,EAAE,KAAK,GAAG,OAAO,GAAG,QAAQ,CAAC;IAElC,QAAQ,CAAC,EAAE,OAAO,CAAC;IAEnB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAKD,eAAO,MAAM,MAAM,wFAqDlB,CAAC"}
|
|
@@ -12,7 +12,8 @@ export var Button = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
12
12
|
var children = _ref.children,
|
|
13
13
|
_ref$variant = _ref.variant,
|
|
14
14
|
variant = _ref$variant === void 0 ? "contained" : _ref$variant,
|
|
15
|
-
size = _ref.size,
|
|
15
|
+
_ref$size = _ref.size,
|
|
16
|
+
size = _ref$size === void 0 ? "medium" : _ref$size,
|
|
16
17
|
_ref$disabled = _ref.disabled,
|
|
17
18
|
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
18
19
|
className = _ref.className,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../src/components/Button/Button.tsx"],"names":["React","forwardRef","StyledButton","StyledButtonElement","StyledButtonElements","classnames","Button","ref","children","variant","size","disabled","className","args","Object","Array","map","value","index","displayName"],"mappings":";;;AAAA,OAAOA,KAAP,IAA2BC,UAA3B,QAA6C,OAA7C;AACA,SACEC,YADF,EAEEC,mBAFF,EAGEC,oBAHF,QAIO,UAJP;AAKA,OAAOC,UAAP,MAAuB,YAAvB;;AAyBA;AACA;AACA;AACA,OAAO,IAAMC,MAAM,gBAAGL,UAAU,CAC9B,gBASEM,GATF,EAUK;AAAA,MARDC,QAQC,QARDA,QAQC;AAAA,0BAPDC,OAOC;AAAA,MAPDA,OAOC,6BAPS,WAOT;AAAA,
|
|
1
|
+
{"version":3,"sources":["../../../../src/components/Button/Button.tsx"],"names":["React","forwardRef","StyledButton","StyledButtonElement","StyledButtonElements","classnames","Button","ref","children","variant","size","disabled","className","args","Object","Array","map","value","index","displayName"],"mappings":";;;AAAA,OAAOA,KAAP,IAA2BC,UAA3B,QAA6C,OAA7C;AACA,SACEC,YADF,EAEEC,mBAFF,EAGEC,oBAHF,QAIO,UAJP;AAKA,OAAOC,UAAP,MAAuB,YAAvB;;AAyBA;AACA;AACA;AACA,OAAO,IAAMC,MAAM,gBAAGL,UAAU,CAC9B,gBASEM,GATF,EAUK;AAAA,MARDC,QAQC,QARDA,QAQC;AAAA,0BAPDC,OAOC;AAAA,MAPDA,OAOC,6BAPS,WAOT;AAAA,uBANDC,IAMC;AAAA,MANDA,IAMC,0BANM,QAMN;AAAA,2BALDC,QAKC;AAAA,MALDA,QAKC,8BALU,KAKV;AAAA,MAJDC,SAIC,QAJDA,SAIC;AAAA,MAHEC,IAGF;;AACH,sBACE,oBAAC,YAAD;AACE,IAAA,QAAQ,EAAEF,QADZ;AAEE,IAAA,SAAS,EAAEN,UAAU,CAAC,OAAD,EAAUO,SAAV,EAAqB;AACxC,0BAAoBH,OAAO,KAAK,SAAZ,IAAyBA,OAAO,KAAK,WADjB;AAExC,yBAAmBA,OAAO,KAAK,WAAZ,IAA2BA,OAAO,KAAK,UAFlB;AAGxC,6BACEA,OAAO,KAAK,UAAZ,IAA0BA,OAAO,KAAK,cAJA;AAKxC,0BAAoBA,OAAO,KAAK,QAAZ,IAAwBA,OAAO,KAAK,WALhB;AAMxC,iCAA2BA,OAAO,KAAK,kBANC;AAOxC,8BAAwBA,OAAO,KAAK,eAPI;AAQxC,oBAAcC,IAAI,KAAK,KARiB;AASxC,sBAAgBA,IAAI,KAAK,OATe;AAUxC,0BACEF,QAAQ,YAAYM,MAApB,IAA8B,EAAEN,QAAQ,YAAYO,KAAtB;AAXQ,KAArB,CAFvB;AAeE,IAAA,QAAQ,EAAEP,QAAQ,YAAYM,MAApB,IAA8B,EAAEN,QAAQ,YAAYO,KAAtB,CAf1C;AAgBE,IAAA,OAAO,EAAEN,OAhBX;AAiBE,IAAA,IAAI,EAAEC;AAjBR,KAkBMG,IAlBN;AAmBE,IAAA,GAAG,EAAEN;AAnBP,MAqBGC,QAAQ,YAAYO,KAApB,gBACC,oBAAC,oBAAD;AAAsB,IAAA,SAAS,EAAC;AAAhC,KACGP,QAAQ,CAACQ,GAAT,CAAa,UAACC,KAAD,EAAQC,KAAR;AAAA,WACZD,KAAK,gBACH,oBAAC,mBAAD;AACE,MAAA,SAAS,EAAC,0BADZ;AAEE,MAAA,GAAG,EAAEC;AAFP,OAIGD,KAJH,CADG,GAOD,IARQ;AAAA,GAAb,CADH,CADD,GAcCT,QAnCJ,CADF;AAwCD,CApD6B,CAAzB;AAuDPF,MAAM,CAACa,WAAP,GAAqB,QAArB","sourcesContent":["import React, { ReactNode, forwardRef } from \"react\";\nimport {\n StyledButton,\n StyledButtonElement,\n StyledButtonElements,\n} from \"./Styles\";\nimport classnames from \"classnames\";\n\nexport interface IButtonProps extends React.ComponentPropsWithoutRef<\"button\"> {\n /** Children type of node or string */\n children: ReactNode;\n /** Variant Buttons */\n variant?:\n | \"primary\"\n | \"secondary\"\n | \"tertiary\"\n | \"option\"\n | \"contained\"\n | \"outlined\"\n | \"text colored\"\n | \"text gray\"\n | \"dark transparent\"\n | \"circle raised\";\n /** Button size can be big, medium or small */\n size?: \"big\" | \"small\" | \"medium\";\n /** Disabled prop */\n disabled?: boolean;\n /** CSS classes */\n className?: string;\n}\n\n/**\n * Button component\n */\nexport const Button = forwardRef<HTMLButtonElement, IButtonProps>(\n (\n {\n children,\n variant = \"contained\",\n size = \"medium\",\n disabled = false,\n className,\n ...args\n },\n ref\n ) => {\n return (\n <StyledButton\n disabled={disabled}\n className={classnames(\"c-btn\", className, {\n \"c-btn--contained\": variant === \"primary\" || variant === \"contained\",\n \"c-btn--outlined\": variant === \"secondary\" || variant === \"outlined\",\n \"c-btn--text_colored\":\n variant === \"tertiary\" || variant === \"text colored\",\n \"c-btn--text_gray\": variant === \"option\" || variant === \"text gray\",\n \"c-btn--dark_transparent\": variant === \"dark transparent\",\n \"c-btn--circle-raised\": variant === \"circle raised\",\n \"c-btn--big\": size === \"big\",\n \"c-btn--small\": size === \"small\",\n \"c-btn--icon-only\":\n children instanceof Object && !(children instanceof Array),\n })}\n iconOnly={children instanceof Object && !(children instanceof Array)}\n variant={variant}\n size={size}\n {...args}\n ref={ref}\n >\n {children instanceof Array ? (\n <StyledButtonElements className=\"c-btn__elements\">\n {children.map((value, index) =>\n value ? (\n <StyledButtonElement\n className=\"c-btn__elements__element\"\n key={index}\n >\n {value}\n </StyledButtonElement>\n ) : null\n )}\n </StyledButtonElements>\n ) : (\n children\n )}\n </StyledButton>\n );\n }\n);\n\nButton.displayName = \"Button\";\n"],"file":"Button.js"}
|
|
@@ -12,7 +12,7 @@ export declare const StyledComboBoxCloseSmallIcon: import("styled-components").S
|
|
|
12
12
|
export declare const StyledComboBoxCollapseExpandSingleIcon: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<Pick<import("react").SVGProps<SVGSVGElement>, "string" | "style" | "clipPath" | "filter" | "mask" | "path" | "key" | "name" | "type" | "className" | "id" | "lang" | "tabIndex" | "role" | "color" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "tw" | "ideographic" | "alphabetic" | "hanging" | "mathematical" | "height" | "max" | "media" | "method" | "min" | "target" | "width" | "crossOrigin" | "accentHeight" | "accumulate" | "additive" | "alignmentBaseline" | "allowReorder" | "amplitude" | "arabicForm" | "ascent" | "attributeName" | "attributeType" | "autoReverse" | "azimuth" | "baseFrequency" | "baselineShift" | "baseProfile" | "bbox" | "begin" | "bias" | "by" | "calcMode" | "capHeight" | "clip" | "clipPathUnits" | "clipRule" | "colorInterpolation" | "colorInterpolationFilters" | "colorProfile" | "colorRendering" | "contentScriptType" | "contentStyleType" | "cursor" | "cx" | "cy" | "d" | "decelerate" | "descent" | "diffuseConstant" | "direction" | "display" | "divisor" | "dominantBaseline" | "dur" | "dx" | "dy" | "edgeMode" | "elevation" | "enableBackground" | "end" | "exponent" | "externalResourcesRequired" | "fill" | "fillOpacity" | "fillRule" | "filterRes" | "filterUnits" | "floodColor" | "floodOpacity" | "focusable" | "fontFamily" | "fontSize" | "fontSizeAdjust" | "fontStretch" | "fontStyle" | "fontVariant" | "fontWeight" | "format" | "from" | "fx" | "fy" | "g1" | "g2" | "glyphName" | "glyphOrientationHorizontal" | "glyphOrientationVertical" | "glyphRef" | "gradientTransform" | "gradientUnits" | "horizAdvX" | "horizOriginX" | "href" | "imageRendering" | "in2" | "in" | "intercept" | "k1" | "k2" | "k3" | "k4" | "k" | "kernelMatrix" | "kernelUnitLength" | "kerning" | "keyPoints" | "keySplines" | "keyTimes" | "lengthAdjust" | "letterSpacing" | "lightingColor" | "limitingConeAngle" | "local" | "markerEnd" | "markerHeight" | "markerMid" | "markerStart" | "markerUnits" | "markerWidth" | "maskContentUnits" | "maskUnits" | "mode" | "numOctaves" | "offset" | "opacity" | "operator" | "order" | "orient" | "orientation" | "origin" | "overflow" | "overlinePosition" | "overlineThickness" | "paintOrder" | "panose1" | "pathLength" | "patternContentUnits" | "patternTransform" | "patternUnits" | "pointerEvents" | "points" | "pointsAtX" | "pointsAtY" | "pointsAtZ" | "preserveAlpha" | "preserveAspectRatio" | "primitiveUnits" | "r" | "radius" | "refX" | "refY" | "renderingIntent" | "repeatCount" | "repeatDur" | "requiredExtensions" | "requiredFeatures" | "restart" | "result" | "rotate" | "rx" | "ry" | "scale" | "seed" | "shapeRendering" | "slope" | "spacing" | "specularConstant" | "specularExponent" | "speed" | "spreadMethod" | "startOffset" | "stdDeviation" | "stemh" | "stemv" | "stitchTiles" | "stopColor" | "stopOpacity" | "strikethroughPosition" | "strikethroughThickness" | "stroke" | "strokeDasharray" | "strokeDashoffset" | "strokeLinecap" | "strokeLinejoin" | "strokeMiterlimit" | "strokeOpacity" | "strokeWidth" | "surfaceScale" | "systemLanguage" | "tableValues" | "targetX" | "targetY" | "textAnchor" | "textDecoration" | "textLength" | "textRendering" | "to" | "transform" | "u1" | "u2" | "underlinePosition" | "underlineThickness" | "unicode" | "unicodeBidi" | "unicodeRange" | "unitsPerEm" | "vAlphabetic" | "values" | "vectorEffect" | "version" | "vertAdvY" | "vertOriginX" | "vertOriginY" | "vHanging" | "vIdeographic" | "viewBox" | "viewTarget" | "visibility" | "vMathematical" | "widths" | "wordSpacing" | "writingMode" | "x1" | "x2" | "x" | "xChannelSelector" | "xHeight" | "xlinkActuate" | "xlinkArcrole" | "xlinkHref" | "xlinkRole" | "xlinkShow" | "xlinkTitle" | "xlinkType" | "xmlBase" | "xmlLang" | "xmlns" | "xmlnsXlink" | "xmlSpace" | "y1" | "y2" | "y" | "yChannelSelector" | "z" | "zoomAndPan"> & import("react").RefAttributes<SVGSVGElement>>, any, {
|
|
13
13
|
$open?: boolean | undefined;
|
|
14
14
|
}, never>;
|
|
15
|
-
export declare const StyledComboBoxInput: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "key" | keyof import("react").InputHTMLAttributes<HTMLInputElement
|
|
15
|
+
export declare const StyledComboBoxInput: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("../Input/Input").InputProps & Omit<Pick<import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "key" | keyof import("react").InputHTMLAttributes<HTMLInputElement>>, "size"> & import("react").RefAttributes<HTMLInputElement>>, any, {}, never>;
|
|
16
16
|
export declare const StyledComboBoxList: import("styled-components").StyledComponent<"div", any, {
|
|
17
17
|
$width?: number | undefined;
|
|
18
18
|
}, never>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Styles.d.ts","sourceRoot":"","sources":["../../../../src/components/ComboBox/Styles.ts"],"names":[],"mappings":";AAMA,UAAU,mBAAmB;IAC3B,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,eAAO,MAAM,cAAc,qFAkC1B,CAAC;AAIF,eAAO,MAAM,qBAAqB;;SAWjC,CAAC;AASF,eAAO,MAAM,4BAA4B,wqPAWxC,CAAC;AAIF,eAAO,MAAM,sCAAsC;;SAalD,CAAC;AAKF,eAAO,MAAM,mBAAmB,
|
|
1
|
+
{"version":3,"file":"Styles.d.ts","sourceRoot":"","sources":["../../../../src/components/ComboBox/Styles.ts"],"names":[],"mappings":";AAMA,UAAU,mBAAmB;IAC3B,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,eAAO,MAAM,cAAc,qFAkC1B,CAAC;AAIF,eAAO,MAAM,qBAAqB;;SAWjC,CAAC;AASF,eAAO,MAAM,4BAA4B,wqPAWxC,CAAC;AAIF,eAAO,MAAM,sCAAsC;;SAalD,CAAC;AAKF,eAAO,MAAM,mBAAmB,qYAM/B,CAAC;AAIF,eAAO,MAAM,kBAAkB;;SAQ9B,CAAC"}
|
|
@@ -1,3 +1,7 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
export declare
|
|
2
|
+
export declare type InputSize = "small" | "regular" | "big";
|
|
3
|
+
export interface InputProps {
|
|
4
|
+
size?: InputSize;
|
|
5
|
+
}
|
|
6
|
+
export declare const Input: React.ForwardRefExoticComponent<InputProps & Omit<Pick<React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "key" | keyof React.InputHTMLAttributes<HTMLInputElement>>, "size"> & React.RefAttributes<HTMLInputElement>>;
|
|
3
7
|
//# sourceMappingURL=Input.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Input.d.ts","sourceRoot":"","sources":["../../../../src/components/Input/Input.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAqB,MAAM,OAAO,CAAC;AAI1C,eAAO,MAAM,KAAK,
|
|
1
|
+
{"version":3,"file":"Input.d.ts","sourceRoot":"","sources":["../../../../src/components/Input/Input.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAqB,MAAM,OAAO,CAAC;AAI1C,oBAAY,SAAS,GAAG,OAAO,GAAG,SAAS,GAAG,KAAK,CAAC;AACpD,MAAM,WAAW,UAAU;IAEzB,IAAI,CAAC,EAAE,SAAS,CAAC;CAClB;AAED,eAAO,MAAM,KAAK,6PAyBjB,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/esm/extends";
|
|
2
2
|
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
|
|
3
|
-
var _excluded = ["className", "type", "disabled"];
|
|
3
|
+
var _excluded = ["className", "type", "disabled", "size"];
|
|
4
4
|
import React, { forwardRef } from "react";
|
|
5
5
|
import classnames from "classnames";
|
|
6
6
|
import { StyledInput } from "./Styles";
|
|
@@ -11,13 +11,16 @@ export var Input = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
11
11
|
type = _ref$type === void 0 ? "text" : _ref$type,
|
|
12
12
|
_ref$disabled = _ref.disabled,
|
|
13
13
|
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
14
|
+
_ref$size = _ref.size,
|
|
15
|
+
size = _ref$size === void 0 ? "regular" : _ref$size,
|
|
14
16
|
rest = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
15
17
|
|
|
16
18
|
return /*#__PURE__*/React.createElement(StyledInput, _extends({
|
|
17
19
|
ref: ref,
|
|
18
20
|
type: type,
|
|
19
21
|
disabled: disabled,
|
|
20
|
-
className: classnames("c-input", className)
|
|
22
|
+
className: classnames("c-input", className),
|
|
23
|
+
$size: size
|
|
21
24
|
}, rest));
|
|
22
25
|
});
|
|
23
26
|
Input.displayName = "Input";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../src/components/Input/Input.tsx"],"names":["React","forwardRef","classnames","StyledInput","Input","ref","className","type","disabled","rest","displayName"],"mappings":";;;AAAA,OAAOA,KAAP,IAAgBC,UAAhB,QAAkC,OAAlC;AACA,OAAOC,UAAP,MAAuB,YAAvB;AACA,SAASC,WAAT,QAA4B,UAA5B;
|
|
1
|
+
{"version":3,"sources":["../../../../src/components/Input/Input.tsx"],"names":["React","forwardRef","classnames","StyledInput","Input","ref","className","type","disabled","size","rest","displayName"],"mappings":";;;AAAA,OAAOA,KAAP,IAAgBC,UAAhB,QAAkC,OAAlC;AACA,OAAOC,UAAP,MAAuB,YAAvB;AACA,SAASC,WAAT,QAA4B,UAA5B;AAQA,OAAO,IAAMC,KAAK,gBAAGH,UAAU,CAI7B,gBAQEI,GARF,EASK;AAAA,4BAPDC,SAOC;AAAA,MAPDA,SAOC,+BAPW,EAOX;AAAA,uBANDC,IAMC;AAAA,MANDA,IAMC,0BANM,MAMN;AAAA,2BALDC,QAKC;AAAA,MALDA,QAKC,8BALU,KAKV;AAAA,uBAJDC,IAIC;AAAA,MAJDA,IAIC,0BAJM,SAIN;AAAA,MAHEC,IAGF;;AACH,sBACE,oBAAC,WAAD;AACE,IAAA,GAAG,EAAEL,GADP;AAEE,IAAA,IAAI,EAAEE,IAFR;AAGE,IAAA,QAAQ,EAAEC,QAHZ;AAIE,IAAA,SAAS,EAAEN,UAAU,CAAC,SAAD,EAAYI,SAAZ,CAJvB;AAKE,IAAA,KAAK,EAAEG;AALT,KAMMC,IANN,EADF;AAUD,CAxB4B,CAAxB;AA2BPN,KAAK,CAACO,WAAN,GAAoB,OAApB","sourcesContent":["import React, { forwardRef } from \"react\";\nimport classnames from \"classnames\";\nimport { StyledInput } from \"./Styles\";\n\nexport type InputSize = \"small\" | \"regular\" | \"big\";\nexport interface InputProps {\n /** Velicina inputa koja definse font-size i border radius */\n size?: InputSize;\n}\n\nexport const Input = forwardRef<\n HTMLInputElement,\n InputProps & Omit<React.ComponentPropsWithoutRef<\"input\">, keyof InputProps>\n>(\n (\n {\n className = \"\",\n type = \"text\",\n disabled = false,\n size = \"regular\",\n ...rest\n },\n ref\n ) => {\n return (\n <StyledInput\n ref={ref}\n type={type}\n disabled={disabled}\n className={classnames(\"c-input\", className)}\n $size={size}\n {...rest}\n />\n );\n }\n);\n\nInput.displayName = \"Input\";\n"],"file":"Input.js"}
|
|
@@ -1,2 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
import { InputSize } from "./Input";
|
|
2
|
+
export declare const StyledInput: import("styled-components").StyledComponent<"input", any, {
|
|
3
|
+
$size?: InputSize | undefined;
|
|
4
|
+
}, never>;
|
|
2
5
|
//# sourceMappingURL=Styles.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Styles.d.ts","sourceRoot":"","sources":["../../../../src/components/Input/Styles.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Styles.d.ts","sourceRoot":"","sources":["../../../../src/components/Input/Styles.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAIpC,eAAO,MAAM,WAAW;;SAqDvB,CAAC"}
|
|
@@ -4,7 +4,11 @@ import { FontStyle } from "../FontStyle";
|
|
|
4
4
|
export var StyledInput = styled.input.withConfig({
|
|
5
5
|
displayName: "Styles__StyledInput",
|
|
6
6
|
componentId: "sc-ce8kcp-0"
|
|
7
|
-
})(["border:1px solid var(--border-primary);border-radius:10px;color:var(--color-theme-900);font-size:14px;padding:4px 10px 6px 8px;height:32px;background-color:var(--input-background-color);transition:all 0.3s ease;width:360px;outline:none;", " ", " ", " &::placeholder{color:var(--color-theme-600);}"], FontStyle, BoxSizingStyle, function (props) {
|
|
7
|
+
})(["border:1px solid var(--border-primary);border-radius:10px;color:var(--color-theme-900);font-size:14px;padding:4px 10px 6px 8px;height:32px;background-color:var(--input-background-color);transition:all 0.3s ease;width:360px;outline:none;", " ", " ", " ", " ", " &::placeholder{color:var(--color-theme-600);}"], FontStyle, BoxSizingStyle, function (props) {
|
|
8
|
+
return props.$size === "small" && css(["border-radius:6px;height:24px;"]);
|
|
9
|
+
}, function (props) {
|
|
10
|
+
return props.$size === "big" && css(["height:40px;font-size:16px;"]);
|
|
11
|
+
}, function (props) {
|
|
8
12
|
return props.disabled ? css(["", ""], {
|
|
9
13
|
"cursor": "not-allowed",
|
|
10
14
|
"opacity": "0.5",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../src/components/Input/Styles.ts"],"names":["styled","css","BoxSizingStyle","FontStyle","StyledInput","input","props","disabled","displayName"],"mappings":"AAAA,OAAOA,MAAP,IAAiBC,GAAjB,QAA4B,mBAA5B;
|
|
1
|
+
{"version":3,"sources":["../../../../src/components/Input/Styles.ts"],"names":["styled","css","BoxSizingStyle","FontStyle","StyledInput","input","props","$size","disabled","displayName"],"mappings":"AAAA,OAAOA,MAAP,IAAiBC,GAAjB,QAA4B,mBAA5B;AAGA,SAASC,cAAT,QAA+B,mBAA/B;AACA,SAASC,SAAT,QAA0B,cAA1B;AAEA,OAAO,IAAMC,WAAW,GAAGJ,MAAM,CAACK,KAAV;AAAA;AAAA;AAAA,2TAcpBF,SAdoB,EAepBD,cAfoB,EAiBpB,UAACI,KAAD;AAAA,SACAA,KAAK,CAACC,KAAN,KAAgB,OAAhB,IACAN,GADA,oCADA;AAAA,CAjBoB,EAwBpB,UAACK,KAAD;AAAA,SACAA,KAAK,CAACC,KAAN,KAAgB,KAAhB,IACAN,GADA,iCADA;AAAA,CAxBoB,EA+BpB,UAACK,KAAD;AAAA,SACAA,KAAK,CAACE,QAAN,GACIP,GADJ,WAEU;AAAA;AAAA;AAAA;AAAA,GAFV,IAIIA,GAJJ,+CAMY;AAAA;AAAA,GANZ,EAUY;AAAA;AAAA,GAVZ,EAcY;AAAA;AAAA,GAdZ,CADA;AAAA,CA/BoB,CAAjB;AAuDPG,WAAW,CAACK,WAAZ,GAA0B,aAA1B","sourcesContent":["import styled, { css } from \"styled-components\";\nimport tw from \"twin.macro\";\nimport { InputSize } from \"./Input\";\nimport { BoxSizingStyle } from \"../BoxSizingStyle\";\nimport { FontStyle } from \"../FontStyle\";\n\nexport const StyledInput = styled.input<{\n $size?: InputSize;\n}>`\n border: 1px solid var(--border-primary);\n border-radius: 10px;\n color: var(--color-theme-900);\n font-size: 14px;\n padding: 4px 10px 6px 8px;\n height: 32px;\n background-color: var(--input-background-color);\n transition: all 0.3s ease;\n width: 360px;\n outline: none;\n\n ${FontStyle}\n ${BoxSizingStyle}\n\n ${(props) =>\n props.$size === \"small\" &&\n css`\n border-radius: 6px;\n height: 24px;\n `}\n\n ${(props) =>\n props.$size === \"big\" &&\n css`\n height: 40px;\n font-size: 16px;\n `}\n\n ${(props) =>\n props.disabled\n ? css`\n ${tw`tw-cursor-not-allowed tw-opacity-50 tw-border-theme-400`}\n `\n : css`\n &:hover {\n ${tw`tw-border-primary`}\n }\n\n &:active {\n ${tw`tw-border-primary`}\n }\n\n &:focus {\n ${tw`tw-border-primary`}\n }\n `}\n\n &::placeholder {\n color: var(--color-theme-600);\n }\n`;\n\nStyledInput.displayName = \"StyledInput\";\n"],"file":"Styles.js"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
export declare const StyledSelectInput: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<Pick<import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "key" | keyof import("react").InputHTMLAttributes<HTMLInputElement
|
|
2
|
+
export declare const StyledSelectInput: import("styled-components").StyledComponent<import("react").ForwardRefExoticComponent<import("../Input/Input").InputProps & Omit<Pick<import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "key" | keyof import("react").InputHTMLAttributes<HTMLInputElement>>, "size"> & import("react").RefAttributes<HTMLInputElement>>, any, {}, never>;
|
|
3
3
|
export declare const StyledSelectForm: import("styled-components").StyledComponent<"form", any, {}, never>;
|
|
4
4
|
//# sourceMappingURL=Styles.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Styles.d.ts","sourceRoot":"","sources":["../../../../src/components/Select/Styles.ts"],"names":[],"mappings":";AAGA,eAAO,MAAM,iBAAiB,
|
|
1
|
+
{"version":3,"file":"Styles.d.ts","sourceRoot":"","sources":["../../../../src/components/Select/Styles.ts"],"names":[],"mappings":";AAGA,eAAO,MAAM,iBAAiB,qYAAkB,CAAC;AAIjD,eAAO,MAAM,gBAAgB,qEAY5B,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -323,7 +323,8 @@
|
|
|
323
323
|
var children = _ref.children,
|
|
324
324
|
_ref$variant = _ref.variant,
|
|
325
325
|
variant = _ref$variant === void 0 ? "contained" : _ref$variant,
|
|
326
|
-
size = _ref.size,
|
|
326
|
+
_ref$size = _ref.size,
|
|
327
|
+
size = _ref$size === void 0 ? "medium" : _ref$size,
|
|
327
328
|
_ref$disabled = _ref.disabled,
|
|
328
329
|
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
329
330
|
className = _ref.className,
|
|
@@ -4592,7 +4593,11 @@
|
|
|
4592
4593
|
var StyledInput = styled__default["default"].input.withConfig({
|
|
4593
4594
|
displayName: "Styles__StyledInput",
|
|
4594
4595
|
componentId: "sc-ce8kcp-0"
|
|
4595
|
-
})(["border:1px solid var(--border-primary);border-radius:10px;color:var(--color-theme-900);font-size:14px;padding:4px 10px 6px 8px;height:32px;background-color:var(--input-background-color);transition:all 0.3s ease;width:360px;outline:none;", " ", " ", " &::placeholder{color:var(--color-theme-600);}"], FontStyle, BoxSizingStyle, function (props) {
|
|
4596
|
+
})(["border:1px solid var(--border-primary);border-radius:10px;color:var(--color-theme-900);font-size:14px;padding:4px 10px 6px 8px;height:32px;background-color:var(--input-background-color);transition:all 0.3s ease;width:360px;outline:none;", " ", " ", " ", " ", " &::placeholder{color:var(--color-theme-600);}"], FontStyle, BoxSizingStyle, function (props) {
|
|
4597
|
+
return props.$size === "small" && styled.css(["border-radius:6px;height:24px;"]);
|
|
4598
|
+
}, function (props) {
|
|
4599
|
+
return props.$size === "big" && styled.css(["height:40px;font-size:16px;"]);
|
|
4600
|
+
}, function (props) {
|
|
4596
4601
|
return props.disabled ? styled.css(["", ""], {
|
|
4597
4602
|
"cursor": "not-allowed",
|
|
4598
4603
|
"opacity": "0.5",
|
|
@@ -4607,7 +4612,7 @@
|
|
|
4607
4612
|
});
|
|
4608
4613
|
StyledInput.displayName = "StyledInput";
|
|
4609
4614
|
|
|
4610
|
-
var _excluded$q = ["className", "type", "disabled"];
|
|
4615
|
+
var _excluded$q = ["className", "type", "disabled", "size"];
|
|
4611
4616
|
var Input = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
|
|
4612
4617
|
var _ref$className = _ref.className,
|
|
4613
4618
|
className = _ref$className === void 0 ? "" : _ref$className,
|
|
@@ -4615,13 +4620,16 @@
|
|
|
4615
4620
|
type = _ref$type === void 0 ? "text" : _ref$type,
|
|
4616
4621
|
_ref$disabled = _ref.disabled,
|
|
4617
4622
|
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
4623
|
+
_ref$size = _ref.size,
|
|
4624
|
+
size = _ref$size === void 0 ? "regular" : _ref$size,
|
|
4618
4625
|
rest = _objectWithoutProperties(_ref, _excluded$q);
|
|
4619
4626
|
|
|
4620
4627
|
return /*#__PURE__*/React__default["default"].createElement(StyledInput, _extends({
|
|
4621
4628
|
ref: ref,
|
|
4622
4629
|
type: type,
|
|
4623
4630
|
disabled: disabled,
|
|
4624
|
-
className: classnames__default["default"]("c-input", className)
|
|
4631
|
+
className: classnames__default["default"]("c-input", className),
|
|
4632
|
+
$size: size
|
|
4625
4633
|
}, rest));
|
|
4626
4634
|
});
|
|
4627
4635
|
Input.displayName = "Input";
|