@monimesl/dot-runtime 0.1.0-alpha.10 → 0.1.0-alpha.12
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/README.md +10 -0
- package/dot.schema.json +9 -77
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -1 +1,11 @@
|
|
|
1
1
|
# @monimesl/dot-runtime
|
|
2
|
+
|
|
3
|
+
Everything a dot needs: `defineDot`, `definePage`, the `dash` calls, and the renderer that draws its
|
|
4
|
+
pages. It also ships `dot.schema.json`, the schema editors use to check and complete `dot.json`.
|
|
5
|
+
|
|
6
|
+
## Which Dash opens a dot
|
|
7
|
+
|
|
8
|
+
The build writes the runtime's version into the dot's `manifest.json`. Dash opens the dot unless it
|
|
9
|
+
was built with a newer major version than the runtime Dash has. A newer minor version can add Dash
|
|
10
|
+
calls that an older Dash doesn't have yet. There, such a call fails with a `HostError` whose `code`
|
|
11
|
+
is `unsupported`, so catch it and carry on without the feature.
|
package/dot.schema.json
CHANGED
|
@@ -4,16 +4,21 @@
|
|
|
4
4
|
"description": "Settings for a dot, a mini app that runs inside Dash. Pages are listed in dot.ts, with defineDot({ pages }).",
|
|
5
5
|
"type": "object",
|
|
6
6
|
"properties": {
|
|
7
|
+
"id": {
|
|
8
|
+
"description": "The ID Monime gives the dot when you register it. Only publishing needs it.",
|
|
9
|
+
"type": "string",
|
|
10
|
+
"minLength": 1
|
|
11
|
+
},
|
|
7
12
|
"$schema": {
|
|
8
13
|
"description": "The schema editors use to check and complete this file.",
|
|
9
14
|
"type": "string"
|
|
10
15
|
},
|
|
11
|
-
"
|
|
12
|
-
"description": "The dot's
|
|
16
|
+
"package": {
|
|
17
|
+
"description": "The dot's package name: a reverse domain name you own, such as \"com.mysalone.thing\". It never changes once the dot is published.",
|
|
13
18
|
"type": "string",
|
|
14
19
|
"pattern": "^(?=[a-z])[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)+$",
|
|
15
20
|
"maxLength": 128,
|
|
16
|
-
"patternErrorMessage": "Use
|
|
21
|
+
"patternErrorMessage": "Use lowercase words joined by dots, such as \"com.mysalone.thing\"."
|
|
17
22
|
},
|
|
18
23
|
"name": {
|
|
19
24
|
"description": "The dot's display name, which Dash shows.",
|
|
@@ -27,65 +32,6 @@
|
|
|
27
32
|
"patternErrorMessage": "Use a semantic version, such as \"1.0.0\".",
|
|
28
33
|
"examples": ["1.0.0", "1.1.0-beta.1"]
|
|
29
34
|
},
|
|
30
|
-
"description": {
|
|
31
|
-
"description": "One line about what the dot does, shown in Dash's listing.",
|
|
32
|
-
"type": "string",
|
|
33
|
-
"minLength": 1
|
|
34
|
-
},
|
|
35
|
-
"categories": {
|
|
36
|
-
"description": "Where Dash lists the dot: one or more, such as [\"finance\", \"savings\"].",
|
|
37
|
-
"type": "array",
|
|
38
|
-
"items": {
|
|
39
|
-
"type": "string",
|
|
40
|
-
"enum": [
|
|
41
|
-
"agriculture",
|
|
42
|
-
"asset_finance",
|
|
43
|
-
"donations",
|
|
44
|
-
"education",
|
|
45
|
-
"electricity",
|
|
46
|
-
"entertainment",
|
|
47
|
-
"events",
|
|
48
|
-
"finance",
|
|
49
|
-
"food_and_drink",
|
|
50
|
-
"gambling",
|
|
51
|
-
"games",
|
|
52
|
-
"government",
|
|
53
|
-
"health",
|
|
54
|
-
"insurance",
|
|
55
|
-
"internet_service_provider",
|
|
56
|
-
"investments",
|
|
57
|
-
"jobs",
|
|
58
|
-
"lifestyle",
|
|
59
|
-
"loans",
|
|
60
|
-
"micro_credit",
|
|
61
|
-
"microfinance",
|
|
62
|
-
"news",
|
|
63
|
-
"other",
|
|
64
|
-
"productivity",
|
|
65
|
-
"real_estate",
|
|
66
|
-
"religion",
|
|
67
|
-
"remittances",
|
|
68
|
-
"savings",
|
|
69
|
-
"shopping",
|
|
70
|
-
"social",
|
|
71
|
-
"sports",
|
|
72
|
-
"telecom",
|
|
73
|
-
"television",
|
|
74
|
-
"transport",
|
|
75
|
-
"travel",
|
|
76
|
-
"utilities",
|
|
77
|
-
"water"
|
|
78
|
-
]
|
|
79
|
-
},
|
|
80
|
-
"minItems": 1,
|
|
81
|
-
"uniqueItems": true
|
|
82
|
-
},
|
|
83
|
-
"icon": {
|
|
84
|
-
"description": "The dot's icon: a square PNG file, relative to this file, such as \"icon.png\".",
|
|
85
|
-
"type": "string",
|
|
86
|
-
"pattern": "\\.png$",
|
|
87
|
-
"patternErrorMessage": "Use a PNG file, such as \"icon.png\"."
|
|
88
|
-
},
|
|
89
35
|
"permissions": {
|
|
90
36
|
"description": "What the dot may ask the person for, each with the reason Dash shows before granting it.",
|
|
91
37
|
"type": "object",
|
|
@@ -118,22 +64,8 @@
|
|
|
118
64
|
},
|
|
119
65
|
"required": ["hosts"],
|
|
120
66
|
"additionalProperties": false
|
|
121
|
-
},
|
|
122
|
-
"dash": {
|
|
123
|
-
"description": "What the dot needs from Dash, the app it runs in.",
|
|
124
|
-
"type": "object",
|
|
125
|
-
"properties": {
|
|
126
|
-
"minVersion": {
|
|
127
|
-
"description": "The oldest Dash version the dot runs in, such as \"2.4.0\". Older versions of Dash should not open it.",
|
|
128
|
-
"type": "string",
|
|
129
|
-
"pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(?:-((?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\\.(?:0|[1-9]\\d*|\\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\\+([0-9a-zA-Z-]+(?:\\.[0-9a-zA-Z-]+)*))?$",
|
|
130
|
-
"patternErrorMessage": "Use a semantic version, such as \"2.4.0\".",
|
|
131
|
-
"examples": ["2.4.0"]
|
|
132
|
-
}
|
|
133
|
-
},
|
|
134
|
-
"additionalProperties": false
|
|
135
67
|
}
|
|
136
68
|
},
|
|
137
|
-
"required": ["
|
|
69
|
+
"required": ["package", "name", "version"],
|
|
138
70
|
"additionalProperties": false
|
|
139
71
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@monimesl/dot-runtime",
|
|
3
|
-
"version": "0.1.0-alpha.
|
|
3
|
+
"version": "0.1.0-alpha.12",
|
|
4
4
|
"description": "A composer of the service and webview runtimes and the default React renderer",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"repository": {
|
|
@@ -54,10 +54,10 @@
|
|
|
54
54
|
"main": "./dist/index.js",
|
|
55
55
|
"types": "./dist/index.d.ts",
|
|
56
56
|
"dependencies": {
|
|
57
|
-
"@monimesl/dot-
|
|
58
|
-
"@monimesl/dot-
|
|
59
|
-
"@monimesl/dot-webview": "0.1.0-alpha.
|
|
60
|
-
"@monimesl/dot-service": "0.1.0-alpha.
|
|
57
|
+
"@monimesl/dot-renderer-react": "0.1.0-alpha.12",
|
|
58
|
+
"@monimesl/dot-dash": "0.1.0-alpha.12",
|
|
59
|
+
"@monimesl/dot-webview": "0.1.0-alpha.12",
|
|
60
|
+
"@monimesl/dot-service": "0.1.0-alpha.12"
|
|
61
61
|
},
|
|
62
62
|
"devDependencies": {
|
|
63
63
|
"publint": "^0.3.24",
|