@shoplflow/templates 0.1.53 → 0.1.57

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/index.cjs CHANGED
@@ -1621,7 +1621,7 @@ var StyledSeparator = styled2__default.default.div`
1621
1621
  border-radius: 0.5px;
1622
1622
  flex-shrink: 0;
1623
1623
  `;
1624
- var AttachmentItemSingle = ({ item, onClick, onDelete }) => {
1624
+ var AttachmentItemSingle = ({ item, onClick, onDelete, lineClamp = 1 }) => {
1625
1625
  const formatFileSize = (bytes) => {
1626
1626
  if (bytes === 0) {
1627
1627
  return "0 Bytes";
@@ -1640,14 +1640,14 @@ var AttachmentItemSingle = ({ item, onClick, onDelete }) => {
1640
1640
  onClick,
1641
1641
  style: onClick ? { cursor: "pointer" } : void 0,
1642
1642
  children: [
1643
- /* @__PURE__ */ jsxRuntime.jsx(base.Text, { typography: "body2_400", color: "neutral700", lineClamp: 1, textOverflow: "ellipsis", whiteSpace: "nowrap", children: item.name }),
1643
+ /* @__PURE__ */ jsxRuntime.jsx(base.Text, { typography: "body2_400", color: "neutral700", lineClamp, textOverflow: "ellipsis", children: item.name }),
1644
1644
  item.extension && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
1645
1645
  /* @__PURE__ */ jsxRuntime.jsx(StyledSeparator, {}),
1646
1646
  /* @__PURE__ */ jsxRuntime.jsx(base.Text, { typography: "body2_400", color: "neutral400", children: item.extension })
1647
1647
  ] }),
1648
1648
  item.size && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
1649
1649
  /* @__PURE__ */ jsxRuntime.jsx(StyledSeparator, {}),
1650
- /* @__PURE__ */ jsxRuntime.jsx(base.Text, { typography: "body2_400", color: "neutral400", children: formatFileSize(item.size) })
1650
+ /* @__PURE__ */ jsxRuntime.jsx(base.Text, { typography: "body2_400", color: "neutral400", whiteSpace: "nowrap", children: formatFileSize(item.size) })
1651
1651
  ] })
1652
1652
  ]
1653
1653
  }
package/dist/index.d.cts CHANGED
@@ -308,6 +308,7 @@ interface AttachmentItemSingleProps {
308
308
  item: AttachmentItemData;
309
309
  onClick?: (e: React.MouseEvent<HTMLDivElement>) => void;
310
310
  onDelete?: (e: React.MouseEvent<HTMLButtonElement>) => void;
311
+ lineClamp?: number;
311
312
  }
312
313
  interface AttachmentItemMultiProps {
313
314
  item?: AttachmentItemData | null;
package/dist/index.d.ts CHANGED
@@ -308,6 +308,7 @@ interface AttachmentItemSingleProps {
308
308
  item: AttachmentItemData;
309
309
  onClick?: (e: React.MouseEvent<HTMLDivElement>) => void;
310
310
  onDelete?: (e: React.MouseEvent<HTMLButtonElement>) => void;
311
+ lineClamp?: number;
311
312
  }
312
313
  interface AttachmentItemMultiProps {
313
314
  item?: AttachmentItemData | null;
package/dist/index.js CHANGED
@@ -1615,7 +1615,7 @@ var StyledSeparator = styled2.div`
1615
1615
  border-radius: 0.5px;
1616
1616
  flex-shrink: 0;
1617
1617
  `;
1618
- var AttachmentItemSingle = ({ item, onClick, onDelete }) => {
1618
+ var AttachmentItemSingle = ({ item, onClick, onDelete, lineClamp = 1 }) => {
1619
1619
  const formatFileSize = (bytes) => {
1620
1620
  if (bytes === 0) {
1621
1621
  return "0 Bytes";
@@ -1634,14 +1634,14 @@ var AttachmentItemSingle = ({ item, onClick, onDelete }) => {
1634
1634
  onClick,
1635
1635
  style: onClick ? { cursor: "pointer" } : void 0,
1636
1636
  children: [
1637
- /* @__PURE__ */ jsx(Text, { typography: "body2_400", color: "neutral700", lineClamp: 1, textOverflow: "ellipsis", whiteSpace: "nowrap", children: item.name }),
1637
+ /* @__PURE__ */ jsx(Text, { typography: "body2_400", color: "neutral700", lineClamp, textOverflow: "ellipsis", children: item.name }),
1638
1638
  item.extension && /* @__PURE__ */ jsxs(Fragment, { children: [
1639
1639
  /* @__PURE__ */ jsx(StyledSeparator, {}),
1640
1640
  /* @__PURE__ */ jsx(Text, { typography: "body2_400", color: "neutral400", children: item.extension })
1641
1641
  ] }),
1642
1642
  item.size && /* @__PURE__ */ jsxs(Fragment, { children: [
1643
1643
  /* @__PURE__ */ jsx(StyledSeparator, {}),
1644
- /* @__PURE__ */ jsx(Text, { typography: "body2_400", color: "neutral400", children: formatFileSize(item.size) })
1644
+ /* @__PURE__ */ jsx(Text, { typography: "body2_400", color: "neutral400", whiteSpace: "nowrap", children: formatFileSize(item.size) })
1645
1645
  ] })
1646
1646
  ]
1647
1647
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shoplflow/templates",
3
- "version": "0.1.53",
3
+ "version": "0.1.57",
4
4
  "type": "module",
5
5
  "license": "Apache-2.0",
6
6
  "main": "dist/index.js",
@@ -91,10 +91,19 @@
91
91
  "react-datepicker": "^7.3.0",
92
92
  "react-dom": "^18.2.0",
93
93
  "simplebar-react": "^3.2.6",
94
- "@shoplflow/base": "^0.45.2",
95
- "@shoplflow/shopl-assets": "^0.12.27",
96
- "@shoplflow/utils": "^0.7.0",
97
- "@shoplflow/hada-assets": "^0.1.8"
94
+ "@shoplflow/base": "^0.45.6",
95
+ "@shoplflow/hada-assets": "^0.1.10",
96
+ "@shoplflow/shopl-assets": "^0.12.31",
97
+ "@shoplflow/utils": "^0.7.2"
98
+ },
99
+ "repository": {
100
+ "type": "git",
101
+ "url": "https://github.com/shopl/shoplflow",
102
+ "directory": "packages/templates"
103
+ },
104
+ "homepage": "https://github.com/shopl/shoplflow#readme",
105
+ "bugs": {
106
+ "url": "https://github.com/shopl/shoplflow/issues"
98
107
  },
99
108
  "scripts": {
100
109
  "type-check": "tsc --noEmit",