Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions lang/ui.en.json
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@
},
"connect-pattern-input-label": {
"defaultMessage": "Column {colNum} - number of LEDs lit on the micro:bit display",
"description": "Screenreader text for numeric pattern input"
"description": "Screen reader text for numeric pattern input"
},
"connect-pattern-subtitle": {
"defaultMessage": "Copy the pattern displayed on the micro:bit.",
Expand Down Expand Up @@ -1036,7 +1036,7 @@
"description": "Makecode block text. The translation should match MakeCode translations."
},
"makecode-load-error-dialog-body": {
"defaultMessage": "micro:bit CreateAI has failed to load MakeCode. Please check your internet connection, reload the page then try again.",
"defaultMessage": "{appNameFull} has failed to load MakeCode. Please check your internet connection, reload the page then try again.",
"description": "Content of MakeCode load error dialog"
},
"makecode-load-error-dialog-title": {
Expand Down Expand Up @@ -1647,4 +1647,4 @@
"defaultMessage": "unplug and replug the USB cable",
"description": "WebUSB error dialog"
}
}
}
7 changes: 6 additions & 1 deletion src/components/MakeCodeLoadErrorDialog.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,13 @@ import { useCallback } from "react";
import { FormattedMessage } from "react-intl";
import { useStore } from "../store";
import ExternalLink from "./ExternalLink";
import { useDeployment } from "../deployment";

const MakeCodeLoadErrorDialog = () => {
const isOpen = useStore((s) => s.isEditorTimedOutDialogOpen);
const setIsOpen = useStore((s) => s.setIsEditorTimedOutDialogOpen);
const onClose = useCallback(() => setIsOpen(false), [setIsOpen]);
const { appNameFull } = useDeployment();
return (
<Modal
motionPreset="none"
Expand All @@ -37,7 +39,10 @@ const MakeCodeLoadErrorDialog = () => {
<ModalBody>
<VStack textAlign="left" w="100%">
<Text w="100%">
<FormattedMessage id="makecode-load-error-dialog-body" />
<FormattedMessage
id="makecode-load-error-dialog-body"
values={{ appNameFull }}
/>
</Text>
</VStack>
</ModalBody>
Expand Down
Loading