Repository: entrylabs/entryjs Branch: develop Commit: 21cb7edaa9ec Files: 944 Total size: 50.3 MB Directory structure: gitextract_80_zfnjb/ ├── .babelrc ├── .eslintignore ├── .eslintrc ├── .github/ │ ├── pr-labeler.yml │ └── workflows/ │ ├── build-and-deploy.yml │ ├── pull-request-workflow.yml │ └── release.yml ├── .gitignore ├── .prettierrc ├── COPYING ├── Gruntfile.js ├── Jenkinsfile ├── LICENSE ├── NOTICE ├── README-en.md ├── README.md ├── contributing.md ├── example/ │ ├── example.ejs │ ├── example_mini.ejs │ └── example_webgl.ejs ├── extern/ │ ├── blockly/ │ │ ├── .ropeproject/ │ │ │ ├── config.py │ │ │ ├── globalnames │ │ │ ├── history │ │ │ └── objectdb │ │ ├── blockly_compressed.js │ │ ├── blockly_uncompressed.js │ │ ├── blocks/ │ │ │ ├── colour.js │ │ │ ├── lists.js │ │ │ ├── logic.js │ │ │ ├── loops.js │ │ │ ├── math.js │ │ │ ├── procedures.js │ │ │ ├── text.js │ │ │ └── variables.js │ │ ├── blocks_compressed.js │ │ ├── build.py │ │ ├── core/ │ │ │ ├── block.js │ │ │ ├── block_menu.js │ │ │ ├── block_svg.js │ │ │ ├── blockly.js │ │ │ ├── blocks.js │ │ │ ├── bubble.js │ │ │ ├── comment.js │ │ │ ├── connection-animation.js │ │ │ ├── connection.js │ │ │ ├── contextmenu.js │ │ │ ├── css.js │ │ │ ├── field.js │ │ │ ├── field_angle.js │ │ │ ├── field_checkbox.js │ │ │ ├── field_colour.js │ │ │ ├── field_dropdown.js │ │ │ ├── field_dropdowndynamic.js │ │ │ ├── field_icon.js │ │ │ ├── field_image.js │ │ │ ├── field_keydown_input.js │ │ │ ├── field_label.js │ │ │ ├── field_textinput.js │ │ │ ├── field_variable.js │ │ │ ├── flyout.js │ │ │ ├── generator.js │ │ │ ├── icon.js │ │ │ ├── inject.js │ │ │ ├── input.js │ │ │ ├── msg.js │ │ │ ├── mutator.js │ │ │ ├── names.js │ │ │ ├── procedures.js │ │ │ ├── realtime-client-utils.js │ │ │ ├── realtime.js │ │ │ ├── scrollbar.js │ │ │ ├── toolbox.js │ │ │ ├── tooltip.js │ │ │ ├── trashcan.js │ │ │ ├── utils.js │ │ │ ├── variables.js │ │ │ ├── warning.js │ │ │ ├── widgetdiv.js │ │ │ ├── workspace.js │ │ │ └── xml.js │ │ ├── dart_compressed.js │ │ ├── generators/ │ │ │ ├── dart/ │ │ │ │ ├── colour.js │ │ │ │ ├── lists.js │ │ │ │ ├── logic.js │ │ │ │ ├── loops.js │ │ │ │ ├── math.js │ │ │ │ ├── procedures.js │ │ │ │ ├── text.js │ │ │ │ └── variables.js │ │ │ ├── dart.js │ │ │ ├── javascript/ │ │ │ │ ├── colour.js │ │ │ │ ├── lists.js │ │ │ │ ├── logic.js │ │ │ │ ├── loops.js │ │ │ │ ├── math.js │ │ │ │ ├── procedures.js │ │ │ │ ├── text.js │ │ │ │ └── variables.js │ │ │ ├── javascript.js │ │ │ ├── python/ │ │ │ │ ├── colour.js │ │ │ │ ├── lists.js │ │ │ │ ├── logic.js │ │ │ │ ├── loops.js │ │ │ │ ├── math.js │ │ │ │ ├── procedures.js │ │ │ │ ├── text.js │ │ │ │ └── variables.js │ │ │ └── python.js │ │ ├── i18n/ │ │ │ ├── common.py │ │ │ ├── create_messages.py │ │ │ ├── dedup_json.py │ │ │ ├── js_to_json.py │ │ │ ├── json_to_js.py │ │ │ ├── status.py │ │ │ ├── tests.py │ │ │ └── xliff_to_json.py │ │ ├── javascript_compressed.js │ │ ├── media/ │ │ │ ├── click.ogg │ │ │ ├── delete.ogg │ │ │ ├── handclosed.cur │ │ │ └── handopen.cur │ │ ├── msg/ │ │ │ ├── js/ │ │ │ │ ├── ar.js │ │ │ │ ├── az-latn.js │ │ │ │ ├── az.js │ │ │ │ ├── be-tarask.js │ │ │ │ ├── br.js │ │ │ │ ├── ca.js │ │ │ │ ├── cs.js │ │ │ │ ├── da.js │ │ │ │ ├── de.js │ │ │ │ ├── el.js │ │ │ │ ├── en.js │ │ │ │ ├── en_us.js │ │ │ │ ├── es.js │ │ │ │ ├── fa.js │ │ │ │ ├── fi.js │ │ │ │ ├── fr.js │ │ │ │ ├── he.js │ │ │ │ ├── hi.js │ │ │ │ ├── hu.js │ │ │ │ ├── ia.js │ │ │ │ ├── id.js │ │ │ │ ├── is.js │ │ │ │ ├── it.js │ │ │ │ ├── ja.js │ │ │ │ ├── ko.js │ │ │ │ ├── lrc.js │ │ │ │ ├── ms.js │ │ │ │ ├── nb.js │ │ │ │ ├── nl.js │ │ │ │ ├── no.js │ │ │ │ ├── pl.js │ │ │ │ ├── pms.js │ │ │ │ ├── pt-br.js │ │ │ │ ├── pt.js │ │ │ │ ├── ro.js │ │ │ │ ├── ru.js │ │ │ │ ├── sq.js │ │ │ │ ├── sr.js │ │ │ │ ├── sv.js │ │ │ │ ├── th.js │ │ │ │ ├── tl.js │ │ │ │ ├── tr.js │ │ │ │ ├── uk.js │ │ │ │ ├── vi.js │ │ │ │ ├── zh-hans.js │ │ │ │ └── zh-hant.js │ │ │ ├── json/ │ │ │ │ ├── ar.json │ │ │ │ ├── az.json │ │ │ │ ├── be-tarask.json │ │ │ │ ├── br.json │ │ │ │ ├── ca.json │ │ │ │ ├── cs.json │ │ │ │ ├── da.json │ │ │ │ ├── de.json │ │ │ │ ├── el.json │ │ │ │ ├── en.json │ │ │ │ ├── es.json │ │ │ │ ├── fa.json │ │ │ │ ├── fi.json │ │ │ │ ├── fr.json │ │ │ │ ├── he.json │ │ │ │ ├── hi.json │ │ │ │ ├── hu.json │ │ │ │ ├── ia.json │ │ │ │ ├── id.json │ │ │ │ ├── is.json │ │ │ │ ├── it.json │ │ │ │ ├── ja.json │ │ │ │ ├── keys.json │ │ │ │ ├── ko.json │ │ │ │ ├── lrc.json │ │ │ │ ├── ms.json │ │ │ │ ├── nb.json │ │ │ │ ├── nl.json │ │ │ │ ├── pl.json │ │ │ │ ├── pms.json │ │ │ │ ├── pt-br.json │ │ │ │ ├── pt.json │ │ │ │ ├── qqq.json │ │ │ │ ├── ro.json │ │ │ │ ├── ru.json │ │ │ │ ├── sq.json │ │ │ │ ├── sr.json │ │ │ │ ├── sv.json │ │ │ │ ├── synonyms.json │ │ │ │ ├── th.json │ │ │ │ ├── tl.json │ │ │ │ ├── tr.json │ │ │ │ ├── uk.json │ │ │ │ ├── vi.json │ │ │ │ ├── zh-hans.json │ │ │ │ └── zh-hant.json │ │ │ └── messages.js │ │ ├── python_compressed.js │ │ └── tests/ │ │ ├── blockly_test.html │ │ ├── blockly_test.js │ │ ├── generator_test.js │ │ ├── generators/ │ │ │ ├── colour.xml │ │ │ ├── index.html │ │ │ ├── lists.xml │ │ │ ├── logic.xml │ │ │ ├── loops1.xml │ │ │ ├── loops2.xml │ │ │ ├── loops3.xml │ │ │ ├── math.xml │ │ │ ├── procedures.xml │ │ │ ├── text.xml │ │ │ ├── unittest.js │ │ │ ├── unittest_dart.js │ │ │ ├── unittest_javascript.js │ │ │ ├── unittest_python.js │ │ │ └── variables.xml │ │ ├── names_test.js │ │ └── playground.html │ ├── face-landmarker.worker.js │ ├── face-landmarker2.worker.js │ ├── gesture-recognition.worker.js │ ├── human/ │ │ ├── human.js │ │ └── models/ │ │ ├── blazeface.json │ │ ├── emotion.json │ │ ├── facemesh.json │ │ └── faceres.json │ ├── khaiii/ │ │ ├── cnv2hdn.lin │ │ ├── config.json │ │ ├── conv.2.fil │ │ ├── conv.3.fil │ │ ├── conv.4.fil │ │ ├── conv.5.fil │ │ ├── errpatch.len │ │ ├── errpatch.tri │ │ ├── errpatch.val │ │ ├── hdn2tag.lin │ │ ├── preanal.tri │ │ ├── preanal.val │ │ ├── restore.key │ │ ├── restore.one │ │ └── restore.val │ ├── lang/ │ │ ├── code.js │ │ ├── ebs.js │ │ ├── en.js │ │ ├── jp.js │ │ ├── ko.js │ │ └── vn.js │ ├── model/ │ │ ├── face_landmarker.task │ │ ├── gesture_recognizer.task │ │ ├── object_detector_lite.tflite │ │ └── pose_landmarker_lite.task │ ├── object-detector.worker.js │ ├── pose-landmarker.worker.js │ ├── tfjs-backend-wasm-simd.wasm │ ├── util/ │ │ ├── CanvasInput.js │ │ ├── CanvasInputOrg.js │ │ ├── DragDropTouch.js │ │ ├── filbert.js │ │ ├── handle.js │ │ ├── ndgmr.Collision.js │ │ ├── static.js │ │ └── static_mini.js │ ├── vision.worker.js │ ├── vision_bundle.js │ └── wasm/ │ ├── vision_wasm_internal.js │ ├── vision_wasm_internal.wasm │ ├── vision_wasm_nosimd_internal.js │ └── vision_wasm_nosimd_internal.wasm ├── images/ │ ├── cursor_eraser.cur │ ├── handclosed.cur │ ├── handopen.cur │ ├── media/ │ │ ├── FlashAudioPlugin.swf │ │ ├── click.ogg │ │ ├── delete.ogg │ │ ├── handclosed.cur │ │ └── handopen.cur │ └── sounds/ │ ├── click.ogg │ └── delete.ogg ├── jsconfig.json ├── karma.conf.js ├── package.json ├── scripts/ │ ├── build.sh │ ├── build_action.sh │ ├── deploy.sh │ └── deploy_action.sh ├── src/ │ ├── class/ │ │ ├── AILearning.js │ │ ├── AIUtilize.js │ │ ├── DataTable.js │ │ ├── Expansion.js │ │ ├── LiterallycanvasPainter.js │ │ ├── blockCountViewer.js │ │ ├── container.js │ │ ├── dialog.ts │ │ ├── doneProject.js │ │ ├── engine.js │ │ ├── entity.js │ │ ├── entryModuleLoader.ts │ │ ├── function.js │ │ ├── hardware/ │ │ │ ├── bluetoothServices/ │ │ │ │ ├── event-dispatcher.ts │ │ │ │ ├── index.ts │ │ │ │ ├── promise-queue.ts │ │ │ │ ├── service-helper.ts │ │ │ │ └── services/ │ │ │ │ ├── accelerometer.ts │ │ │ │ ├── button.ts │ │ │ │ ├── device-information.ts │ │ │ │ ├── dfu-control.ts │ │ │ │ ├── event.ts │ │ │ │ ├── io-pin.ts │ │ │ │ ├── led.ts │ │ │ │ ├── magnetometer.ts │ │ │ │ ├── temperature.ts │ │ │ │ └── uart.ts │ │ │ ├── externalProgramLauncher.ts │ │ │ ├── functions/ │ │ │ │ └── createHardwarePopup.ts │ │ │ ├── hardwareMonitor.ts │ │ │ ├── hardwareSocketMessageHandler.ts │ │ │ ├── webApiConnector.ts │ │ │ ├── webBluetoothConnector.ts │ │ │ ├── webSerialConnector.ts │ │ │ └── webUsbFlasher.ts │ │ ├── helper.js │ │ ├── hw.ts │ │ ├── hw_lite.ts │ │ ├── intro.ts │ │ ├── learning/ │ │ │ ├── Chart.js │ │ │ ├── Cluster.js │ │ │ ├── DecisionTree.js │ │ │ ├── ImageLearning.js │ │ │ ├── InputPopup.js │ │ │ ├── LearningBase.ts │ │ │ ├── LearningView.js │ │ │ ├── LogisticRegression.js │ │ │ ├── NumberClassification.js │ │ │ ├── Regression.js │ │ │ ├── SpeechClassification.js │ │ │ ├── Svm.js │ │ │ ├── TextLearning.js │ │ │ ├── Utils.ts │ │ │ └── bayes.ts │ │ ├── maxrect-packer/ │ │ │ ├── abstract_bin.ts │ │ │ ├── geom/ │ │ │ │ ├── ImageRect.ts │ │ │ │ └── Rectangle.ts │ │ │ ├── maxrects_bin.ts │ │ │ ├── maxrects_packer.ts │ │ │ └── oversized_element_bin.ts │ │ ├── object.js │ │ ├── painter.js │ │ ├── pdf.ts │ │ ├── pixi/ │ │ │ ├── atlas/ │ │ │ │ ├── AtlasCanvasViewer.ts │ │ │ │ ├── EntryTextureOption.ts │ │ │ │ ├── ISceneTextures.ts │ │ │ │ ├── PIXIAtlasHelper.ts │ │ │ │ ├── PIXIAtlasManager.ts │ │ │ │ ├── PIXIScaleAdaptor.ts │ │ │ │ ├── SceneBins.ts │ │ │ │ ├── SceneTextures.ts │ │ │ │ ├── loader/ │ │ │ │ │ ├── AtlasImageLoader.ts │ │ │ │ │ └── AtlasImageLoadingInfo.ts │ │ │ │ ├── model/ │ │ │ │ │ ├── IRawObject.ts │ │ │ │ │ └── IRawPicture.ts │ │ │ │ ├── structure/ │ │ │ │ │ ├── PrimitiveMap.ts │ │ │ │ │ └── PrimitiveSet.ts │ │ │ │ └── texture/ │ │ │ │ ├── AtlasBaseTexture.ts │ │ │ │ ├── AtlasTexture.ts │ │ │ │ ├── EntryBaseTexture.ts │ │ │ │ ├── EntryTexture.ts │ │ │ │ └── EntryTextureBase.ts │ │ │ ├── etc/ │ │ │ │ ├── PIXI-ndgmr.Collision.js │ │ │ │ ├── PIXIBrushAdaptor.ts │ │ │ │ ├── PIXICanvasInput.js │ │ │ │ ├── PIXIPaintAdaptor.ts │ │ │ │ └── PIXITempStore.ts │ │ │ ├── handle/ │ │ │ │ ├── PIXIHandle.js │ │ │ │ └── PIXIHandleEdge.js │ │ │ ├── helper/ │ │ │ │ ├── PIXIDragHelper.js │ │ │ │ └── PIXIHelper.ts │ │ │ ├── init/ │ │ │ │ ├── PIXIBaseAsset.ts │ │ │ │ ├── PIXIFontLoadHandler.ts │ │ │ │ └── PIXIGlobal.ts │ │ │ ├── mesh/ │ │ │ │ └── PIXIH3Plane.js │ │ │ ├── plugins/ │ │ │ │ ├── PIXIGraphicOverride.js │ │ │ │ ├── PIXIPixelPerfectInteractionPlugIn.js │ │ │ │ ├── PIXIShortPropPlugin.js │ │ │ │ ├── PIXISprite.ts │ │ │ │ ├── PIXITextMetricsPlugIn.js │ │ │ │ └── pixiGetChildAt.js │ │ │ ├── text/ │ │ │ │ ├── PIXIText.js │ │ │ │ └── PIXITextStyle.ts │ │ │ └── utils/ │ │ │ ├── AutoFit.ts │ │ │ ├── TimeoutTimer.ts │ │ │ └── logs.ts │ │ ├── playground.js │ │ ├── popup.js │ │ ├── popup_helper.ts │ │ ├── popup_list.js │ │ ├── project.js │ │ ├── property_panel.ts │ │ ├── reporter.js │ │ ├── scene.js │ │ ├── sound.ts │ │ ├── source/ │ │ │ └── DataTableSource.js │ │ ├── stage.js │ │ ├── stamp_entity.js │ │ ├── time_wait.js │ │ ├── toast.js │ │ ├── variable/ │ │ │ ├── answerVariable.js │ │ │ ├── index.js │ │ │ ├── listVariable.js │ │ │ ├── slideVariable.js │ │ │ ├── sttVariable.js │ │ │ ├── timerVariable.js │ │ │ └── variable.js │ │ └── variable_container.js │ ├── command/ │ │ ├── command.js │ │ ├── command_util.js │ │ ├── commander.js │ │ └── commands/ │ │ ├── block.js │ │ ├── comment.js │ │ ├── container.js │ │ ├── dataTable.js │ │ ├── engine.js │ │ ├── function.js │ │ ├── object.js │ │ ├── painter.js │ │ ├── playground.js │ │ ├── scene.js │ │ ├── textbox.js │ │ └── variableContainer.js │ ├── core/ │ │ ├── collection.js │ │ ├── db.js │ │ ├── dom.ts │ │ ├── event.js │ │ ├── model.js │ │ ├── modelClass.ts │ │ ├── observer.js │ │ ├── promiseManager.js │ │ ├── singleInstance.js │ │ └── svg.js │ ├── css/ │ │ ├── codemirror_theme.less │ │ ├── common.less │ │ ├── components/ │ │ │ ├── block.less │ │ │ ├── block_menu.less │ │ │ ├── board.less │ │ │ ├── console.less │ │ │ ├── container.less │ │ │ ├── context_menu.less │ │ │ ├── curtain.less │ │ │ ├── engine.less │ │ │ ├── extensions.less │ │ │ ├── function.less │ │ │ ├── global_svg.less │ │ │ ├── helper.less │ │ │ ├── hw_monitor.less │ │ │ ├── object.less │ │ │ ├── painter.less │ │ │ ├── pdf.less │ │ │ ├── playground.less │ │ │ ├── popup.less │ │ │ ├── property_panel.less │ │ │ ├── scene.less │ │ │ ├── stage.less │ │ │ ├── state_manager.less │ │ │ ├── table.less │ │ │ ├── target_checker.less │ │ │ ├── textcoding_helper.less │ │ │ ├── toast.less │ │ │ ├── tooltip.less │ │ │ ├── variable_container.less │ │ │ └── zoomController.less │ │ ├── entry.less │ │ ├── minimize.less │ │ ├── prefix.less │ │ └── static.less │ ├── entry.js │ ├── extensions/ │ │ ├── CloudVariable.js │ │ ├── dmet.js │ │ ├── dropper.js │ │ ├── extension.js │ │ └── target_checker.js │ ├── graphicEngine/ │ │ ├── EaselResManager.ts │ │ ├── FakePIXI.js │ │ ├── GEDragHelper.ts │ │ ├── GEHandle.js │ │ ├── GEHelper.ts │ │ └── IGEResManager.ts │ ├── log/ │ │ ├── activity.js │ │ ├── activityReporter.js │ │ ├── recorder.js │ │ ├── state.js │ │ └── state_manager.js │ ├── model/ │ │ ├── block_model.js │ │ ├── block_render_model.js │ │ ├── box_model.js │ │ ├── drag_instance.js │ │ └── thread_model.js │ ├── parser-no/ │ │ ├── block.js │ │ ├── js.js │ │ └── parser.js │ ├── playground/ │ │ ├── block.js │ │ ├── block_entry.js │ │ ├── block_entry_mini.js │ │ ├── block_menu.ts │ │ ├── block_menu_scroll.js │ │ ├── block_view.js │ │ ├── blocks/ │ │ │ ├── block_ai_learning.js │ │ │ ├── block_ai_learning_cluster.js │ │ │ ├── block_ai_learning_decisiontree.js │ │ │ ├── block_ai_learning_knn.js │ │ │ ├── block_ai_learning_logistic_regression.js │ │ │ ├── block_ai_learning_regression.js │ │ │ ├── block_ai_learning_svm.js │ │ │ ├── block_ai_utilize_audio.js │ │ │ ├── block_ai_utilize_face_landmarker.js │ │ │ ├── block_ai_utilize_gesture_recognition.js │ │ │ ├── block_ai_utilize_media_pipe.js │ │ │ ├── block_ai_utilize_object_detector.js │ │ │ ├── block_ai_utilize_pose_landmarker.js │ │ │ ├── block_ai_utilize_translate.js │ │ │ ├── block_ai_utilize_tts.js │ │ │ ├── block_ai_utilize_video.js │ │ │ ├── block_analysis.js │ │ │ ├── block_brush.js │ │ │ ├── block_calc.js │ │ │ ├── block_expansion_behaviorconduct_disaster.js │ │ │ ├── block_expansion_behaviorconduct_lifesafety.js │ │ │ ├── block_expansion_disasterAlert.js │ │ │ ├── block_expansion_emergencyActionGuidelines.js │ │ │ ├── block_expansion_festival.js │ │ │ ├── block_expansion_weather.js │ │ │ ├── block_flow.js │ │ │ ├── block_func.js │ │ │ ├── block_judgement.js │ │ │ ├── block_looks.js │ │ │ ├── block_moving.js │ │ │ ├── block_sound.js │ │ │ ├── block_start.js │ │ │ ├── block_text.js │ │ │ ├── block_variable.js │ │ │ ├── hardware/ │ │ │ │ ├── block_0uboard.js │ │ │ │ ├── block_CloverSEntry1.js │ │ │ │ ├── block_ITPLE_board.js │ │ │ │ ├── block_KKMOO.js │ │ │ │ ├── block_KRC.js │ │ │ │ ├── block_LineCoding.js │ │ │ │ ├── block_Lline.js │ │ │ │ ├── block_RichShield.js │ │ │ │ ├── block_abilix_Krypton0.js │ │ │ │ ├── block_aidrone.js │ │ │ │ ├── block_aidrone_tracking.js │ │ │ │ ├── block_aiot.js │ │ │ │ ├── block_aiservo.js │ │ │ │ ├── block_albert.js │ │ │ │ ├── block_albert_ai.js │ │ │ │ ├── block_altino.js │ │ │ │ ├── block_altino_lite.js │ │ │ │ ├── block_altino_neo.js │ │ │ │ ├── block_alux_connect.js │ │ │ │ ├── block_alux_nemo.js │ │ │ │ ├── block_alux_technic.js │ │ │ │ ├── block_ardublock.js │ │ │ │ ├── block_arduino.js │ │ │ │ ├── block_arduino_cake.js │ │ │ │ ├── block_arduino_ext.js │ │ │ │ ├── block_arduino_nano.js │ │ │ │ ├── block_armz.js │ │ │ │ ├── block_asomebot.js │ │ │ │ ├── block_asomekit.js │ │ │ │ ├── block_avatarbot.js │ │ │ │ ├── block_bingles.js │ │ │ │ ├── block_bitbrick.js │ │ │ │ ├── block_blacksmith.js │ │ │ │ ├── block_bridge.js │ │ │ │ ├── block_brown.js │ │ │ │ ├── block_byrobot_base.js │ │ │ │ ├── block_byrobot_controller_3_4.js │ │ │ │ ├── block_byrobot_controller_4.js │ │ │ │ ├── block_byrobot_drone_3_10.js │ │ │ │ ├── block_byrobot_drone_4.js │ │ │ │ ├── block_byrobot_drone_8.js │ │ │ │ ├── block_byrobot_dronefighter_controller.js │ │ │ │ ├── block_byrobot_dronefighter_drive.js │ │ │ │ ├── block_byrobot_dronefighter_flight.js │ │ │ │ ├── block_byrobot_petrone_v2_base.js │ │ │ │ ├── block_byrobot_petrone_v2_controller.js │ │ │ │ ├── block_byrobot_petrone_v2_drive.js │ │ │ │ ├── block_byrobot_petrone_v2_flight.js │ │ │ │ ├── block_c3coding_arduino.js │ │ │ │ ├── block_castarter_v2.js │ │ │ │ ├── block_cheese.js │ │ │ │ ├── block_choco.js │ │ │ │ ├── block_choco2.js │ │ │ │ ├── block_chocopi.js │ │ │ │ ├── block_coalaboard.js │ │ │ │ ├── block_cobl.js │ │ │ │ ├── block_coco.js │ │ │ │ ├── block_coconut.js │ │ │ │ ├── block_codeino.js │ │ │ │ ├── block_codestar.js │ │ │ │ ├── block_codewiz.js │ │ │ │ ├── block_coding_box.js │ │ │ │ ├── block_codingmachine.js │ │ │ │ ├── block_cp_moving.js │ │ │ │ ├── block_creamo.js │ │ │ │ ├── block_cremaker_3Dpen.js │ │ │ │ ├── block_cuboai.js │ │ │ │ ├── block_cue.js │ │ │ │ ├── block_dadublock.js │ │ │ │ ├── block_dalgona.js │ │ │ │ ├── block_dalgona_basic.js │ │ │ │ ├── block_dash.js │ │ │ │ ├── block_davinci.js │ │ │ │ ├── block_diaboard.js │ │ │ │ ├── block_dodaland.js │ │ │ │ ├── block_dplay.js │ │ │ │ ├── block_eduino.js │ │ │ │ ├── block_edumaker.js │ │ │ │ ├── block_elio.js │ │ │ │ ├── block_etboard.js │ │ │ │ ├── block_etkit.js │ │ │ │ ├── block_ev3.js │ │ │ │ ├── block_exmars_cube.js │ │ │ │ ├── block_firmtech2.js │ │ │ │ ├── block_freearduino.js │ │ │ │ ├── block_freelinker2.js │ │ │ │ ├── block_funboard.js │ │ │ │ ├── block_gbot.js │ │ │ │ ├── block_genirobot.js │ │ │ │ ├── block_hamster.js │ │ │ │ ├── block_hamster_s.js │ │ │ │ ├── block_handino.js │ │ │ │ ├── block_hasseam.js │ │ │ │ ├── block_hexaboard.js │ │ │ │ ├── block_hummingbird.js │ │ │ │ ├── block_hyact.js │ │ │ │ ├── block_iCOBOT.js │ │ │ │ ├── block_iboard.js │ │ │ │ ├── block_iotsmartfarm.js │ │ │ │ ├── block_jcboard.js │ │ │ │ ├── block_jdcode.js │ │ │ │ ├── block_jdkit.js │ │ │ │ ├── block_jikko.js │ │ │ │ ├── block_jikko_basic.js │ │ │ │ ├── block_jikko_lidoc.js │ │ │ │ ├── block_jikko_make.js │ │ │ │ ├── block_jinirobot_aibot.js │ │ │ │ ├── block_jinirobot_toybot.js │ │ │ │ ├── block_joystick.js │ │ │ │ ├── block_kaboino.js │ │ │ │ ├── block_kaduino.js │ │ │ │ ├── block_kamibot.js │ │ │ │ ├── block_kamibotPi.js │ │ │ │ ├── block_kingcoding.js │ │ │ │ ├── block_lecoboard.js │ │ │ │ ├── block_lecoboardAvr.js │ │ │ │ ├── block_lecoboardAvrBT.js │ │ │ │ ├── block_littlebits.js │ │ │ │ ├── block_magkinder.js │ │ │ │ ├── block_makermate.js │ │ │ │ ├── block_mechanicblock_controller.js │ │ │ │ ├── block_mechanicblock_uno.js │ │ │ │ ├── block_mechanicblock_uno_mini.js │ │ │ │ ├── block_mechanicblock_uno_s.js │ │ │ │ ├── block_mechatro.js │ │ │ │ ├── block_mechatronics_4d.js │ │ │ │ ├── block_memaker.js │ │ │ │ ├── block_microbit.js │ │ │ │ ├── block_microbit2.js │ │ │ │ ├── block_microbit_ext.js │ │ │ │ ├── block_mindpiggy.js │ │ │ │ ├── block_mkboard.js │ │ │ │ ├── block_modi.js │ │ │ │ ├── block_mrt.js │ │ │ │ ├── block_nemoino.js │ │ │ │ ├── block_neo.js │ │ │ │ ├── block_neo_cannon.js │ │ │ │ ├── block_neo_spider.js │ │ │ │ ├── block_neobot.js │ │ │ │ ├── block_neobot_game_theme.js │ │ │ │ ├── block_neobot_purple.js │ │ │ │ ├── block_neobot_robot_theme.js │ │ │ │ ├── block_neobot_sensor_theme.js │ │ │ │ ├── block_neobot_soco.js │ │ │ │ ├── block_neobot_thinkcar.js │ │ │ │ ├── block_orange.js │ │ │ │ ├── block_ozobot.js │ │ │ │ ├── block_palmkit.js │ │ │ │ ├── block_pingpong.js │ │ │ │ ├── block_pingpong_multi.js │ │ │ │ ├── block_playcode.js │ │ │ │ ├── block_plrun.js │ │ │ │ ├── block_robico.js │ │ │ │ ├── block_robodog.js │ │ │ │ ├── block_roboid.js │ │ │ │ ├── block_robolink_codrone_diy.js │ │ │ │ ├── block_robolink_codrone_edu.js │ │ │ │ ├── block_robolink_codrone_mini.js │ │ │ │ ├── block_robomation.js │ │ │ │ ├── block_roborobo_base.js │ │ │ │ ├── block_roborobo_cube.js │ │ │ │ ├── block_roborobo_robokit_rs.js │ │ │ │ ├── block_roborobo_roduino.js │ │ │ │ ├── block_roborobo_roe.js │ │ │ │ ├── block_roborobo_schoolkit.js │ │ │ │ ├── block_robotamicoding.js │ │ │ │ ├── block_robotis.js │ │ │ │ ├── block_robotisDream.js │ │ │ │ ├── block_robotisRB.js │ │ │ │ ├── block_robotisRBCar.js │ │ │ │ ├── block_robotisRBHumanoid.js │ │ │ │ ├── block_robotisRBKoala.js │ │ │ │ ├── block_robotisRBPracticalAssembly.js │ │ │ │ ├── block_robotori.js │ │ │ │ ├── block_robotry_parodule.js │ │ │ │ ├── block_robotry_robit_stage.js │ │ │ │ ├── block_rokoboard.js │ │ │ │ ├── block_runcoding.js │ │ │ │ ├── block_runcoding_display.js │ │ │ │ ├── block_sally.js │ │ │ │ ├── block_sciencecube.js │ │ │ │ ├── block_sensorboard.js │ │ │ │ ├── block_smartCodingHouse.js │ │ │ │ ├── block_smartboard.js │ │ │ │ ├── block_ssboard_nano.js │ │ │ │ ├── block_suno.js │ │ │ │ ├── block_talebot.js │ │ │ │ ├── block_telliot_Base.js │ │ │ │ ├── block_telliot_lite.js │ │ │ │ ├── block_thinkboard.js │ │ │ │ ├── block_timbo.js │ │ │ │ ├── block_truerobot.js │ │ │ │ ├── block_turtle.js │ │ │ │ ├── block_uglybot.js │ │ │ │ ├── block_uo_albert.js │ │ │ │ ├── block_wearable.js │ │ │ │ ├── block_whalesbot_eagle_1001.js │ │ │ │ ├── block_xbot.js │ │ │ │ ├── block_zerone.js │ │ │ │ ├── block_zumiMini.js │ │ │ │ └── index.js │ │ │ ├── hardwareLite/ │ │ │ │ ├── block_alux_connect_lite.js │ │ │ │ ├── block_alux_nemo_lite.js │ │ │ │ ├── block_alux_teachnic_normal_lite.js │ │ │ │ ├── block_alux_teachnic_power_lite.js │ │ │ │ ├── block_arduino_lite.js │ │ │ │ ├── block_choco_lite.js │ │ │ │ ├── block_cocodron_controller_Lite.js │ │ │ │ ├── block_codewiz_lite.js │ │ │ │ ├── block_hamster_lite.js │ │ │ │ ├── block_microbit2_lite.js │ │ │ │ ├── block_microbit2ble_lite.js │ │ │ │ ├── block_neo_cannon_lite.js │ │ │ │ ├── block_neo_lite.js │ │ │ │ ├── block_neo_spider_lite.js │ │ │ │ ├── block_neobot_purple_lite.js │ │ │ │ ├── block_neobot_soco_lite.js │ │ │ │ ├── block_neobot_thinkcar_lite.js │ │ │ │ ├── block_robolink_ZumiMini_lite.js │ │ │ │ ├── block_robotis_kkokdu_lite.js │ │ │ │ ├── block_robotis_koalabot_lite.js │ │ │ │ ├── block_robotis_rgee_lite.js │ │ │ │ ├── block_robotis_rla_lite.js │ │ │ │ ├── block_robotis_robotai_lite.js │ │ │ │ ├── block_sensorboard_lite.js │ │ │ │ ├── block_whalesbot_drone_lite.js │ │ │ │ ├── block_wizwing_controller_lite.js │ │ │ │ ├── index.js │ │ │ │ ├── metadata_alux_connect_lite.json │ │ │ │ ├── metadata_alux_nemo_lite.json │ │ │ │ ├── metadata_alux_teachnic_normal_lite.json │ │ │ │ ├── metadata_alux_teachnic_power_lite.json │ │ │ │ ├── metadata_arduino_lite.json │ │ │ │ ├── metadata_choco_lite.json │ │ │ │ ├── metadata_cocodron_controller_Lite.json │ │ │ │ ├── metadata_codewiz_lite.json │ │ │ │ ├── metadata_hamster_lite.json │ │ │ │ ├── metadata_microbit2_lite.json │ │ │ │ ├── metadata_microbit2ble_lite.json │ │ │ │ ├── metadata_neo_cannon_lite.json │ │ │ │ ├── metadata_neo_lite.json │ │ │ │ ├── metadata_neo_spider_lite.json │ │ │ │ ├── metadata_neobot_purple_lite.json │ │ │ │ ├── metadata_neobot_soco_lite.json │ │ │ │ ├── metadata_neobot_thinkcar_lite.json │ │ │ │ ├── metadata_robolink_ZumiMini_lite.json │ │ │ │ ├── metadata_robotis_kkokdu_lite.json │ │ │ │ ├── metadata_robotis_koalabot_lite.json │ │ │ │ ├── metadata_robotis_rgee_lite.json │ │ │ │ ├── metadata_robotis_rla_lite.json │ │ │ │ ├── metadata_robotis_robotai_lite.json │ │ │ │ ├── metadata_sensorboard_lite.json │ │ │ │ ├── metadata_whalesbot_drone_lite.json │ │ │ │ └── metadata_wizwing_controller_lite.json │ │ │ ├── index.js │ │ │ └── inputs/ │ │ │ └── keyboard.js │ │ ├── board.js │ │ ├── code.js │ │ ├── code_view.js │ │ ├── comment.js │ │ ├── connection_ripple.js │ │ ├── executors.js │ │ ├── executors2.js │ │ ├── extension/ │ │ │ ├── extension.js │ │ │ ├── guide.js │ │ │ └── side_tag.js │ │ ├── field/ │ │ │ ├── angle.js │ │ │ ├── block.js │ │ │ ├── color.js │ │ │ ├── dropdown.js │ │ │ ├── dropdownDynamic.js │ │ │ ├── dropdownExtra.js │ │ │ ├── field.js │ │ │ ├── image.js │ │ │ ├── indicator.js │ │ │ ├── keyboardInput.js │ │ │ ├── led.js │ │ │ ├── led2.js │ │ │ ├── lineBreak.js │ │ │ ├── musicScale.js │ │ │ ├── output.js │ │ │ ├── statement.js │ │ │ ├── text.js │ │ │ ├── textDynamic.js │ │ │ └── textInput.js │ │ ├── globalSvg.js │ │ ├── mutator.js │ │ ├── renderView.js │ │ ├── scope.js │ │ ├── scroll.js │ │ ├── skeleton/ │ │ │ ├── basic/ │ │ │ │ ├── basic.ts │ │ │ │ ├── basic_boolean_field.ts │ │ │ │ ├── basic_button.ts │ │ │ │ ├── basic_button_disabled.ts │ │ │ │ ├── basic_create.ts │ │ │ │ ├── basic_create_value.ts │ │ │ │ ├── basic_define.ts │ │ │ │ ├── basic_double_loop.ts │ │ │ │ ├── basic_event.ts │ │ │ │ ├── basic_loop.ts │ │ │ │ ├── basic_param.ts │ │ │ │ ├── basic_string_field.ts │ │ │ │ ├── basic_text.ts │ │ │ │ └── basic_text_light.ts │ │ │ ├── clickable_text.ts │ │ │ ├── comment.ts │ │ │ ├── index.ts │ │ │ └── pebble/ │ │ │ ├── pebble_basic.ts │ │ │ ├── pebble_event.ts │ │ │ └── pebble_loop.ts │ │ ├── skinner.js │ │ ├── thread.js │ │ ├── thread_view.js │ │ ├── toast.js │ │ ├── trashcan.js │ │ ├── vim.js │ │ ├── workspace.js │ │ └── zoom_controller.js │ ├── textcoding/ │ │ ├── ast/ │ │ │ ├── jsAstGenerator.js │ │ │ └── pyAstGenerator.js │ │ ├── data_processing/ │ │ │ ├── map.js │ │ │ └── queue.js │ │ ├── error/ │ │ │ └── textCodingError.js │ │ ├── hint/ │ │ │ └── python.js │ │ ├── parser/ │ │ │ └── core/ │ │ │ ├── block/ │ │ │ │ ├── blockToJs.js │ │ │ │ └── blockToPy.js │ │ │ └── text/ │ │ │ ├── jsToBlock.js │ │ │ └── pyToBlock.js │ │ ├── parser.js │ │ ├── static/ │ │ │ ├── codeMap.js │ │ │ └── keyboardCode.js │ │ └── util/ │ │ ├── console.js │ │ └── textCodingUtil.js │ ├── theme/ │ │ ├── old.js │ │ └── standard.js │ └── util/ │ ├── audioSocket.js │ ├── audioUtils.js │ ├── binPacking.js │ ├── block_driver.js │ ├── common.js │ ├── contextmenu.js │ ├── curtain.js │ ├── dataSource.ts │ ├── destroyer/ │ │ └── Destroyer.ts │ ├── domUtils.js │ ├── eventHandler.js │ ├── extrablockUtils.js │ ├── functions/ │ │ └── showConsoleBanner.ts │ ├── fuzzy.js │ ├── hardwareUtils.ts │ ├── htmlElementPatcher.js │ ├── init.js │ ├── loader.js │ ├── location.js │ ├── mediaPipeUtils.ts │ ├── modal.js │ ├── restrictor.js │ ├── scheduler.js │ ├── static.js │ ├── tooltip.js │ ├── tvCast.js │ ├── utils.js │ ├── virtualScroll.js │ ├── workers/ │ │ └── newmotion.worker.ts │ └── youtube.js ├── test/ │ ├── class/ │ │ └── container.spec.js │ ├── entry/ │ │ └── entry.js │ └── textcoding/ │ └── block.js ├── test_util/ │ └── helper.js ├── tsconfig.json ├── types/ │ ├── entry.d.ts │ ├── index.d.ts │ └── window.d.ts ├── webpack.config.js ├── webpack_config/ │ ├── common.js │ ├── dev.js │ ├── lint.js │ ├── prod.js │ └── serve.js └── weights/ ├── age_gender_model-shard1 ├── age_gender_model-weights_manifest.json ├── face_expression_model-shard1 ├── face_expression_model-weights_manifest.json ├── face_landmark_68_model-shard1 ├── face_landmark_68_model-weights_manifest.json ├── face_landmark_68_tiny_model-shard1 ├── face_landmark_68_tiny_model-weights_manifest.json ├── tiny_face_detector_model-shard1 └── tiny_face_detector_model-weights_manifest.json ================================================ FILE CONTENTS ================================================ ================================================ FILE: .babelrc ================================================ { "presets": ["@babel/preset-env"], "plugins": [ "@babel/plugin-transform-runtime", "@babel/plugin-transform-object-assign", "@babel/plugin-transform-modules-commonjs", "@babel/plugin-syntax-dynamic-import", "@babel/plugin-proposal-object-rest-spread", "@babel/plugin-proposal-class-properties", "@babel/plugin-proposal-private-methods" ], "env": { "test": { "plugins": ["dynamic-import-node"] } } } ================================================ FILE: .eslintignore ================================================ src/playground/blocks/hardware/**/*.js extern test test_util ================================================ FILE: .eslintrc ================================================ { "parser": "@babel/eslint-parser", "plugins": ["prettier"], "extends": ["plugin:prettier/recommended"], "overrides": [ { "files": ["*.ts"], "parser": "@typescript-eslint/parser", "rules": { "no-unused-vars": "off", }, }, { "files": ["*.d.ts"], "parser": "@typescript-eslint/parser", "rules": { "no-unused-vars": "off", "no-var": "off", "no-useless-constructor": "off", }, }, ], "env": { "es6": true, "browser": true, "jquery": true, }, "parserOptions": { "requireConfigFile": false, "ecmaVersion": 2020, "sourceType": "module", "ecmaFeatures": { "jsx": true, }, }, "rules": { "prefer-const": "warn", "no-var": "warn", "eqeqeq": 0, "no-const-assign": "error", "no-new-object": "warn", "object-shorthand": "warn", "no-prototype-builtins": "warn", "no-array-constructor": "warn", "prefer-template": "warn", "no-useless-escape": "warn", "wrap-iife": ["warn", "inside"], "no-loop-func": "warn", "no-new-func": "warn", "prefer-rest-params": "warn", "prefer-arrow-callback": "warn", "template-curly-spacing": "warn", "no-param-reassign": ["warn", { "props": false }], "prefer-spread": "warn", "arrow-spacing": "warn", "arrow-body-style": ["warn", "as-needed"], "no-useless-constructor": "warn", "no-dupe-class-members": "warn", "no-duplicate-imports": "warn", "dot-notation": "warn", "no-undef": ["warn", { "typeof": true }], "one-var": ["warn", "never"], "no-multi-assign": "warn", "no-case-declarations": "warn", "no-nested-ternary": "warn", "no-unneeded-ternary": "warn", "brace-style": "warn", "space-before-blocks": [ "warn", { "functions": "always", "keywords": "always", "classes": "always" }, ], "space-infix-ops": "warn", "eol-last": ["warn", "always"], "no-whitespace-before-property": "warn", "padded-blocks": ["warn", "never"], "space-in-parens": ["warn", "never"], "array-bracket-spacing": ["warn", "never"], "object-curly-spacing": ["warn", "always"], "max-len": ["warn", { "code": 100 }], "comma-style": ["warn", "last"], "semi": ["warn"], "radix": "warn", "camelcase": ["warn", { "properties": "never" }], "new-cap": ["warn", { "capIsNewExceptionPattern": "^Entry." }], "curly": "warn", "keyword-spacing": "warn", }, "globals": { "$": true, "_": true, "arcon": true, "goog": true, "acorn": true, "createjs": true, "Entry": true, "filbert": true, "Blockly": true, "BigNumber": true, "Lang": true, "context": true, "popup": true, "WebFont": true, "CanvasInput": true, "EntryStatic": true, "EaselHandle": true, "ndgmr": true, "Ntry": true, "Snap": true, "mina": true, "Touch": true, "io": true, "LC": true, "ActiveXObject": true, "CodeMirror": true, "entrylms": true, "require": true, "module": true, "Symbol": true, "process": true, }, } ================================================ FILE: .github/pr-labeler.yml ================================================ feature: feature/* security: security/* issue: [issue/*, Issue/*] hotfix: hotfix/* ================================================ FILE: .github/workflows/build-and-deploy.yml ================================================ name: 'build-and-deploy' on: push: branches: - 'deploy/**' - master - develop-hw - develop2 - develop jobs: build-and-deploy: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - name: Use Node.js 20.x uses: actions/setup-node@v4 env: NODE_OPTIONS: '--max-old-space-size=4096' TOOL_NODE_FLAGS: '--max-old-space-size=4096' with: node-version: 20 - uses: pnpm/action-setup@v3 name: Install pnpm with: version: 9 run_install: true - name: entry build env: NODE_OPTIONS: '--max-old-space-size=4096' TOOL_NODE_FLAGS: '--max-old-space-size=4096' run: pnpm prod - name: Define branch name id: target_branch shell: bash run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF##*/})" - uses: haya14busa/action-cond@v1 id: deploy_branch with: cond: ${{ steps.target_branch.outputs.branch == 'master' }} if_true: 'build' if_false: dist/${{ steps.target_branch.outputs.branch }} - name: Execute build.sh run: | sh ./scripts/build.sh - name: Execute deploy.sh run: | sh ./scripts/deploy.sh - name: Push Changes into build branch uses: ad-m/github-push-action@master with: github_token: ${{ secrets.GITHUB_TOKEN }} force: true directory: ./build branch: ${{ steps.deploy_branch.outputs.value }} ================================================ FILE: .github/workflows/pull-request-workflow.yml ================================================ name: PR Workflow on: pull_request: types: [opened, edited, synchronize] jobs: pr-labeler: runs-on: ubuntu-latest steps: - uses: TimonVS/pr-labeler-action@v3 with: configuration-path: .github/pr-labeler.yml # optional, .github/pr-labeler.yml is the default value env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} eslint: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - name: Install pnpm uses: pnpm/action-setup@v3 with: version: 9 - run: pnpm install - uses: reviewdog/action-eslint@v1 with: github_token: ${{ secrets.GITHUB_TOKEN }} reporter: github-pr-review eslint_flags: '--ignore-pattern .eslintignore src/' ================================================ FILE: .github/workflows/release.yml ================================================ name: 'release' on: release: types: [created] jobs: release: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - name: Install pnpm uses: pnpm/action-setup@v3 with: version: 9 - uses: actions/setup-node@v4 with: node-version: '20' cache: 'pnpm' - run: pnpm install - run: pnpm prod - uses: JS-DevTools/npm-publish@v3 with: token: ${{ secrets.NPM_TOKEN }} ================================================ FILE: .gitignore ================================================ # Logs logs *.log # Runtime data pids *.pid *.seed # Directory for instrumented libs generated by jscoverage/JSCover lib-cov # Coverage directory used by tools like istanbul coverage reports # Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files) .grunt # node-waf configuration .lock-wscript # Compiled binary addons (http://nodejs.org/api/addons.html) build/Release # Dependency directory # https://www.npmjs.org/doc/misc/npm-faq.html#should-i-check-my-node_modules-folder-into-git node_modules # external libraries extern/closure-library .DS_Store *.map .vscode/* .idea/ dist/ ================================================ FILE: .prettierrc ================================================ { "printWidth": 100, "tabWidth": 4, "singleQuote": true, "trailingComma": "es5", "bracketSpacing": true, "semi": true, "arrowParens": "always", "endOfLine": "auto" } ================================================ FILE: COPYING ================================================ Copyright 2015 Entry Labs Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. ================================================ FILE: Gruntfile.js ================================================ module.exports = function(grunt) { 'use strict'; const ClosureCompiler = require('google-closure-compiler').compiler; grunt.initConfig({ concurrent: { tasks: ['watch'], options: { logConcurrentOutput: true, }, }, watch: { test: { files: ['test/**/*.js'], tasks: ['karma'], }, js: { files: ['src/**'], tasks: ['closureCompiler:targetName', 'karma', 'jshint', 'less'], }, }, less: { options: { compress: false, }, development: { files: { 'dist/entry.css': 'src/css/*.less', }, }, }, jshint: { all: ['src/**/*.js'], options: { jshintrc: true, ignores: ['src/blocks/*.js'], }, }, karma: { options: { frameworks: ['mocha', 'chai'], files: [ 'http://ajax.aspnetcdn.com/ajax/jshint/r07/jshint.js', 'test_util/*.js', 'extern/lang/ko.js', 'extern/blockly/blockly_compressed.js', 'extern/util/static.js', 'extern/util/filbert.js', 'extern/util/bignumber.min.js', 'node_modules/jquery/jquery.js', 'node_modules/createjs-easeljs/lib/easeljs-0.8.2.min.js', 'node_modules/createjs-soundjs/lib/soundjs-0.6.2.min.js', 'node_modules/createjs-preloadjs/lib/preloadjs-0.6.2.min.js', 'dist/entry.js', 'src/workspace/block_entry.js', ], }, unit: { configFile: 'karma.conf.js', files: [{ src: ['test/**/*.js'] }], }, }, closureCompiler: { options: { compilerFile: ClosureCompiler.COMPILER_PATH, checkModified: true, compilerOpts: { create_source_map: 'entry.js.map', compilation_level: 'SIMPLE_OPTIMIZATIONS', language_in: 'ECMASCRIPT5', language_out: 'ECMASCRIPT5', formatting: 'pretty_print', }, }, targetName: { src: ['src/entry.js', 'src/**/*.js', '!src/workspace/block_entry.js'], dest: 'dist/entry.js', }, dist: { options: { compilerOpts: { compilation_level: 'SIMPLE_OPTIMIZATIONS', language_in: 'ECMASCRIPT5', language_out: 'ECMASCRIPT5', }, }, expand: false, src: ['src/entry.js', 'src/**/*.js'], dest: 'dist/entry.min.js', ext: '.min.js', }, }, }); // Load NPM tasks grunt.loadNpmTasks('grunt-closure-tools'); grunt.loadNpmTasks('grunt-contrib-jshint'); grunt.loadNpmTasks('grunt-concurrent'); grunt.loadNpmTasks('grunt-contrib-watch'); grunt.loadNpmTasks('grunt-karma'); grunt.loadNpmTasks('grunt-contrib-less'); grunt.option('force', true); // Default tasks. grunt.registerTask('default', ['closureCompiler', 'karma', 'jshint', 'less']); grunt.registerTask('development', [ 'watch', 'closureCompiler:targetName', 'karma', 'concurrent', ]); grunt.registerTask('test', ['karma']); grunt.registerTask('closure', ['closureCompiler']); grunt.registerTask('build', ['closureCompiler', 'less']); }; ================================================ FILE: Jenkinsfile ================================================ pipeline { agent none stages { stage('EntryJS Test') { when { beforeAgent true expression { return env.CHANGE_ID } } agent { docker { image 'node:8.11.3' } } steps { script { sh "npm prune" sh "npm install" sh "yarn test" } } post { always { junit 'reports/*.xml' } } } stage('SonarQube Analysis') { when { beforeAgent true expression { return env.CHANGE_ID } } agent { docker { image 'maven:3-alpine' } } steps { script { def scannerHome = tool "sonarqube-scanner"; withSonarQubeEnv("sonar") { sh "${scannerHome}/bin/sonar-scanner " + "-Dsonar.projectKey=entry.entryjs " + "-Dsonar.projectName=entryjs " + "-Dsonar.sourceEncoding=UTF-8 " + "-Dsonar.analysis.mode=preview " + "-Dsonar.github.repository=entrylabs/entryjs " + "-Dsonar.github.endpoint=https://api.github.com " + "-Dsonar.github.oauth=${GH_TOKEN} " + "-Dsonar.issuesReport.console.enable=true " + "-Dsonar.github.disableInlineComments=true " + "-Dsonar.github.pullRequest=${env.CHANGE_ID} " + "-Dsonar.sources=src " } } } } stage('SonarQube Scan') { when { beforeAgent true allOf { expression { BRANCH_NAME ==~ /(^master$)/ } not { changeRequest() } } } agent { docker { image 'maven:3-alpine' } } steps { script { def scannerHome = tool "sonarqube-scanner"; withSonarQubeEnv("sonar") { sh "${scannerHome}/bin/sonar-scanner " + "-Dsonar.projectKey=entry.entryjs " + "-Dsonar.projectName=entryjs " + "-Dsonar.sourceEncoding=UTF-8 " + "-Dsonar.sources=src " } } } } stage('EntryJS Deploy') { when { beforeAgent true allOf { expression { BRANCH_NAME ==~ /(^master$|^deploy\/.*$)/ } not { changeRequest() } } } agent { docker { image 'node:8.11.3' } } steps { script { sh '''npm prune npm install chmod +x ./scripts/build.sh chmod +x ./scripts/deploy.sh ./scripts/build.sh ./scripts/deploy.sh''' } } } } environment { GH_REPO = 'https://github.com/entrylabs/entryjs.git' GH_REF = 'github.com/entrylabs/entryjs.git' } } ================================================ FILE: LICENSE ================================================ Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 1. Definitions. "License" shall mean the terms and conditions for use, reproduction, and distribution as defined by Sections 1 through 9 of this document. "Licensor" shall mean the copyright owner or entity authorized by the copyright owner that is granting the License. "Legal Entity" shall mean the union of the acting entity and all other entities that control, are controlled by, or are under common control with that entity. For the purposes of this definition, "control" means (i) the power, direct or indirect, to cause the direction or management of such entity, whether by contract or otherwise, or (ii) ownership of fifty percent (50%) or more of the outstanding shares, or (iii) beneficial ownership of such entity. "You" (or "Your") shall mean an individual or Legal Entity exercising permissions granted by this License. "Source" form shall mean the preferred form for making modifications, including but not limited to software source code, documentation source, and configuration files. "Object" form shall mean any form resulting from mechanical transformation or translation of a Source form, including but not limited to compiled object code, generated documentation, and conversions to other media types. "Work" shall mean the work of authorship, whether in Source or Object form, made available under the License, as indicated by a copyright notice that is included in or attached to the work (an example is provided in the Appendix below). "Derivative Works" shall mean any work, whether in Source or Object form, that is based on (or derived from) the Work and for which the editorial revisions, annotations, elaborations, or other modifications represent, as a whole, an original work of authorship. For the purposes of this License, Derivative Works shall not include works that remain separable from, or merely link (or bind by name) to the interfaces of, the Work and Derivative Works thereof. "Contribution" shall mean any work of authorship, including the original version of the Work and any modifications or additions to that Work or Derivative Works thereof, that is intentionally submitted to Licensor for inclusion in the Work by the copyright owner or by an individual or Legal Entity authorized to submit on behalf of the copyright owner. For the purposes of this definition, "submitted" means any form of electronic, verbal, or written communication sent to the Licensor or its representatives, including but not limited to communication on electronic mailing lists, source code control systems, and issue tracking systems that are managed by, or on behalf of, the Licensor for the purpose of discussing and improving the Work, but excluding communication that is conspicuously marked or otherwise designated in writing by the copyright owner as "Not a Contribution." "Contributor" shall mean Licensor and any individual or Legal Entity on behalf of whom a Contribution has been received by Licensor and subsequently incorporated within the Work. 2. Grant of Copyright License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare Derivative Works of, publicly display, publicly perform, sublicense, and distribute the Work and such Derivative Works in Source or Object form. 3. Grant of Patent License. Subject to the terms and conditions of this License, each Contributor hereby grants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer the Work, where such license applies only to those patent claims licensable by such Contributor that are necessarily infringed by their Contribution(s) alone or by combination of their Contribution(s) with the Work to which such Contribution(s) was submitted. If You institute patent litigation against any entity (including a cross-claim or counterclaim in a lawsuit) alleging that the Work or a Contribution incorporated within the Work constitutes direct or contributory patent infringement, then any patent licenses granted to You under this License for that Work shall terminate as of the date such litigation is filed. 4. Redistribution. You may reproduce and distribute copies of the Work or Derivative Works thereof in any medium, with or without modifications, and in Source or Object form, provided that You meet the following conditions: (a) You must give any other recipients of the Work or Derivative Works a copy of this License; and (b) You must cause any modified files to carry prominent notices stating that You changed the files; and (c) You must retain, in the Source form of any Derivative Works that You distribute, all copyright, patent, trademark, and attribution notices from the Source form of the Work, excluding those notices that do not pertain to any part of the Derivative Works; and (d) If the Work includes a "NOTICE" text file as part of its distribution, then any Derivative Works that You distribute must include a readable copy of the attribution notices contained within such NOTICE file, excluding those notices that do not pertain to any part of the Derivative Works, in at least one of the following places: within a NOTICE text file distributed as part of the Derivative Works; within the Source form or documentation, if provided along with the Derivative Works; or, within a display generated by the Derivative Works, if and wherever such third-party notices normally appear. The contents of the NOTICE file are for informational purposes only and do not modify the License. You may add Your own attribution notices within Derivative Works that You distribute, alongside or as an addendum to the NOTICE text from the Work, provided that such additional attribution notices cannot be construed as modifying the License. You may add Your own copyright statement to Your modifications and may provide additional or different license terms and conditions for use, reproduction, or distribution of Your modifications, or for any such Derivative Works as a whole, provided Your use, reproduction, and distribution of the Work otherwise complies with the conditions stated in this License. 5. Submission of Contributions. Unless You explicitly state otherwise, any Contribution intentionally submitted for inclusion in the Work by You to the Licensor shall be under the terms and conditions of this License, without any additional terms or conditions. Notwithstanding the above, nothing herein shall supersede or modify the terms of any separate license agreement you may have executed with Licensor regarding such Contributions. 6. Trademarks. This License does not grant permission to use the trade names, trademarks, service marks, or product names of the Licensor, except as required for reasonable and customary use in describing the origin of the Work and reproducing the content of the NOTICE file. 7. Disclaimer of Warranty. Unless required by applicable law or agreed to in writing, Licensor provides the Work (and each Contributor provides its Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determining the appropriateness of using or redistributing the Work and assume any risks associated with Your exercise of permissions under this License. 8. Limitation of Liability. In no event and under no legal theory, whether in tort (including negligence), contract, or otherwise, unless required by applicable law (such as deliberate and grossly negligent acts) or agreed to in writing, shall any Contributor be liable to You for damages, including any direct, indirect, special, incidental, or consequential damages of any character arising as a result of this License or out of the use or inability to use the Work (including but not limited to damages for loss of goodwill, work stoppage, computer failure or malfunction, or any and all other commercial damages or losses), even if such Contributor has been advised of the possibility of such damages. 9. Accepting Warranty or Additional Liability. While redistributing the Work or Derivative Works thereof, You may choose to offer, and charge a fee for, acceptance of support, warranty, indemnity, or other liability obligations and/or rights consistent with this License. However, in accepting such obligations, You may act only on Your own behalf and on Your sole responsibility, not on behalf of any other Contributor, and only if You agree to indemnify, defend, and hold each Contributor harmless for any liability incurred by, or claims asserted against, such Contributor by reason of your accepting any such warranty or additional liability. END OF TERMS AND CONDITIONS APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following boilerplate notice, with the fields enclosed by brackets "{}" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a file or class name and description of purpose be included on the same "printed page" as the copyright notice for easier identification within third-party archives. Copyright {yyyy} {name of copyright owner} Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. ================================================ FILE: NOTICE ================================================ EntryJS Copyright 2015 Entry Labs EntryJS project contains subcomponents with separate copyright notices and license terms. Your use of the source code for the these subcomponents is subject to the terms and conditions of the following licenses. ======================================================================= Blockly (https://github.com/google/blockly) ======================================================================= /** * @license * Visual Blocks Editor * * Copyright 2011 Google Inc. * https://developers.google.com/blockly/ * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ ======================================================================= Collision-Detection-for-EaselJS (https://github.com/olsn/Collision-Detection-for-EaselJS) ======================================================================= Copyright (c) 2013 Olaf Horstmann Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ======================================================================= CanvasInput (https://github.com/goldfire/CanvasInput) ======================================================================= /*! * CanvasInput v1.2.1 * http://goldfirestudios.com/blog/108/CanvasInput-HTML5-Canvas-Text-Input * * (c) 2013-2015, James Simpson of GoldFire Studios * goldfirestudios.com * * MIT License */ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ======================================================================= Context.js (https://github.com/jakiestfu/Context.js) ======================================================================= /* * Context.js * Copyright Jacob Kelley * MIT License * * Modified by Joshua Christman */ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ================================================ FILE: README-en.md ================================================ # entryjs entryjs is an HTML5-based block coding library developed by entry. If you access the [Entry](https://playentry.org) site, you can check the block coding environment using entryjs. ## get started entryjs uses several open source libraries to handle HTML Canvas, audio, and vector images. After these libraries are loaded in the web project, entryjs should be loaded. ### 3rd party library * [jQuery](http://jquery.com/download/) - 1.9.1 * [jquery-ui](https://github.com/jquery/jquery-ui) - 1.10.4 * [Underscore](https://github.com/jashkenas/underscore) - 1.8.3 * [CreateJS](http://createjs.com/downloads) * EaselJS - 0.8.0 * PreloadJS - 0.6.0 * SoundJS - 0.6.0 * [Lodash](https://lodash.com/docs/4.17.15) - 4.17.10 * [Velocity](https://github.com/julianshapiro/velocity) - ~1.2.3 * [CodeMirror](https://codemirror.net) - 5.12.0 * [Fuzzy](https://github.com/mattyork/fuzzy) - ~0.1.1 * [Literallycanvas](https://github.com/entrylabs/literallycanvas) - entry version * [EntryTool](https://github.com/entrylabs/entry-tool) - entry version All of these libraries are distributed as open source, You can download it yourself or install it using [npm](http://npmjs.org) or [bower](http://bower.io). ### JavaScript library ```html ``` ### entryjs stylesheet Basic styles related to block design are defined. ```html ``` ### Entry Initialization (Inject Options) Once you have loaded the necessary libraries and entryjs, you can inject the entryjs workspace using Javascript at a specific location in the current DOM. * Entry.init(domElement, initOptions); ```html
``` ```javascript var workspace = document.getElementById("workspace"); var initOptions = { type: 'workspace', libDir: '/lib', fonts: [{ name: '나눔고딕', family: 'Nanum Gothic', url: '/css/nanumgothic.css' }] }; Entry.init(workspace, initOptions); ``` * domElement : The DOM node into which the entry will be injected. * initOptions : Option value of entryjs workspace. ### initOptions All options except Workspace type and font information are optional and Boolean type. * Required - type: Workspace type. (workspace: creation environment, minimize: viewing environment) - libDir:Third-party library repository. Library location including entryjs. (default: '/lib') - fonts: Web font information * choice - projectsaveable: Whether the project can be saved (true) - objectaddable: Whether objects can be added (true) - objectEditable: Whether the object can be modified (true). Setting this value to false also sets objectAddable to false. - objectdeletable: Whether the object can be deleted (true) - soundeditable: Whether sound can be modified (true) - pictureeditable: Whether the shape can be modified (true) - sceneEditable: Whether the scene can be modified (true) - functionEnable: Whether the function is available (true) - messageEnable: signal available (true) - variableEnable: Whether the variable is available (true) - listEnable: list available (true) - isForLecture: Lecture project or not (false) - textCodingEnable: Whether entry python is available (true) - hardwareEnable: Hardware availability (true) * Web font information 정보 You can add one or more arrays of fonts to be used in the entry textbox and paint. ```javascript [{ name: 'Font name to display on screen', family: 'font-family name', url: 'Font definition file path' }] ``` ```javascript // 예시 [{ name: 'Nanum Gothic', family: 'Nanum Gothic', url: '/css/nanumgothic.css' }, { name: 'Nanum handwriting', family: 'Nanum Pen Script', url: '/css/nanumpenscript.css' }] ``` Free Korean web fonts can be downloaded from https://www.google.com/fonts/earlyaccess. ### Entry.playground.setBlockMenu(); Block menu reset ### Entry.loadProject(project); Load project. If the project argument is omitted, the default project is returned.. ### event. (Event description) * event listening ```javascript Entry.addEventListener(eventName, function); ``` - eventName: The name of the custom event you want to catch - function: Function to be executed when the corresponding custom event occurs * event dispatch ```javascript Entry.dispatchEvent(eventName,params); ``` - eventName: The name of the event you want to trigger - params: Parameters to be passed to the callback function listening for events * representative event - run - stop * user interaction - keyPressed - keyUpped - canvasClick - canvasClickCanceled - entityClick - entityClickCanceled - stageMouseMove - stageMouseOut * screen - windowResized ### Entry.Toast * Display notification messages at the bottom of the workspace - Entry.Toast.warning(title, message, auto-dospose); // caution - Entry.Toast.success(title, message, auto-dospose); // success - Entry.Toast.alert(title, message, auto-dospose); // warning ### Block shape definition and running script. ``` ${entryjs}/src/blocks/**/* ``` ### block shape definition Please refer to [EntryDocs - Write block specification](https://entrylabs.github.io/docs/guide/entryjs/2016-05-22-add_new_blocks.html). ### Project Schema ### save :You can save essential information in JSON format using the Entry function below. A saved project can be reloaded using Entry.loadProject(project) . ```javascript var project = Entry.exportProject(); ``` ### detailed schema ```javascript /** * MongoDB schema example. */ var ProjectSchema = new Schema({ speed: { // Execution frames per second type: Number, default: 60 }, objects: [ // object list { id: String, // Object ID. Unique. name: String, // The object (or textbox title) name. text: String, // text box content. (If objectType is textBox) order: Number, // TODO objectType: String, // object type. (sprite, textBox) scene: String, // Scene ID. Unique. active: { // whether the object is active type: Boolean, default: true }, lock: { // object lock type: Boolean, default: false }, rotateMethod: String, // rotation method (free, vertical, none) entity: { // entity information rotation: Number, // rotation direction: Number, // direction x: Number, // x coordinate y: Number, // y coordinate regX: Number, // horizontal center point regY: Number, // vertical center point scaleX: Number, // horizontal scale scaleY: Number, // vertical scale width: Number, // area height: Number, // height imageIndex: Number, // TODO visible: Boolean, // screen display colour: String, // text box font color font: String, // text box font bgColor: String, // text box background color textAlign: Number, // textbox alignment lineBreak: Boolean, // Whether text box line breaks underLine: Boolean, // text box strike: Boolean // text box underline }, script: String, // block script sprite: { // sprite information name: String, // sprite name pictures: [{ // shape list id: String, // Shape ID. Unique/ name: String, // shape name fileurl: String, // shape image dimension: { // shape size width: Number, height: Number, scaleX: Number, scaleY: Number }, scale: { // Magnification, reduction ratio (based on 100%) type: Number, default: 100 } }], sounds: [{ // list of sounds id: String, // Sound ID. Unique. name: String, // name fileurl: String, // Sound file URL duration: Number // play time. (in seconds) }] }, selectedPictureId: String, // ID of the currently active shape selectedSoundId: String // ID of currently active sound } ], variables: [ // project variable { name: String, // variable name variableType: String, // variable type. (General variable: variable, timer: timer, answer: answer, slide: slide, list: list) id: String, // variable ID. Unique. value: String, // variable value minValue: Number, // minimum maxValue: Number, // max value visible: Boolean, // visibility on canvas x: Number, // Converse position x coordinate y: Number, // canvas position y-coordinate width: Number, // width height: Number, // height isCloud: { // Shared variable or not type: Boolean, default: false }, object: { // If it is a local variable, the ID of the object it refers to type: String, default: null }, array: [{ // A list of values if the variable type is list data: String // value data }] } ], messages: [ // signal list { name: String, // signal name id: String // Signal ID. Unique. } ], functions: [ // function list { id: String, // function ID. Unique. block: String, // function block information content: String, // function execution information id: String, name: String }] } ], scenes: { // scene information type: [ // scene list { name: String, // scene name id: String // Scene ID. Unique. } ] }, }); ``` ### Sprite, Picture, Sound schema ### Sprites ```javascript var SpriteSchema = new Schema({ name: String, // sprite name pictures: [{ // shape list name: String, // shape name fileurl: String, // shape image dimension: { // shape size width: Number, height: Number } }], sounds: [{ // list of sounds name: String, // name fileurl: String, // Sound file URL duration: Number // play time. (in seconds) }] }) ``` #### Pictures ```javascript var PictureSchema = new Schema({ name: String, // shape name fileurl: String, // shape image dimension: { // shape size width: Number, height: Number } }) ``` #### Sounds ```javascript var SoundSchema = new Schema({ name: String, // name fileurl: String, // Sound file URL duration: Number // play time. (in seconds) }) ``` ## Copyright and License EntryJS Copyright (c) 2015 Entry Labs. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. ================================================ FILE: README.md ================================================ # entryjs entryjs는 엔트리에서 개발한 HTML5 기반의 블록코딩 라이브러리 입니다. [엔트리](https://playentry.org) 사이트에 접속하시면 entryjs를 사용한 블록코딩 환경을 확인해 볼 수 있습니다. ## 시작하기 entryjs는 HTML Canvas와 오디오, 벡터 이미지등을 다루기 위해 몇가지 오픈소스 라이브러리들을 사용합니다. 이 라이브러리들이 웹프로젝트에 먼저 로딩된 후에 entryjs를 로딩하여야 합니다. ### 써드파티 라이브러리 - [jQuery](http://jquery.com/download/) - 1.9.1 - [jquery-ui](https://github.com/jquery/jquery-ui) - 1.10.4 - [Underscore](https://github.com/jashkenas/underscore) - 1.8.3 - [CreateJS](http://createjs.com/downloads) - EaselJS - 0.8.0 - PreloadJS - 0.6.0 - SoundJS - 0.6.0 - [Lodash](https://lodash.com/docs/4.17.15) - 4.17.10 - [Velocity](https://github.com/julianshapiro/velocity) - ~1.2.3 - [CodeMirror](https://codemirror.net) - 5.12.0 - [Fuzzy](https://github.com/mattyork/fuzzy) - ~0.1.1 - [Literallycanvas](https://github.com/entrylabs/literallycanvas) - entry version - [EntryTool](https://github.com/entrylabs/entry-tool) - entry version 위 라이브러리들은 모두 오픈소스로 배포되며, 직접 다운로드 받거나 [npm](http://npmjs.org), [bower](http://bower.io)등을 이용해 설치할 수 있습니다. ### 자바스크립트 라이브러리 ```html ``` ### entryjs 스타일시트 블록 디자인과 관련된 기본적인 스타일들이 정의되어 있습니다. ```html ``` ### 엔트리 초기화 (Inject Options) 필요한 라이브러리와 entryjs를 로딩하였으면 현재 DOM의 특정 위치에 Javascript를 이용해 entryjs workspace를 주입할 수 있습니다. - Entry.init(domElement, initOptions); ```html ``` ```javascript var workspace = document.getElementById('workspace'); var initOptions = { type: 'workspace', libDir: '/lib', fonts: [ { name: '나눔고딕', family: 'Nanum Gothic', url: '/css/nanumgothic.css', }, ], }; Entry.init(workspace, initOptions); ``` - domElement : Entry가 Inject될 DOM 노드. - initOptions : entryjs workspace의 옵션값. ### initOptions Workspace 타입과 폰트정보를 제외한 모든 옵션은 선택사항이며 Boolean 타입입니다. - 필수항목 - type: 워크스페이스 타입. (workspace: 만들기 환경, minimize: 구경하기 환경) - libDir: 써드파티 라이브러리 저장소. entryjs를 포함한 Library 위치. (기본값: '/lib') - fonts: 웹폰트 정보 - 선택항목 - projectsaveable: 프로젝트 저장가능 여부 (true) - objectaddable: 오브젝트 추가가능 여부 (true) - objectEditable: 오브젝트 수정가능 여부 (true). 이값을 false로 세팅하면 objectAddable도 false가 된다. - objectdeletable: 오브젝트 삭제가능 여부 (true) - soundeditable: 소리 수정가능 여부 (true) - pictureeditable: 모양 수정가능 여부 (true) - sceneEditable: 장면 수정가능 여부 (true) - functionEnable: 함수 사용가능 여부 (true) - messageEnable: 신호 사용가능 여부 (true) - variableEnable: 변수 사용가능 여부 (true) - listEnable: 리스트 사용가능 여부 (true) - isForLecture: 강의용 프로젝트 여부 (false) - textCodingEnable: 엔트리 파이선 사용가능 여부 (true) - hardwareEnable: 하드웨어 사용가능 여부 (true) - 웹폰트 정보 엔트리 글상자와 그림판에서 사용할 폰트들을 하나 이상 배열로 추가할 수 있습니다. ```javascript [ { name: '화면에 표시할 폰트 이름', family: 'font-family 이름', url: '폰트 정의파일 경로', }, ]; ``` ```javascript // 예시 [ { name: '나눔고딕', family: 'Nanum Gothic', url: '/css/nanumgothic.css', }, { name: '나눔필기체', family: 'Nanum Pen Script', url: '/css/nanumpenscript.css', }, ]; ``` 무료 한글 웹폰트는 https://www.google.com/fonts/earlyaccess 에서 다운로드 하실 수 있습니다. ### Entry.playground.setBlockMenu(); 블록메뉴 초기화 ### Entry.loadProject(project); 프로젝트 불러오기. project 인자를 생략할 경우 기본 프로젝트를 리턴합니다. ### 이벤트. (Event description) - event listening ```javascript Entry.addEventListener(eventName, function); ``` - eventName: 캐치하고 싶은 커스텀 이벤트의 이름 - function: 해당 커스텀 이벤트가 발생했을 경우 실행 될 함수 * event dispatch ```javascript Entry.dispatchEvent(eventName, params); ``` - eventName: 발생 시키고 싶은 이벤트의 이름 - params: 이벤트를 리스닝 하고 있는 콜백함수에 넘겨줄 파라미터 * 대표적인 이벤트 - run - stop * 유저 인터랙션 - keyPressed - keyUpped - canvasClick - canvasClickCanceled - entityClick - entityClickCanceled - stageMouseMove - stageMouseOut * 화면 - windowResized ### Entry.Toast - 워크스페이스 하단에 알림 메시지 표시 * Entry.Toast.warning(title, message, auto-dospose); // 주의 * Entry.Toast.success(title, message, auto-dospose); // 성공 * Entry.Toast.alert(title, message, auto-dospose); // 경고 ### 블록 모양 정의와 실행 스크립트. ``` ${entryjs}/src/blocks/**/* ``` ### 블록 모양 정의 [EntryDocs - 블록 명세 작성](https://entrylabs.github.io/docs/guide/entryjs/2016-05-22-add_new_blocks.html) 을 참고해주세요. ### 프로젝트 (Project Schema) ### 저장 : 아래의 Entry 함수를 이용해 필수정보들을 JSON형태로 저장할 수 있습니다. 저장된 프로젝트는 Entry.loadProject(project) 를 이용해 다시 로드할 수 있습니다. ```javascript var project = Entry.exportProject(); ``` ### 상세 스키마 ```javascript /** * MongoDB 스키마 예제. */ var ProjectSchema = new Schema({ speed: { // 초당 실행 프레임수 type: Number, default: 60 }, objects: [ // 오브젝트 목록 { id: String, // 오브젝트 ID. Unique. name: String, // 오브젝트(또는 글상자 제목) 이름. text: String, // 글상자 내용. (objectType이 textBox일 경우) order: Number, // TODO objectType: String, // 오브젝트 유형. (sprite, textBox) scene: String, // 장면 ID. Unique. active: { // 오브젝트 활성화 여부 type: Boolean, default: true }, lock: { // 오브젝트 잠금 여부 type: Boolean, default: false }, rotateMethod: String, // 회전방식. (free, vertical, none) entity: { // 엔티티 정보 rotation: Number, // 회전 direction: Number, // 방향 x: Number, // x 좌표 y: Number, // y 좌표 regX: Number, // 가로 중심점 regY: Number, // 세로 중심점 scaleX: Number, // 가로 배율 scaleY: Number, // 세로 배율 width: Number, // 넓이 height: Number, // 높이 imageIndex: Number, // TODO visible: Boolean, // 화면표시 여부 colour: String, // 글상자 폰트색깔 font: String, // 글상자 폰트 bgColor: String, // 글상자 배경색깔 textAlign: Number, // 글상자 정렬 lineBreak: Boolean, // 글상자 줄바꿈 여부 underLine: Boolean, // 글상자 strike: Boolean // 글상자 밑줄 }, script: String, // 블록 스크립트 sprite: { // 스프라이트 정보 name: String, // 스프라이트 이름 pictures: [{ // 모양 목록 id: String, // 모양 ID. Unique/ name: String, // 모양 이름 fileurl: String, // 모양 이미지 dimension: { // 모양 크기 width: Number, height: Number, scaleX: Number, scaleY: Number }, scale: { // 확대, 축소 비율(100% 기준) type: Number, default: 100 } }], sounds: [{ // 소리 목록 id: String, // 소리 ID. Unique. name: String, // 이름 fileurl: String, // 사운드 파일 URL duration: Number // 재생시간. (초단위) }] }, selectedPictureId: String, // 현재 활성화된 모양의 ID selectedSoundId: String // 현재 활성화된 소리의 ID } ], variables: [ // 프로젝트 변수 { name: String, // 변수명 variableType: String, // 변수형. (일반변수: variable, 타이머: timer, 대답: answer, 슬라이드: slide, 리스트: list) id: String, // 변수ID. Unique. value: String, // 변수 값 minValue: Number, // 최소값 maxValue: Number, // 최대값 visible: Boolean, // 캔버스에 표시여부 x: Number, // 컨버스 위치 x좌표 y: Number, // 캔버스 위치 y좌표 width: Number, // 넓이 height: Number, // 높이 isCloud: { // 공유 변수 여부 type: Boolean, default: false }, object: { // 지역변수일 경우 참조하는 오브젝트 ID type: String, default: null }, array: [{ // 변수형이 list일 경우 값 목록 data: String // 값 데이터 }] } ], messages: [ // 신호 목록 { name: String, // 신호명 id: String // 신호 ID. Unique. } ], functions: [ // 함수 목록 { id: String, // 함수 ID. Unique. block: String, // 함수 블록 정보 content: String, // 함수 실행 정보 id: String, name: String }] } ], scenes: { // 장면 정보 type: [ // 장면 목록 { name: String, // 장면 이름 id: String // 장면 ID. Unique. } ] }, }); ``` ### Sprite, Picture, Sound schema ### 스프라이트 ```javascript var SpriteSchema = new Schema({ name: String, // 스프라이트 이름 pictures: [ { // 모양 목록 name: String, // 모양 이름 fileurl: String, // 모양 이미지 dimension: { // 모양 크기 width: Number, height: Number, }, }, ], sounds: [ { // 소리 목록 name: String, // 이름 fileurl: String, // 사운드 파일 URL duration: Number, // 재생시간. (초단위) }, ], }); ``` #### 모양 ```javascript var PictureSchema = new Schema({ name: String, // 모양 이름 fileurl: String, // 모양 이미지 dimension: { // 모양 크기 width: Number, height: Number, }, }); ``` #### 소리 ```javascript var SoundSchema = new Schema({ name: String, // 이름 fileurl: String, // 사운드 파일 URL duration: Number, // 재생시간. (초단위) }); ``` ## Copyright and License EntryJS Copyright (c) 2015 Entry Labs. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. ================================================ FILE: contributing.md ================================================ #### 업체PR 가이드 하드웨어 업체에서는 entryjs 레포지토리에서 Pull Request를 보내실때 devleop-hw브랜치로 보내주시기 바랍니다. 기타 다른브랜치에 PR보내시면 Reject사유가 될수 있습니다. ================================================ FILE: example/example.ejs ================================================