@teambit/schema 0.0.566 → 0.0.570

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.
@@ -0,0 +1 @@
1
+ export { ParserNotFound } from './parser-not-found';
@@ -0,0 +1,8 @@
1
+ export class ParserNotFound extends Error {
2
+ constructor(readonly filePath: string) {
3
+ super(`
4
+ no parser is configured to apply on file path: ${filePath}.\n
5
+ please use an extension to handle your file extension formats.
6
+ `);
7
+ }
8
+ }
package/package.json CHANGED
@@ -1,22 +1,22 @@
1
1
  {
2
2
  "name": "@teambit/schema",
3
- "version": "0.0.566",
3
+ "version": "0.0.570",
4
4
  "homepage": "https://bit.dev/teambit/semantics/schema",
5
5
  "main": "dist/index.js",
6
6
  "componentId": {
7
7
  "scope": "teambit.semantics",
8
8
  "name": "schema",
9
- "version": "0.0.566"
9
+ "version": "0.0.570"
10
10
  },
11
11
  "dependencies": {
12
12
  "@teambit/harmony": "0.2.11",
13
13
  "graphql-tag": "2.12.1",
14
14
  "@babel/runtime": "7.12.18",
15
15
  "core-js": "^3.0.0",
16
- "@teambit/component": "0.0.566",
17
- "@teambit/cli": "0.0.393",
18
- "@teambit/envs": "0.0.566",
19
- "@teambit/graphql": "0.0.566"
16
+ "@teambit/component": "0.0.570",
17
+ "@teambit/cli": "0.0.395",
18
+ "@teambit/envs": "0.0.570",
19
+ "@teambit/graphql": "0.0.570"
20
20
  },
21
21
  "devDependencies": {
22
22
  "@types/mocha": "5.2.7",
@@ -27,7 +27,7 @@
27
27
  "@types/node": "12.20.4"
28
28
  },
29
29
  "peerDependencies": {
30
- "@teambit/legacy": "1.0.179",
30
+ "@teambit/legacy": "1.0.181",
31
31
  "react-dom": "^16.8.0 || ^17.0.0",
32
32
  "react": "^16.8.0 || ^17.0.0"
33
33
  },
@@ -55,27 +55,12 @@
55
55
  "react": "-"
56
56
  },
57
57
  "peerDependencies": {
58
- "@teambit/legacy": "1.0.179",
58
+ "@teambit/legacy": "1.0.181",
59
59
  "react-dom": "^16.8.0 || ^17.0.0",
60
60
  "react": "^16.8.0 || ^17.0.0"
61
61
  }
62
62
  }
63
63
  },
64
- "files": [
65
- "dist",
66
- "!dist/tsconfig.tsbuildinfo",
67
- "**/*.md",
68
- "**/*.mdx",
69
- "**/*.js",
70
- "**/*.json",
71
- "**/*.sass",
72
- "**/*.scss",
73
- "**/*.less",
74
- "**/*.css",
75
- "**/*.css",
76
- "**/*.jpeg",
77
- "**/*.gif"
78
- ],
79
64
  "private": false,
80
65
  "engines": {
81
66
  "node": ">=12.22.0"
@@ -0,0 +1,20 @@
1
+ type Primitive = string | number | boolean | null | undefined;
2
+ export type StaticProperties = Map<string, Primitive>;
3
+
4
+ export class Export {
5
+ constructor(
6
+ /**
7
+ * named export identifier of the module export.
8
+ */
9
+ readonly identifier: string,
10
+
11
+ /**
12
+ * static properties attached to this export
13
+ * @example
14
+ * export hello = () => {};
15
+ * hello.value = "text"; // <-- staticProperty
16
+ * hello.count = 3; // <-- static property
17
+ */
18
+ readonly staticProperties?: StaticProperties
19
+ ) {}
20
+ }
@@ -0,0 +1,2 @@
1
+ export { Module } from './module';
2
+ export { Export, StaticProperties } from './export';
@@ -0,0 +1,10 @@
1
+ import { Export } from './export';
2
+
3
+ export class Module {
4
+ constructor(
5
+ /**
6
+ * all module exports.
7
+ */
8
+ readonly exports: Export[]
9
+ ) {}
10
+ }
@@ -0,0 +1,29 @@
1
+ declare module '*.png' {
2
+ const value: any;
3
+ export = value;
4
+ }
5
+ declare module '*.svg' {
6
+ import type { FunctionComponent, SVGProps } from 'react';
7
+
8
+ export const ReactComponent: FunctionComponent<SVGProps<SVGSVGElement> & { title?: string }>;
9
+ const src: string;
10
+ export default src;
11
+ }
12
+
13
+ // @TODO Gilad
14
+ declare module '*.jpg' {
15
+ const value: any;
16
+ export = value;
17
+ }
18
+ declare module '*.jpeg' {
19
+ const value: any;
20
+ export = value;
21
+ }
22
+ declare module '*.gif' {
23
+ const value: any;
24
+ export = value;
25
+ }
26
+ declare module '*.bmp' {
27
+ const value: any;
28
+ export = value;
29
+ }
@@ -0,0 +1,42 @@
1
+ declare module '*.module.css' {
2
+ const classes: { readonly [key: string]: string };
3
+ export default classes;
4
+ }
5
+ declare module '*.module.scss' {
6
+ const classes: { readonly [key: string]: string };
7
+ export default classes;
8
+ }
9
+ declare module '*.module.sass' {
10
+ const classes: { readonly [key: string]: string };
11
+ export default classes;
12
+ }
13
+
14
+ declare module '*.module.less' {
15
+ const classes: { readonly [key: string]: string };
16
+ export default classes;
17
+ }
18
+
19
+ declare module '*.less' {
20
+ const classes: { readonly [key: string]: string };
21
+ export default classes;
22
+ }
23
+
24
+ declare module '*.css' {
25
+ const classes: { readonly [key: string]: string };
26
+ export default classes;
27
+ }
28
+
29
+ declare module '*.sass' {
30
+ const classes: { readonly [key: string]: string };
31
+ export default classes;
32
+ }
33
+
34
+ declare module '*.scss' {
35
+ const classes: { readonly [key: string]: string };
36
+ export default classes;
37
+ }
38
+
39
+ declare module '*.mdx' {
40
+ const component: any;
41
+ export default component;
42
+ }