@teambit/schema 0.0.752 → 0.0.755
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/schema.cmd.js
CHANGED
|
@@ -49,7 +49,7 @@ class SchemaCommand {
|
|
|
49
49
|
(0, _defineProperty2().default)(this, "name", 'schema <pattern>');
|
|
50
50
|
(0, _defineProperty2().default)(this, "description", 'shows the API schema of a certain component.');
|
|
51
51
|
(0, _defineProperty2().default)(this, "extendedDescription", `${(0, _constants().PATTERN_HELP)('schema')}`);
|
|
52
|
-
(0, _defineProperty2().default)(this, "group", '
|
|
52
|
+
(0, _defineProperty2().default)(this, "group", 'development');
|
|
53
53
|
(0, _defineProperty2().default)(this, "options", [['j', 'json', 'return the component data in json format']]);
|
|
54
54
|
}
|
|
55
55
|
|
package/dist/schema.cmd.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["SchemaCommand","constructor","schema","component","logger","PATTERN_HELP","report","pattern","schemas","getSchemas","map","toStringPerType","join","json","toObject","host","getHost","ids","idsByPattern","components","getMany","longRunningLog","createLongProcessLogger","length","results","pMapSeries","logProgress","id","toString","getSchema","end"],"sources":["schema.cmd.ts"],"sourcesContent":["import { Command, CommandOptions } from '@teambit/cli';\nimport { ComponentMain } from '@teambit/component';\nimport pMapSeries from 'p-map-series';\nimport { Logger } from '@teambit/logger';\nimport { APISchema } from '@teambit/semantics.entities.semantic-schema';\nimport { PATTERN_HELP } from '@teambit/legacy/dist/constants';\nimport type { SchemaMain } from './schema.main.runtime';\n\nexport class SchemaCommand implements Command {\n name = 'schema <pattern>';\n description = 'shows the API schema of a certain component.';\n extendedDescription = `${PATTERN_HELP('schema')}`;\n group = '
|
|
1
|
+
{"version":3,"names":["SchemaCommand","constructor","schema","component","logger","PATTERN_HELP","report","pattern","schemas","getSchemas","map","toStringPerType","join","json","toObject","host","getHost","ids","idsByPattern","components","getMany","longRunningLog","createLongProcessLogger","length","results","pMapSeries","logProgress","id","toString","getSchema","end"],"sources":["schema.cmd.ts"],"sourcesContent":["import { Command, CommandOptions } from '@teambit/cli';\nimport { ComponentMain } from '@teambit/component';\nimport pMapSeries from 'p-map-series';\nimport { Logger } from '@teambit/logger';\nimport { APISchema } from '@teambit/semantics.entities.semantic-schema';\nimport { PATTERN_HELP } from '@teambit/legacy/dist/constants';\nimport type { SchemaMain } from './schema.main.runtime';\n\nexport class SchemaCommand implements Command {\n name = 'schema <pattern>';\n description = 'shows the API schema of a certain component.';\n extendedDescription = `${PATTERN_HELP('schema')}`;\n group = 'development';\n options = [['j', 'json', 'return the component data in json format']] as CommandOptions;\n\n constructor(private schema: SchemaMain, private component: ComponentMain, private logger: Logger) {}\n\n async report([pattern]) {\n const schemas = await this.getSchemas([pattern]);\n return schemas.map((schema) => schema.toStringPerType()).join('\\n\\n\\n');\n }\n\n async json([pattern]) {\n const schemas = await this.getSchemas([pattern]);\n return schemas.map((schema) => schema.toObject());\n }\n\n private async getSchemas([pattern]): Promise<APISchema[]> {\n const host = this.component.getHost();\n const ids = await host.idsByPattern(pattern, true);\n const components = await host.getMany(ids);\n const longRunningLog = this.logger.createLongProcessLogger('generating schema', ids.length);\n const results = await pMapSeries(components, (component) => {\n longRunningLog.logProgress(component.id.toString());\n return this.schema.getSchema(component);\n });\n longRunningLog.end();\n return results;\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAEA;EAAA;;EAAA;IAAA;EAAA;;EAAA;AAAA;;AAGA;EAAA;;EAAA;IAAA;EAAA;;EAAA;AAAA;;AAGO,MAAMA,aAAN,CAAuC;EAO5CC,WAAW,CAASC,MAAT,EAAqCC,SAArC,EAAuEC,MAAvE,EAAuF;IAAA,KAA9EF,MAA8E,GAA9EA,MAA8E;IAAA,KAAlDC,SAAkD,GAAlDA,SAAkD;IAAA,KAAhBC,MAAgB,GAAhBA,MAAgB;IAAA,8CAN3F,kBAM2F;IAAA,qDALpF,8CAKoF;IAAA,6DAJ3E,GAA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S,GAAf;IACA,OAAON,OAAP;EACD;;AA9B2C"}
|
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@teambit/schema",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.755",
|
|
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.
|
|
9
|
+
"version": "0.0.755"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"p-map-series": "2.1.0",
|
|
@@ -16,13 +16,13 @@
|
|
|
16
16
|
"core-js": "^3.0.0",
|
|
17
17
|
"@teambit/harmony": "0.3.3",
|
|
18
18
|
"@teambit/base-react.navigation.link": "2.0.27",
|
|
19
|
-
"@teambit/semantics.entities.semantic-schema": "0.0.
|
|
20
|
-
"@teambit/builder": "0.0.
|
|
21
|
-
"@teambit/component": "0.0.
|
|
22
|
-
"@teambit/cli": "0.0.
|
|
23
|
-
"@teambit/logger": "0.0.
|
|
24
|
-
"@teambit/envs": "0.0.
|
|
25
|
-
"@teambit/graphql": "0.0.
|
|
19
|
+
"@teambit/semantics.entities.semantic-schema": "0.0.18",
|
|
20
|
+
"@teambit/builder": "0.0.755",
|
|
21
|
+
"@teambit/component": "0.0.755",
|
|
22
|
+
"@teambit/cli": "0.0.498",
|
|
23
|
+
"@teambit/logger": "0.0.591",
|
|
24
|
+
"@teambit/envs": "0.0.755",
|
|
25
|
+
"@teambit/graphql": "0.0.755"
|
|
26
26
|
},
|
|
27
27
|
"devDependencies": {
|
|
28
28
|
"@types/react": "^17.0.8",
|
|
@@ -36,10 +36,10 @@
|
|
|
36
36
|
"@teambit/component-id": "0.0.402",
|
|
37
37
|
"@teambit/harmony.testing.load-aspect": "0.0.6",
|
|
38
38
|
"@teambit/workspace.testing.mock-workspace": "0.0.5",
|
|
39
|
-
"@teambit/workspace": "0.0.
|
|
39
|
+
"@teambit/workspace": "0.0.755"
|
|
40
40
|
},
|
|
41
41
|
"peerDependencies": {
|
|
42
|
-
"@teambit/legacy": "1.0.
|
|
42
|
+
"@teambit/legacy": "1.0.278",
|
|
43
43
|
"react-dom": "^16.8.0 || ^17.0.0",
|
|
44
44
|
"react": "^16.8.0 || ^17.0.0"
|
|
45
45
|
},
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
"react": "-"
|
|
68
68
|
},
|
|
69
69
|
"peerDependencies": {
|
|
70
|
-
"@teambit/legacy": "1.0.
|
|
70
|
+
"@teambit/legacy": "1.0.278",
|
|
71
71
|
"react-dom": "^16.8.0 || ^17.0.0",
|
|
72
72
|
"react": "^16.8.0 || ^17.0.0"
|
|
73
73
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const compositions = [require('/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.semantics_schema@0.0.
|
|
2
|
-
export const overview = [require('/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.semantics_schema@0.0.
|
|
1
|
+
export const compositions = [require('/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.semantics_schema@0.0.755/dist/schema.composition.js'), require('/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.semantics_schema@0.0.755/dist/mock/button/button.composition.js')]
|
|
2
|
+
export const overview = [require('/home/circleci/Library/Caches/Bit/capsules/8891be5ad3d35bfc38b9cd90c0e05b598a5a55af/teambit.semantics_schema@0.0.755/dist/schema.docs.mdx')]
|
|
Binary file
|