@expo/html-elements 0.2.2 → 0.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/babel.js +10 -2
- package/build/elements/Anchor.d.ts.map +1 -1
- package/build/elements/Anchor.js +6 -2
- package/build/elements/Anchor.js.map +1 -1
- package/build/elements/Headings.js +1 -1
- package/build/elements/Headings.js.map +1 -1
- package/build/elements/Lists.d.ts +1 -1
- package/build/elements/Lists.d.ts.map +1 -1
- package/build/elements/Text.d.ts +1 -1
- package/build/elements/Text.d.ts.map +1 -1
- package/build/elements/Text.types.d.ts +8 -4
- package/build/elements/Text.types.d.ts.map +1 -1
- package/build/elements/Text.types.js.map +1 -1
- package/build/primitives/Table.d.ts +2 -2
- package/build/primitives/Table.d.ts.map +1 -1
- package/build/primitives/Text.d.ts +23 -5
- package/build/primitives/Text.d.ts.map +1 -1
- package/build/primitives/Text.js.map +1 -1
- package/build/primitives/View.d.ts +4 -4
- package/build/primitives/View.d.ts.map +1 -1
- package/build/primitives/View.js.map +1 -1
- package/package.json +2 -3
package/babel.js
CHANGED
|
@@ -76,11 +76,11 @@ module.exports = ({ types: t }, { expo }) => {
|
|
|
76
76
|
const importDeclarationVisitor = {
|
|
77
77
|
ImportDeclaration(path, state) {
|
|
78
78
|
if (path.get('source').isStringLiteral({ value: '@expo/html-elements' })) {
|
|
79
|
-
state.replacedComponents.forEach(component => {
|
|
79
|
+
state.replacedComponents.forEach((component) => {
|
|
80
80
|
if (
|
|
81
81
|
path
|
|
82
82
|
.get('specifiers')
|
|
83
|
-
.some(specifier => specifier.get('local').isIdentifier({ name: component }))
|
|
83
|
+
.some((specifier) => specifier.get('local').isIdentifier({ name: component }))
|
|
84
84
|
) {
|
|
85
85
|
return;
|
|
86
86
|
}
|
|
@@ -93,6 +93,7 @@ module.exports = ({ types: t }, { expo }) => {
|
|
|
93
93
|
},
|
|
94
94
|
};
|
|
95
95
|
|
|
96
|
+
const source = '@expo/html-elements';
|
|
96
97
|
return {
|
|
97
98
|
name: 'Rewrite React DOM to universal Expo elements',
|
|
98
99
|
visitor: {
|
|
@@ -101,6 +102,13 @@ module.exports = ({ types: t }, { expo }) => {
|
|
|
101
102
|
state.unsupportedComponents = new Set();
|
|
102
103
|
|
|
103
104
|
path.traverse(htmlElementVisitor, state);
|
|
105
|
+
|
|
106
|
+
// If state.replacedComponents is not empty, then ensure `import { ... } from '@expo/html-elements'` is present
|
|
107
|
+
if (state.replacedComponents.size > 0) {
|
|
108
|
+
const importDeclaration = t.importDeclaration([], t.stringLiteral(source));
|
|
109
|
+
path.unshiftContainer('body', importDeclaration);
|
|
110
|
+
}
|
|
111
|
+
|
|
104
112
|
path.traverse(importDeclarationVisitor, state);
|
|
105
113
|
},
|
|
106
114
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Anchor.d.ts","sourceRoot":"","sources":["../../src/elements/Anchor.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoC,MAAM,OAAO,CAAC;AAIzD,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEzC,eAAO,MAAM,CAAC,
|
|
1
|
+
{"version":3,"file":"Anchor.d.ts","sourceRoot":"","sources":["../../src/elements/Anchor.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoC,MAAM,OAAO,CAAC;AAIzD,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEzC,eAAO,MAAM,CAAC,gCAoBgB,CAAC"}
|
package/build/elements/Anchor.js
CHANGED
|
@@ -1,11 +1,15 @@
|
|
|
1
1
|
import React, { forwardRef } from 'react';
|
|
2
2
|
import { Linking, Platform } from 'react-native';
|
|
3
3
|
import Text from '../primitives/Text';
|
|
4
|
-
export const A = forwardRef(({ href, target, ...props }, ref) => {
|
|
4
|
+
export const A = forwardRef(({ href, target, download, rel, ...props }, ref) => {
|
|
5
5
|
const nativeProps = Platform.select({
|
|
6
6
|
web: {
|
|
7
7
|
href,
|
|
8
|
-
|
|
8
|
+
hrefAttrs: {
|
|
9
|
+
target,
|
|
10
|
+
download,
|
|
11
|
+
rel,
|
|
12
|
+
},
|
|
9
13
|
},
|
|
10
14
|
default: {
|
|
11
15
|
onPress: (event) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Anchor.js","sourceRoot":"","sources":["../../src/elements/Anchor.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAiB,UAAU,EAAE,MAAM,OAAO,CAAC;AACzD,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AAEjD,OAAO,IAAI,MAAM,oBAAoB,CAAC;AAGtC,MAAM,CAAC,MAAM,CAAC,GAAG,UAAU,CAAC,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,GAAG,KAAK,EAAa,EAAE,GAAG,EAAE,EAAE;
|
|
1
|
+
{"version":3,"file":"Anchor.js","sourceRoot":"","sources":["../../src/elements/Anchor.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAiB,UAAU,EAAE,MAAM,OAAO,CAAC;AACzD,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AAEjD,OAAO,IAAI,MAAM,oBAAoB,CAAC;AAGtC,MAAM,CAAC,MAAM,CAAC,GAAG,UAAU,CAAC,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,GAAG,EAAE,GAAG,KAAK,EAAa,EAAE,GAAG,EAAE,EAAE;IACxF,MAAM,WAAW,GAAG,QAAQ,CAAC,MAAM,CAAY;QAC7C,GAAG,EAAE;YACH,IAAI;YACJ,SAAS,EAAE;gBACT,MAAM;gBACN,QAAQ;gBACR,GAAG;aACJ;SACF;QACD,OAAO,EAAE;YACP,OAAO,EAAE,CAAC,KAAK,EAAE,EAAE;gBACjB,KAAK,CAAC,OAAO,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;gBACtC,IAAI,QAAQ,CAAC,EAAE,KAAK,KAAK,IAAI,IAAI,KAAK,SAAS,EAAE;oBAC/C,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;iBACvB;YACH,CAAC;SACF;KACF,CAAC,CAAC;IACH,OAAO,oBAAC,IAAI,IAAC,iBAAiB,EAAC,MAAM,KAAK,KAAK,KAAM,WAAW,EAAE,GAAG,EAAE,GAAG,GAAI,CAAC;AACjF,CAAC,CAA6B,CAAC","sourcesContent":["import React, { ComponentType, forwardRef } from 'react';\nimport { Linking, Platform } from 'react-native';\n\nimport Text from '../primitives/Text';\nimport { LinkProps } from './Text.types';\n\nexport const A = forwardRef(({ href, target, download, rel, ...props }: LinkProps, ref) => {\n const nativeProps = Platform.select<LinkProps>({\n web: {\n href,\n hrefAttrs: {\n target,\n download,\n rel,\n },\n },\n default: {\n onPress: (event) => {\n props.onPress && props.onPress(event);\n if (Platform.OS !== 'web' && href !== undefined) {\n Linking.openURL(href);\n }\n },\n },\n });\n return <Text accessibilityRole=\"link\" {...props} {...nativeProps} ref={ref} />;\n}) as ComponentType<LinkProps>;\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Headings.js","sourceRoot":"","sources":["../../src/elements/Headings.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAiB,UAAU,EAAE,MAAM,OAAO,CAAC;AACzD,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAEpD,OAAO,EAAE,EAAE,EAAE,MAAM,cAAc,CAAC;AAClC,OAAO,IAAmB,MAAM,oBAAoB,CAAC;AAErD,SAAS,sBAAsB,CAAC,KAAa;IAC3C,MAAM,WAAW,GAAQ,QAAQ,CAAC,MAAM,CAAC;QACvC,GAAG,EAAE;YACH,
|
|
1
|
+
{"version":3,"file":"Headings.js","sourceRoot":"","sources":["../../src/elements/Headings.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAiB,UAAU,EAAE,MAAM,O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UAAU,EAAE,MAAM;KACnB;IACD,EAAE,EAAE;QACF,QAAQ,EAAE,EAAE,CAAC,GAAG,CAAC;QACjB,cAAc,EAAE,EAAE,CAAC,IAAI,CAAC;QACxB,UAAU,EAAE,MAAM;KACnB;IACD,EAAE,EAAE;QACF,QAAQ,EAAE,EAAE,CAAC,IAAI,CAAC;QAClB,cAAc,EAAE,EAAE,CAAC,CAAC,CAAC;QACrB,UAAU,EAAE,MAAM;KACnB;IACD,EAAE,EAAE;QACF,QAAQ,EAAE,EAAE,CAAC,CAAC,CAAC;QACf,cAAc,EAAE,EAAE,CAAC,IAAI,CAAC;QACxB,UAAU,EAAE,MAAM;KACnB;IACD,EAAE,EAAE;QACF,QAAQ,EAAE,EAAE,CAAC,IAAI,CAAC;QAClB,cAAc,EAAE,EAAE,CAAC,IAAI,CAAC;QACxB,UAAU,EAAE,MAAM;KACnB;IACD,EAAE,EAAE;QACF,QAAQ,EAAE,EAAE,CAAC,IAAI,CAAC;QAClB,cAAc,EAAE,EAAE,CAAC,IAAI,CAAC;QACxB,UAAU,EAAE,MAAM;KACnB;CACF,CAAC,CAAC","sourcesContent":["import React, { ComponentType, forwardRef } from 'react';\nimport { Platform, StyleSheet } from 'react-native';\n\nimport { em } from '../css/units';\nimport Text, { TextProps } from '../primitives/Text';\n\nfunction createHeadingComponent(level: number): ComponentType<TextProps> {\n const nativeProps: any = Platform.select({\n web: {\n accessibilityLevel: level,\n },\n default: {},\n });\n return forwardRef((props: TextProps, ref) => {\n return (\n <Text\n {...nativeProps}\n accessibilityRole=\"header\"\n {...props}\n style={[styles[`h${level}`], props.style]}\n ref={ref}\n />\n );\n }) as ComponentType<TextProps>;\n}\n\nexport const H1 = createHeadingComponent(1);\nexport const H2 = createHeadingComponent(2);\nexport const H3 = createHeadingComponent(3);\nexport const H4 = createHeadingComponent(4);\nexport const H5 = createHeadingComponent(5);\nexport const H6 = createHeadingComponent(6);\n\n// Default web styles: http://trac.webkit.org/browser/trunk/Source/WebCore/css/html.css\nconst styles = StyleSheet.create({\n h1: {\n fontSize: em(2),\n marginVertical: em(0.67),\n fontWeight: 'bold',\n },\n h2: {\n fontSize: em(1.5),\n marginVertical: em(0.83),\n fontWeight: 'bold',\n },\n h3: {\n fontSize: em(1.17),\n marginVertical: em(1),\n fontWeight: 'bold',\n },\n h4: {\n fontSize: em(1),\n marginVertical: em(1.33),\n fontWeight: 'bold',\n },\n h5: {\n fontSize: em(0.83),\n marginVertical: em(1.67),\n fontWeight: 'bold',\n },\n h6: {\n fontSize: em(0.67),\n marginVertical: em(2.33),\n fontWeight: 'bold',\n },\n});\n"]}
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { TextProps } from '../primitives/Text';
|
|
3
3
|
import { ViewProps } from '../primitives/View';
|
|
4
4
|
export declare const UL: React.ComponentType<ViewProps>;
|
|
5
|
-
|
|
5
|
+
type LIProps = TextProps | ViewProps;
|
|
6
6
|
export declare const LI: React.ComponentType<LIProps>;
|
|
7
7
|
export {};
|
|
8
8
|
//# sourceMappingURL=Lists.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Lists.d.ts","sourceRoot":"","sources":["../../src/elements/Lists.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAuD,MAAM,OAAO,CAAC;AAG5E,OAAa,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAa,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAQrD,eAAO,MAAM,EAAE,gCAMd,CAAC;AAOF,
|
|
1
|
+
{"version":3,"file":"Lists.d.ts","sourceRoot":"","sources":["../../src/elements/Lists.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAuD,MAAM,OAAO,CAAC;AAG5E,OAAa,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAa,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAQrD,eAAO,MAAM,EAAE,gCAMd,CAAC;AAOF,KAAK,OAAO,GAAG,SAAS,GAAG,SAAS,CAAC;AAErC,eAAO,MAAM,EAAE,8BAaa,CAAC"}
|
package/build/elements/Text.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ export declare const BlockQuote: React.ComponentType<BlockQuoteProps>;
|
|
|
11
11
|
export declare const BR: React.ComponentType<TextProps>;
|
|
12
12
|
export declare const Mark: React.ComponentType<TextProps>;
|
|
13
13
|
export declare const Code: React.ComponentType<TextProps>;
|
|
14
|
-
|
|
14
|
+
type PreProps = TextProps | ViewProps;
|
|
15
15
|
export declare const Pre: React.ComponentType<PreProps>;
|
|
16
16
|
export declare const Time: React.ComponentType<TimeProps>;
|
|
17
17
|
export declare const Strong: React.ComponentType<TextProps>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Text.d.ts","sourceRoot":"","sources":["../../src/elements/Text.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoC,MAAM,OAAO,CAAC;AAIzD,OAAa,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAa,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAO,EAAE,eAAe,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEtE,eAAO,MAAM,CAAC,gCAEgB,CAAC;AAE/B,eAAO,MAAM,CAAC,gCAEgB,CAAC;AAE/B,eAAO,MAAM,CAAC,gCAEgB,CAAC;AAE/B,eAAO,MAAM,CAAC,gCAEgB,CAAC;AAE/B,eAAO,MAAM,CAAC,iCAMiB,CAAC;AAEhC,eAAO,MAAM,UAAU,sCAEa,CAAC;AAErC,eAAO,MAAM,EAAE,gCAEe,CAAC;AAE/B,eAAO,MAAM,IAAI,gCAEa,CAAC;AAE/B,eAAO,MAAM,IAAI,gCAEa,CAAC;AAM/B,
|
|
1
|
+
{"version":3,"file":"Text.d.ts","sourceRoot":"","sources":["../../src/elements/Text.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoC,MAAM,OAAO,CAAC;AAIzD,OAAa,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAa,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAO,EAAE,eAAe,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEtE,eAAO,MAAM,CAAC,gCAEgB,CAAC;AAE/B,eAAO,MAAM,CAAC,gCAEgB,CAAC;AAE/B,eAAO,MAAM,CAAC,gCAEgB,CAAC;AAE/B,eAAO,MAAM,CAAC,gCAEgB,CAAC;AAE/B,eAAO,MAAM,CAAC,iCAMiB,CAAC;AAEhC,eAAO,MAAM,UAAU,sCAEa,CAAC;AAErC,eAAO,MAAM,EAAE,gCAEe,CAAC;AAE/B,eAAO,MAAM,IAAI,gCAEa,CAAC;AAE/B,eAAO,MAAM,IAAI,gCAEa,CAAC;AAM/B,KAAK,QAAQ,GAAG,SAAS,GAAG,SAAS,CAAC;AAEtC,eAAO,MAAM,GAAG,+BAKa,CAAC;AAG9B,eAAO,MAAM,IAAI,gCAEa,CAAC;AAE/B,eAAO,MAAM,MAAM,gCAAI,CAAC;AACxB,eAAO,MAAM,GAAG,gCAAI,CAAC;AACrB,eAAO,MAAM,EAAE,gCAAI,CAAC"}
|
|
@@ -1,18 +1,22 @@
|
|
|
1
1
|
import { TextProps } from '../primitives/Text';
|
|
2
2
|
import { ViewProps } from '../primitives/View';
|
|
3
|
-
export
|
|
3
|
+
export type QuoteProps = React.PropsWithChildren<TextProps & {
|
|
4
4
|
cite?: string;
|
|
5
5
|
}>;
|
|
6
|
-
export
|
|
6
|
+
export type BlockQuoteProps = React.PropsWithChildren<ViewProps & {
|
|
7
7
|
cite?: string;
|
|
8
8
|
}>;
|
|
9
|
-
export
|
|
9
|
+
export type TimeProps = React.PropsWithChildren<TextProps & {
|
|
10
10
|
dateTime?: string;
|
|
11
11
|
}>;
|
|
12
|
-
export
|
|
12
|
+
export type LinkProps = React.PropsWithChildren<TextProps & {
|
|
13
13
|
/** @platform web */
|
|
14
14
|
href?: string;
|
|
15
15
|
/** @platform web */
|
|
16
16
|
target?: string;
|
|
17
|
+
/** @platform web */
|
|
18
|
+
rel?: string;
|
|
19
|
+
/** @platform web */
|
|
20
|
+
download?: boolean | string;
|
|
17
21
|
}>;
|
|
18
22
|
//# sourceMappingURL=Text.types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Text.types.d.ts","sourceRoot":"","sources":["../../src/elements/Text.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAC/C,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAE/C,
|
|
1
|
+
{"version":3,"file":"Text.types.d.ts","sourceRoot":"","sources":["../../src/elements/Text.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAC/C,OAAO,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAE/C,MAAM,MAAM,UAAU,GAAG,KAAK,CAAC,iBAAiB,CAAC,SAAS,GAAG;IAAE,IAAI,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;AAEhF,MAAM,MAAM,eAAe,GAAG,KAAK,CAAC,iBAAiB,CAAC,SAAS,GAAG;IAAE,IAAI,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;AAErF,MAAM,MAAM,SAAS,GAAG,KAAK,CAAC,iBAAiB,CAAC,SAAS,GAAG;IAAE,QAAQ,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;AAEnF,MAAM,MAAM,SAAS,GAAG,KAAK,CAAC,iBAAiB,CAC7C,SAAS,GAAG;IACV,oBAAoB;IACpB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,oBAAoB;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,oBAAoB;IACpB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,oBAAoB;IACpB,QAAQ,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;CAC7B,CACF,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Text.types.js","sourceRoot":"","sources":["../../src/elements/Text.types.ts"],"names":[],"mappings":"","sourcesContent":["import { TextProps } from '../primitives/Text';\nimport { ViewProps } from '../primitives/View';\n\nexport type QuoteProps = React.PropsWithChildren<TextProps & { cite?: string }>;\n\nexport type BlockQuoteProps = React.PropsWithChildren<ViewProps & { cite?: string }>;\n\nexport type TimeProps = React.PropsWithChildren<TextProps & { dateTime?: string }>;\n\nexport type LinkProps = React.PropsWithChildren<\n TextProps & {\n /** @platform web */\n href?: string;\n /** @platform web */\n target?: string;\n }\n>;\n"]}
|
|
1
|
+
{"version":3,"file":"Text.types.js","sourceRoot":"","sources":["../../src/elements/Text.types.ts"],"names":[],"mappings":"","sourcesContent":["import { TextProps } from '../primitives/Text';\nimport { ViewProps } from '../primitives/View';\n\nexport type QuoteProps = React.PropsWithChildren<TextProps & { cite?: string }>;\n\nexport type BlockQuoteProps = React.PropsWithChildren<ViewProps & { cite?: string }>;\n\nexport type TimeProps = React.PropsWithChildren<TextProps & { dateTime?: string }>;\n\nexport type LinkProps = React.PropsWithChildren<\n TextProps & {\n /** @platform web */\n href?: string;\n /** @platform web */\n target?: string;\n /** @platform web */\n rel?: string;\n /** @platform web */\n download?: boolean | string;\n }\n>;\n"]}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ClassAttributes, ComponentProps, ComponentType } from 'react';
|
|
2
2
|
import Text from './Text';
|
|
3
|
-
|
|
4
|
-
export
|
|
3
|
+
type NativeTextProps = ComponentProps<typeof Text> & ClassAttributes<typeof Text>;
|
|
4
|
+
export type TableTextProps = NativeTextProps & {
|
|
5
5
|
/** @platform web */
|
|
6
6
|
colSpan?: number | string;
|
|
7
7
|
/** @platform web */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Table.d.ts","sourceRoot":"","sources":["../../src/primitives/Table.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAEvE,OAAO,IAAI,MAAM,QAAQ,CAAC;AAE1B,
|
|
1
|
+
{"version":3,"file":"Table.d.ts","sourceRoot":"","sources":["../../src/primitives/Table.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAEvE,OAAO,IAAI,MAAM,QAAQ,CAAC;AAE1B,KAAK,eAAe,GAAG,cAAc,CAAC,OAAO,IAAI,CAAC,GAAG,eAAe,CAAC,OAAO,IAAI,CAAC,CAAC;AAElF,MAAM,MAAM,cAAc,GAAG,eAAe,GAAG;IAC7C,oBAAoB;IACpB,OAAO,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC1B,oBAAoB;IACpB,OAAO,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;CAC3B,CAAC;AAEF,eAAO,MAAM,SAAS,+BAAwC,CAAC"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ClassAttributes, ComponentProps, ComponentType } from 'react';
|
|
2
2
|
import { AccessibilityRole, StyleProp, Text as NativeText, TextStyle as NativeTextStyle } from 'react-native';
|
|
3
|
-
|
|
3
|
+
import { WebViewStyle } from './View';
|
|
4
|
+
type NativeTextProps = ComponentProps<typeof NativeText> & ClassAttributes<typeof NativeText>;
|
|
4
5
|
export interface WebTextStyle {
|
|
5
6
|
/** string is only available on web */
|
|
6
7
|
fontSize?: NativeTextStyle['fontSize'] | string;
|
|
@@ -21,14 +22,31 @@ export interface WebTextStyle {
|
|
|
21
22
|
/** @platform web */
|
|
22
23
|
wordWrap?: string;
|
|
23
24
|
}
|
|
24
|
-
export
|
|
25
|
-
export
|
|
25
|
+
export type TextStyle = Omit<NativeTextStyle, 'position' | 'fontSize' | 'lineHeight'> & WebTextStyle & WebViewStyle;
|
|
26
|
+
export type WebTextProps = {
|
|
26
27
|
style?: StyleProp<TextStyle>;
|
|
27
28
|
/** @platform web */
|
|
28
29
|
tabIndex?: number;
|
|
29
|
-
|
|
30
|
+
/** @platform web */
|
|
31
|
+
accessibilityLevel?: number;
|
|
32
|
+
accessibilityRole?: 'listitem' | 'heading' | AccessibilityRole;
|
|
33
|
+
/** @platform web */
|
|
34
|
+
href?: string;
|
|
35
|
+
/** @deprecated use the prop `hrefAttrs={{ target: '...' }}` instead. */
|
|
36
|
+
target?: string;
|
|
37
|
+
/** @platform web */
|
|
38
|
+
hrefAttrs?: {
|
|
39
|
+
/** @platform web */
|
|
40
|
+
target?: string;
|
|
41
|
+
/** @platform web */
|
|
42
|
+
rel?: string;
|
|
43
|
+
/** @platform web */
|
|
44
|
+
download?: boolean | string;
|
|
45
|
+
};
|
|
46
|
+
/** @platform web */
|
|
47
|
+
lang?: string;
|
|
30
48
|
};
|
|
31
|
-
export
|
|
49
|
+
export type TextProps = Omit<NativeTextProps, 'style' | 'accessibilityRole'> & WebTextProps;
|
|
32
50
|
declare const Text: ComponentType<TextProps>;
|
|
33
51
|
export default Text;
|
|
34
52
|
//# sourceMappingURL=Text.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Text.d.ts","sourceRoot":"","sources":["../../src/primitives/Text.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AACvE,OAAO,EACL,iBAAiB,EACjB,SAAS,EACT,IAAI,IAAI,UAAU,EAClB,SAAS,IAAI,eAAe,EAC7B,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"Text.d.ts","sourceRoot":"","sources":["../../src/primitives/Text.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AACvE,OAAO,EACL,iBAAiB,EACjB,SAAS,EACT,IAAI,IAAI,UAAU,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oBAAoB;IACpB,SAAS,CAAC,EAAE;QACV,oBAAoB;QACpB,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,oBAAoB;QACpB,GAAG,CAAC,EAAE,MAAM,CAAC;QACb,oBAAoB;QACpB,QAAQ,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;KAC7B,CAAC;IACF,oBAAoB;IACpB,IAAI,CAAC,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,MAAM,MAAM,SAAS,GAAG,IAAI,CAAC,eAAe,EAAE,OAAO,GAAG,mBAAmB,CAAC,GAAG,YAAY,CAAC;AAE5F,QAAA,MAAM,IAAI,0BAAyC,CAAC;AAEpD,eAAe,IAAI,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Text.js","sourceRoot":"","sources":["../../src/primitives/Text.tsx"],"names":[],"mappings":"AACA,OAAO,EAGL,IAAI,IAAI,UAAU,GAEnB,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"Text.js","sourceRoot":"","sources":["../../src/primitives/Text.tsx"],"names":[],"mappings":"AACA,OAAO,EAGL,IAAI,IAAI,UAAU,GAEnB,MAAM,cAAc,CAAC;AA2DtB,MAAM,IAAI,GAAG,UAAsC,CAAC;AAEpD,eAAe,IAAI,CAAC","sourcesContent":["import { ClassAttributes, ComponentProps, ComponentType } from 'react';\nimport {\n AccessibilityRole,\n StyleProp,\n Text as NativeText,\n TextStyle as NativeTextStyle,\n} from 'react-native';\n\nimport { WebViewStyle } from './View';\n\n// https://github.com/necolas/react-native-web/issues/832\n\ntype NativeTextProps = ComponentProps<typeof NativeText> & ClassAttributes<typeof NativeText>;\n\nexport interface WebTextStyle {\n /** string is only available on web */\n fontSize?: NativeTextStyle['fontSize'] | string;\n /** string is only available on web */\n lineHeight?: NativeTextStyle['lineHeight'] | string;\n /** @platform web */\n fontFeatureSettings?: string;\n /** @platform web */\n textIndent?: string;\n /** @platform web */\n textOverflow?: string;\n /** @platform web */\n textRendering?: string;\n /** @platform web */\n textTransform?: string;\n /** @platform web */\n unicodeBidi?: string;\n /** @platform web */\n wordWrap?: string;\n}\n\nexport type TextStyle = Omit<NativeTextStyle, 'position' | 'fontSize' | 'lineHeight'> &\n WebTextStyle &\n WebViewStyle;\n\nexport type WebTextProps = {\n style?: StyleProp<TextStyle>;\n /** @platform web */\n tabIndex?: number;\n /** @platform web */\n accessibilityLevel?: number;\n accessibilityRole?: 'listitem' | 'heading' | AccessibilityRole;\n /** @platform web */\n href?: string;\n /** @deprecated use the prop `hrefAttrs={{ target: '...' }}` instead. */\n target?: string;\n /** @platform web */\n hrefAttrs?: {\n /** @platform web */\n target?: string;\n /** @platform web */\n rel?: string;\n /** @platform web */\n download?: boolean | string;\n };\n /** @platform web */\n lang?: string;\n};\n\nexport type TextProps = Omit<NativeTextProps, 'style' | 'accessibilityRole'> & WebTextProps;\n\nconst Text = NativeText as ComponentType<TextProps>;\n\nexport default Text;\n"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ClassAttributes, ComponentProps, ComponentType } from 'react';
|
|
2
2
|
import { StyleProp, View as NativeView, AccessibilityRole, ViewStyle as NativeViewStyle } from 'react-native';
|
|
3
|
-
|
|
3
|
+
type NativeViewProps = ComponentProps<typeof NativeView> & ClassAttributes<typeof NativeView>;
|
|
4
4
|
/**
|
|
5
5
|
* https://baconbrix.gitbook.io/react-native-web/primitives/view
|
|
6
6
|
*/
|
|
@@ -110,12 +110,12 @@ export interface WebViewStyle {
|
|
|
110
110
|
/** @platform web */
|
|
111
111
|
willChange?: string;
|
|
112
112
|
}
|
|
113
|
-
export
|
|
114
|
-
export
|
|
113
|
+
export type ViewStyle = Omit<NativeViewStyle, 'position'> & WebViewStyle;
|
|
114
|
+
export type WebViewProps = {
|
|
115
115
|
style?: StyleProp<ViewStyle>;
|
|
116
116
|
accessibilityRole?: 'list' | 'listitem' | 'complementary' | 'contentinfo' | 'region' | 'navigation' | 'main' | 'article' | 'banner' | AccessibilityRole;
|
|
117
117
|
};
|
|
118
|
-
export
|
|
118
|
+
export type ViewProps = WebViewProps & Omit<NativeViewProps, 'style' | 'accessibilityRole'>;
|
|
119
119
|
declare const View: ComponentType<ViewProps>;
|
|
120
120
|
export default View;
|
|
121
121
|
//# sourceMappingURL=View.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"View.d.ts","sourceRoot":"","sources":["../../src/primitives/View.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AACvE,OAAO,EACL,SAAS,EACT,IAAI,IAAI,UAAU,EAClB,iBAAiB,EACjB,SAAS,IAAI,eAAe,EAC7B,MAAM,cAAc,CAAC;AAItB,
|
|
1
|
+
{"version":3,"file":"View.d.ts","sourceRoot":"","sources":["../../src/primitives/View.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AACvE,OAAO,EACL,SAAS,EACT,IAAI,IAAI,UAAU,EAClB,iBAAiB,EACjB,SAAS,IAAI,eAAe,EAC7B,MAAM,cAAc,CAAC;AAItB,KAAK,eAAe,GAAG,cAAc,CAAC,OAAO,UAAU,CAAC,GAAG,eAAe,CAAC,OAAO,UAAU,CAAC,CAAC;AAE9F;;GAEG;AACH,MAAM,WAAW,YAAY;IAC3B,oBAAoB;IACpB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,oBAAoB;IACpB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,oBAAoB;IACpB,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,oBAAoB;IACpB,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,oBAAoB;IACpB,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,oBAAoB;IACpB,aAAa,CAAC,EAAE,MAAM,GAAG,GAAG,EAAE,CAAC;IAC/B,oBAAoB;IACpB,uBAAuB,C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;AAED,MAAM,MAAM,SAAS,GAAG,IAAI,CAAC,eAAe,EAAE,UAAU,CAAC,GAAG,YAAY,CAAC;AAEzE,MAAM,MAAM,YAAY,GAAG;IACzB,KAAK,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;IAE7B,iBAAiB,CAAC,EACd,MAAM,GACN,UAAU,GACV,eAAe,GACf,aAAa,GACb,QAAQ,GACR,YAAY,GACZ,MAAM,GACN,SAAS,GACT,QAAQ,GACR,iBAAiB,CAAC;CACvB,CAAC;AAEF,MAAM,MAAM,SAAS,GAAG,YAAY,GAAG,IAAI,CAAC,eAAe,EAAE,OAAO,GAAG,mBAAmB,CAAC,CAAC;AAE5F,QAAA,MAAM,IAAI,0BAAyC,CAAC;AAEpD,eAAe,IAAI,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"View.js","sourceRoot":"","sources":["../../src/primitives/View.tsx"],"names":[],"mappings":"AACA,OAAO,EAEL,IAAI,IAAI,UAAU,GAGnB,MAAM,cAAc,CAAC;AAwItB,MAAM,IAAI,GAAG,UAAsC,CAAC;AAEpD,eAAe,IAAI,CAAC","sourcesContent":["import { ClassAttributes, ComponentProps, ComponentType } from 'react';\nimport {\n StyleProp,\n View as NativeView,\n AccessibilityRole,\n ViewStyle as NativeViewStyle,\n} from 'react-native';\n\n// https://github.com/necolas/react-native-web/issues/832\n\ntype NativeViewProps = ComponentProps<typeof NativeView> & ClassAttributes<typeof NativeView>;\n\n/**\n * https://baconbrix.gitbook.io/react-native-web/primitives/view\n */\nexport interface WebViewStyle {\n /** @platform web */\n backdropFilter?: string;\n /** @platform web */\n animationDelay?: string;\n /** @platform web */\n animationDirection?: string;\n /** @platform web */\n animationDuration?: string;\n /** @platform web */\n animationFillMode?: string;\n /** @platform web */\n animationName?: string | any[];\n /** @platform web */\n animationIterationCount?: number | 'infinite';\n /** @platform web */\n animationPlayState?: string;\n /** @platform web */\n animationTimingFunction?: string;\n /** @platform web */\n backgroundAttachment?: string;\n /** @platform web */\n backgroundBlendMode?: string;\n /** @platform web */\n backgroundClip?: string;\n /** @platform web */\n backgroundImage?: string;\n /** @platform web */\n backgroundOrigin?: 'border-box' | 'content-box' | 'padding-box';\n /** @platform web */\n backgroundPosition?: string;\n /** @platform web */\n backgroundRepeat?: string;\n /** @platform web */\n backgroundSize?: string;\n /** @platform web */\n boxShadow?: string;\n /** @platform web */\n boxSizing?: string;\n /** @platform web */\n clip?: string;\n /** @platform web */\n cursor?: string;\n /** @platform web */\n filter?: string;\n /** @platform web */\n gridAutoColumns?: string;\n /** @platform web */\n gridAutoFlow?: string;\n /** @platform web */\n gridAutoRows?: string;\n /** @platform web */\n gridColumnEnd?: string;\n /** @platform web */\n gridColumnGap?: string;\n /** @platform web */\n gridColumnStart?: string;\n /** @platform web */\n gridRowEnd?: string;\n /** @platform web */\n gridRowGap?: string;\n /** @platform web */\n gridRowStart?: string;\n /** @platform web */\n gridTemplateColumns?: string;\n /** @platform web */\n gridTemplateRows?: string;\n /** @platform web */\n gridTemplateAreas?: string;\n /** @platform web */\n outline?: string;\n /** @platform web */\n outlineColor?: string;\n /** @platform web */\n overflowX?: string;\n /** @platform web */\n overflowY?: string;\n /** @platform web */\n overscrollBehavior?: 'auto' | 'contain' | 'none';\n /** @platform web */\n overscrollBehaviorX?: 'auto' | 'contain' | 'none';\n /** @platform web */\n overscrollBehaviorY?: 'auto' | 'contain' | 'none';\n /** @platform web */\n perspective?: string;\n /** @platform web */\n perspectiveOrigin?: string;\n /** @platform web */\n touchAction?: string;\n /** @platform web */\n transformOrigin?: string;\n /** @platform web */\n transitionDelay?: string;\n /** @platform web */\n transitionDuration?: string;\n /** @platform web */\n transitionProperty?: string;\n /** @platform web */\n transitionTimingFunction?: string;\n /** @platform web */\n userSelect?: string;\n /** @platform web */\n visibility?: string;\n /** @platform web */\n willChange?: string;\n}\n\nexport type ViewStyle = NativeViewStyle & WebViewStyle;\n\nexport type WebViewProps = {\n style?: StyleProp<ViewStyle>;\n\n accessibilityRole?:\n | 'list'\n | 'listitem'\n | 'complementary'\n | 'contentinfo'\n | 'region'\n | 'navigation'\n | 'main'\n | 'article'\n | 'banner'\n | AccessibilityRole;\n};\n\nexport type ViewProps = WebViewProps & Omit<NativeViewProps, 'style' | 'accessibilityRole'>;\n\nconst View = NativeView as ComponentType<ViewProps>;\n\nexport default View;\n"]}
|
|
1
|
+
{"version":3,"file":"View.js","sourceRoot":"","sources":["../../src/primitives/View.tsx"],"names":[],"mappings":"AACA,OAAO,EAEL,IAAI,IAAI,UAAU,GAGnB,MAAM,cAAc,CAAC;AAwItB,MAAM,IAAI,GAAG,UAAsC,CAAC;AAEpD,eAAe,IAAI,CAAC","sourcesContent":["import { ClassAttributes, ComponentProps, ComponentType } from 'react';\nimport {\n StyleProp,\n View as NativeView,\n AccessibilityRole,\n ViewStyle as NativeViewStyle,\n} from 'react-native';\n\n// https://github.com/necolas/react-native-web/issues/832\n\ntype NativeViewProps = ComponentProps<typeof NativeView> & ClassAttributes<typeof NativeView>;\n\n/**\n * https://baconbrix.gitbook.io/react-native-web/primitives/view\n */\nexport interface WebViewStyle {\n /** @platform web */\n backdropFilter?: string;\n /** @platform web */\n animationDelay?: string;\n /** @platform web */\n animationDirection?: string;\n /** @platform web */\n animationDuration?: string;\n /** @platform web */\n animationFillMode?: string;\n /** @platform web */\n animationName?: string | any[];\n /** @platform web */\n animationIterationCount?: number | 'infinite';\n /** @platform web */\n animationPlayState?: string;\n /** @platform web */\n animationTimingFunction?: string;\n /** @platform web */\n backgroundAttachment?: string;\n /** @platform web */\n backgroundBlendMode?: string;\n /** @platform web */\n backgroundClip?: string;\n /** @platform web */\n backgroundImage?: string;\n /** @platform web */\n backgroundOrigin?: 'border-box' | 'content-box' | 'padding-box';\n /** @platform web */\n backgroundPosition?: string;\n /** @platform web */\n backgroundRepeat?: string;\n /** @platform web */\n backgroundSize?: string;\n /** @platform web */\n boxShadow?: string;\n /** @platform web */\n boxSizing?: string;\n /** @platform web */\n clip?: string;\n /** @platform web */\n cursor?: string;\n /** @platform web */\n filter?: string;\n /** @platform web */\n gridAutoColumns?: string;\n /** @platform web */\n gridAutoFlow?: string;\n /** @platform web */\n gridAutoRows?: string;\n /** @platform web */\n gridColumnEnd?: string;\n /** @platform web */\n gridColumnGap?: string;\n /** @platform web */\n gridColumnStart?: string;\n /** @platform web */\n gridRowEnd?: string;\n /** @platform web */\n gridRowGap?: string;\n /** @platform web */\n gridRowStart?: string;\n /** @platform web */\n gridTemplateColumns?: string;\n /** @platform web */\n gridTemplateRows?: string;\n /** @platform web */\n gridTemplateAreas?: string;\n /** @platform web */\n outline?: string;\n /** @platform web */\n outlineColor?: string;\n /** @platform web */\n overflowX?: string;\n /** @platform web */\n overflowY?: string;\n /** @platform web */\n overscrollBehavior?: 'auto' | 'contain' | 'none';\n /** @platform web */\n overscrollBehaviorX?: 'auto' | 'contain' | 'none';\n /** @platform web */\n overscrollBehaviorY?: 'auto' | 'contain' | 'none';\n /** @platform web */\n perspective?: string;\n /** @platform web */\n perspectiveOrigin?: string;\n /** @platform web */\n touchAction?: string;\n /** @platform web */\n transformOrigin?: string;\n /** @platform web */\n transitionDelay?: string;\n /** @platform web */\n transitionDuration?: string;\n /** @platform web */\n transitionProperty?: string;\n /** @platform web */\n transitionTimingFunction?: string;\n /** @platform web */\n userSelect?: string;\n /** @platform web */\n visibility?: string;\n /** @platform web */\n willChange?: string;\n}\n\nexport type ViewStyle = Omit<NativeViewStyle, 'position'> & WebViewStyle;\n\nexport type WebViewProps = {\n style?: StyleProp<ViewStyle>;\n\n accessibilityRole?:\n | 'list'\n | 'listitem'\n | 'complementary'\n | 'contentinfo'\n | 'region'\n | 'navigation'\n | 'main'\n | 'article'\n | 'banner'\n | AccessibilityRole;\n};\n\nexport type ViewProps = WebViewProps & Omit<NativeViewProps, 'style' | 'accessibilityRole'>;\n\nconst View = NativeView as ComponentType<ViewProps>;\n\nexport default View;\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@expo/html-elements",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"description": "Universal semantic HTML React components for iOS, Android, web, and desktop",
|
|
5
5
|
"main": "build/Elements.js",
|
|
6
6
|
"types": "build/Elements.d.ts",
|
|
@@ -47,6 +47,5 @@
|
|
|
47
47
|
},
|
|
48
48
|
"devDependencies": {
|
|
49
49
|
"expo-module-scripts": "^3.0.0"
|
|
50
|
-
}
|
|
51
|
-
"gitHead": "779ad6af070d07a14f371e3106f02ddd1b093538"
|
|
50
|
+
}
|
|
52
51
|
}
|