techsbcn-storybook 0.24.0 → 0.24.1

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.
@@ -45,7 +45,8 @@ interface ColumnProps {
45
45
  noSort?: boolean;
46
46
  isPrice?: boolean;
47
47
  priceFormat?: {
48
- currency?: string;
48
+ currencyStart?: string;
49
+ currencyEnd?: string;
49
50
  };
50
51
  isImage?: {
51
52
  isUrl?: boolean;
@@ -541,7 +541,7 @@ var TableComponent = function TableComponent(props) {
541
541
  };
542
542
 
543
543
  var formatValue = function formatValue(value, column) {
544
- var _column$enumColumn;
544
+ var _column$enumColumn, _column$priceFormat$c, _column$priceFormat, _column$priceFormat2, _column$priceFormat$c2, _column$priceFormat3;
545
545
 
546
546
  if ((_column$enumColumn = column.enumColumn) != null && _column$enumColumn.isEnum) {
547
547
  var _column$enumColumn2, _column$enumColumn9;
@@ -581,7 +581,7 @@ var TableComponent = function TableComponent(props) {
581
581
  }
582
582
 
583
583
  if (column.isDate && value) return dayjs.utc(value).tz(dayjs.tz.guess()).format('L');
584
- if (column.isPrice && value) return Number(value).toFixed(2).replace('.', ',').toLocaleString().replace(/(\d)(?=(\d{3})+(?!\d))/g, '$1.') + " " + props.values.SYMBOL_EURO;
584
+ if (column.isPrice && value) return "" + ((_column$priceFormat$c = (_column$priceFormat = column.priceFormat) == null ? void 0 : _column$priceFormat.currencyStart) != null ? _column$priceFormat$c : '') + Number(value).toFixed(2).replace('.', ',').toLocaleString().replace(/(\d)(?=(\d{3})+(?!\d))/g, '$1.') + " " + (!((_column$priceFormat2 = column.priceFormat) != null && _column$priceFormat2.currencyStart) ? (_column$priceFormat$c2 = (_column$priceFormat3 = column.priceFormat) == null ? void 0 : _column$priceFormat3.currencyEnd) != null ? _column$priceFormat$c2 : props.values.SYMBOL_EURO : '');
585
585
 
586
586
  if (column.isImage && value) {
587
587
  if (column.isImage.isUrl) {
@@ -1627,7 +1627,7 @@ ButtonComponent.defaultProps = {
1627
1627
  component: 'button'
1628
1628
  };
1629
1629
 
1630
- var css_248z$e = ".text-simple-component .MuiFormLabel-root {\n color: #666666;\n font-size: 1rem !important;\n transform: translate(0, 0.5px) scale(0.85);\n transform-origin: top left;\n text-overflow: initial !important;\n}\n.text-simple-component .MuiFormLabel-root + .text-simple-box {\n margin-top: 2px;\n}\n.text-simple-component .MuiFormLabel-root + .text-simple-box.no-border {\n margin-top: 15px !important;\n}\n.text-simple-component .MuiFormLabel-root + .text-simple-box.no-margin.no-border {\n margin-top: 7px !important;\n}\n.text-simple-component .text-simple-box.in-center.label-margin {\n margin-top: 38px !important;\n}\n.text-simple-component .MuiFormLabel-root + .text-simple-box.in-center {\n margin-top: 15px !important;\n}\n.text-simple-component .text-simple-box.label-margin {\n margin-top: 25px !important;\n}\n.text-simple-component .text-simple-box.in-center {\n margin-top: 10px !important;\n}\n.text-simple-component .text-simple-box.no-border {\n border: none !important;\n padding: 0 !important;\n}\n.text-simple-component .text-simple-box {\n color: #666666;\n font-size: 14px;\n border: 1px solid grey;\n border-radius: 3px !important;\n padding: 0.611rem 0.87rem;\n line-height: 1.4375em;\n letter-spacing: 0.00938em;\n}\n.text-simple-component .text-simple-box.icon-padding {\n padding: 0.49rem 0.87rem;\n}\n.text-simple-component .text-simple-box.end-icon-padding {\n padding: 0.177rem 0.87rem;\n}\n.text-simple-component .helper-text {\n font-size: 0.85rem !important;\n padding: 0 !important;\n margin-top: 3px;\n line-height: 1.66;\n color: #666666 !important;\n letter-spacing: 0.03333em;\n}\n.text-simple-component .helper-text.no-border {\n margin-top: 12px;\n}\n.text-simple-component .has-error-border {\n border-color: #F24726 !important;\n}\n.text-simple-component .has-error {\n color: #F24726 !important;\n}";
1630
+ var css_248z$e = ".text-simple-component .MuiFormLabel-root {\n color: #666666;\n font-size: 1rem !important;\n transform: translate(0, 0.5px) scale(0.85);\n transform-origin: top left;\n text-overflow: initial !important;\n}\n.text-simple-component .MuiFormLabel-root + .text-simple-box {\n margin-top: 2px;\n}\n.text-simple-component .MuiFormLabel-root + .text-simple-box.no-margin.no-border {\n margin-top: 7px !important;\n}\n.text-simple-component .text-simple-box.in-center.label-margin {\n margin-top: 38px !important;\n}\n.text-simple-component .MuiFormLabel-root + .text-simple-box.in-center {\n margin-top: 15px !important;\n}\n.text-simple-component .text-simple-box.label-margin {\n margin-top: 25px !important;\n}\n.text-simple-component .text-simple-box.in-center {\n margin-top: 10px !important;\n}\n.text-simple-component .text-simple-box.no-border {\n border: none !important;\n padding: 0 !important;\n}\n.text-simple-component .text-simple-box {\n color: #666666;\n font-size: 14px;\n border: 1px solid grey;\n border-radius: 3px !important;\n padding: 0.611rem 0.87rem;\n line-height: 1.4375em;\n letter-spacing: 0.00938em;\n}\n.text-simple-component .text-simple-box.icon-padding {\n padding: 0.49rem 0.87rem;\n}\n.text-simple-component .text-simple-box.end-icon-padding {\n padding: 0.177rem 0.87rem;\n}\n.text-simple-component .helper-text {\n font-size: 0.85rem !important;\n padding: 0 !important;\n margin-top: 3px;\n line-height: 1.66;\n color: #666666 !important;\n letter-spacing: 0.03333em;\n}\n.text-simple-component .helper-text.no-border {\n margin-top: 12px;\n}\n.text-simple-component .has-error-border {\n border-color: #F24726 !important;\n}\n.text-simple-component .has-error {\n color: #F24726 !important;\n}";
1631
1631
  styleInject(css_248z$e);
1632
1632
 
1633
1633
  var TextSimpleComponent = function TextSimpleComponent(props) {