From 3be92eea7659b5a6d59f1261c95f51d62e072981 Mon Sep 17 00:00:00 2001 From: Ray Foss Date: Sun, 4 Jun 2023 23:12:09 -0500 Subject: [PATCH 1/6] Update website.yml --- .github/workflows/website.yml | 38 +++++++++++++++++++++++++---------- 1 file changed, 27 insertions(+), 11 deletions(-) diff --git a/.github/workflows/website.yml b/.github/workflows/website.yml index 7508da49..49857512 100644 --- a/.github/workflows/website.yml +++ b/.github/workflows/website.yml @@ -7,17 +7,30 @@ on: # enable users to manually trigger with workflow_dispatch workflow_dispatch: {} +# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages +permissions: + contents: read + pages: write + id-token: write + +# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued. +# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete. +concurrency: + group: 'pages' + cancel-in-progress: false + jobs: - publish-website: - name: Publish Website + deploy: + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} runs-on: ubuntu-latest steps: - - uses: actions/checkout@dc323e67f16fb5f7663d20ff7941f27f5809e9b6 # pin@v2 - + - name: Checkout + uses: actions/checkout@v3 - uses: actions/setup-node@1f8c6b94b26d0feae1e387ca63ccbdc44d27b561 # pin@v2 with: node-version: 16 - - name: Cache node modules id: cacheNodeModules uses: actions/cache@v2 @@ -25,11 +38,9 @@ jobs: path: '**/node_modules' key: ${{ runner.os }}-cacheNodeModules2-${{ hashFiles('**/package-lock.json') }} restore-keys: ${{ runner.os }}-cacheNodeModules2- - - name: execute `npm ci` (1) if: ${{ steps.cacheNodeModules.outputs.cache-hit != 'true' }} run: npm ci - - name: Build run: npm run build-monaco-editor @@ -45,8 +56,13 @@ jobs: working-directory: website run: yarn run build - - name: Upload website to github pages - uses: peaceiris/actions-gh-pages@bd8c6b06eba6b3d25d72b7a1767993c0aeee42e7 # pin@v3 + - name: Setup Pages + uses: actions/configure-pages@v3 + - name: Upload artifact + uses: actions/upload-pages-artifact@v1 with: - github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: ./website/dist + # Upload entire repository + path: './website/dist' + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v2 From 5ce724a28176c2adde16f1dc707341b75b0cc9e1 Mon Sep 17 00:00:00 2001 From: Steven Weiss Date: Wed, 21 Jun 2023 12:30:10 -0700 Subject: [PATCH 2/6] Fix lorem ipsum text on marketing page. Format with prettier from command line. --- website/src/website/pages/home/Home.tsx | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/website/src/website/pages/home/Home.tsx b/website/src/website/pages/home/Home.tsx index 1f3bde98..759a06b2 100644 --- a/website/src/website/pages/home/Home.tsx +++ b/website/src/website/pages/home/Home.tsx @@ -172,10 +172,9 @@ class EditorDemo extends React.Component {

IntelliSense, Validation

- Paragraph of text beneath the heading to explain - the heading. We'll add onto it with another - sentence and probably just keep going until we - run out of words. + Get completions and errors directly in the + browser for supported languages. Or write your + own completion providers in JavaScript.

@@ -184,10 +183,9 @@ class EditorDemo extends React.Component {

Basic Syntax Colorization

- Paragraph of text beneath the heading to explain - the heading. We'll add onto it with another - sentence and probably just keep going until we - run out of words. + Colorize code using our pre-built syntax + highlighting, or configure your own custom + colorization.

From 2df7a51aa139646d49213ed8f595bb5101258b7c Mon Sep 17 00:00:00 2001 From: Leandro Pereira Date: Sat, 24 Jun 2023 09:07:36 -0400 Subject: [PATCH 3/6] Elixir - Add support for multi-letter uppercase sigils Elixir v1.15.0 has added support for multi-letter uppercase sigils ~LVN/content/ ~LVN/content/m Refs: Proposal: https://groups.google.com/g/elixir-lang-core/c/cocMcghahs4/m/DdYRNfuYAwAJ PR: elixir-lang/elixir#12448 Release notes: https://github.com/elixir-lang/elixir/releases/tag/v1.15.0 --- src/basic-languages/elixir/elixir.test.ts | 33 +++++++++++++++++++++++ src/basic-languages/elixir/elixir.ts | 19 ++++++------- 2 files changed, 43 insertions(+), 9 deletions(-) diff --git a/src/basic-languages/elixir/elixir.test.ts b/src/basic-languages/elixir/elixir.test.ts index fe68c922..25c06294 100644 --- a/src/basic-languages/elixir/elixir.test.ts +++ b/src/basic-languages/elixir/elixir.test.ts @@ -303,6 +303,17 @@ testTokenization('elixir', [ ] } ], + // Sigils (multi-letter uppercase) + [ + { + line: '~DX/foo/', + tokens: [ + { startIndex: 0, type: 'sigil.delimiter.elixir' }, + { startIndex: 4, type: 'sigil.elixir' }, + { startIndex: 7, type: 'sigil.delimiter.elixir' } + ] + } + ], // Sigils (no interpolation) [ { @@ -314,6 +325,17 @@ testTokenization('elixir', [ ] } ], + // Sigils (multi-letter uppercase no interpolation) + [ + { + line: '~WW/foo#{1}/', + tokens: [ + { startIndex: 0, type: 'sigil.delimiter.elixir' }, + { startIndex: 4, type: 'sigil.elixir' }, + { startIndex: 11, type: 'sigil.delimiter.elixir' } + ] + } + ], // Sigils (modifiers) [ { @@ -325,6 +347,17 @@ testTokenization('elixir', [ ] } ], + // Sigils (multi-letter uppercase with modifiers) + [ + { + line: '~DX/custom/az09', + tokens: [ + { startIndex: 0, type: 'sigil.delimiter.elixir' }, + { startIndex: 4, type: 'sigil.elixir' }, + { startIndex: 10, type: 'sigil.delimiter.elixir' } + ] + } + ], // Module attributes [ { diff --git a/src/basic-languages/elixir/elixir.ts b/src/basic-languages/elixir/elixir.ts index 078d1030..bb98e976 100644 --- a/src/basic-languages/elixir/elixir.ts +++ b/src/basic-languages/elixir/elixir.ts @@ -333,7 +333,8 @@ export const language = { // See https://elixir-lang.org/getting-started/sigils.html // Sigils allow for typing values using their textual representation. - // All sigils start with ~ followed by a letter indicating sigil type + // All sigils start with ~ followed by a letter or + // multi-letter uppercase starting at Elixir v1.15.0, indicating sigil type // and then a delimiter pair enclosing the textual representation. // Optional modifiers are allowed after the closing delimiter. // For instance a regular expressions can be written as: @@ -353,16 +354,16 @@ export const language = { sigils: [ [/~[a-z]@sigilStartDelimiter/, { token: '@rematch', next: '@sigil.interpol' }], - [/~[A-Z]@sigilStartDelimiter/, { token: '@rematch', next: '@sigil.noInterpol' }] + [/~([A-Z]+)@sigilStartDelimiter/, { token: '@rematch', next: '@sigil.noInterpol' }] ], sigil: [ - [/~([a-zA-Z])\{/, { token: '@rematch', switchTo: '@sigilStart.$S2.$1.{.}' }], - [/~([a-zA-Z])\[/, { token: '@rematch', switchTo: '@sigilStart.$S2.$1.[.]' }], - [/~([a-zA-Z])\(/, { token: '@rematch', switchTo: '@sigilStart.$S2.$1.(.)' }], - [/~([a-zA-Z])\' }], + [/~([a-z]|[A-Z]+)\{/, { token: '@rematch', switchTo: '@sigilStart.$S2.$1.{.}' }], + [/~([a-z]|[A-Z]+)\[/, { token: '@rematch', switchTo: '@sigilStart.$S2.$1.[.]' }], + [/~([a-z]|[A-Z]+)\(/, { token: '@rematch', switchTo: '@sigilStart.$S2.$1.(.)' }], + [/~([a-z]|[A-Z]+)\' }], [ - /~([a-zA-Z])(@sigilSymmetricDelimiter)/, + /~([a-z]|[A-Z]+)(@sigilSymmetricDelimiter)/, { token: '@rematch', switchTo: '@sigilStart.$S2.$1.$2.$2' } ] ], @@ -475,7 +476,7 @@ export const language = { // Fallback to the generic sigil by default 'sigilStart.interpol': [ [ - /~([a-zA-Z])@sigilStartDelimiter/, + /~([a-z]|[A-Z]+)@sigilStartDelimiter/, { token: 'sigil.delimiter', switchTo: '@sigilContinue.$S2.$S3.$S4.$S5' @@ -498,7 +499,7 @@ export const language = { 'sigilStart.noInterpol': [ [ - /~([a-zA-Z])@sigilStartDelimiter/, + /~([a-z]|[A-Z]+)@sigilStartDelimiter/, { token: 'sigil.delimiter', switchTo: '@sigilContinue.$S2.$S3.$S4.$S5' From dc5c24591beeaa42147b06900125629db52e5401 Mon Sep 17 00:00:00 2001 From: Henning Dieterichs Date: Thu, 29 Jun 2023 14:24:23 +0200 Subject: [PATCH 4/6] latest -> latest stable (versionNumber) --- .../playground/PlaygroundPageContent.tsx | 26 ++++++++++--------- 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/website/src/website/pages/playground/PlaygroundPageContent.tsx b/website/src/website/pages/playground/PlaygroundPageContent.tsx index cdd953cf..66b5e3f7 100644 --- a/website/src/website/pages/playground/PlaygroundPageContent.tsx +++ b/website/src/website/pages/playground/PlaygroundPageContent.tsx @@ -1,24 +1,24 @@ import { autorun } from "mobx"; import { observer } from "mobx-react"; import * as React from "react"; +import { ButtonGroup, FormCheck } from "react-bootstrap"; import { getLoadedMonaco } from "../../../monaco-loader"; -import { IPlaygroundProject, IPreviewState } from "../../../shared"; import { Page } from "../../components/Page"; import { Select } from "../../components/Select"; +import { Button, Col, Row, Stack } from "../../components/bootstrap"; import { MonacoEditor, MonacoEditorHeight, } from "../../components/monaco/MonacoEditor"; import { withLoadedMonaco } from "../../components/monaco/MonacoLoader"; +import { monacoEditorVersion } from "../../monacoEditorVersion"; import { hotComponent } from "../../utils/hotComponent"; import { IReference, ref } from "../../utils/ref"; -import { getNpmVersionsSync } from "./getNpmVersionsSync"; -import { getPlaygroundExamples, PlaygroundExample } from "./playgroundExamples"; import { PlaygroundModel } from "./PlaygroundModel"; import { Preview } from "./Preview"; import { SettingsDialog } from "./SettingsDialog"; -import { Button, Col, Row, Stack } from "../../components/bootstrap"; -import { ButtonGroup, FormCheck } from "react-bootstrap"; +import { getNpmVersionsSync } from "./getNpmVersionsSync"; +import { PlaygroundExample, getPlaygroundExamples } from "./playgroundExamples"; @hotComponent(module) @observer @@ -258,13 +258,15 @@ export class VersionSelector extends React.Component<{