@justeattakeaway/pie-assistive-text 0.2.4 → 0.3.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.
- package/package.json +10 -5
- package/src/react.ts +19 -0
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@justeattakeaway/pie-assistive-text",
|
|
3
3
|
"description": "PIE Design System Assistive Text built using Web Components",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.3.1",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
7
|
"module": "dist/index.js",
|
|
@@ -12,8 +12,12 @@
|
|
|
12
12
|
"dist",
|
|
13
13
|
"**/*.d.ts"
|
|
14
14
|
],
|
|
15
|
+
"pieMetadata": {
|
|
16
|
+
"componentStatus": "alpha"
|
|
17
|
+
},
|
|
15
18
|
"scripts": {
|
|
16
|
-
"build": "
|
|
19
|
+
"build": "run -T vite build",
|
|
20
|
+
"build:react-wrapper": "npx build-react-wrapper",
|
|
17
21
|
"create:manifest": "yarn cem analyze --litelement",
|
|
18
22
|
"lint:scripts": "run -T eslint .",
|
|
19
23
|
"lint:scripts:fix": "yarn lint:scripts --fix",
|
|
@@ -22,6 +26,7 @@
|
|
|
22
26
|
"watch": "run -T vite build --watch",
|
|
23
27
|
"test": "echo \"Error: no test specified\" && exit 0",
|
|
24
28
|
"test:ci": "yarn test",
|
|
29
|
+
"test:browsers-setup": "npx playwright-lit-setup",
|
|
25
30
|
"test:browsers": "npx playwright test -c ./playwright-lit.config.ts",
|
|
26
31
|
"test:browsers:ci": "yarn test:browsers",
|
|
27
32
|
"test:visual": "run -T cross-env-shell PERCY_TOKEN=${PERCY_TOKEN_PIE_ASSISTIVE_TEXT} percy exec --allowed-hostname cloudfront.net -- npx playwright test -c ./playwright-lit-visual.config.ts",
|
|
@@ -31,12 +36,12 @@
|
|
|
31
36
|
"license": "Apache-2.0",
|
|
32
37
|
"devDependencies": {
|
|
33
38
|
"@custom-elements-manifest/analyzer": "0.9.0",
|
|
34
|
-
"@justeattakeaway/pie-components-config": "0.
|
|
39
|
+
"@justeattakeaway/pie-components-config": "0.14.0",
|
|
35
40
|
"cem-plugin-module-file-extensions": "0.0.5"
|
|
36
41
|
},
|
|
37
42
|
"dependencies": {
|
|
38
|
-
"@justeattakeaway/pie-icons-webc": "0.
|
|
39
|
-
"@justeattakeaway/pie-webc-core": "0.
|
|
43
|
+
"@justeattakeaway/pie-icons-webc": "0.20.0",
|
|
44
|
+
"@justeattakeaway/pie-webc-core": "0.20.0"
|
|
40
45
|
},
|
|
41
46
|
"volta": {
|
|
42
47
|
"extends": "../../../package.json"
|
package/src/react.ts
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { createComponent } from '@lit/react';
|
|
3
|
+
import { PieAssistiveText as PieAssistiveTextLit } from './index';
|
|
4
|
+
import { AssistiveTextProps } from './defs';
|
|
5
|
+
|
|
6
|
+
export * from './defs';
|
|
7
|
+
|
|
8
|
+
const PieAssistiveTextReact = createComponent({
|
|
9
|
+
displayName: 'PieAssistiveText',
|
|
10
|
+
elementClass: PieAssistiveTextLit,
|
|
11
|
+
react: React,
|
|
12
|
+
tagName: 'pie-assistive-text',
|
|
13
|
+
events: {},
|
|
14
|
+
});
|
|
15
|
+
|
|
16
|
+
type ReactBaseType = React.HTMLAttributes<HTMLElement>
|
|
17
|
+
|
|
18
|
+
export const PieAssistiveText = PieAssistiveTextReact as React.ForwardRefExoticComponent<React.PropsWithoutRef<AssistiveTextProps>
|
|
19
|
+
& React.RefAttributes<PieAssistiveTextLit> & ReactBaseType>;
|