@paubox/ui 0.10.1 → 0.10.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.
Files changed (2) hide show
  1. package/index.esm.js +36 -31
  2. package/package.json +1 -1
package/index.esm.js CHANGED
@@ -1650,7 +1650,7 @@ function _templateObject4$5() {
1650
1650
  };
1651
1651
  return data;
1652
1652
  }
1653
- function _templateObject5$3() {
1653
+ function _templateObject5$4() {
1654
1654
  var data = _tagged_template_literal$p([
1655
1655
  "\n ",
1656
1656
  "\n font-size: ",
@@ -1658,7 +1658,7 @@ function _templateObject5$3() {
1658
1658
  "rem;\n letter-spacing: ",
1659
1659
  "px;\n font-weight: 400;\n"
1660
1660
  ]);
1661
- _templateObject5$3 = function _templateObject() {
1661
+ _templateObject5$4 = function _templateObject() {
1662
1662
  return data;
1663
1663
  };
1664
1664
  return data;
@@ -1929,7 +1929,7 @@ var $headline100Regular = css(_templateObject1$e(), commonStyles, headline100Fon
1929
1929
  var $headline100Semibold = css(_templateObject2$b(), commonStyles, headline100FontSize / BASE_FONT_SIZE, headline100LineHeight / BASE_FONT_SIZE, headline100LetterSpacing);
1930
1930
  var $headline200Regular = css(_templateObject3$8(), commonStyles, headline200FontSize / BASE_FONT_SIZE, headline200LineHeight / BASE_FONT_SIZE, headline200LetterSpacing);
1931
1931
  var $headline200Semibold = css(_templateObject4$5(), commonStyles, headline200FontSize / BASE_FONT_SIZE, headline200LineHeight / BASE_FONT_SIZE, headline200LetterSpacing);
1932
- var $headline300Regular = css(_templateObject5$3(), commonStyles, headline300FontSize / BASE_FONT_SIZE, headline300LineHeight / BASE_FONT_SIZE, headline300LetterSpacing);
1932
+ var $headline300Regular = css(_templateObject5$4(), commonStyles, headline300FontSize / BASE_FONT_SIZE, headline300LineHeight / BASE_FONT_SIZE, headline300LetterSpacing);
1933
1933
  var $headline300Semibold = css(_templateObject6$1(), commonStyles, headline300FontSize / BASE_FONT_SIZE, headline300LineHeight / BASE_FONT_SIZE, headline300LetterSpacing);
1934
1934
  // PARAGRAPH
1935
1935
  var $paragraph100Regular = css(_templateObject7(), commonStyles, paragraph100FontSize / BASE_FONT_SIZE, paragraph100LineHeight / BASE_FONT_SIZE, paragraph100LetterSpacing);
@@ -2090,13 +2090,13 @@ function _templateObject4$4() {
2090
2090
  };
2091
2091
  return data;
2092
2092
  }
2093
- function _templateObject5$2() {
2093
+ function _templateObject5$3() {
2094
2094
  var data = _tagged_template_literal$o([
2095
2095
  "\n background-color: transparent;\n border: none;\n color: ",
2096
2096
  ";\n cursor: pointer;\n padding: 0.25rem;\n font-size: 0.75rem;\n margin-left: ",
2097
2097
  ";\n"
2098
2098
  ]);
2099
- _templateObject5$2 = function _templateObject() {
2099
+ _templateObject5$3 = function _templateObject() {
2100
2100
  return data;
2101
2101
  };
2102
2102
  return data;
@@ -2118,7 +2118,7 @@ var StyledIcon = styled.div(_templateObject3$7(), function(param) {
2118
2118
  return type === 'info' ? primary700 : type === 'error' ? danger700 : type === 'success' ? success700 : warning700;
2119
2119
  });
2120
2120
  var TextWrapper = styled.div(_templateObject4$4());
2121
- var TruncaterButton = styled.button(_templateObject5$2(), primary700, function(param) {
2121
+ var TruncaterButton = styled.button(_templateObject5$3(), primary700, function(param) {
2122
2122
  var isExpanded = param.isExpanded;
2123
2123
  return !isExpanded ? '0' : '0.25rem';
2124
2124
  });
@@ -22266,7 +22266,7 @@ function _templateObject$h() {
22266
22266
  };
22267
22267
  return data;
22268
22268
  }
22269
- var Menu = styled.div(_templateObject$h(), function(param) {
22269
+ var Menu = styled('div')(_templateObject$h(), function(param) {
22270
22270
  var open = param.open;
22271
22271
  return open ? 'flex' : 'none';
22272
22272
  }, textPrimaryWhite, function(param) {
@@ -22328,7 +22328,7 @@ function _tagged_template_literal$g(strings, raw) {
22328
22328
  }
22329
22329
  function _templateObject$g() {
22330
22330
  var data = _tagged_template_literal$g([
22331
- "\n cursor: pointer;\n width: 100%;\n display: flex;\n flex-direction: row;\n align-items: center;\n box-sizing: border-box;\n white-space: nowrap;\n gap: 0.5rem;\n "
22331
+ "\n display: inline-block;\n width: 100%;\n"
22332
22332
  ]);
22333
22333
  _templateObject$g = function _templateObject() {
22334
22334
  return data;
@@ -22337,8 +22337,8 @@ function _templateObject$g() {
22337
22337
  }
22338
22338
  function _templateObject1$b() {
22339
22339
  var data = _tagged_template_literal$g([
22340
- "\n display: flex;\n align-items: center;\n justify-content: center;\n padding: 0 0.5rem;\n &:hover {\n background-color: ",
22341
- ";\n }\n "
22340
+ "\n display: flex;\n align-items: center;\n justify-content: center;\n padding: 0 0.5rem;\n &:hover {\n background-color: ",
22341
+ ";\n }\n"
22342
22342
  ]);
22343
22343
  _templateObject1$b = function _templateObject() {
22344
22344
  return data;
@@ -22347,8 +22347,7 @@ function _templateObject1$b() {
22347
22347
  }
22348
22348
  function _templateObject2$8() {
22349
22349
  var data = _tagged_template_literal$g([
22350
- "\n cursor: pointer;\n background-color: transparent;\n text-align: left;\n border: none;\n padding: 1rem 0.625rem;\n white-space: nowrap;\n width: 100%;\n ",
22351
- "\n "
22350
+ "\n cursor: pointer;\n width: 100%;\n display: flex;\n flex-direction: row;\n align-items: center;\n box-sizing: border-box;\n white-space: nowrap;\n gap: 0.5rem;\n"
22352
22351
  ]);
22353
22352
  _templateObject2$8 = function _templateObject() {
22354
22353
  return data;
@@ -22357,7 +22356,7 @@ function _templateObject2$8() {
22357
22356
  }
22358
22357
  function _templateObject3$6() {
22359
22358
  var data = _tagged_template_literal$g([
22360
- "\n display: flex;\n align-items: center;\n justify-content: center;\n "
22359
+ "\n display: flex;\n align-items: center;\n justify-content: center;\n"
22361
22360
  ]);
22362
22361
  _templateObject3$6 = function _templateObject() {
22363
22362
  return data;
@@ -22366,24 +22365,34 @@ function _templateObject3$6() {
22366
22365
  }
22367
22366
  function _templateObject4$3() {
22368
22367
  var data = _tagged_template_literal$g([
22369
- "\n display: inline-block;\n width: 100%;\n "
22368
+ "\n cursor: pointer;\n background-color: transparent;\n text-align: left;\n border: none;\n padding: 1rem 0.625rem;\n white-space: nowrap;\n width: 100%;\n ",
22369
+ "\n"
22370
22370
  ]);
22371
22371
  _templateObject4$3 = function _templateObject() {
22372
22372
  return data;
22373
22373
  };
22374
22374
  return data;
22375
22375
  }
22376
+ function _templateObject5$2() {
22377
+ var data = _tagged_template_literal$g([
22378
+ "\n ",
22379
+ "\n"
22380
+ ]);
22381
+ _templateObject5$2 = function _templateObject() {
22382
+ return data;
22383
+ };
22384
+ return data;
22385
+ }
22386
+ var DropdownOptionWrapper = styled.div(_templateObject$g());
22387
+ var CheckboxContainer = styled.div(_templateObject1$b(), primary100);
22388
+ var DropdownOptionContainer = styled.div(_templateObject2$8());
22389
+ var IconContainer = styled.div(_templateObject3$6());
22390
+ var StyledOption = styled.button(_templateObject4$3(), $paragraph200Regular);
22391
+ var StyledLink = styled.a(_templateObject5$2(), StyledOption);
22376
22392
  var DropdownOption = function(param) {
22377
22393
  var label = param.label, href = param.href, selected = param.selected, checkbox = param.checkbox, onClick = param.onClick, icon = param.icon;
22378
- var dropdownOptionStyles = css(_templateObject$g());
22379
- var checkboxStyles = css(_templateObject1$b(), primary100);
22380
- var optionStyles = css(_templateObject2$8(), $paragraph200Regular);
22381
- var iconStyles = css(_templateObject3$6());
22382
- var dropdownOptionWrapper = css(_templateObject4$3());
22383
- return /*#__PURE__*/ jsx("div", {
22384
- css: dropdownOptionWrapper,
22385
- children: /*#__PURE__*/ jsxs("div", {
22386
- css: checkboxStyles,
22394
+ return /*#__PURE__*/ jsx(DropdownOptionWrapper, {
22395
+ children: /*#__PURE__*/ jsxs(CheckboxContainer, {
22387
22396
  children: [
22388
22397
  checkbox && /*#__PURE__*/ jsx(Checkbox, {
22389
22398
  checked: selected,
@@ -22391,15 +22400,12 @@ var DropdownOption = function(param) {
22391
22400
  return onClick === null || onClick === void 0 ? void 0 : onClick();
22392
22401
  }
22393
22402
  }),
22394
- /*#__PURE__*/ jsxs("div", {
22395
- css: dropdownOptionStyles,
22403
+ /*#__PURE__*/ jsxs(DropdownOptionContainer, {
22396
22404
  children: [
22397
- icon && /*#__PURE__*/ jsx("div", {
22398
- css: iconStyles,
22405
+ icon && /*#__PURE__*/ jsx(IconContainer, {
22399
22406
  children: icon
22400
22407
  }),
22401
- href ? /*#__PURE__*/ jsx("a", {
22402
- css: optionStyles,
22408
+ href ? /*#__PURE__*/ jsx(StyledLink, {
22403
22409
  href: href,
22404
22410
  onClick: function() {
22405
22411
  return onClick === null || onClick === void 0 ? void 0 : onClick();
@@ -22407,8 +22413,7 @@ var DropdownOption = function(param) {
22407
22413
  children: /*#__PURE__*/ jsx("div", {
22408
22414
  children: label
22409
22415
  })
22410
- }) : /*#__PURE__*/ jsx("button", {
22411
- css: optionStyles,
22416
+ }) : /*#__PURE__*/ jsx(StyledOption, {
22412
22417
  type: "button",
22413
22418
  onClick: function() {
22414
22419
  return onClick === null || onClick === void 0 ? void 0 : onClick();
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@paubox/ui",
3
3
  "author": "Paubox, Inc.",
4
4
  "description": "Paubox Component Library",
5
- "version": "0.10.1",
5
+ "version": "0.10.2",
6
6
  "type": "module",
7
7
  "private": false,
8
8
  "publishConfig": {