@cambly/syntax-core 9.2.0 → 9.3.0
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.d.ts +5 -1
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +2 -0
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -651,7 +651,7 @@ declare namespace Divider {
|
|
|
651
651
|
/**
|
|
652
652
|
* [Heading](https://cambly-syntax.vercel.app/?path=/docs/components-heading--docs) enforces a consistent style & accessibility best practices for headings.
|
|
653
653
|
*/
|
|
654
|
-
declare const Heading: ({ align, as, children, color, "data-testid": dataTestId, size, }: {
|
|
654
|
+
declare const Heading: ({ align, as, children, color, "data-testid": dataTestId, lineClamp, size, }: {
|
|
655
655
|
/**
|
|
656
656
|
* Aligns the text to the left, right, or center of the container.
|
|
657
657
|
* * `start` and `end` will align the text to the left or right of the container depending on the locale.
|
|
@@ -680,6 +680,10 @@ declare const Heading: ({ align, as, children, color, "data-testid": dataTestId,
|
|
|
680
680
|
* Test id for the text.
|
|
681
681
|
*/
|
|
682
682
|
"data-testid"?: string | undefined;
|
|
683
|
+
/**
|
|
684
|
+
* The number of lines we should truncate the text at
|
|
685
|
+
*/
|
|
686
|
+
lineClamp?: number | undefined;
|
|
683
687
|
/**
|
|
684
688
|
* Size of the text.
|
|
685
689
|
*
|
package/dist/index.js
CHANGED
|
@@ -981,6 +981,7 @@ var Heading = ({
|
|
|
981
981
|
children,
|
|
982
982
|
color = "gray900",
|
|
983
983
|
"data-testid": dataTestId,
|
|
984
|
+
lineClamp,
|
|
984
985
|
size = 500
|
|
985
986
|
}) => {
|
|
986
987
|
const weight = [700, 800].includes(size) ? "heavy" : "bold";
|
|
@@ -991,6 +992,7 @@ var Heading = ({
|
|
|
991
992
|
as,
|
|
992
993
|
color,
|
|
993
994
|
"data-testid": dataTestId,
|
|
995
|
+
lineClamp,
|
|
994
996
|
size,
|
|
995
997
|
weight,
|
|
996
998
|
children
|