pxt-core 8.2.12 → 8.2.14
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/built/buildengine.js +3 -3
- package/built/cli.js +5 -5
- package/built/gdb.js +4 -4
- package/built/nodeutil.d.ts +1 -0
- package/built/pxt.js +366 -364
- package/built/pxtblockly.js +35 -35
- package/built/pxtblocks.js +35 -35
- package/built/pxtcompiler.js +162 -160
- package/built/pxteditor.d.ts +15 -3
- package/built/pxteditor.js +6 -6
- package/built/pxtlib.d.ts +2 -1
- package/built/pxtlib.js +162 -161
- package/built/pxtpy.js +34 -35
- package/built/pxtsim.d.ts +5 -5
- package/built/pxtsim.js +3 -3
- package/built/server.js +5 -5
- package/built/storage.js +4 -4
- package/built/target.js +1 -1
- package/built/web/main.js +1 -1
- package/built/web/pxtapp.js +1 -1
- package/built/web/pxtasseteditor.js +1 -1
- package/built/web/pxtcompiler.js +1 -1
- package/built/web/pxteditor.js +1 -1
- package/built/web/pxtembed.js +2 -2
- package/built/web/pxtlib.js +1 -1
- package/built/web/pxtpy.js +1 -1
- package/built/web/pxtsim.js +1 -1
- package/built/web/pxtworker.js +1 -1
- package/built/web/rtlsemantic.css +1 -1
- package/built/web/semantic.css +1 -1
- package/built/web/skillmap/js/2.960f04a5.chunk.js +2 -0
- package/built/web/skillmap/js/main.44b2383f.chunk.js +1 -0
- package/common-docs/static/logo/social-buttons/google-classroom.png +0 -0
- package/common-docs/static/logo/social-buttons/microsoft-teams.png +0 -0
- package/docfiles/pxtweb/tsconfig.json +2 -1
- package/localtypings/dom.d.ts +3 -0
- package/localtypings/react.d.ts +1 -1
- package/package.json +6 -6
- package/react-common/components/controls/Modal.tsx +2 -2
- package/react-common/components/share/ShareInfo.tsx +1 -1
- package/react-common/tsconfig.json +3 -2
- package/theme/common.less +5 -3
- package/theme/highcontrast.less +3 -0
- package/theme/toolbox.less +25 -0
- package/theme/tutorial-sidebar.less +171 -115
- package/webapp/public/skillmap.html +1 -1
- package/built/web/skillmap/js/2.26325281.chunk.js +0 -2
- package/built/web/skillmap/js/main.d94a2bd9.chunk.js +0 -1
package/built/pxteditor.d.ts
CHANGED
|
@@ -174,6 +174,17 @@ declare namespace pxt.editor {
|
|
|
174
174
|
initials?: string;
|
|
175
175
|
photo?: string;
|
|
176
176
|
}
|
|
177
|
+
interface ShareData {
|
|
178
|
+
url: string;
|
|
179
|
+
embed: {
|
|
180
|
+
code?: string;
|
|
181
|
+
editor?: string;
|
|
182
|
+
simulator?: string;
|
|
183
|
+
url?: string;
|
|
184
|
+
};
|
|
185
|
+
qr?: string;
|
|
186
|
+
error?: any;
|
|
187
|
+
}
|
|
177
188
|
type Activity = "tutorial" | "recipe" | "example";
|
|
178
189
|
interface IProjectView {
|
|
179
190
|
state: IAppState;
|
|
@@ -242,9 +253,9 @@ declare namespace pxt.editor {
|
|
|
242
253
|
clearUserPoke(): void;
|
|
243
254
|
setHintSeen(step: number): void;
|
|
244
255
|
setEditorOffset(): void;
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
256
|
+
anonymousPublishHeaderByIdAsync(headerId: string, projectName?: string): Promise<ShareData>;
|
|
257
|
+
publishCurrentHeaderAsync(persistent: boolean, screenshotUri?: string): Promise<string>;
|
|
258
|
+
publishAsync(name: string, screenshotUri?: string, forceAnonymous?: boolean): Promise<pxt.editor.ShareData>;
|
|
248
259
|
startStopSimulator(opts?: SimulatorStartOptions): void;
|
|
249
260
|
stopSimulator(unload?: boolean, opts?: SimulatorStartOptions): void;
|
|
250
261
|
restartSimulator(): void;
|
|
@@ -746,6 +757,7 @@ declare namespace pxt.editor {
|
|
|
746
757
|
interface EditorShareRequest extends EditorMessageRequest {
|
|
747
758
|
action: "shareproject";
|
|
748
759
|
headerId: string;
|
|
760
|
+
projectName: string;
|
|
749
761
|
}
|
|
750
762
|
interface EditorShareResponse extends EditorMessageRequest {
|
|
751
763
|
action: "shareproject";
|
package/built/pxteditor.js
CHANGED
|
@@ -259,7 +259,7 @@ var pxt;
|
|
|
259
259
|
}
|
|
260
260
|
case "shareproject": {
|
|
261
261
|
const msg = data;
|
|
262
|
-
return projectView.anonymousPublishHeaderByIdAsync(msg.headerId)
|
|
262
|
+
return projectView.anonymousPublishHeaderByIdAsync(msg.headerId, msg.projectName)
|
|
263
263
|
.then(scriptInfo => {
|
|
264
264
|
resp = scriptInfo;
|
|
265
265
|
});
|
|
@@ -1146,13 +1146,13 @@ var pxt;
|
|
|
1146
1146
|
const name = matchedName.trim();
|
|
1147
1147
|
const project = pxt.react.getTilemapProject();
|
|
1148
1148
|
this.isAsset = true;
|
|
1149
|
-
const asset = project.lookupAssetByName("image" /* Image */, name);
|
|
1149
|
+
const asset = project.lookupAssetByName("image" /* pxt.AssetType.Image */, name);
|
|
1150
1150
|
if (asset) {
|
|
1151
1151
|
return asset;
|
|
1152
1152
|
}
|
|
1153
1153
|
else {
|
|
1154
1154
|
const newAsset = project.createNewImage();
|
|
1155
|
-
if (name && !project.isNameTaken("image" /* Image */, name) && pxt.validateAssetName(name)) {
|
|
1155
|
+
if (name && !project.isNameTaken("image" /* pxt.AssetType.Image */, name) && pxt.validateAssetName(name)) {
|
|
1156
1156
|
newAsset.meta.displayName = name;
|
|
1157
1157
|
}
|
|
1158
1158
|
return newAsset;
|
|
@@ -1189,7 +1189,7 @@ var pxt;
|
|
|
1189
1189
|
editor.MonacoSpriteEditor = MonacoSpriteEditor;
|
|
1190
1190
|
function createFakeAsset(bitmap) {
|
|
1191
1191
|
return {
|
|
1192
|
-
type: "image" /* Image */,
|
|
1192
|
+
type: "image" /* pxt.AssetType.Image */,
|
|
1193
1193
|
id: "",
|
|
1194
1194
|
internalID: 0,
|
|
1195
1195
|
bitmap: bitmap.data(),
|
|
@@ -1252,7 +1252,7 @@ var pxt;
|
|
|
1252
1252
|
let id;
|
|
1253
1253
|
if (name) {
|
|
1254
1254
|
id = ts.pxtc.escapeIdentifier(name);
|
|
1255
|
-
proj = project.getTilemap(id) || project.lookupAssetByName("tilemap" /* Tilemap */, name);
|
|
1255
|
+
proj = project.getTilemap(id) || project.lookupAssetByName("tilemap" /* AssetType.Tilemap */, name);
|
|
1256
1256
|
}
|
|
1257
1257
|
if (!proj) {
|
|
1258
1258
|
let tileWidth = 16;
|
|
@@ -1320,7 +1320,7 @@ var pxt;
|
|
|
1320
1320
|
editor.MonacoTilemapEditor = MonacoTilemapEditor;
|
|
1321
1321
|
function createFakeAsset(data) {
|
|
1322
1322
|
return {
|
|
1323
|
-
type: "tilemap" /* Tilemap */,
|
|
1323
|
+
type: "tilemap" /* pxt.AssetType.Tilemap */,
|
|
1324
1324
|
id: "",
|
|
1325
1325
|
internalID: 0,
|
|
1326
1326
|
meta: {},
|
package/built/pxtlib.d.ts
CHANGED
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
/// <reference path="../localtypings/pxtparts.d.ts" />
|
|
3
3
|
/// <reference path="../localtypings/pxtarget.d.ts" />
|
|
4
4
|
/// <reference path="../localtypings/projectheader.d.ts" />
|
|
5
|
+
/// <reference path="../localtypings/dom.d.ts" />
|
|
5
6
|
/// <reference path="../localtypings/dompurify.d.ts" />
|
|
6
7
|
/// <reference path="../pxtcompiler/ext-typescript/lib/typescriptServices.d.ts" />
|
|
7
8
|
/// <reference types="marked" />
|
|
@@ -396,7 +397,7 @@ declare namespace ts.pxtc.Util {
|
|
|
396
397
|
export function nowSeconds(): number;
|
|
397
398
|
export function timeout(ms: number): Promise<void>;
|
|
398
399
|
export let cpuUs: () => number;
|
|
399
|
-
export function getMime(filename: string): "
|
|
400
|
+
export function getMime(filename: string): "text/plain" | "text/html" | "text/css" | "application/javascript" | "image/jpeg" | "image/png" | "image/x-icon" | "text/cache-manifest" | "application/manifest+json" | "application/json" | "image/svg+xml" | "application/vnd.ms-fontobject" | "font/ttf" | "application/font-woff" | "application/font-woff2" | "text/markdown" | "application/xml" | "audio/m4a" | "audio/mp3" | "application/octet-stream";
|
|
400
401
|
export function randomUint32(): number;
|
|
401
402
|
export function guidGen(): string;
|
|
402
403
|
export function downloadLiveTranslationsAsync(lang: string, filename: string, branch?: string, etag?: string): Promise<pxt.Map<string>>;
|