@builder.io/sdk 1.1.27-0 → 1.1.27-3
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 +6 -0
- package/README.md +5 -4
- package/dist/index.browser.js +1 -1
- package/dist/index.browser.js.map +1 -1
- package/dist/index.cjs.js +61 -56
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +61 -56
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +7 -6
- package/dist/index.js.map +1 -1
- package/dist/index.umd.js +61 -56
- package/dist/index.umd.js.map +1 -1
- package/dist/package.json +9 -2
- package/dist/src/builder.class.d.ts +203 -18
- package/dist/src/builder.class.js +63 -57
- package/dist/src/builder.class.js.map +1 -1
- package/dist/src/classes/animator.class.js +13 -12
- package/dist/src/classes/animator.class.js.map +1 -1
- package/dist/src/classes/cookies.class.js +8 -8
- package/dist/src/classes/cookies.class.js.map +1 -1
- package/dist/src/classes/observable.class.js +2 -1
- package/dist/src/classes/observable.class.js.map +1 -1
- package/dist/src/classes/promise.class.js +5 -4
- package/dist/src/classes/promise.class.js.map +1 -1
- package/dist/src/classes/query-string.class.js +2 -1
- package/dist/src/classes/query-string.class.js.map +1 -1
- package/dist/src/constants/builder.js +1 -0
- package/dist/src/constants/builder.js.map +1 -1
- package/dist/src/functions/assign.function.js +1 -0
- package/dist/src/functions/assign.function.js.map +1 -1
- package/dist/src/functions/fetch.function.js +3 -2
- package/dist/src/functions/fetch.function.js.map +1 -1
- package/dist/src/functions/finder.function.js +13 -11
- package/dist/src/functions/finder.function.js.map +1 -1
- package/dist/src/functions/get-top-level-domain.js +1 -0
- package/dist/src/functions/get-top-level-domain.js.map +1 -1
- package/dist/src/functions/next-tick.function.js +1 -0
- package/dist/src/functions/next-tick.function.js.map +1 -1
- package/dist/src/functions/omit.function.js +1 -0
- package/dist/src/functions/omit.function.js.map +1 -1
- package/dist/src/functions/throttle.function.js +1 -0
- package/dist/src/functions/throttle.function.js.map +1 -1
- package/dist/src/functions/uuid.js +1 -0
- package/dist/src/functions/uuid.js.map +1 -1
- package/dist/src/types/element.d.ts +4 -2
- package/docs/interfaces/Component.md +267 -0
- package/docs/interfaces/GetContentOptions.md +396 -0
- package/docs/interfaces/Input.md +232 -0
- package/docs/interfaces/InsertMenuConfig.md +83 -0
- package/docs/interfaces/InsertMenuItem.md +39 -0
- package/docs/interfaces/ParamsMap.md +5 -0
- package/docs/interfaces/UserAttributes.md +25 -0
- package/jest.config.ts +4 -4
- package/package.json +9 -2
- package/scripts/cleanup-generated-docs.js +18 -0
- package/typedoc.js +5 -0
- package/BUILD +0 -19
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
# Interface: InsertMenuItem
|
|
2
|
+
|
|
3
|
+
## Table of contents
|
|
4
|
+
|
|
5
|
+
### Properties
|
|
6
|
+
|
|
7
|
+
- [icon](InsertMenuItem.md#icon)
|
|
8
|
+
- [item](InsertMenuItem.md#item)
|
|
9
|
+
- [name](InsertMenuItem.md#name)
|
|
10
|
+
|
|
11
|
+
## Properties
|
|
12
|
+
|
|
13
|
+
### icon
|
|
14
|
+
|
|
15
|
+
• `Optional` **icon**: `string`
|
|
16
|
+
|
|
17
|
+
#### Defined in
|
|
18
|
+
|
|
19
|
+
[builder.class.ts:732](https://github.com/builderio/builder/blob/faf038e7/packages/core/src/builder.class.ts#L732)
|
|
20
|
+
|
|
21
|
+
___
|
|
22
|
+
|
|
23
|
+
### item
|
|
24
|
+
|
|
25
|
+
• **item**: `DeepPartial`<`BuilderElement`\>
|
|
26
|
+
|
|
27
|
+
#### Defined in
|
|
28
|
+
|
|
29
|
+
[builder.class.ts:733](https://github.com/builderio/builder/blob/faf038e7/packages/core/src/builder.class.ts#L733)
|
|
30
|
+
|
|
31
|
+
___
|
|
32
|
+
|
|
33
|
+
### name
|
|
34
|
+
|
|
35
|
+
• **name**: `string`
|
|
36
|
+
|
|
37
|
+
#### Defined in
|
|
38
|
+
|
|
39
|
+
[builder.class.ts:731](https://github.com/builderio/builder/blob/faf038e7/packages/core/src/builder.class.ts#L731)
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# Interface: UserAttributes
|
|
2
|
+
|
|
3
|
+
Attributes that can be used for custom targeting. [https://www.builder.io/c/docs/guides/targeting-and-scheduling](https://www.builder.io/c/docs/guides/targeting-and-scheduling)
|
|
4
|
+
|
|
5
|
+
## Indexable
|
|
6
|
+
|
|
7
|
+
▪ [key: `string`]: `undefined` \| `string` \| `string`[] \| `boolean` \| `boolean`[] \| `number` \| `number`[] \| `Record`<`string`, `any`\>
|
|
8
|
+
|
|
9
|
+
## Table of contents
|
|
10
|
+
|
|
11
|
+
### Properties
|
|
12
|
+
|
|
13
|
+
- [urlPath](UserAttributes.md#urlpath)
|
|
14
|
+
|
|
15
|
+
## Properties
|
|
16
|
+
|
|
17
|
+
### urlPath
|
|
18
|
+
|
|
19
|
+
• `Optional` **urlPath**: `string`
|
|
20
|
+
|
|
21
|
+
URL path of the current user.
|
|
22
|
+
|
|
23
|
+
#### Defined in
|
|
24
|
+
|
|
25
|
+
[builder.class.ts:202](https://github.com/builderio/builder/blob/faf038e7/packages/core/src/builder.class.ts#L202)
|
package/jest.config.ts
CHANGED
|
@@ -23,7 +23,7 @@ export default {
|
|
|
23
23
|
// collectCoverageFrom: undefined,
|
|
24
24
|
|
|
25
25
|
// The directory where Jest should output its coverage files
|
|
26
|
-
coverageDirectory:
|
|
26
|
+
coverageDirectory: 'coverage',
|
|
27
27
|
|
|
28
28
|
// An array of regexp pattern strings used to skip coverage collection
|
|
29
29
|
// coveragePathIgnorePatterns: [
|
|
@@ -31,7 +31,7 @@ export default {
|
|
|
31
31
|
// ],
|
|
32
32
|
|
|
33
33
|
// Indicates which provider should be used to instrument code for coverage
|
|
34
|
-
coverageProvider:
|
|
34
|
+
coverageProvider: 'v8',
|
|
35
35
|
|
|
36
36
|
// A list of reporter names that Jest uses when writing coverage reports
|
|
37
37
|
// coverageReporters: [
|
|
@@ -137,7 +137,7 @@ export default {
|
|
|
137
137
|
// snapshotSerializers: [],
|
|
138
138
|
|
|
139
139
|
// The test environment that will be used for testing
|
|
140
|
-
testEnvironment:
|
|
140
|
+
testEnvironment: 'jsdom',
|
|
141
141
|
|
|
142
142
|
// Options that will be passed to the testEnvironment
|
|
143
143
|
// testEnvironmentOptions: {},
|
|
@@ -173,7 +173,7 @@ export default {
|
|
|
173
173
|
|
|
174
174
|
// A map from regular expressions to paths to transformers
|
|
175
175
|
transform: {
|
|
176
|
-
|
|
176
|
+
'\\.ts$': 'esbuild-runner/jest',
|
|
177
177
|
},
|
|
178
178
|
|
|
179
179
|
// An array of regexp pattern strings that are matched against all source file paths, matched files will skip transformation
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@builder.io/sdk",
|
|
3
|
-
"version": "1.1.27-
|
|
3
|
+
"version": "1.1.27-3",
|
|
4
4
|
"unpkg": "./dist/index.browser.js",
|
|
5
5
|
"main": "./dist/index.cjs.js",
|
|
6
6
|
"module": "./dist/index.esm.js",
|
|
@@ -13,6 +13,9 @@
|
|
|
13
13
|
"scripts": {
|
|
14
14
|
"_unlink": "npm unlink *",
|
|
15
15
|
"_install": "npm install",
|
|
16
|
+
"docs": "npm run docs:generate && npm run docs:cleanup",
|
|
17
|
+
"docs:generate": "typedoc",
|
|
18
|
+
"docs:cleanup": "node scripts/cleanup-generated-docs",
|
|
16
19
|
"build": "npm run tsc && rollup -c",
|
|
17
20
|
"watch": "rollup -cw",
|
|
18
21
|
"start": "npm run watch",
|
|
@@ -41,6 +44,8 @@
|
|
|
41
44
|
"@types/virtual-dom": "^2.0.27",
|
|
42
45
|
"esbuild": "0.14.14",
|
|
43
46
|
"esbuild-runner": "2.2.1",
|
|
47
|
+
"glob": "^7.2.3",
|
|
48
|
+
"glob-promise": "^4.2.2",
|
|
44
49
|
"jest": "27.4.7",
|
|
45
50
|
"rollup": "^0.58.2",
|
|
46
51
|
"rollup-plugin-alias": "^1.4.0",
|
|
@@ -53,7 +58,9 @@
|
|
|
53
58
|
"rollup-plugin-typescript": "^0.8.1",
|
|
54
59
|
"rollup-plugin-typescript2": "^0.13.0",
|
|
55
60
|
"rollup-plugin-uglify": "^3.0.0",
|
|
56
|
-
"
|
|
61
|
+
"typedoc": "^0.22.15",
|
|
62
|
+
"typedoc-plugin-markdown": "^3.12.1",
|
|
63
|
+
"typescript": "^4.6.4"
|
|
57
64
|
},
|
|
58
65
|
"dependencies": {
|
|
59
66
|
"hash-sum": "^2.0.0",
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
const glob = require('glob-promise');
|
|
2
|
+
const { readFile, writeFile } = require('fs').promises;
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Typedoc generates markdown files with links to docs that we gitignore,
|
|
6
|
+
* so let's clean out the dead links that display as breadcrumbs at the top
|
|
7
|
+
*/
|
|
8
|
+
async function main() {
|
|
9
|
+
const files = await glob('docs/**/*.md');
|
|
10
|
+
for (const file of files) {
|
|
11
|
+
const content = await readFile(file, 'utf8');
|
|
12
|
+
// Detect the initial breadcrumb pattern and remove it
|
|
13
|
+
const newContent = content.replace(/^\[@builder.io\/sdk\].*\n+/g, '');
|
|
14
|
+
await writeFile(file, newContent);
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
main();
|
package/typedoc.js
ADDED
package/BUILD
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
load("@npm//@bazel/typescript:index.bzl", "ts_project")
|
|
2
|
-
|
|
3
|
-
package(default_visibility = ["//visibility:public"])
|
|
4
|
-
|
|
5
|
-
ts_project(
|
|
6
|
-
name = "core",
|
|
7
|
-
srcs = glob(
|
|
8
|
-
[
|
|
9
|
-
"**/*.ts",
|
|
10
|
-
],
|
|
11
|
-
),
|
|
12
|
-
declaration = True,
|
|
13
|
-
source_map = True,
|
|
14
|
-
tsconfig = "//:tsconfig.json",
|
|
15
|
-
deps = [
|
|
16
|
-
"@npm_core//@types/node",
|
|
17
|
-
"@npm_core//tslib",
|
|
18
|
-
],
|
|
19
|
-
)
|