-
Notifications
You must be signed in to change notification settings - Fork 8
/
circuit-construction-kit-dc_en.html
164 lines (152 loc) · 5.22 KB
/
circuit-construction-kit-dc_en.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
<!DOCTYPE HTML>
<!-- Top-level HTML file for circuit-construction-kit-dc generated by 'grunt generate-development-html' -->
<html>
<head>
<meta charset="utf-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=edge"/>
<meta name="viewport" content="initial-scale=1,user-scalable=no,maximum-scale=1"/>
<meta name="mobile-web-app-capable" content="yes">
<meta name="phet-sim-level" content="development">
<title>circuit-construction-kit-dc</title>
</head>
<!-- body is only made black for the loading phase so that the splash screen is black -->
<body style="background-color:black;">
<script type="text/javascript">
/* eslint-disable quotes, quote-props */
window.phet = window.phet || {};
window.phet.chipper = window.phet.chipper || {};
window.phet.chipper.packageObject =
{
"name": "circuit-construction-kit-dc",
"version": "1.4.0-dev.0",
"license": "GPL-3.0",
"repository": {
"type": "git",
"url": "https://github.com/phetsims/circuit-construction-kit-dc.git"
},
"devDependencies": {
"grunt": "~1.5.3"
},
"phet": {
"requirejsNamespace": "CIRCUIT_CONSTRUCTION_KIT_DC",
"phetLibs": [
"circuit-construction-kit-common",
"twixt",
"griddle",
"bamboo"
],
"runnable": true,
"supportedBrands": [
"phet",
"adapted-from-phet",
"phet-io"
],
"simulation": true,
"simFeatures": {
"supportsSound": false,
"supportsInteractiveDescription": true,
"supportsInteractiveHighlights": false,
"supportsDynamicLocale": true
},
"supportsOutputJS": true,
"published": true,
"phet-io": {
"compareDesignedAPIChanges": true,
"wrappers": [
"phet-io-sim-specific/repos/circuit-construction-kit-dc/wrappers/statistics-integration"
]
},
"screenNameKeys": [
"CIRCUIT_CONSTRUCTION_KIT_DC/screen.intro",
"CIRCUIT_CONSTRUCTION_KIT_DC/screen.lab"
]
}
};
window.phet.chipper.stringRepos =
[
{
"repo": "bamboo",
"requirejsNamespace": "BAMBOO"
},
{
"repo": "circuit-construction-kit-common",
"requirejsNamespace": "CIRCUIT_CONSTRUCTION_KIT_COMMON"
},
{
"repo": "circuit-construction-kit-dc",
"requirejsNamespace": "CIRCUIT_CONSTRUCTION_KIT_DC"
},
{
"repo": "griddle",
"requirejsNamespace": "GRIDDLE"
},
{
"repo": "joist",
"requirejsNamespace": "JOIST"
},
{
"repo": "scenery-phet",
"requirejsNamespace": "SCENERY_PHET"
},
{
"repo": "sun",
"requirejsNamespace": "SUN"
},
{
"repo": "tambo",
"requirejsNamespace": "TAMBO"
},
{
"repo": "twixt",
"requirejsNamespace": "TWIXT"
}
];
window.phet.chipper.allowLocaleSwitching = true;
// Identify the brand (assume generated brand if not provided with query parameters)
const brandMatch = location.search.match( /brand=([^&]+)/ );
const brand = brandMatch ? decodeURIComponent( brandMatch[ 1 ] ) : 'adapted-from-phet';
// Preloads, with more included for phet-io brand
let preloads = [
'../joist/js/splash.js',
'../sherpa/lib/jquery-2.1.0.js',
'../sherpa/lib/lodash-4.17.4.js',
'../sherpa/lib/FileSaver-b8054a2.js',
'../sherpa/lib/linebreak-1.1.0.js',
'../sherpa/lib/flatqueue-1.2.1.js',
'../sherpa/lib/paper-js-0.12.17.js',
'../sherpa/lib/he-1.1.1.js',
'../assert/js/assert.js',
'../query-string-machine/js/QueryStringMachine.js',
'../chipper/js/browser/initialize-globals.js',
'../sherpa/lib/seedrandom-2.4.2.js',
'../sherpa/lib/base64-js-1.2.0.js',
'../sherpa/lib/TextEncoderLite-3c9f6f0.js'
];
if ( brand === 'phet-io' ) {
preloads = preloads.concat( [
'../phet-io/js/phet-io-initialize-globals.js',
'../circuit-construction-kit-dc/js/circuit-construction-kit-dc-phet-io-overrides.js'
] );
}
// Loads a synchronously-executed asynchronously-downloaded script tag, with optional data-main parameter.
// See http://www.html5rocks.com/en/tutorials/speed/script-loading/ for more about script loading. It helps to
// load all of the scripts with this method, so they are treated the same (and placed in the correct execution
// order).
const loadURL = ( preloadURL, type = 'text/javascript' ) => {
const script = document.createElement( 'script' );
script.type = type;
script.src = preloadURL;
script.async = false;
script.setAttribute( 'crossorigin', 'use-credentials' );
document.head.appendChild( script );
};
// Kick off string loading immediately
loadURL( '../chipper/js/browser/load-unbuilt-strings.js' );
// Queue all of the preloads to be loaded.
preloads.forEach( preload => loadURL( preload ) );
// Module loading in compilation-free (development) mode will be kicked off once strings are loaded.
// This is done in load-unbuilt-strings.js
window.phet.chipper.loadModules = () => loadURL( '../chipper/dist/js/circuit-construction-kit-dc/js/circuit-construction-kit-dc-main.js', 'module' );
</script>
</body>
</html>