@atlaskit/heading 0.1.16 → 0.1.18
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/CHANGELOG.md +12 -0
- package/dist/cjs/heading.js +2 -1
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/heading.js +2 -1
- package/dist/es2019/version.json +1 -1
- package/dist/esm/heading.js +2 -1
- package/dist/esm/version.json +1 -1
- package/dist/types-ts4.0/heading.d.ts +20 -0
- package/dist/types-ts4.0/index.d.ts +2 -0
- package/dist/types-ts4.0/types.d.ts +26 -0
- package/dist/types-ts4.0/utils.d.ts +1 -0
- package/package.json +13 -3
- package/report.api.md +31 -50
- package/tmp/api-report-tmp.d.ts +26 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @atlaskit/heading
|
|
2
2
|
|
|
3
|
+
## 0.1.18
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`bc989043572`](https://bitbucket.org/atlassian/atlassian-frontend/commits/bc989043572) - Internal changes to apply spacing tokens. This should be a no-op change.
|
|
8
|
+
|
|
9
|
+
## 0.1.17
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [`8cc2f888c83`](https://bitbucket.org/atlassian/atlassian-frontend/commits/8cc2f888c83) - Upgrade Typescript from `4.3.5` to `4.5.5`
|
|
14
|
+
|
|
3
15
|
## 0.1.16
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
package/dist/cjs/heading.js
CHANGED
|
@@ -26,7 +26,8 @@ var levelMap = {
|
|
|
26
26
|
h100: 'div'
|
|
27
27
|
};
|
|
28
28
|
var headingResetStyles = (0, _react.css)({
|
|
29
|
-
|
|
29
|
+
// TODO Delete this comment after verifying spacing token -> previous value `0`
|
|
30
|
+
margin: "var(--ds-scale-0, 0px)"
|
|
30
31
|
});
|
|
31
32
|
var h900Styles = (0, _react.css)({
|
|
32
33
|
fontSize: 35,
|
package/dist/cjs/version.json
CHANGED
package/dist/es2019/heading.js
CHANGED
|
@@ -16,7 +16,8 @@ const levelMap = {
|
|
|
16
16
|
h100: 'div'
|
|
17
17
|
};
|
|
18
18
|
const headingResetStyles = css({
|
|
19
|
-
|
|
19
|
+
// TODO Delete this comment after verifying spacing token -> previous value `0`
|
|
20
|
+
margin: "var(--ds-scale-0, 0px)"
|
|
20
21
|
});
|
|
21
22
|
const h900Styles = css({
|
|
22
23
|
fontSize: 35,
|
package/dist/es2019/version.json
CHANGED
package/dist/esm/heading.js
CHANGED
package/dist/esm/version.json
CHANGED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/** @jsx jsx */
|
|
2
|
+
import { FC } from 'react';
|
|
3
|
+
import type { HeadingProps } from './types';
|
|
4
|
+
/**
|
|
5
|
+
* __Heading__
|
|
6
|
+
*
|
|
7
|
+
* A heading is a typography component used to display text in different sizes and formats.
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
*
|
|
11
|
+
* ```jsx
|
|
12
|
+
* import Heading from '@atlaskit/heading';
|
|
13
|
+
*
|
|
14
|
+
* const H100 = () => (
|
|
15
|
+
* <Heading level="h100">h100</Heading>
|
|
16
|
+
* );
|
|
17
|
+
* ```
|
|
18
|
+
*/
|
|
19
|
+
declare const Heading: FC<HeadingProps>;
|
|
20
|
+
export default Heading;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
export declare type HeadingProps = {
|
|
3
|
+
/**
|
|
4
|
+
* A `testId` prop is provided for specified elements, which is a unique
|
|
5
|
+
* string that appears as a data attribute `data-testid` in the rendered code,
|
|
6
|
+
* serving as a hook for automated tests
|
|
7
|
+
*/
|
|
8
|
+
testId?: string;
|
|
9
|
+
/**
|
|
10
|
+
* The text of the heading
|
|
11
|
+
*/
|
|
12
|
+
children: ReactNode;
|
|
13
|
+
/**
|
|
14
|
+
* The headling level as defined by by the ADG
|
|
15
|
+
*/
|
|
16
|
+
level: 'h900' | 'h800' | 'h700' | 'h600' | 'h500' | 'h400' | 'h300' | 'h200' | 'h100';
|
|
17
|
+
id?: string;
|
|
18
|
+
/**
|
|
19
|
+
* Allows the component to be rendered as the specified DOM Element
|
|
20
|
+
*/
|
|
21
|
+
as?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'div' | 'span';
|
|
22
|
+
/**
|
|
23
|
+
* Text color of the heading.
|
|
24
|
+
*/
|
|
25
|
+
color?: 'inverse' | 'default';
|
|
26
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const lh: (sizePx: number, lineHeightPx: number) => number;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/heading",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.18",
|
|
4
4
|
"description": "A heading is a typography component used to display text in different sizes and formats.",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|
"registry": "https://registry.npmjs.org/"
|
|
9
9
|
},
|
|
10
10
|
"atlassian": {
|
|
11
|
+
"disableProductCI": true,
|
|
11
12
|
"team": "Design System Team",
|
|
12
13
|
"releaseModel": "continuous",
|
|
13
14
|
"website": {
|
|
@@ -20,6 +21,14 @@
|
|
|
20
21
|
"module": "dist/esm/index.js",
|
|
21
22
|
"module:es2019": "dist/es2019/index.js",
|
|
22
23
|
"types": "dist/types/index.d.ts",
|
|
24
|
+
"typesVersions": {
|
|
25
|
+
">=4.0 <4.5": {
|
|
26
|
+
"*": [
|
|
27
|
+
"dist/types-ts4.0/*",
|
|
28
|
+
"dist/types-ts4.0/index.d.ts"
|
|
29
|
+
]
|
|
30
|
+
}
|
|
31
|
+
},
|
|
23
32
|
"sideEffects": false,
|
|
24
33
|
"atlaskit:src": "src/index.tsx",
|
|
25
34
|
"af:exports": {
|
|
@@ -42,9 +51,9 @@
|
|
|
42
51
|
"@atlaskit/visual-regression": "*",
|
|
43
52
|
"@atlaskit/webdriver-runner": "*",
|
|
44
53
|
"@atlassian/atlassian-frontend-prettier-config-1.0.0": "npm:@atlassian/atlassian-frontend-prettier-config@1.0.0",
|
|
45
|
-
"@testing-library/react": "^
|
|
54
|
+
"@testing-library/react": "^12.1.5",
|
|
46
55
|
"react-dom": "^16.8.0",
|
|
47
|
-
"typescript": "4.
|
|
56
|
+
"typescript": "4.5.5",
|
|
48
57
|
"wait-for-expect": "^1.2.0"
|
|
49
58
|
},
|
|
50
59
|
"techstack": {
|
|
@@ -61,6 +70,7 @@
|
|
|
61
70
|
],
|
|
62
71
|
"ui-components": "lite-mode",
|
|
63
72
|
"analytics": "analytics-next",
|
|
73
|
+
"design-tokens": "spacing",
|
|
64
74
|
"theming": "tokens",
|
|
65
75
|
"deprecation": "no-deprecated-imports"
|
|
66
76
|
}
|
package/report.api.md
CHANGED
|
@@ -1,65 +1,46 @@
|
|
|
1
|
-
|
|
1
|
+
<!-- API Report Version: 2.3 -->
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
## API Report File for "@atlaskit/heading"
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
> Do not edit this file. This report is auto-generated using [API Extractor](https://api-extractor.com/).
|
|
6
|
+
> [Learn more about API reports](https://hello.atlassian.net/wiki/spaces/UR/pages/1825484529/Package+API+Reports)
|
|
6
7
|
|
|
7
|
-
|
|
8
|
+
### Table of contents
|
|
9
|
+
|
|
10
|
+
- [Main Entry Types](#main-entry-types)
|
|
11
|
+
|
|
12
|
+
### Main Entry Types
|
|
13
|
+
|
|
14
|
+
<!--SECTION START: Main Entry Types-->
|
|
15
|
+
|
|
16
|
+
```ts
|
|
8
17
|
import { FC } from 'react';
|
|
9
18
|
import { ReactNode } from 'react';
|
|
10
19
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
*
|
|
14
|
-
* A heading is a typography component used to display text in different sizes and formats.
|
|
15
|
-
*
|
|
16
|
-
* @example
|
|
17
|
-
*
|
|
18
|
-
* ```jsx
|
|
19
|
-
* import Heading from '@atlaskit/heading';
|
|
20
|
-
*
|
|
21
|
-
* const H100 = () => (
|
|
22
|
-
* <Heading level="h100">h100</Heading>
|
|
23
|
-
* );
|
|
24
|
-
* ```
|
|
25
|
-
*/
|
|
26
|
-
declare const Heading: FC<HeadingProps>;
|
|
20
|
+
// @public
|
|
21
|
+
const Heading: FC<HeadingProps>;
|
|
27
22
|
export default Heading;
|
|
28
23
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
* A `testId` prop is provided for specified elements, which is a unique
|
|
32
|
-
* string that appears as a data attribute `data-testid` in the rendered code,
|
|
33
|
-
* serving as a hook for automated tests
|
|
34
|
-
*/
|
|
24
|
+
// @public (undocumented)
|
|
25
|
+
export type HeadingProps = {
|
|
35
26
|
testId?: string;
|
|
36
|
-
/**
|
|
37
|
-
* The text of the heading
|
|
38
|
-
*/
|
|
39
27
|
children: ReactNode;
|
|
40
|
-
/**
|
|
41
|
-
* The headling level as defined by by the ADG
|
|
42
|
-
*/
|
|
43
28
|
level:
|
|
44
|
-
| '
|
|
45
|
-
| 'h800'
|
|
46
|
-
| 'h700'
|
|
47
|
-
| 'h600'
|
|
48
|
-
| 'h500'
|
|
49
|
-
| 'h400'
|
|
50
|
-
| 'h300'
|
|
29
|
+
| 'h100'
|
|
51
30
|
| 'h200'
|
|
52
|
-
| '
|
|
31
|
+
| 'h300'
|
|
32
|
+
| 'h400'
|
|
33
|
+
| 'h500'
|
|
34
|
+
| 'h600'
|
|
35
|
+
| 'h700'
|
|
36
|
+
| 'h800'
|
|
37
|
+
| 'h900';
|
|
53
38
|
id?: string;
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
*/
|
|
57
|
-
as?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'div' | 'span';
|
|
58
|
-
/**
|
|
59
|
-
* Text color of the heading.
|
|
60
|
-
*/
|
|
61
|
-
color?: 'inverse' | 'default';
|
|
39
|
+
as?: 'div' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'span';
|
|
40
|
+
color?: 'default' | 'inverse';
|
|
62
41
|
};
|
|
63
42
|
|
|
64
|
-
|
|
65
|
-
|
|
43
|
+
// (No @packageDocumentation comment for this package)
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
<!--SECTION END: Main Entry Types-->
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
## API Report File for "@atlaskit/heading"
|
|
2
|
+
|
|
3
|
+
> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
|
|
4
|
+
|
|
5
|
+
```ts
|
|
6
|
+
|
|
7
|
+
import { FC } from 'react';
|
|
8
|
+
import { ReactNode } from 'react';
|
|
9
|
+
|
|
10
|
+
// @public
|
|
11
|
+
const Heading: FC<HeadingProps>;
|
|
12
|
+
export default Heading;
|
|
13
|
+
|
|
14
|
+
// @public (undocumented)
|
|
15
|
+
export type HeadingProps = {
|
|
16
|
+
testId?: string;
|
|
17
|
+
children: ReactNode;
|
|
18
|
+
level: 'h100' | 'h200' | 'h300' | 'h400' | 'h500' | 'h600' | 'h700' | 'h800' | 'h900';
|
|
19
|
+
id?: string;
|
|
20
|
+
as?: 'div' | 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'span';
|
|
21
|
+
color?: 'default' | 'inverse';
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
// (No @packageDocumentation comment for this package)
|
|
25
|
+
|
|
26
|
+
```
|