@happeouikit/form-elements 2.3.26 → 2.3.28

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/Badge.js CHANGED
@@ -23,7 +23,7 @@ var Badge = function Badge(_ref) {
23
23
  };
24
24
  var Wrapper = styled.span.withConfig({
25
25
  displayName: "Badge__Wrapper",
26
- componentId: "sc-xyqvne-0"
26
+ componentId: "sc-1fz0j0z-0"
27
27
  })(["display:inline-block;background:", ";padding:4px 8px;border-radius:100px;"], function (_ref2) {
28
28
  var color = _ref2.color,
29
29
  isFilled = _ref2.isFilled;
package/dist/Checkbox.js CHANGED
@@ -3,7 +3,7 @@ import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProper
3
3
  var _excluded = ["label", "background", "role", "indeterminate"];
4
4
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
5
5
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
6
- import { useRef } from "react";
6
+ import React, { useRef } from "react";
7
7
  import styled from "styled-components";
8
8
  import PropTypes from "prop-types";
9
9
  import { white, active, gray01, gray06, gray08 } from "@happeouikit/colors";
@@ -67,23 +67,23 @@ Checkbox.defaultProps = {
67
67
  };
68
68
  var StyledCheckbox = styled.span.withConfig({
69
69
  displayName: "Checkbox__StyledCheckbox",
70
- componentId: "sc-tc08iy-0"
70
+ componentId: "sc-uagbwn-0"
71
71
  })(["cursor:pointer;position:absolute;height:18px;width:18px;border-radius:3px;background-color:", ";border:2px solid ", ";box-sizing:content-box !important;&:focus-visible{outline:0;box-shadow:0 0 0 1px ", ";}"], white, gray06, active);
72
72
  var StyledIndeterminate = styled.span.withConfig({
73
73
  displayName: "Checkbox__StyledIndeterminate",
74
- componentId: "sc-tc08iy-1"
74
+ componentId: "sc-uagbwn-1"
75
75
  })(["cursor:pointer;position:absolute;height:18px;width:18px;border-radius:3px;background-color:", ";border:2px solid ", ";box-sizing:content-box !important;&:focus-visible{outline:0;box-shadow:0 0 0 1px ", ";}"], white, gray06, active);
76
76
  var Checkmark = styled(IconCheck).withConfig({
77
77
  displayName: "Checkbox__Checkmark",
78
- componentId: "sc-tc08iy-2"
78
+ componentId: "sc-uagbwn-2"
79
79
  })(["position:absolute;display:none;fill:", ";width:18px;height:16px;top:50%;transform:translateY(-50%);"], white);
80
80
  var Indeterminate = styled(IconRemove).withConfig({
81
81
  displayName: "Checkbox__Indeterminate",
82
- componentId: "sc-tc08iy-3"
82
+ componentId: "sc-uagbwn-3"
83
83
  })(["position:absolute;fill:", ";width:18px;height:16px;top:50%;transform:translateY(-50%);"], white);
84
84
  var CheckboxWrapper = styled.label.withConfig({
85
85
  displayName: "Checkbox__CheckboxWrapper",
86
- componentId: "sc-tc08iy-4"
86
+ componentId: "sc-uagbwn-4"
87
87
  })(["display:flex;align-items:center;position:relative;cursor:", ";user-select:none;padding:4px 0;input{opacity:0;width:0;height:0;}input:checked + ", "{background:", ";border:", ";}input:checked + ", " > svg{display:block;}input:disabled + ", "{cursor:not-allowed;background:", ";border:2px solid ", ";}input + ", "{background:", ";border:", ";}input + ", " > svg{display:block;}input:disabled + ", "{cursor:not-allowed;background:", ";border:2px solid ", ";}input:disabled ~ p{color:", ";}"], function (_ref2) {
88
88
  var disabled = _ref2.disabled;
89
89
  return disabled ? "not-allowed" : " pointer";
@@ -102,6 +102,6 @@ var CheckboxWrapper = styled.label.withConfig({
102
102
  }, StyledIndeterminate, StyledIndeterminate, gray08, gray08, gray06);
103
103
  var Label = styled(TextZeta).withConfig({
104
104
  displayName: "Checkbox__Label",
105
- componentId: "sc-tc08iy-5"
105
+ componentId: "sc-uagbwn-5"
106
106
  })(["display:inline-block;position:relative;margin-left:30px;color:", ";"], gray01);
107
107
  export default Checkbox;
@@ -397,23 +397,23 @@ var MonthPicker = function MonthPicker(_ref4) {
397
397
  };
398
398
  var YearMonthSelectContainer = styled.div.withConfig({
399
399
  displayName: "DatePicker__YearMonthSelectContainer",
400
- componentId: "sc-ce3xgi-0"
400
+ componentId: "sc-8lna7p-0"
401
401
  })(["position:absolute;z-index:1;top:0;bottom:0;left:0;right:0;background-color:", ";padding:", ";"], white, padding300);
402
402
  var ActionList = styled.div.withConfig({
403
403
  displayName: "DatePicker__ActionList",
404
- componentId: "sc-ce3xgi-1"
404
+ componentId: "sc-8lna7p-1"
405
405
  })(["display:flex;align-items:center;justify-content:flex-end;margin-top:", ";"], padding300);
406
406
  var YearSelectContainer = styled.div.withConfig({
407
407
  displayName: "DatePicker__YearSelectContainer",
408
- componentId: "sc-ce3xgi-2"
408
+ componentId: "sc-8lna7p-2"
409
409
  })(["align-items:center;justify-content:center;margin-bottom:", ";> div{width:100%;}"], margin200);
410
410
  var MonthUl = styled.ul.withConfig({
411
411
  displayName: "DatePicker__MonthUl",
412
- componentId: "sc-ce3xgi-3"
412
+ componentId: "sc-8lna7p-3"
413
413
  })(["display:grid;grid-template-columns:1fr 1fr 1fr 1fr;grid-gap:8px;width:100%;margin:", " 0 0 0;padding:0;list-style:none;li{width:100%;}"], padding300);
414
414
  var MonthSelectButton2 = styled(ButtonSecondary).withConfig({
415
415
  displayName: "DatePicker__MonthSelectButton2",
416
- componentId: "sc-ce3xgi-4"
416
+ componentId: "sc-8lna7p-4"
417
417
  })(["padding:8px;", ""], function (_ref8) {
418
418
  var $isActive = _ref8.$isActive;
419
419
  return $isActive && css(["background-color:", ";p{color:", ";font-weight:bold;}"], lighten(active, 0.9), active);
@@ -421,7 +421,7 @@ var MonthSelectButton2 = styled(ButtonSecondary).withConfig({
421
421
  var borderRadius = "100px";
422
422
  var Wrapper = styled.div.withConfig({
423
423
  displayName: "DatePicker__Wrapper",
424
- componentId: "sc-ce3xgi-5"
424
+ componentId: "sc-8lna7p-5"
425
425
  })(["display:flex;flex-direction:column;width:", ";.DayPickerInput-Overlay{margin-top:8px;box-shadow:", ";border-radius:", ";}.DayPickerInput{.Range{.DayPicker-Day{min-width:21px;:focus{outline:none;}&.DayPicker-Day--selected:not(.DayPicker-Day--before):not(.DayPicker-Day--after){", "}&.DayPicker-Day--selected{background-color:", ";color:", ";}&.DayPicker-Day--before{position:relative;", "}&.DayPicker-Day--after{position:relative;", "}&.DayPicker-Day--today:not(.DayPicker-Day--selected){color:", ";}&.DayPicker-Day--outside{&.DayPicker-Day--before,&.DayPicker-Day--after{color:", ";}}}}input{font-family:", ";width:100%;border-radius:4px;border:solid 1px ", ";box-sizing:border-box;box-shadow:none;font-size:14px;padding:9px 12px 9px 38px;font-weight:normal;font-style:normal;font-stretch:normal;line-height:1.43;letter-spacing:0.3px;color:", ";:hover{border-color:", ";}:active{outline:none;box-shadow:none;border-color:", ";}:focus{outline:none;border-color:", ";}}.DayPicker-wrapper{font-family:", ";color:", ";letter-spacing:-0.3px;font-size:14px;font-weight:normal;}.DayPicker-Week{", " .DayPicker-Day--selected{&:first-child{&.DayPicker-Day--after{::before{content:none;}}}&:last-child{&.DayPicker-Day--before{::before{content:none;}}}}}.DayPicker-Caption{display:none;}}"], function (_ref9) {
426
426
  var width = _ref9.width;
427
427
  return width || "200px";
@@ -440,6 +440,6 @@ var Wrapper = styled.div.withConfig({
440
440
  });
441
441
  var NavBarContainer = styled.div.withConfig({
442
442
  displayName: "DatePicker__NavBarContainer",
443
- componentId: "sc-ce3xgi-6"
443
+ componentId: "sc-8lna7p-6"
444
444
  })(["display:flex;align-items:center;justify-content:space-between;padding:16px 14px 0px 14px;"]);
445
445
  export default DatePicker;
@@ -177,7 +177,7 @@ var DateTimePicker = function DateTimePicker(_ref) {
177
177
  };
178
178
  var Wrapper = styled.div.withConfig({
179
179
  displayName: "DateTimePicker__Wrapper",
180
- componentId: "sc-sdui13-0"
180
+ componentId: "sc-efk0t1-0"
181
181
  })(["display:grid;grid-template-columns:180px 90px 90px;column-gap:8px;"]);
182
182
  DateTimePicker.propTypes = {
183
183
  onChange: PropTypes.func.isRequired,
package/dist/Dropdown.js CHANGED
@@ -56,10 +56,10 @@ export var dropdownStyles = css(["min-width:200px;width:auto;font-family:", ";le
56
56
  });
57
57
  var StyledDropdown = styled(Select).withConfig({
58
58
  displayName: "Dropdown__StyledDropdown",
59
- componentId: "sc-pcee56-0"
59
+ componentId: "sc-1i6nt19-0"
60
60
  })(["", ""], dropdownStyles);
61
61
  var Label = styled.div.withConfig({
62
62
  displayName: "Dropdown__Label",
63
- componentId: "sc-pcee56-1"
63
+ componentId: "sc-1i6nt19-1"
64
64
  })(["margin:4px 0;"]);
65
65
  export default /*#__PURE__*/forwardRef(Dropdown);
package/dist/Input.js CHANGED
@@ -6,7 +6,6 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
6
6
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
7
7
  import React from "react";
8
8
  import styled from "styled-components";
9
- import { placeholder } from "polished";
10
9
  import { gray01, gray04, gray08, gray05, gray06, active, black, success, alert } from "@happeouikit/colors";
11
10
  import { TinyText, sansFamily, BodyUI } from "@happeouikit/typography";
12
11
  import { uuidv4 } from "./utils";
@@ -81,15 +80,15 @@ export var Input = function Input(_ref) {
81
80
  };
82
81
  var ErrorMessage = styled(TinyText).withConfig({
83
82
  displayName: "Input__ErrorMessage",
84
- componentId: "sc-1izazxd-0"
83
+ componentId: "sc-igrift-0"
85
84
  })(["margin:8px 0;"]);
86
85
  var Container = styled.div.withConfig({
87
86
  displayName: "Input__Container",
88
- componentId: "sc-1izazxd-1"
87
+ componentId: "sc-igrift-1"
89
88
  })(["display:flex;flex-direction:column;position:relative;width:100%;"]);
90
89
  var InputLabel = styled.div.withConfig({
91
90
  displayName: "Input__InputLabel",
92
- componentId: "sc-1izazxd-2"
91
+ componentId: "sc-igrift-2"
93
92
  })(["margin:4px 0;"]);
94
93
  export var StyledInput = styled.input.attrs(function (_ref2) {
95
94
  var type = _ref2.type;
@@ -98,14 +97,8 @@ export var StyledInput = styled.input.attrs(function (_ref2) {
98
97
  };
99
98
  }).withConfig({
100
99
  displayName: "Input__StyledInput",
101
- componentId: "sc-1izazxd-3"
102
- })(["", ";font-family:", ";width:100%;height:40px;border-radius:4px;border:solid 1px ", ";box-sizing:border-box;box-shadow:none;font-size:14px;padding:", ";font-weight:normal;font-style:normal;font-stretch:normal;line-height:1.43;letter-spacing:0.3px;color:", ";:hover{border-color:", ";}:active{outline:none;box-shadow:none;border-color:", ";}:focus{outline:none;border-color:", " !important;}:disabled{border:solid 1px ", ";color:", ";", "}border-color:", ";"], placeholder({
103
- "font-family": sansFamily,
104
- color: gray05,
105
- "letter-spacing": "-0.3px",
106
- "font-size": "14px",
107
- "font-weight": "normal"
108
- }), sansFamily, gray06, function (_ref3) {
100
+ componentId: "sc-igrift-3"
101
+ })(["::placeholder{font-family:sansFamily;color:gray05;letter-spacing:-0.3px;font-size:14px;font-weight:normal;}font-family:", ";width:100%;height:40px;border-radius:4px;border:solid 1px ", ";box-sizing:border-box;box-shadow:none;font-size:14px;padding:", ";font-weight:normal;font-style:normal;font-stretch:normal;line-height:1.43;letter-spacing:0.3px;color:", ";:hover{border-color:", ";}:active{outline:none;box-shadow:none;border-color:", ";}:focus{outline:none;border-color:", " !important;}:disabled{border:solid 1px ", ";color:", ";::placeholder{color:gray05;}}border-color:", ";"], sansFamily, gray06, function (_ref3) {
109
102
  var hasIcon = _ref3.hasIcon;
110
103
  return hasIcon ? "10px 12px 10px 38px" : "10px 12px";
111
104
  }, black, function (_ref4) {
@@ -120,16 +113,14 @@ export var StyledInput = styled.input.attrs(function (_ref2) {
120
113
  var _ref6$state = _ref6.state,
121
114
  state = _ref6$state === void 0 ? "default" : _ref6$state;
122
115
  return state === "default" ? active : inputStates[state];
123
- }, gray08, gray05, placeholder({
124
- color: gray05
125
- }), function (_ref7) {
116
+ }, gray08, gray05, function (_ref7) {
126
117
  var _ref7$state = _ref7.state,
127
118
  state = _ref7$state === void 0 ? "default" : _ref7$state;
128
119
  return inputStates[state];
129
120
  });
130
121
  var InputIconWrapper = styled.span.withConfig({
131
122
  displayName: "Input__InputIconWrapper",
132
- componentId: "sc-1izazxd-4"
123
+ componentId: "sc-igrift-4"
133
124
  })(["position:relative;"]);
134
125
 
135
126
  /**
@@ -148,13 +139,13 @@ export var InputNumber = function InputNumber(_ref8) {
148
139
  };
149
140
  var StyledInputNumber = styled(Input).withConfig({
150
141
  displayName: "Input__StyledInputNumber",
151
- componentId: "sc-1izazxd-5"
142
+ componentId: "sc-igrift-5"
152
143
  })(["width:60px;text-align:center;font-size:14px;"]);
153
144
  var InputNumberContainer = styled.div.withConfig({
154
145
  displayName: "Input__InputNumberContainer",
155
- componentId: "sc-1izazxd-6"
146
+ componentId: "sc-igrift-6"
156
147
  })(["display:flex;align-items:center;", "{width:auto;}"], Container);
157
148
  var InputNumberLabel = styled(BodyUI).withConfig({
158
149
  displayName: "Input__InputNumberLabel",
159
- componentId: "sc-1izazxd-7"
150
+ componentId: "sc-igrift-7"
160
151
  })(["color:", ";margin-left:10px;"], gray01);
package/dist/Link.js CHANGED
@@ -27,7 +27,7 @@ export var LinkExternal = /*#__PURE__*/React.forwardRef(function (props, ref) {
27
27
  });
28
28
  var StyledLink = styled(BodyUI).withConfig({
29
29
  displayName: "Link__StyledLink",
30
- componentId: "sc-jezurh-0"
30
+ componentId: "sc-11s0n25-0"
31
31
  })(["text-decoration:", ";color:", ";:hover{color:", ";text-decoration:underline;}"], function (_ref) {
32
32
  var underline = _ref.underline;
33
33
  return underline ? "underline" : "none";
@@ -1,41 +1,84 @@
1
1
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
+ import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
2
3
  import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
3
- var _excluded = ["label"];
4
+ var _excluded = ["label", "subtitle", "description"];
4
5
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
5
6
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
6
- import React from "react";
7
+ import React, { useState } from "react";
7
8
  import styled from "styled-components";
8
9
  import PropTypes from "prop-types";
9
- import { white, active, gray06, gray01, gray08 } from "@happeouikit/colors";
10
- import { TextZeta } from "@happeouikit/typography";
10
+ import { BodyUI } from "@happeouikit/typography";
11
+ import { uuidv4 } from "./utils";
11
12
  import { jsx as _jsx } from "react/jsx-runtime";
12
13
  import { jsxs as _jsxs } from "react/jsx-runtime";
13
14
  var RadioButton = function RadioButton(_ref) {
14
15
  var label = _ref.label,
16
+ subtitle = _ref.subtitle,
17
+ description = _ref.description,
15
18
  props = _objectWithoutProperties(_ref, _excluded);
19
+ var _useState = useState(function () {
20
+ return props.id || "radio_".concat(uuidv4());
21
+ }),
22
+ _useState2 = _slicedToArray(_useState, 1),
23
+ id = _useState2[0];
16
24
  return /*#__PURE__*/_jsxs(RadioButtonWrapper, {
17
- children: [/*#__PURE__*/_jsx("input", _objectSpread({
18
- type: "radio"
19
- }, props)), /*#__PURE__*/_jsx(StyledRadioButton, _objectSpread({}, props)), label && /*#__PURE__*/_jsx(Label, {
20
- "data-tip": props["data-tip"],
21
- "data-tip-disable": props["data-tip-disable"],
22
- children: label
25
+ children: [/*#__PURE__*/_jsx("input", _objectSpread(_objectSpread({
26
+ type: "radio",
27
+ "aria-describedby": description ? "".concat(id, "_description") : null
28
+ }, props), {}, {
29
+ id: id
30
+ })), /*#__PURE__*/_jsx(StyledRadioButton, {}), label && /*#__PURE__*/_jsxs(TextContainer, {
31
+ children: [/*#__PURE__*/_jsxs(LabelRow, {
32
+ children: [label && /*#__PURE__*/_jsx(Label, {
33
+ bold: true,
34
+ htmlFor: id,
35
+ "data-tip": props["data-tip"],
36
+ "data-tip-disable": props["data-tip-disable"],
37
+ children: label
38
+ }), subtitle && /*#__PURE__*/_jsx(Subtitle, {
39
+ children: subtitle
40
+ })]
41
+ }), description && /*#__PURE__*/_jsx(Description, {
42
+ id: "".concat(id, "_description"),
43
+ children: description
44
+ })]
23
45
  })]
24
46
  });
25
47
  };
26
48
  RadioButton.propTypes = {
27
- label: PropTypes.node
49
+ label: PropTypes.node,
50
+ subtitle: PropTypes.node,
51
+ description: PropTypes.node
52
+ };
53
+ RadioButton.defaultProps = {
54
+ label: null
28
55
  };
29
56
  var StyledRadioButton = styled.span.withConfig({
30
57
  displayName: "RadioButton__StyledRadioButton",
31
- componentId: "sc-118nqq7-0"
32
- })(["position:absolute;height:12px;width:12px;background-color:", ";border:2px solid ", ";box-shadow:0px 0px 0px 2px ", ";border-radius:50%;"], white, white, gray06);
33
- var Label = styled(TextZeta).withConfig({
58
+ componentId: "sc-gwa7wx-0"
59
+ })(["position:relative;height:20px;width:20px;background-color:var(--color-surface,#ffffff);border:2px solid var(--color-stroke,#ffffff);border-radius:var(--radius-circle,50%);flex-shrink:0;input:focus + &{:before{content:\"\";position:absolute;top:-4px;left:-4px;right:-4px;bottom:-4px;border-radius:var(--radius-circle,50%);border:1px solid var(--color-focus-indicator,#0075db);}}"]);
60
+ var TextContainer = styled.div.withConfig({
61
+ displayName: "RadioButton__TextContainer",
62
+ componentId: "sc-gwa7wx-1"
63
+ })(["display:flex;flex-direction:column;gap:var(--space-xxs,2px);"]);
64
+ var LabelRow = styled.div.withConfig({
65
+ displayName: "RadioButton__LabelRow",
66
+ componentId: "sc-gwa7wx-2"
67
+ })(["display:flex;gap:var(--space-sm,8px);"]);
68
+ var Subtitle = styled(BodyUI).withConfig({
69
+ displayName: "RadioButton__Subtitle",
70
+ componentId: "sc-gwa7wx-3"
71
+ })(["color:var(--color-secondary-text-on-light,#2b313b);font-size:12px;"]);
72
+ var Description = styled(BodyUI).withConfig({
73
+ displayName: "RadioButton__Description",
74
+ componentId: "sc-gwa7wx-4"
75
+ })(["color:var(--color-primary-text-on-light,#2b313b);"]);
76
+ var Label = styled(BodyUI).withConfig({
34
77
  displayName: "RadioButton__Label",
35
- componentId: "sc-118nqq7-1"
36
- })(["display:inline-block;margin-left:25px;color:", ";"], gray01);
78
+ componentId: "sc-gwa7wx-5"
79
+ })(["color:var(--color-primary-text-on-light,#2b313b);"]);
37
80
  var RadioButtonWrapper = styled.label.withConfig({
38
81
  displayName: "RadioButton__RadioButtonWrapper",
39
- componentId: "sc-118nqq7-2"
40
- })(["display:flex;align-items:center;position:relative;cursor:pointer;user-select:none;padding:4px 0;input{display:none;}input:checked ~ ", "{background:", ";box-shadow:0px 0px 0px 2px ", ";}input:disabled + ", "{cursor:not-allowed;box-shadow:0px 0px 0px 2px ", ";}input:disabled ~ ", "{color:", ";cursor:not-allowed;}"], StyledRadioButton, active, active, StyledRadioButton, gray08, Label, gray06);
82
+ componentId: "sc-gwa7wx-6"
83
+ })(["display:flex;align-items:flex-start;position:relative;cursor:pointer;user-select:none;gap:var(--space-sm,8px);input{position:absolute;opacity:0;z-index:-1;}:hover{input:not(:disabled) + ", "{border-color:var(--color-stroke-darken,#596578);}input:checked + ", "{border-color:var(--color-active-primary,#0075db);}}input:checked + ", "{border-color:var(--color-active-primary,#0075db);:after{content:\"\";position:absolute;top:3px;left:3px;right:3px;bottom:3px;border-radius:var(--radius-circle,50%);background-color:var(--color-active-primary,#0075db);}}input:disabled + ", "{cursor:not-allowed;opacity:0.3;border-color:var(--color-stroke-darken,#596578) !important;:after{background-color:var(--color-stroke-darken,#596578) !important;}}input:disabled ~ ", "{color:var(--color-gray600,#596578);cursor:not-allowed;}"], StyledRadioButton, StyledRadioButton, StyledRadioButton, StyledRadioButton, Label);
41
84
  export default RadioButton;
package/dist/Switch.js CHANGED
@@ -57,14 +57,14 @@ Switch.defaultProps = {
57
57
  };
58
58
  var StyledSwitch = styled.button.withConfig({
59
59
  displayName: "Switch__StyledSwitch",
60
- componentId: "sc-1pn4n4-0"
60
+ componentId: "sc-1v8j4x4-0"
61
61
  })(["all:unset;position:relative;top:0;left:0;right:0;bottom:0;box-sizing:content-box;width:40px;height:20px;background-color:white;border:2px solid ", ";border-radius:13px;transition:0.4s;:before{position:absolute;content:\"\";height:14px;width:14px;left:3px;bottom:3px;border-radius:50%;background-color:", ";transition:0.4s;}&:focus-visible{outline:0;box-shadow:0 0 0 1px ", ";}&:hover{background-color:transparent;}&:active{background-color:transparent;transform:none;box-shadow:none;}"], gray08, gray08, active);
62
62
  var ToggleSwitchWrapper = styled.label.withConfig({
63
63
  displayName: "Switch__ToggleSwitchWrapper",
64
- componentId: "sc-1pn4n4-1"
64
+ componentId: "sc-1v8j4x4-1"
65
65
  })(["display:flex;align-items:center;position:relative;cursor:pointer;line-height:33px;padding:8px 0;input{opacity:0;width:0;height:0;}input:checked + ", "{border:2px solid ", ";}input:checked + ", ":before{transform:translateX(20px);background:", ";}input:disabled + ", "{border-color:", ";&:before{background:", ";}}"], StyledSwitch, active, StyledSwitch, active, StyledSwitch, gray08, gray08);
66
66
  var Label = styled(BodyUI).withConfig({
67
67
  displayName: "Switch__Label",
68
- componentId: "sc-1pn4n4-2"
68
+ componentId: "sc-1v8j4x4-2"
69
69
  })(["margin-left:8px;color:", ";"], gray01);
70
70
  export default Switch;
package/dist/Tag.js CHANGED
@@ -46,14 +46,14 @@ Tag.propTypes = {
46
46
  };
47
47
  var TagWrapper = styled.div.withConfig({
48
48
  displayName: "Tag__TagWrapper",
49
- componentId: "sc-1lpt0c6-0"
49
+ componentId: "sc-1b21q6r-0"
50
50
  })(["display:inline;background:", ";height:24px;width:auto;border-radius:100px;"], active);
51
51
  var IconWrapper = styled.span.withConfig({
52
52
  displayName: "Tag__IconWrapper",
53
- componentId: "sc-1lpt0c6-1"
53
+ componentId: "sc-1b21q6r-1"
54
54
  })(["display:inline-block;position:relative;right:5px;fill:", ";cursor:pointer;padding-right:10px;"], white);
55
55
  var Text = styled(BodyUI).withConfig({
56
56
  displayName: "Tag__Text",
57
- componentId: "sc-1lpt0c6-2"
57
+ componentId: "sc-1b21q6r-2"
58
58
  })(["display:inline-block;position:relative;padding:2px 11.6px 2px 10px;bottom:3px;color:", ";"], white);
59
59
  export default Tag;
package/dist/Textarea.js CHANGED
@@ -75,7 +75,7 @@ Textarea.defaultProps = {
75
75
  };
76
76
  var StyledTextarea = styled.textarea.withConfig({
77
77
  displayName: "Textarea__StyledTextarea",
78
- componentId: "sc-1qfb7cm-0"
78
+ componentId: "sc-15109nt-0"
79
79
  })(["font-family:", ";border-radius:4px;", ";", ";padding:10px 12px;border:solid 1px ", ";box-sizing:border-box;box-shadow:none;font-size:14px;:hover{border-color:", ";}:active{outline:none;border-color:", ";}:focus{outline:none;border-color:", ";}"], sansFamily, function (props) {
80
80
  return props.cols ? "" : "width: 100%;";
81
81
  }, function (props) {
@@ -83,6 +83,6 @@ var StyledTextarea = styled.textarea.withConfig({
83
83
  }, gray06, gray04, active, active);
84
84
  var Label = styled.div.withConfig({
85
85
  displayName: "Textarea__Label",
86
- componentId: "sc-1qfb7cm-1"
86
+ componentId: "sc-15109nt-1"
87
87
  })(["margin:4px 0;"]);
88
88
  export default Textarea;
@@ -183,7 +183,7 @@ var Typeahead = function Typeahead(_ref) {
183
183
  };
184
184
  var Wrapper = styled.div.withConfig({
185
185
  displayName: "Typeahead__Wrapper",
186
- componentId: "sc-16j2d25-0"
186
+ componentId: "sc-1kafn9p-0"
187
187
  })(["width:100%;"]);
188
188
  Typeahead.propTypes = {
189
189
  onQuery: PropTypes.func.isRequired,
@@ -192,7 +192,7 @@ Typeahead.propTypes = {
192
192
  text: PropTypes.string,
193
193
  // If keepResult, this is showed when selecting a result
194
194
  component: PropTypes.element.isRequired,
195
- data: PropTypes.shape.isRequired // Data will be passed with onSelect
195
+ data: PropTypes.any.isRequired // Data will be passed with onSelect
196
196
  })).isRequired,
197
197
  onSelect: PropTypes.func.isRequired,
198
198
  onClear: PropTypes.func,
@@ -14,11 +14,11 @@ var TypeaheadDropdown = function TypeaheadDropdown(_ref) {
14
14
  };
15
15
  var Dropdown = styled.div.withConfig({
16
16
  displayName: "TypeaheadDropdown__Dropdown",
17
- componentId: "sc-c2clla-0"
17
+ componentId: "sc-1qsk6hz-0"
18
18
  })(["position:relative;display:block;width:100%;z-index:1000;"]);
19
19
  var DropdownContent = styled.div.withConfig({
20
20
  displayName: "TypeaheadDropdown__DropdownContent",
21
- componentId: "sc-c2clla-1"
21
+ componentId: "sc-1qsk6hz-1"
22
22
  })(["position:absolute;display:block;width:100%;background:", ";margin-top:8px;padding-top:8px;padding-bottom:8px;box-shadow:", ";border-radius:4px;max-height:", ";overflow-y:auto;"], white, shadow400, function (props) {
23
23
  return props.maxHeight;
24
24
  });
@@ -28,10 +28,10 @@ var TypeaheadList = /*#__PURE__*/React.forwardRef(function (_ref, ref) {
28
28
  });
29
29
  var Container = styled.ul.withConfig({
30
30
  displayName: "TypeaheadList__Container",
31
- componentId: "sc-ce1llk-0"
31
+ componentId: "sc-b2d1n3-0"
32
32
  })(["padding:0px;margin:0px;"]);
33
33
  var Row = styled.li.withConfig({
34
34
  displayName: "TypeaheadList__Row",
35
- componentId: "sc-ce1llk-1"
35
+ componentId: "sc-b2d1n3-1"
36
36
  })(["padding:9px 15px 9px 15px;border:solid 1px transparent;list-style-type:none;cursor:pointer;&:hover{background:", ";}"], toBgLight(active));
37
37
  export default TypeaheadList;
@@ -26,14 +26,14 @@ var TypeaheadMessage = function TypeaheadMessage(_ref) {
26
26
  };
27
27
  var Title = styled(TextEpsilon).withConfig({
28
28
  displayName: "TypeaheadMessage__Title",
29
- componentId: "sc-1yxn5eq-0"
29
+ componentId: "sc-f5kka9-0"
30
30
  })(["text-align:center;margin-bottom:8px;"]);
31
31
  var Details = styled(BodyUI).withConfig({
32
32
  displayName: "TypeaheadMessage__Details",
33
- componentId: "sc-1yxn5eq-1"
33
+ componentId: "sc-f5kka9-1"
34
34
  })(["text-align:center;color:", ";"], gray04);
35
35
  var Flexbox = styled.div.withConfig({
36
36
  displayName: "TypeaheadMessage__Flexbox",
37
- componentId: "sc-1yxn5eq-2"
37
+ componentId: "sc-f5kka9-2"
38
38
  })(["display:flex;flex-direction:column;align-items:center;padding:24px;"]);
39
39
  export default TypeaheadMessage;
package/messages.json ADDED
@@ -0,0 +1 @@
1
+ [{"id":"datePicker.label.date.time.picker","defaultMessage":"Select date"},{"id":"datePicker.label.am","defaultMessage":"AM"},{"id":"datePicker.label.pm","defaultMessage":"PM"},{"id":"datePicker.label.24h","defaultMessage":"24h"},{"id":"datePicker.placeholder.time","defaultMessage":"hh:mm"},{"id":"datePicker.label.time","defaultMessage":"Time"},{"id":"datePicker.message.invalid.time","defaultMessage":"Invalid Time"},{"id":"datePicker.message.formatDescription","defaultMessage":"Provide a date using the format {localeFormat}"},{"id":"datePicker.message.invalid.format","defaultMessage":"Invalid Format"},{"id":"datePicker.message.invalid.not.number","defaultMessage":"Given time is not a number"},{"id":"datePicker.button.prevMonth","defaultMessage":"Previous month"},{"id":"datePicker.button.nextMonth","defaultMessage":"Next month"},{"id":"datePicker.button.selectYear","defaultMessage":"Select year and month"},{"id":"datePicker.dropdown.selectYear","defaultMessage":"Select year"},{"id":"datePicker.button.closeYearMonthPicker","defaultMessage":"Done"}]
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@happeouikit/form-elements",
3
- "version": "2.3.26",
3
+ "version": "2.3.28",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "module": "src/index.js",
@@ -45,5 +45,5 @@
45
45
  "publishConfig": {
46
46
  "access": "public"
47
47
  },
48
- "gitHead": "1c9002847f9ea2b991713f907fd1dc78af386ed2"
48
+ "gitHead": "9e581c37693df95b5fdf2dadaa2117a56ca35b2a"
49
49
  }