diff --git a/prism-astro/index.mjs b/astro-prism/index.mjs similarity index 100% rename from prism-astro/index.mjs rename to astro-prism/index.mjs diff --git a/prism-astro/package-lock.json b/astro-prism/package-lock.json similarity index 100% rename from prism-astro/package-lock.json rename to astro-prism/package-lock.json diff --git a/prism-astro/package.json b/astro-prism/package.json similarity index 67% rename from prism-astro/package.json rename to astro-prism/package.json index f9a2f9dea7..2ce03a0bf4 100644 --- a/prism-astro/package.json +++ b/astro-prism/package.json @@ -1,16 +1,16 @@ { - "name": "prism-astro", + "name": "astro-prism", "version": "1.0.0", - "description": "", + "description": "This is not published at this time.", "main": "index.mjs", "scripts": { "test": "echo \"Error: no test specified\" && exit 1" }, "exports": { - ".": "./index.mjs", - "./Prism.astro": "./Prism.astro" + ".": "./index.mjs" }, "keywords": [], + "private": true, "author": "", "license": "ISC", "devDependencies": { diff --git a/prism-astro/test/demo.html b/astro-prism/test/demo.html similarity index 100% rename from prism-astro/test/demo.html rename to astro-prism/test/demo.html diff --git a/prism-astro/Prism.astro b/components/Prism.astro similarity index 84% rename from prism-astro/Prism.astro rename to components/Prism.astro index 70d43fc4a5..52995fab7b 100644 --- a/prism-astro/Prism.astro +++ b/components/Prism.astro @@ -1,6 +1,6 @@ --- import Prism from 'prismjs'; -import { addAstro } from './index.mjs'; +import { addAstro } from '../astro-prism/index.mjs'; addAstro(Prism); diff --git a/package-lock.json b/package-lock.json index 8cf22a3fb7..5849d256d8 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1030,6 +1030,17 @@ "resolved": "https://registry.npmjs.org/cli-spinners/-/cli-spinners-2.6.0.tgz", "integrity": "sha512-t+4/y50K/+4xcCRosKkA7W4gTr1MySvLV0q+PxmG7FJ5g+66ChKurYjxBCjHggHH3HA5Hh9cy+lcUGWDqVH+4Q==" }, + "clipboard": { + "version": "2.0.8", + "resolved": "https://registry.npmjs.org/clipboard/-/clipboard-2.0.8.tgz", + "integrity": "sha512-Y6WO0unAIQp5bLmk1zdThRhgJt/x3ks6f30s3oE3H1mgIEU33XyQjEf8gsf6DxC7NPX8Y1SsNWjUjL/ywLnnbQ==", + "optional": true, + "requires": { + "good-listener": "^1.2.2", + "select": "^1.1.2", + "tiny-emitter": "^2.0.0" + } + }, "cliui": { "version": "7.0.4", "resolved": "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz", @@ -1295,6 +1306,12 @@ "integrity": "sha512-0ISdNousHvZT2EiFlZeZAHBUvSxmKswVCEf8hW7KWgG4a8MVEu/3Vb6uWYozkjylyCxe0JBIiRB1jV45S70WVQ==", "dev": true }, + "delegate": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/delegate/-/delegate-3.2.0.tgz", + "integrity": "sha512-IofjkYBZaZivn0V8nnsMJGBr4jVLxHDheKSW88PyxS5QC4Vo9ZbZVvhzlSxY87fVq3STR6r+4cGepyHkcWOQSw==", + "optional": true + }, "dequal": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/dequal/-/dequal-2.0.2.tgz", @@ -1961,6 +1978,15 @@ "slash": "^3.0.0" } }, + "good-listener": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/good-listener/-/good-listener-1.2.2.tgz", + "integrity": "sha1-1TswzfkxPf+33JoNR3CWqm0UXFA=", + "optional": true, + "requires": { + "delegate": "^3.1.2" + } + }, "got": { "version": "9.6.0", "resolved": "https://registry.npmjs.org/got/-/got-9.6.0.tgz", @@ -3119,6 +3145,14 @@ "resolved": "https://registry.npmjs.org/pretty-format/-/pretty-format-3.8.0.tgz", "integrity": "sha1-v77VbV6ad2ZF9LH/eqGjrE+jw4U=" }, + "prismjs": { + "version": "1.23.0", + "resolved": "https://registry.npmjs.org/prismjs/-/prismjs-1.23.0.tgz", + "integrity": "sha512-c29LVsqOaLbBHuIbsTxaKENh1N2EQBOHaWv7gkHN4dgRbxSREqDnDbtFJYdpPauS4YCplMSNCABQ6Eeor69bAA==", + "requires": { + "clipboard": "^2.0.0" + } + }, "progress": { "version": "2.0.3", "resolved": "https://registry.npmjs.org/progress/-/progress-2.0.3.tgz", @@ -3410,6 +3444,12 @@ "kind-of": "^6.0.0" } }, + "select": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/select/-/select-1.1.2.tgz", + "integrity": "sha1-DnNQrN7ICxEIUoeG7B1EGNEbOW0=", + "optional": true + }, "semver": { "version": "5.7.1", "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", @@ -3717,6 +3757,12 @@ "integrity": "sha1-f17oI66AUgfACvLfSoTsP8+lcLQ=", "dev": true }, + "tiny-emitter": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/tiny-emitter/-/tiny-emitter-2.1.0.tgz", + "integrity": "sha512-NB6Dk1A9xgQPMoGqC5CVXn123gWyte215ONT5Pp5a0yt4nlEoO1ZWeCwpncaekPHXO60i47ihFnZPiRPjRMq4Q==", + "optional": true + }, "to-fast-properties": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", diff --git a/package.json b/package.json index cc58685222..b4711aab8d 100644 --- a/package.json +++ b/package.json @@ -7,14 +7,18 @@ "license": "MIT", "type": "module", "exports": { - ".": "./mastro.mjs", + ".": "./astro.mjs", "./snowpack-plugin": "./snowpack-plugin.cjs", - "./h": "./lib/h.js", - "./render/preact": "./lib/render/preact.js" + "./components/*.astro": "./components/*.astro" }, "bin": { "astro": "astro.mjs" }, + "files": [ + "components", + "lib", + "prism-astro" + ], "scripts": { "build": "tsc", "dev": "tsc --watch", @@ -57,6 +61,7 @@ "postcss-icss-keyframes": "^0.2.1", "preact": "^10.5.13", "preact-render-to-string": "^5.1.18", + "prismjs": "^1.23.0", "react": "^17.0.1", "react-dom": "^17.0.1", "rollup": "^2.43.1", diff --git a/www/astro/pages/blog.md b/www/astro/pages/blog.md index eeecedf657..3d6a3e23ae 100644 --- a/www/astro/pages/blog.md +++ b/www/astro/pages/blog.md @@ -2,7 +2,7 @@ layout: ../layouts/index.astro title: Astro import: - Prism: prism-astro/Prism.astro + Prism: astro/components/Prism.astro --- ## Links diff --git a/www/astro/pages/index.astro b/www/astro/pages/index.astro index beb4b29b35..ad8d998cf7 100644 --- a/www/astro/pages/index.astro +++ b/www/astro/pages/index.astro @@ -1,5 +1,5 @@ --- -import Prism from 'prism-astro/Prism.astro'; +import Prism from 'astro/components/Prism.astro'; import 'prismjs/themes/prism-tomorrow.css'; let title = 'Astro Build'; diff --git a/www/package.json b/www/package.json index 526082049b..385c5b6ba4 100644 --- a/www/package.json +++ b/www/package.json @@ -12,7 +12,6 @@ "license": "ISC", "devDependencies": { "astro": "file:../", - "prism-astro": "file:../prism-astro/", "prismjs": "^1.23.0" } }