From 0d6d18b8020565f839abee17f66e0b7109a3ff62 Mon Sep 17 00:00:00 2001 From: Rongjian Zhang Date: Sat, 7 Oct 2023 11:44:16 +0800 Subject: [PATCH] chore: drop gemoji package --- examples/lit/package.json | 1 - examples/lit/src/index.ts | 3 - examples/lit/src/text.md | 8 --- examples/lit/tsconfig.json | 3 - packages/plugin-gemoji/README.md | 26 --------- packages/plugin-gemoji/package.json | 37 ------------- packages/plugin-gemoji/src/index.ts | 8 --- packages/plugin-gemoji/tsconfig.json | 13 ----- packages/plugin-gemoji/vite.config.ts | 7 --- pnpm-lock.yaml | 80 +-------------------------- tsconfig.json | 3 - 11 files changed, 3 insertions(+), 186 deletions(-) delete mode 100644 packages/plugin-gemoji/README.md delete mode 100644 packages/plugin-gemoji/package.json delete mode 100644 packages/plugin-gemoji/src/index.ts delete mode 100644 packages/plugin-gemoji/tsconfig.json delete mode 100644 packages/plugin-gemoji/vite.config.ts diff --git a/examples/lit/package.json b/examples/lit/package.json index 72cd787a4..a4e36b0c1 100644 --- a/examples/lit/package.json +++ b/examples/lit/package.json @@ -11,7 +11,6 @@ "dependencies": { "@hashmd/plugin-breaks": "workspace:*", "@hashmd/plugin-frontmatter": "workspace:*", - "@hashmd/plugin-gemoji": "workspace:*", "@hashmd/plugin-gfm": "workspace:*", "@hashmd/plugin-highlight": "workspace:*", "@hashmd/plugin-highlight-ssr": "workspace:*", diff --git a/examples/lit/src/index.ts b/examples/lit/src/index.ts index 9ce7d52e0..c2d6cf4a4 100644 --- a/examples/lit/src/index.ts +++ b/examples/lit/src/index.ts @@ -1,7 +1,6 @@ import markdownText from "./text.md?raw"; import breaks from "@hashmd/plugin-breaks"; import frontmatter from "@hashmd/plugin-frontmatter"; -import gemoji from "@hashmd/plugin-gemoji"; import gfm from "@hashmd/plugin-gfm"; import highlight from "@hashmd/plugin-highlight"; import math from "@hashmd/plugin-math"; @@ -53,7 +52,6 @@ export class MyElement extends LitElement { @property() enabled = { breaks: false, frontmatter: true, - gemoji: true, gfm: true, highlight: true, math: true, @@ -66,7 +64,6 @@ export class MyElement extends LitElement { const plugins = [ enabled.breaks && breaks(), enabled.frontmatter && frontmatter(), - enabled.gemoji && gemoji(), enabled.gfm && gfm({ locale: gfmLocales[locale], diff --git a/examples/lit/src/text.md b/examples/lit/src/text.md index 6378894cd..b6e99c45f 100644 --- a/examples/lit/src/text.md +++ b/examples/lit/src/text.md @@ -66,14 +66,6 @@ Here's a simple footnote,[^1] and here's a longer one.[^bignote] Add as many paragraphs as you like. -## Gemoji - -Thumbs up: :+1:, thumbs down: :-1:. - -Families: :family_man_man_boy_boy: - -Long flags: :wales:, :scotland:, :england:. - ## Math Equation Inline math equation: $a+b$ diff --git a/examples/lit/tsconfig.json b/examples/lit/tsconfig.json index 296985749..6ed3c8525 100644 --- a/examples/lit/tsconfig.json +++ b/examples/lit/tsconfig.json @@ -25,9 +25,6 @@ { "path": "../../packages/plugin-frontmatter" }, - { - "path": "../../packages/plugin-gemoji" - }, { "path": "../../packages/plugin-gfm" }, diff --git a/packages/plugin-gemoji/README.md b/packages/plugin-gemoji/README.md deleted file mode 100644 index 776ca977d..000000000 --- a/packages/plugin-gemoji/README.md +++ /dev/null @@ -1,26 +0,0 @@ -# @hashmd/plugin-gemoji - -[![npm](https://img.shields.io/npm/v/@hashmd/plugin-gemoji.svg)](https://npm.im/@hashmd/plugin-gemoji) - -HashMD plugin to support Gemoji shortcodes - -## Usage - -```js -import gemoji from "@hashmd/plugin-gemoji"; -import { Editor } from "hashmd"; - -new Editor({ - target: document.body, - props: { - plugins: [ - gemoji(), - // ... other plugins - ], - }, -}); -``` - -## License - -MIT diff --git a/packages/plugin-gemoji/package.json b/packages/plugin-gemoji/package.json deleted file mode 100644 index 50e124cea..000000000 --- a/packages/plugin-gemoji/package.json +++ /dev/null @@ -1,37 +0,0 @@ -{ - "name": "@hashmd/plugin-gemoji", - "version": "1.21.0", - "description": "HashMD plugin to support Gemoji shortcodes", - "repository": { - "type": "git", - "url": "https://github.com/pd4d10/hashmd.git", - "directory": "packages/plugin-gemoji" - }, - "license": "MIT", - "author": "Rongjian Zhang", - "type": "module", - "exports": { - ".": { - "types": "./dist/index.d.ts", - "import": "./dist/index.mjs", - "require": "./dist/index.js" - }, - "./locales/*": "./locales/*" - }, - "main": "./dist/index.js", - "module": "./dist/index.mjs", - "types": "./dist/index.d.ts", - "files": [ - "dist", - "locales" - ], - "dependencies": { - "remark-gemoji": "^8.0.0" - }, - "devDependencies": { - "hashmd": "workspace:*" - }, - "peerDependencies": { - "hashmd": "^1.5.0" - } -} diff --git a/packages/plugin-gemoji/src/index.ts b/packages/plugin-gemoji/src/index.ts deleted file mode 100644 index 414cfba42..000000000 --- a/packages/plugin-gemoji/src/index.ts +++ /dev/null @@ -1,8 +0,0 @@ -import type { Plugin } from "hashmd"; -import remarkGemoji from "remark-gemoji"; - -export default function gemoji(): Plugin { - return { - remark: (processor) => processor.use(remarkGemoji), - }; -} diff --git a/packages/plugin-gemoji/tsconfig.json b/packages/plugin-gemoji/tsconfig.json deleted file mode 100644 index ba92745d3..000000000 --- a/packages/plugin-gemoji/tsconfig.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "extends": "../../tsconfig-base.json", - "include": ["src", "src/locales/*.json"], - "compilerOptions": { - "rootDir": "src", - "outDir": "dist" - }, - "references": [ - { - "path": "../core" - } - ] -} diff --git a/packages/plugin-gemoji/vite.config.ts b/packages/plugin-gemoji/vite.config.ts deleted file mode 100644 index ffba77bac..000000000 --- a/packages/plugin-gemoji/vite.config.ts +++ /dev/null @@ -1,7 +0,0 @@ -import { defineConfig } from "vite"; - -export default defineConfig({ - build: { - lib: { entry: "src/index.ts" }, - }, -}); diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 222b4cbcc..06bbbc971 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -82,7 +82,7 @@ importers: dependencies: vitepress: specifier: 1.0.0-rc.20 - version: 1.0.0-rc.20(@algolia/client-search@4.20.0)(sass@1.68.0)(search-insights@2.8.3) + version: 1.0.0-rc.20(@algolia/client-search@4.20.0)(sass@1.69.0)(search-insights@2.8.3) examples/lit: dependencies: @@ -92,9 +92,6 @@ importers: '@hashmd/plugin-frontmatter': specifier: workspace:* version: link:../../packages/plugin-frontmatter - '@hashmd/plugin-gemoji': - specifier: workspace:* - version: link:../../packages/plugin-gemoji '@hashmd/plugin-gfm': specifier: workspace:* version: link:../../packages/plugin-gfm @@ -233,16 +230,6 @@ importers: specifier: workspace:* version: link:../core - packages/plugin-gemoji: - dependencies: - remark-gemoji: - specifier: ^8.0.0 - version: 8.0.0 - devDependencies: - hashmd: - specifier: workspace:* - version: link:../core - packages/plugin-gfm: dependencies: remark-gfm: @@ -3596,10 +3583,6 @@ packages: wide-align: 1.1.5 dev: true - /gemoji@8.1.0: - resolution: {integrity: sha512-HA4Gx59dw2+tn+UAa7XEV4ufUKI4fH1KgcbenVA9YKSj1QJTT0xh5Mwv5HMFNN3l2OtUe3ZIfuRwSyZS5pLIWw==} - dev: false - /get-caller-file@2.0.5: resolution: {integrity: sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==} engines: {node: 6.* || 8.* || >= 10.*} @@ -6600,14 +6583,6 @@ packages: - supports-color dev: false - /remark-gemoji@8.0.0: - resolution: {integrity: sha512-/fL9rc72FYwFGtOKcT+QeQdx9Q9t5v4N6KLXSDOTEgaedzK85I9judBqB2eqz+g4b0ERMejlwSOuPK+wket6aA==} - dependencies: - '@types/mdast': 4.0.1 - gemoji: 8.1.0 - mdast-util-find-and-replace: 3.0.1 - dev: false - /remark-gfm@4.0.0: resolution: {integrity: sha512-U92vJgBPkbw4Zfu/IiW2oTZLSL3Zpv+uI7My2eq8JxKgqraFdU8YUGicEJCEgSbeaG+QDFqIcwwfMTOEelPxuA==} dependencies: @@ -6787,16 +6762,6 @@ packages: /safer-buffer@2.1.2: resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==} - /sass@1.68.0: - resolution: {integrity: sha512-Lmj9lM/fef0nQswm1J2HJcEsBUba4wgNx2fea6yJHODREoMFnwRpZydBnX/RjyXw2REIwdkbqE4hrTo4qfDBUA==} - engines: {node: '>=14.0.0'} - hasBin: true - dependencies: - chokidar: 3.5.3 - immutable: 4.3.4 - source-map-js: 1.0.2 - dev: false - /sass@1.69.0: resolution: {integrity: sha512-l3bbFpfTOGgQZCLU/gvm1lbsQ5mC/WnLz3djL2v4WCJBDrWm58PO+jgngcGRNnKUh6wSsdm50YaovTqskZ0xDQ==} engines: {node: '>=14.0.0'} @@ -6805,7 +6770,6 @@ packages: chokidar: 3.5.3 immutable: 4.3.4 source-map-js: 1.0.2 - dev: true /search-insights@2.8.3: resolution: {integrity: sha512-W9rZfQ9XEfF0O6ntgQOTI7Txc8nkZrO4eJ/pTHK0Br6wWND2sPGPoWg+yGhdIW7wMbLqk8dc23IyEtLlNGpeNw==} @@ -7614,43 +7578,6 @@ packages: - typescript dev: true - /vite@4.4.11(@types/node@20.8.2)(sass@1.68.0): - resolution: {integrity: sha512-ksNZJlkcU9b0lBwAGZGGaZHCMqHsc8OpgtoYhsQ4/I2v5cnpmmmqe5pM4nv/4Hn6G/2GhTdj0DhZh2e+Er1q5A==} - engines: {node: ^14.18.0 || >=16.0.0} - hasBin: true - peerDependencies: - '@types/node': '>= 14' - less: '*' - lightningcss: ^1.21.0 - sass: '*' - stylus: '*' - sugarss: '*' - terser: ^5.4.0 - peerDependenciesMeta: - '@types/node': - optional: true - less: - optional: true - lightningcss: - optional: true - sass: - optional: true - stylus: - optional: true - sugarss: - optional: true - terser: - optional: true - dependencies: - '@types/node': 20.8.2 - esbuild: 0.18.20 - postcss: 8.4.31 - rollup: 3.29.4 - sass: 1.68.0 - optionalDependencies: - fsevents: 2.3.3 - dev: false - /vite@4.4.11(@types/node@20.8.2)(sass@1.69.0): resolution: {integrity: sha512-ksNZJlkcU9b0lBwAGZGGaZHCMqHsc8OpgtoYhsQ4/I2v5cnpmmmqe5pM4nv/4Hn6G/2GhTdj0DhZh2e+Er1q5A==} engines: {node: ^14.18.0 || >=16.0.0} @@ -7686,9 +7613,8 @@ packages: sass: 1.69.0 optionalDependencies: fsevents: 2.3.3 - dev: true - /vitepress@1.0.0-rc.20(@algolia/client-search@4.20.0)(sass@1.68.0)(search-insights@2.8.3): + /vitepress@1.0.0-rc.20(@algolia/client-search@4.20.0)(sass@1.69.0)(search-insights@2.8.3): resolution: {integrity: sha512-CykMUJ8JLxLcGWek0ew3wln4RYbsOd1+0YzXITTpajggpynm2S331TNkJVOkHrMRc6GYe3y4pS40GfgcW0ZwAw==} hasBin: true peerDependencies: @@ -7710,7 +7636,7 @@ packages: mark.js: 8.11.1 minisearch: 6.1.0 shiki: 0.14.4 - vite: 4.4.11(@types/node@20.8.2)(sass@1.68.0) + vite: 4.4.11(@types/node@20.8.2)(sass@1.69.0) vue: 3.3.4 transitivePeerDependencies: - '@algolia/client-search' diff --git a/tsconfig.json b/tsconfig.json index a6f9bc149..0e7030a0a 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -13,9 +13,6 @@ { "path": "packages/plugin-frontmatter" }, - { - "path": "packages/plugin-gemoji" - }, { "path": "packages/plugin-gfm" },