Skip to content

Commit

Permalink
resolved conflicts with dev
Browse files Browse the repository at this point in the history
  • Loading branch information
pmalacho-mit committed Nov 21, 2023
2 parents 707db09 + 5d5f8b2 commit 4232808
Show file tree
Hide file tree
Showing 119 changed files with 2,003 additions and 802 deletions.
25 changes: 25 additions & 0 deletions .github/ISSUE_TEMPLATE/port-extension-to-framework.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
---
name: Port Extension to Framework
about: Task for converting an existing extension to the new PRG framework form
title: ''
labels: extension framework
assignees: ''

---

# Details

Old extension Location: `packages/scratch-vm/extensions/___`

Branch name: `___`

Folder name: `___`

# Getting started

## Checkout branch
```bash
git checkout dev
git pull
git checkout -b <branch-name>
```
27 changes: 27 additions & 0 deletions .github/workflows/generate-extension-docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Generate Extension Documentation

on: [push]
permissions:
contents: write
pages: write
id-token: write
jobs:
generate:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16.17.1]
steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- name: Initialize
run: npm run init
- name: Generate
run: npm run document:extensions
- uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: 're-generate extension documentation\n\nskip-checks:true'
file_pattern: 'extensions/README.md'
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ yarn-debug.log*
yarn-error.log*
lerna-debug.log*

.DS_Store
**/.DS_Store

# Diagnostic reports (https://nodejs.org/api/report.html)
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json

Expand Down
41 changes: 40 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,46 @@ All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).

## 2023-03-25 (pending)
## 2023-07-14

### Changed
- Custom Argument UI now support updating the value of the argument whenever it's `setter` is called (instead of having to explicitly click "Apply")
- This is a lot more intuitive and really how it should've been implemented from the beginning (it just didn't occur to me how) -- these changes also bring some serious cleanup and simplification of the custom argument code to hopefully make maintenance easier in the future
- In the process of implemeting this, we were able to remove the need for any changes to the `scratch-vm` to make custom arguments work
- **BREAKING CHANGE:** If you're a developer who uses custom arguments in their extension, you will have to change how you specify the `component` to associate with your custom argument. Instead of specifying the name of the svelte file to load (in a string), you'll actually now import the svelte component directly:
- Before:
```ts
arg: self.makeCustomArgument({
component: "MyArgUI",
initial: { value: { a: 10, b: "Hello world", c: false }, text: "[10, Hello world, false]", }
}),
```
- Now:
```ts
// At top of file
import MyArgUI from "./MyArgUI.svelte"
// Within block definition
arg: self.makeCustomArgument({
component: MyArgUI,
initial: { value: { a: 10, b: "Hello world", c: false }, text: "[10, Hello world, false]", }
}),
```

## 2023-03 - 2023-06 (backfill)

### Added
- Support for changing the color of blocks. (docs coming soon -- ping @pmalacho-mit if you need 'em and can't find em)
- Support for inline image arguments. [See docs](https://github.com/mitmedialab/prg-extension-boilerplate/tree/dev/extensions#adding-inline-images-to-the-text-of-blocks)
- Support for indicators (docs coming soon -- ping @pmalacho-mit if you need 'em and can't find em))
- Support for accessing block's ID form `BlockUtility`. [See docs](https://github.com/mitmedialab/prg-extension-boilerplate/tree/dev/extensions#block-id)
- Ability to tag extensions to control how they are sorted in the extensions menu: [See docs](https://github.com/mitmedialab/prg-extension-boilerplate/tree/dev/extensions#extension-menu-tags--categories)

### Changed

- Teachable machine extension is now a `configurable` extension (as opposed to a `generic` extension (the old way of doing things))

## 2023-03-25

### Changed

Expand Down
30 changes: 30 additions & 0 deletions DEVELOPMENT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Current development (ordered by priority)

Items will be crossed off as they are completed and merged to dev. The merge & review process is documented [here]();

@pmalacho-mit will manage merging dev to main periodically (at first as needed, but eventually on a regular schedule).

- [Hat block update to support App Inventor interoperability](https://github.com/mitmedialab/prg-extension-boilerplate/issues/203) (easy)
- [Document bundling/build process & project architecture]() (medium)
- [First class Google Drive support]() (hard)
- [Tutorial support all from extension's folder]() (medium)
- [Loading curricullum 'recipes']() (medium)
- Support all extension fields
- [branchCount]() (easy)
- [filter]() (easy)
- [launchPeripheralConnectionFlow]() (easy)
- [terminal]() (easy)
- [Save/load data per extension]()
- [Workers]()
- First class support for other cloud providers (re-order based on feedback from teacher's schools)
- Dropbox
- OneDrive
- Microsoft

# Wishlist
- Opencv / feature perception object classification and localization extension (maybe 2 seperate extensions)
- Fly tello using scratch

# Things that'd be awesome to do, but are likely more work than is currently worth it
- Split every extension into it's own package
- Custom block arguments
8 changes: 5 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ Assuming you have...

Run the following from the command line:

(**NOTE:** If using gitpod, this all will be done for you on startup)

```shell script
git clone [email protected]:mitmedialab/prg-extension-boilerplate.git
# Clone the repository onto your computer. This could take a while (~5m), grab a beverage!
Expand Down Expand Up @@ -165,7 +167,7 @@ Also, try hovering over fields to view their documentation (typically a [summary

![Gif of video hovering over fields to peak documentation](/assets/hover.gif)

Still stuck? Check out our [From 0 to Extension guide](#-from-0-to-extension) and/or contact more experienced Scratch developers, like [Parker](https://github.com/pmalacho-mit) or [Randi](https://github.com/randi-c-dubs)
Still stuck? Check out our [From 0 to Extension guide](#-from-0-to-extension) and/or contact more experienced extension developers, like [Parker](https://github.com/pmalacho-mit) or [Randi](https://github.com/randi-c-dubs)

### 🪜 From 0 to Extension

Expand All @@ -174,7 +176,7 @@ Still stuck? Check out our [From 0 to Extension guide](#-from-0-to-extension) an
Currently, depending on what's new to you, here are some recommendations:
- ***New to Javascript and Typescript?*** Follow this [javascript tutorial](https://www.w3schools.com/js/) and then check out the [Typescript handbook](https://www.typescriptlang.org/docs/handbook/intro.html)
- ***Know javascript but new to Typescript?*** Check out the [Typescript handbook](https://www.typescriptlang.org/docs/handbook/intro.html)
- ***Know javascript/typescript but never made an extension before?*** Nice! The documentation of the template `index.ts` should be enough to get you started (and if not, please give that feedback)
- ***Know javascript/typescript but never made an extension before?*** Nice! The documentation of the template `index.ts` should be enough to get you started (and if not, please give us that feedback)
- ***New to the extension framework (but had developed extensions in the past)?*** The [Porting an extension to Typescript guide](#-porting-an-extension-to-typescript) is likely for you!
Probably will have:
Expand Down Expand Up @@ -212,7 +214,7 @@ Like many web development projects, this project requires [node](https://nodejs.

Also, [due to a Webpack 4 issue](https://github.com/webpack/webpack/issues/14532), we require a node version <=16.

Please locate the [latest v16 release](https://nodejs.org/en/blog/release) and install a suitable version for your operating system.
Please locate the [latest v16 release](https://nodejs.org/en/blog/release) and install a suitable version for your operating system. If you already have node and need to downgrade to a version <= 16, please see these [instructions for downgrading node](https://www.educative.io/answers/how-to-downgrade-node-version).

#### Maintainer Note (9/15/22)

Expand Down
Loading

0 comments on commit 4232808

Please sign in to comment.