@ui5/create-webcomponents-package 0.0.5 → 1.1.2
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 +8 -0
- package/README.md +8 -8
- package/index.js +8 -7
- package/package.json +1 -2
- package/template/src/Assets.js +1 -1
- package/template/src/MyFirstComponent.js +6 -11
- package/yarn-error.log +0 -10165
package/CHANGELOG.md
ADDED
@@ -0,0 +1,8 @@
|
|
1
|
+
# Change Log
|
2
|
+
|
3
|
+
All notable changes to this project will be documented in this file.
|
4
|
+
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
5
|
+
|
6
|
+
## [1.1.2](https://github.com/SAP/ui5-webcomponents/compare/v1.1.1...v1.1.2) (2022-01-26)
|
7
|
+
|
8
|
+
**Note:** Version bump only for package @ui5/create-webcomponents-package
|
package/README.md
CHANGED
@@ -1,25 +1,25 @@
|
|
1
1
|

|
2
2
|
|
3
|
-
# UI5 Web Components - Create
|
3
|
+
# UI5 Web Components - Create Package
|
4
4
|
|
5
5
|
[](https://travis-ci.org/SAP/ui5-webcomponents)
|
6
6
|
[](https://www.npmjs.com/package/@ui5/webcomponents)
|
7
7
|
|
8
|
-
Provides an `npm init` script for creating new UI5
|
8
|
+
Provides an `npm init` script for creating new "UI5 Web Components" packages.
|
9
9
|
|
10
10
|
## Usage
|
11
11
|
|
12
12
|
with `npm`
|
13
13
|
|
14
|
-
- `npm init @ui5/webcomponents-package` (the user will be asked for **name**, **port**, **tag**)
|
15
|
-
- `npm init @ui5/webcomponents-package <NEW-PACKAGE-NAME>` (the user will be asked for **port** and **tag** only)
|
14
|
+
- `npm init @ui5/webcomponents-package` (the user will be asked for **name**, **port**, **tag**);
|
15
|
+
- `npm init @ui5/webcomponents-package <NEW-PACKAGE-NAME>` (the user will be asked for **port** and **tag** only).
|
16
16
|
|
17
|
-
|
17
|
+
And with `yarn`
|
18
18
|
|
19
19
|
- `yarn create @ui5/webcomponents-package`
|
20
|
-
- `yarn create @ui5/webcomponents-package <NEW-PACKAGE-NAME
|
20
|
+
- `yarn create @ui5/webcomponents-package <NEW-PACKAGE-NAME>`.
|
21
21
|
|
22
|
-
The script creates a new directory, and fills it with a `package.json` file and all necessary source files and resources for a new
|
22
|
+
The script creates a new directory, and fills it with a `package.json` file and all necessary source files, and resources for a new
|
23
23
|
components package.
|
24
24
|
|
25
25
|
## Resources
|
@@ -31,7 +31,7 @@ components package.
|
|
31
31
|
We welcome all comments, suggestions, questions, and bug reports. Please follow our [Support Guidelines](https://github.com/SAP/ui5-webcomponents/blob/master/SUPPORT.md#-content) on how to report an issue, or chat with us in the `#webcomponents` channel of the [OpenUI5 Community Slack](https://join-ui5-slack.herokuapp.com/).
|
32
32
|
|
33
33
|
## Contribute
|
34
|
-
Please check our [Contribution Guidelines](https://github.com/SAP/ui5-webcomponents/blob/master/
|
34
|
+
Please check our [Contribution Guidelines](https://github.com/SAP/ui5-webcomponents/blob/master/docs/6-contributing/02-conventions-and-guidelines.md).
|
35
35
|
|
36
36
|
## License
|
37
37
|
Copyright (c) 2019 SAP SE or an SAP affiliate company. All rights reserved.
|
package/index.js
CHANGED
@@ -1,8 +1,9 @@
|
|
1
|
+
#!/usr/bin/env node
|
2
|
+
|
1
3
|
const fs = require("fs");
|
2
4
|
const path = require("path");
|
3
5
|
const mkdirp = require("mkdirp");
|
4
6
|
const prompts = require("prompts");
|
5
|
-
const beautify = require("json-beautify");
|
6
7
|
const parser = require("npm-config-user-agent-parser");
|
7
8
|
|
8
9
|
// from where all the files will be copied
|
@@ -129,11 +130,11 @@ const createWebcomponentsPackage = async () => {
|
|
129
130
|
"./*": "./dist/*",
|
130
131
|
},
|
131
132
|
"dependencies": {
|
132
|
-
"@ui5/webcomponents-base": "
|
133
|
-
"@ui5/webcomponents-
|
133
|
+
"@ui5/webcomponents-base": "1.1.1",
|
134
|
+
"@ui5/webcomponents-theming": "1.1.1",
|
134
135
|
},
|
135
136
|
"devDependencies": {
|
136
|
-
"@ui5/webcomponents-tools": "
|
137
|
+
"@ui5/webcomponents-tools": "1.1.1",
|
137
138
|
"chromedriver": "*",
|
138
139
|
},
|
139
140
|
};
|
@@ -141,11 +142,11 @@ const createWebcomponentsPackage = async () => {
|
|
141
142
|
// Update package.json
|
142
143
|
const destDir = path.join(`./`, name);
|
143
144
|
mkdirp.sync(destDir);
|
144
|
-
fs.writeFileSync(path.join(destDir, "package.json"),
|
145
|
+
fs.writeFileSync(path.join(destDir, "package.json"), JSON.stringify(packageContent, null, 2));
|
145
146
|
// Copy files
|
146
147
|
copyFiles(vars, TEMPLATE_DIR, destDir);
|
147
148
|
|
148
|
-
console.log("
|
149
|
+
console.log("\nPackage successfully created!\nNext steps:\n");
|
149
150
|
console.log(`$ cd ${name}`);
|
150
151
|
|
151
152
|
let userAgentInfo;
|
@@ -161,7 +162,7 @@ const createWebcomponentsPackage = async () => {
|
|
161
162
|
console.log(`$ npm start`);
|
162
163
|
}
|
163
164
|
|
164
|
-
console.log("\n
|
165
|
+
console.log("\n");
|
165
166
|
};
|
166
167
|
|
167
168
|
createWebcomponentsPackage();
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@ui5/create-webcomponents-package",
|
3
|
-
"version": "
|
3
|
+
"version": "1.1.2",
|
4
4
|
"description": "UI5 Web Components: create package",
|
5
5
|
"author": "SAP SE (https://www.sap.com)",
|
6
6
|
"license": "Apache-2.0",
|
@@ -19,7 +19,6 @@
|
|
19
19
|
"directory": "packages/create-package"
|
20
20
|
},
|
21
21
|
"dependencies": {
|
22
|
-
"json-beautify": "^1.1.1",
|
23
22
|
"mkdirp": "^1.0.4",
|
24
23
|
"npm-config-user-agent-parser": "^1.0.0",
|
25
24
|
"prompts": "^2.4.1"
|
package/template/src/Assets.js
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
import UI5Element from "@ui5/webcomponents-base/dist/UI5Element.js";
|
2
2
|
import litRender from "@ui5/webcomponents-base/dist/renderer/LitRenderer.js";
|
3
|
-
import {
|
3
|
+
import { getI18nBundle } from "@ui5/webcomponents-base/dist/i18nBundle.js";
|
4
4
|
|
5
5
|
// Template
|
6
6
|
import INIT_PACKAGE_VAR_CLASS_NAMETemplate from "./generated/templates/INIT_PACKAGE_VAR_CLASS_NAMETemplate.lit.js";
|
@@ -21,15 +21,6 @@ const metadata = {
|
|
21
21
|
};
|
22
22
|
|
23
23
|
class INIT_PACKAGE_VAR_CLASS_NAME extends UI5Element {
|
24
|
-
constructor() {
|
25
|
-
super();
|
26
|
-
this.i18nBundle = getI18nBundle("INIT_PACKAGE_VAR_NAME");
|
27
|
-
}
|
28
|
-
|
29
|
-
get pleaseWaitText() {
|
30
|
-
return this.i18nBundle.getText(PLEASE_WAIT);
|
31
|
-
}
|
32
|
-
|
33
24
|
static get metadata() {
|
34
25
|
return metadata;
|
35
26
|
}
|
@@ -47,7 +38,11 @@ class INIT_PACKAGE_VAR_CLASS_NAME extends UI5Element {
|
|
47
38
|
}
|
48
39
|
|
49
40
|
static async onDefine() {
|
50
|
-
await
|
41
|
+
INIT_PACKAGE_VAR_CLASS_NAME.i18nBundle = await getI18nBundle("INIT_PACKAGE_VAR_NAME");
|
42
|
+
}
|
43
|
+
|
44
|
+
get pleaseWaitText() {
|
45
|
+
return INIT_PACKAGE_VAR_CLASS_NAME.i18nBundle.getText(PLEASE_WAIT);
|
51
46
|
}
|
52
47
|
}
|
53
48
|
|