mirror of
https://github.com/modernweb-dev/rocket.git
synced 2026-03-21 15:54:57 +00:00
Compare commits
16 Commits
plugins-ma
...
@rocket/cl
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
bb07267289 | ||
|
|
738941afdd | ||
|
|
ef086c7aa3 | ||
|
|
3d22fbb72e | ||
|
|
adf0f1d88f | ||
|
|
4145031162 | ||
|
|
ac58953527 | ||
|
|
7dc3e0f9b0 | ||
|
|
305a657ff5 | ||
|
|
8585e2ad66 | ||
|
|
4585675b00 | ||
|
|
39f4fa7050 | ||
|
|
ccdd4d077e | ||
|
|
a5661b85c2 | ||
|
|
99b12c7c9e | ||
|
|
61bb700c3e |
@@ -19,6 +19,11 @@
|
|||||||
src="https://img.shields.io/badge/twitter-@modern_web_dev-1DA1F3?style=flat-square"
|
src="https://img.shields.io/badge/twitter-@modern_web_dev-1DA1F3?style=flat-square"
|
||||||
alt="Follow @modern_web_dev on Twitter"
|
alt="Follow @modern_web_dev on Twitter"
|
||||||
/></a>
|
/></a>
|
||||||
|
<a href="https://open.vscode.dev/modernweb-dev/rocket"
|
||||||
|
><img
|
||||||
|
src="https://open.vscode.dev/badges/open-in-vscode.svg"
|
||||||
|
alt="Open in VS Code"
|
||||||
|
/></a>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<p align="center">
|
<p align="center">
|
||||||
|
|||||||
1
docs/.eleventyignore
Normal file
1
docs/.eleventyignore
Normal file
@@ -0,0 +1 @@
|
|||||||
|
*.docs.md
|
||||||
@@ -1,5 +1,39 @@
|
|||||||
:root {
|
:not(rocket-navigation):not(:defined) {
|
||||||
--markdown-table-row-odd-background-color: #efefef;
|
opacity: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
rocket-navigation,
|
||||||
|
header {
|
||||||
|
font-family: 'Montserrat', sans-serif;
|
||||||
|
}
|
||||||
|
|
||||||
|
code-tabs[collection="package-managers"] {
|
||||||
|
--code-tabs-icon-height: 18px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.call-to-action {
|
||||||
|
background: var(--button-one) !important;
|
||||||
|
text-shadow: none !important;
|
||||||
|
border-radius: 5px !important;
|
||||||
|
padding-top: 15px !important;
|
||||||
|
padding-bottom: 15px !important;
|
||||||
|
border: none !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.call-to-action:hover,
|
||||||
|
.call-to-action:focus,
|
||||||
|
.call-to-action:active {
|
||||||
|
background: var(--button-one-hover) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.call-to-action:nth-child(2) {
|
||||||
|
background: var(--button-two) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.call-to-action:nth-child(2):hover,
|
||||||
|
.call-to-action:nth-child(2):focus,
|
||||||
|
.call-to-action:nth-child(2):active {
|
||||||
|
background: var(--button-two-hover) !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
body[layout^='layout-home'] .markdown-body .call-to-action:nth-of-type(2) {
|
body[layout^='layout-home'] .markdown-body .call-to-action:nth-of-type(2) {
|
||||||
@@ -15,20 +49,3 @@ body[layout^='layout-home'] .markdown-body .call-to-action:nth-of-type(2) {
|
|||||||
transform: rotate(45deg);
|
transform: rotate(45deg);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
rocket-navigation {
|
|
||||||
font-family: 'Montserrat', sans-serif;
|
|
||||||
}
|
|
||||||
|
|
||||||
header {
|
|
||||||
font-family: 'Montserrat', sans-serif;
|
|
||||||
}
|
|
||||||
|
|
||||||
code-tabs[collection="package-managers"] {
|
|
||||||
--code-tabs-icon-height: 18px;
|
|
||||||
--code-tabs-justify-tabs: end;
|
|
||||||
}
|
|
||||||
|
|
||||||
:not(rocket-navigation):not(:defined) {
|
|
||||||
opacity: 0;
|
|
||||||
}
|
|
||||||
|
|||||||
135
docs/_assets/theme.css
Normal file
135
docs/_assets/theme.css
Normal file
@@ -0,0 +1,135 @@
|
|||||||
|
html {
|
||||||
|
--button-one-hover: #436eff;
|
||||||
|
--button-one: #2758ff;
|
||||||
|
--button-two-hover: #444;
|
||||||
|
--button-two: black;
|
||||||
|
--contrast-color-dark: #1d3557;
|
||||||
|
--contrast-color-light: #fff;
|
||||||
|
--footer-background: rgba(0, 0, 0, 0.02);
|
||||||
|
--header-color: white;
|
||||||
|
--markdown-link-color: #2758ff;
|
||||||
|
--markdown-syntax-background-color: #f9f9f9;
|
||||||
|
--markdown-table-row-odd-background-color: #efefef;
|
||||||
|
--owc-active-color: #2758ff;
|
||||||
|
--owc-hover-color: #436eff;
|
||||||
|
--page-background: white;
|
||||||
|
--primary-color-accent: #cee5f6;
|
||||||
|
--primary-color-darker: #1a5285;
|
||||||
|
--primary-color-lighter: #449ad7;
|
||||||
|
--primary-color: rgb(44, 62, 80);
|
||||||
|
--primary-lines-color: #ccc;
|
||||||
|
--primary-text-color: #2c3e50;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (prefers-color-scheme: dark) {
|
||||||
|
html {
|
||||||
|
--header-color: #2f3136;
|
||||||
|
--footer-background: rgba(255, 255, 255, 0.1);
|
||||||
|
--page-background: #36393e;
|
||||||
|
--text-color: #eee;
|
||||||
|
--primary-text-color: #eee;
|
||||||
|
--primary-color: white;
|
||||||
|
--primary-color-lighter: #449ad7;
|
||||||
|
--primary-color-darker: #1a5285;
|
||||||
|
--primary-color-accent: #cee5f6;
|
||||||
|
--contrast-color-light: #fff;
|
||||||
|
--contrast-color-dark: #1d3557;
|
||||||
|
--primary-lines-color: #333;
|
||||||
|
--owc-active-color: #41ffb0;
|
||||||
|
--owc-hover-color: #6dffc2;
|
||||||
|
--button-one: #9b03fe;
|
||||||
|
--button-one-hover: #a724ff;
|
||||||
|
--button-two: black;
|
||||||
|
--button-two-hover: rgb(36, 36, 36);
|
||||||
|
--rocket-search-background-color: #4a4d52;
|
||||||
|
--rocket-search-highlight-color: #41ffb0;
|
||||||
|
--rocket-search-hover-background-color: #6b717a;
|
||||||
|
--rocket-search-fill-color: #fff;
|
||||||
|
|
||||||
|
/* Markdown */
|
||||||
|
--markdown-octicon-link: var(--primary-text-color);
|
||||||
|
--markdown-link-color: #41ffb0;
|
||||||
|
--markdown-divider-color: #e1e4e8;
|
||||||
|
--markdown-blockquote-border-color: #dfe2e5;
|
||||||
|
--markdown-blockquote-color: #90aac7;
|
||||||
|
--markdown-kbd-background-color: #fafbfc;
|
||||||
|
--markdown-kbd-border-color: #c6cbd1;
|
||||||
|
--markdown-kbd-border-bottom-color: #959da5;
|
||||||
|
--markdown-kbd-color: #444d56;
|
||||||
|
--markdown-heading-color-6: #6a737d;
|
||||||
|
--markdown-table-background-color: var(--markdown-syntax-background-color);
|
||||||
|
--markdown-table-row-odd-background-color: var(--markdown-kbd-color);
|
||||||
|
--markdown-table-border-color: transparent;
|
||||||
|
--markdown-code-background-color: rgba(27, 31, 35, 0.05);
|
||||||
|
--markdown-pre-background-color: rgb(49, 49, 49);
|
||||||
|
|
||||||
|
/* syntax */
|
||||||
|
--markdown-syntax-color: #f8f8f2;
|
||||||
|
--markdown-syntax-background-color: #2e3440;
|
||||||
|
--markdown-syntax-atrule-color: #88c0d0;
|
||||||
|
--markdown-syntax-attr-name-color: #a3be8c;
|
||||||
|
--markdown-syntax-attr-value-color: #88c0d0;
|
||||||
|
--markdown-syntax-builtin-color: #a3be8c;
|
||||||
|
--markdown-syntax-boolean-color: #81a1c1;
|
||||||
|
--markdown-syntax-class-name-color: #88c0d0;
|
||||||
|
--markdown-syntax-constant-color: #81a1c1;
|
||||||
|
--markdown-syntax-char-color: #a3be8c;
|
||||||
|
--markdown-syntax-deleted-color: #81a1c1;
|
||||||
|
--markdown-syntax-entity-color: #81a1c1;
|
||||||
|
--markdown-syntax-function-color: #88c0d0;
|
||||||
|
--markdown-syntax-inserted-color: #a3be8c;
|
||||||
|
--markdown-syntax-keyword-color: #81a1c1;
|
||||||
|
--markdown-syntax-number-color: #b48ead;
|
||||||
|
--markdown-syntax-operator-color: #81a1c1;
|
||||||
|
--markdown-syntax-property-color: #81a1c1;
|
||||||
|
--markdown-syntax-punctuation-color: #81a1c1;
|
||||||
|
--markdown-syntax-regex-color: #81a1c1;
|
||||||
|
--markdown-syntax-important-color: #81a1c1;
|
||||||
|
--markdown-syntax-selector-color: #a3be8c;
|
||||||
|
--markdown-syntax-symbol-color: #81a1c1;
|
||||||
|
--markdown-syntax-string-color: #a3be8c;
|
||||||
|
--markdown-syntax-tag-color: #81a1c1;
|
||||||
|
--markdown-syntax-url-color: #81a1c1;
|
||||||
|
--markdown-syntax-variable-color: #81a1c1;
|
||||||
|
--markdown-syntax-hotkey-selector-color: #d73a49;
|
||||||
|
--markdown-syntax-keyword-color: #22863a;
|
||||||
|
--markdown-syntax-background-color: rgb(27, 29, 35);
|
||||||
|
--markdown-syntax-atrule-color: rgb(198, 120, 221);
|
||||||
|
--markdown-syntax-attr-name-color: rgb(198, 120, 221);
|
||||||
|
--markdown-syntax-boolean-color: rgb(209, 154, 102);
|
||||||
|
--markdown-syntax-class-name-color: rgb(97, 175, 239);
|
||||||
|
--markdown-syntax-constant-color: rgb(220, 220, 170);
|
||||||
|
--markdown-syntax-entity-color: rgb(220, 220, 170);
|
||||||
|
--markdown-syntax-function-color: rgb(97, 175, 239);
|
||||||
|
--markdown-syntax-inserted-color: rgb(220, 220, 170);
|
||||||
|
--markdown-syntax-keyword-color: rgb(198, 120, 221);
|
||||||
|
--markdown-syntax-number-color: rgb(220, 220, 170);
|
||||||
|
--markdown-syntax-operator-color: rgb(220, 220, 170);
|
||||||
|
--markdown-syntax-property-color: rgb(220, 220, 170);
|
||||||
|
--markdown-syntax-punctuation-color: white;
|
||||||
|
--markdown-syntax-regex-color: rgb(209, 154, 102);
|
||||||
|
--markdown-syntax-selector-color: rgb(86, 156, 214);
|
||||||
|
--markdown-syntax-symbol-color: rgb(220, 220, 170);
|
||||||
|
--markdown-syntax-tag-color: rgb(86, 156, 214);
|
||||||
|
--markdown-syntax-url-color: rgb(220, 220, 170);
|
||||||
|
--markdown-syntax-variable-color: rgb(220, 220, 170);
|
||||||
|
}
|
||||||
|
|
||||||
|
.string {
|
||||||
|
color: rgb(152, 195, 121);
|
||||||
|
}
|
||||||
|
|
||||||
|
.comment {
|
||||||
|
color: #7d7d7d;
|
||||||
|
}
|
||||||
|
|
||||||
|
.language-css {
|
||||||
|
--markdown-syntax-string-color: #81a1c1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
body[layout='home'] .markdown-body .call-to-action:nth-of-type(2) {
|
||||||
|
--primary-color: #222;
|
||||||
|
--primary-color-lighter: #333;
|
||||||
|
--primary-color-darker: #000;
|
||||||
|
}
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
<link rel="stylesheet" href="{{ '/_assets/theme.css' | asset | url }}">
|
||||||
@@ -88,8 +88,10 @@ The default preset for regular markdown content is available as `responsive`.
|
|||||||
|
|
||||||
👉 `rocket.config.js`
|
👉 `rocket.config.js`
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js
|
```js
|
||||||
export default {
|
/** @type {import('rocket/cli').RocketCliConfig} */
|
||||||
|
export default ({
|
||||||
imagePresets: {
|
imagePresets: {
|
||||||
responsive: {
|
responsive: {
|
||||||
widths: [300, 820],
|
widths: [300, 820],
|
||||||
@@ -97,8 +99,9 @@ export default {
|
|||||||
sizes: '(min-width: 1024px) 820px, calc(100vw - 20px)',
|
sizes: '(min-width: 1024px) 820px, calc(100vw - 20px)',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
});
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|
||||||
## Ignoring Images
|
## Ignoring Images
|
||||||
|
|
||||||
@@ -148,8 +151,10 @@ For this example we want to also ignore `.jpeg` files.
|
|||||||
|
|
||||||
👉 `rocket.config.js`
|
👉 `rocket.config.js`
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js
|
```js
|
||||||
export default {
|
/** @type {import('rocket/cli').RocketCliConfig} */
|
||||||
|
export default ({
|
||||||
imagePresets: {
|
imagePresets: {
|
||||||
responsive: {
|
responsive: {
|
||||||
// ...
|
// ...
|
||||||
@@ -157,8 +162,9 @@ export default {
|
|||||||
src.endsWith('.jpeg') || src.endsWith('svg') || src.includes('rocket-unresponsive.'),
|
src.endsWith('.jpeg') || src.endsWith('svg') || src.includes('rocket-unresponsive.'),
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
});
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|
||||||
With that setting we get the following behavior
|
With that setting we get the following behavior
|
||||||
|
|
||||||
@@ -180,8 +186,10 @@ becomes
|
|||||||
|
|
||||||
You can add your own image preset like so
|
You can add your own image preset like so
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js
|
```js
|
||||||
export default {
|
/** @type {import('rocket/cli').RocketCliConfig} */
|
||||||
|
export default ({
|
||||||
imagePresets: {
|
imagePresets: {
|
||||||
'my-image-preset': {
|
'my-image-preset': {
|
||||||
widths: [30, 60],
|
widths: [30, 60],
|
||||||
@@ -189,8 +197,9 @@ export default {
|
|||||||
sizes: '(min-width: 1024px) 30px, 60px',
|
sizes: '(min-width: 1024px) 30px, 60px',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
});
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|
||||||
Once that `imagePreset` is defined you can use it by adding it to any `img` tag.
|
Once that `imagePreset` is defined you can use it by adding it to any `img` tag.
|
||||||
|
|
||||||
@@ -232,15 +241,18 @@ If you want to add `webp` (or replace `avif` with it) you can do so by setting t
|
|||||||
|
|
||||||
👉 `rocket.config.js`
|
👉 `rocket.config.js`
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js
|
```js
|
||||||
export default {
|
/** @type {import('rocket/cli').RocketCliConfig} */
|
||||||
|
export default ({
|
||||||
imagePresets: {
|
imagePresets: {
|
||||||
responsive: {
|
responsive: {
|
||||||
formats: ['avif', 'webp', 'jpeg'],
|
formats: ['avif', 'webp', 'jpeg'],
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
});
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|
||||||
## Default widths
|
## Default widths
|
||||||
|
|
||||||
@@ -262,16 +274,19 @@ If you want to add more widths you can add them to `widths`.
|
|||||||
|
|
||||||
👉 `rocket.config.js`
|
👉 `rocket.config.js`
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js
|
```js
|
||||||
export default {
|
/** @type {import('rocket/cli').RocketCliConfig} */
|
||||||
|
export default ({
|
||||||
imagePresets: {
|
imagePresets: {
|
||||||
responsive: {
|
responsive: {
|
||||||
widths: [300, 600, 900, 1200, 1640],
|
widths: [300, 600, 900, 1200, 1640],
|
||||||
sizes: '(min-width: 1024px) 820px, calc(100vw - 20px)',
|
sizes: '(min-width: 1024px) 820px, calc(100vw - 20px)',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
});
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|
||||||
<inline-notification type="tip">
|
<inline-notification type="tip">
|
||||||
|
|
||||||
|
|||||||
@@ -4,22 +4,27 @@ The configuration file is `rocket.config.js` or `rocket.config.mjs`.
|
|||||||
|
|
||||||
The config files consist of the following parts:
|
The config files consist of the following parts:
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js
|
```js
|
||||||
import { rocketLaunch } from '@rocket/launch';
|
import { rocketLaunch } from '@rocket/launch';
|
||||||
|
|
||||||
export default {
|
/** @type {import('rocket/cli').RocketCliConfig} */
|
||||||
|
export default ({
|
||||||
presets: [rocketLaunch()],
|
presets: [rocketLaunch()],
|
||||||
emptyOutputDir: true,
|
emptyOutputDir: true,
|
||||||
pathPrefix: 'subfolder-only-for-build',
|
pathPrefix: 'subfolder-only-for-build',
|
||||||
};
|
});
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|
||||||
Rocket is primarily build around plugins for each of its systems.
|
Rocket is primarily build around plugins for each of its systems.
|
||||||
|
|
||||||
New plugins can be added and all default plugins can be adjusted or even removed by using the following functions.
|
New plugins can be added and all default plugins can be adjusted or even removed by using the following functions.
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js
|
```js
|
||||||
export default {
|
/** @type {import('rocket/cli').RocketCliConfig} */
|
||||||
|
export default ({
|
||||||
// add remark/unified plugin to the Markdown processing (e.g. enable special code blocks)
|
// add remark/unified plugin to the Markdown processing (e.g. enable special code blocks)
|
||||||
setupUnifiedPlugins: [],
|
setupUnifiedPlugins: [],
|
||||||
|
|
||||||
@@ -40,8 +45,9 @@ export default {
|
|||||||
|
|
||||||
// add a plugin to the cli (e.g. a new command like "rocket my-command")
|
// add a plugin to the cli (e.g. a new command like "rocket my-command")
|
||||||
setupCliPlugins: [],
|
setupCliPlugins: [],
|
||||||
};
|
});
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|
||||||
## Adding Rollup Plugins
|
## Adding Rollup Plugins
|
||||||
|
|
||||||
@@ -55,19 +61,19 @@ You can accomplish this with Rollup and dev server plugins. Make sure to add bot
|
|||||||
|
|
||||||
For these cases you can use `setupDevAndBuildPlugins`, which will automatically add the plugin for you to both Rollup and dev-server:
|
For these cases you can use `setupDevAndBuildPlugins`, which will automatically add the plugin for you to both Rollup and dev-server:
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js
|
```js
|
||||||
import json from '@rollup/plugin-json';
|
import json from '@rollup/plugin-json';
|
||||||
import { addPlugin } from 'plugins-manager';
|
import { addPlugin } from 'plugins-manager';
|
||||||
|
|
||||||
/** @type {import('@rocket/cli').RocketCliOptions} */
|
/** @type {import('@rocket/cli').RocketCliOptions} */
|
||||||
const config = {
|
export default ({
|
||||||
setupDevAndBuildPlugins: [
|
setupDevAndBuildPlugins: [
|
||||||
addPlugin({ name: 'json', plugin: json, location: 'top', options: { my: 'settings' } }),
|
addPlugin({ name: 'json', plugin: json, location: 'top', options: { my: 'settings' } }),
|
||||||
],
|
],
|
||||||
};
|
});
|
||||||
|
|
||||||
export default config;
|
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|
||||||
This will add the Rollup plugin `json` with the id `json` at the top of the plugin list of Rollup and the dev server. It needs to be at the top so further plugins down the line can work with JSON imports.
|
This will add the Rollup plugin `json` with the id `json` at the top of the plugin list of Rollup and the dev server. It needs to be at the top so further plugins down the line can work with JSON imports.
|
||||||
For the Dev Server the plugins are automatically wrapped by `@web/dev-server-rollup`. Note that [not all Rollup plugins](https://modern-web.dev/docs/dev-server/plugins/rollup/#compatibility-with-rollup-plugins) will work with the dev-server.
|
For the Dev Server the plugins are automatically wrapped by `@web/dev-server-rollup`. Note that [not all Rollup plugins](https://modern-web.dev/docs/dev-server/plugins/rollup/#compatibility-with-rollup-plugins) will work with the dev-server.
|
||||||
@@ -76,25 +82,48 @@ For the Dev Server the plugins are automatically wrapped by `@web/dev-server-rol
|
|||||||
|
|
||||||
All plugins which are either default or are added via a preset can still be adjusted by using `adjustPluginOptions`.
|
All plugins which are either default or are added via a preset can still be adjusted by using `adjustPluginOptions`.
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js
|
```js
|
||||||
import { adjustPluginOptions } from 'plugins-manager';
|
import { adjustPluginOptions } from 'plugins-manager';
|
||||||
|
|
||||||
/** @type {import('@rocket/cli').RocketCliOptions} */
|
/** @type {import('@rocket/cli').RocketCliOptions} */
|
||||||
const config = {
|
export default ({
|
||||||
setupDevAndBuildPlugins: [adjustPluginOptions('json', { my: 'overwrite settings' })],
|
setupDevAndBuildPlugins: [adjustPluginOptions('json', { my: 'overwrite settings' })],
|
||||||
};
|
});
|
||||||
|
|
||||||
export default config;
|
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|
||||||
## Lifecycle
|
## Lifecycle
|
||||||
|
|
||||||
You can hook into the rocket lifecycle by specifying a function for `before11ty`. This function runs before 11ty calls it's write method. If it is an async function, Rocket will await it's promise.
|
You can hook into the rocket lifecycle by specifying a function for `before11ty`. This function runs before 11ty calls it's write method. If it is an async function, Rocket will await it's promise.
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js
|
```js
|
||||||
export default {
|
/** @type {import('rocket/cli').RocketCliConfig} */
|
||||||
|
export default ({
|
||||||
async before11ty() {
|
async before11ty() {
|
||||||
await copyDataFiles();
|
await copyDataFiles();
|
||||||
},
|
},
|
||||||
};
|
});
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|
||||||
|
## Advanced
|
||||||
|
|
||||||
|
Sometimes you need even more control over the build process. In these cases you can take full control over the rollup config.
|
||||||
|
|
||||||
|
For example if you wanna add an `acron` plugin to rollup
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
|
```js
|
||||||
|
import { importAssertions } from 'acorn-import-assertions';
|
||||||
|
|
||||||
|
/** @type {import('rocket/cli').RocketCliConfig} */
|
||||||
|
export default ({
|
||||||
|
rollup: config => ({
|
||||||
|
...config,
|
||||||
|
acornInjectPlugins: [importAssertions],
|
||||||
|
}),
|
||||||
|
});
|
||||||
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|||||||
@@ -12,11 +12,14 @@ Changing the service worker file name can be quite a hassle so you can adjust ge
|
|||||||
|
|
||||||
👉 `rocket.config.js`
|
👉 `rocket.config.js`
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js
|
```js
|
||||||
export default {
|
/** @type {import('rocket/cli').RocketCliConfig} */
|
||||||
|
export default ({
|
||||||
serviceWorkerName: 'my-service-worker-name.js',
|
serviceWorkerName: 'my-service-worker-name.js',
|
||||||
};
|
});
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|
||||||
## Meet the Service Worker
|
## Meet the Service Worker
|
||||||
|
|
||||||
|
|||||||
@@ -72,15 +72,18 @@ excludeFromSearch: true
|
|||||||
|
|
||||||
Once you have that you need to configure it for the story renderer by setting it in your `rocket.config.js`.
|
Once you have that you need to configure it for the story renderer by setting it in your `rocket.config.js`.
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js
|
```js
|
||||||
export default {
|
/** @type {import('rocket/cli').RocketCliConfig} */
|
||||||
|
export default ({
|
||||||
setupUnifiedPlugins: [
|
setupUnifiedPlugins: [
|
||||||
adjustPluginOptions('mdjsSetupCode', {
|
adjustPluginOptions('mdjsSetupCode', {
|
||||||
simulationSettings: { simulatorUrl: '/simulator/' },
|
simulationSettings: { simulatorUrl: '/simulator/' },
|
||||||
}),
|
}),
|
||||||
],
|
],
|
||||||
};
|
});
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|
||||||
<inline-notification type="tip">
|
<inline-notification type="tip">
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ Enable writing blog posts within your Rocket site.
|
|||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
<code-tabs collection="package-managers" default-tab="npm">
|
<code-tabs collection="package-managers" default-tab="npm" align="end">
|
||||||
|
|
||||||
```bash tab npm
|
```bash tab npm
|
||||||
npm i @rocket/blog
|
npm i @rocket/blog
|
||||||
@@ -24,10 +24,13 @@ pnpm add @rocket/blog
|
|||||||
|
|
||||||
👉 `rocket.config.js`
|
👉 `rocket.config.js`
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js
|
```js
|
||||||
import { rocketBlog } from '@rocket/blog';
|
import { rocketBlog } from '@rocket/blog';
|
||||||
|
|
||||||
export default {
|
/** @type {import('rocket/cli').RocketCliConfig} */
|
||||||
|
export default ({
|
||||||
presets: [rocketBlog()],
|
presets: [rocketBlog()],
|
||||||
};
|
});
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|||||||
7
docs/docs/presets/launch/custom-elements.md
Normal file
7
docs/docs/presets/launch/custom-elements.md
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
---
|
||||||
|
layout: layout-api
|
||||||
|
package: '@rocket/launch'
|
||||||
|
module: inline-notification/index.js
|
||||||
|
---
|
||||||
|
|
||||||
|
# Presets >> Launch >> Custom Elements || 20
|
||||||
4
docs/docs/presets/launch/index.md
Normal file
4
docs/docs/presets/launch/index.md
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
# Presets >> Launch || 20
|
||||||
|
|
||||||
|
- [Preset](./preset/)
|
||||||
|
- [Custom Elements](./custom-elements/)
|
||||||
@@ -8,7 +8,7 @@ alerts:
|
|||||||
content: You **really** shouldn't!
|
content: You **really** shouldn't!
|
||||||
---
|
---
|
||||||
|
|
||||||
# Presets >> Launch || 20
|
# Presets >> Launch >> Preset || 10
|
||||||
|
|
||||||
Rocket comes with a preset you will love. Simple, responsive and behaving like native, it sure is going to be a hit among your users.
|
Rocket comes with a preset you will love. Simple, responsive and behaving like native, it sure is going to be a hit among your users.
|
||||||
|
|
||||||
@@ -16,7 +16,7 @@ Rocket comes with a preset you will love. Simple, responsive and behaving like n
|
|||||||
|
|
||||||
Install `@rocket/launch` from the NPM repository using your favourite package manager.
|
Install `@rocket/launch` from the NPM repository using your favourite package manager.
|
||||||
|
|
||||||
<code-tabs collection="package-managers" default-tab="npm">
|
<code-tabs collection="package-managers" default-tab="npm" align="end">
|
||||||
|
|
||||||
```bash tab npm
|
```bash tab npm
|
||||||
npm i @rocket/launch
|
npm i @rocket/launch
|
||||||
@@ -36,13 +36,16 @@ pnpm add @rocket/launch
|
|||||||
|
|
||||||
👉 `rocket.config.js`
|
👉 `rocket.config.js`
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js
|
```js
|
||||||
import { rocketLaunch } from '@rocket/launch';
|
import { rocketLaunch } from '@rocket/launch';
|
||||||
|
|
||||||
export default {
|
/** @type {import('rocket/cli').RocketCliConfig} */
|
||||||
|
export default ({
|
||||||
presets: [rocketLaunch()],
|
presets: [rocketLaunch()],
|
||||||
};
|
});
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|
||||||
## Data
|
## Data
|
||||||
|
|
||||||
@@ -1,43 +0,0 @@
|
|||||||
# Presets >> Search || 30
|
|
||||||
|
|
||||||
Add a search for all your static content.
|
|
||||||
|
|
||||||
## Installation
|
|
||||||
|
|
||||||
<code-tabs collection="package-managers" default-tab="npm">
|
|
||||||
|
|
||||||
```bash tab npm
|
|
||||||
npm i @rocket/search
|
|
||||||
```
|
|
||||||
|
|
||||||
```bash tab yarn
|
|
||||||
yarn add @rocket/search
|
|
||||||
```
|
|
||||||
|
|
||||||
```bash tab pnpm
|
|
||||||
pnpm add @rocket/search
|
|
||||||
```
|
|
||||||
|
|
||||||
</code-tabs>
|
|
||||||
|
|
||||||
## Usage
|
|
||||||
|
|
||||||
👉 `rocket.config.js`
|
|
||||||
|
|
||||||
```js
|
|
||||||
import { rocketSearch } from '@rocket/search';
|
|
||||||
|
|
||||||
export default {
|
|
||||||
presets: [rocketSearch()],
|
|
||||||
};
|
|
||||||
```
|
|
||||||
|
|
||||||
## Styling
|
|
||||||
|
|
||||||
| Property | Default | Description |
|
|
||||||
| ------------------------------------- | --------- | ------------------------------------ |
|
|
||||||
| `--rocket-search-background-color` | `#fff` | Search results background color |
|
|
||||||
| `--rocket-search-input-border-color` | `#dfe1e5` | |
|
|
||||||
| `--rocket-search-input-border-radius` | `24px` | |
|
|
||||||
| `--rocket-search-fill-color` | `#000` | Search Icon Color |
|
|
||||||
| `--rocket-search-highlight-color` | `#6c63ff` | Highlighted search result text color |
|
|
||||||
9
docs/docs/presets/search/custom-elements.md
Normal file
9
docs/docs/presets/search/custom-elements.md
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
---
|
||||||
|
layout: layout-api
|
||||||
|
package: '@rocket/search'
|
||||||
|
modules:
|
||||||
|
- src/RocketSearch.js
|
||||||
|
- src/RocketSearchCombobox.js
|
||||||
|
---
|
||||||
|
|
||||||
|
# Presets >> Search >> Custom Elements || 20
|
||||||
4
docs/docs/presets/search/index.md
Normal file
4
docs/docs/presets/search/index.md
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
# Presets >> Search || 10
|
||||||
|
|
||||||
|
- [Preset](./preset/)
|
||||||
|
- [Custom Elements](./custom-elements/)
|
||||||
36
docs/docs/presets/search/preset.md
Normal file
36
docs/docs/presets/search/preset.md
Normal file
@@ -0,0 +1,36 @@
|
|||||||
|
# Presets >> Search >> Preset || 10
|
||||||
|
|
||||||
|
Add a search for all your static content.
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
<code-tabs collection="package-managers" default-tab="npm" align="end">
|
||||||
|
|
||||||
|
```bash tab npm
|
||||||
|
npm i @rocket/search
|
||||||
|
```
|
||||||
|
|
||||||
|
```bash tab yarn
|
||||||
|
yarn add @rocket/search
|
||||||
|
```
|
||||||
|
|
||||||
|
```bash tab pnpm
|
||||||
|
pnpm add @rocket/search
|
||||||
|
```
|
||||||
|
|
||||||
|
</code-tabs>
|
||||||
|
|
||||||
|
## Usage
|
||||||
|
|
||||||
|
👉 `rocket.config.js`
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
|
```js
|
||||||
|
import { rocketSearch } from '@rocket/search';
|
||||||
|
|
||||||
|
/** @type {import('rocket/cli').RocketCliConfig} */
|
||||||
|
export default ({
|
||||||
|
presets: [rocketSearch()],
|
||||||
|
});
|
||||||
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
@@ -7,12 +7,16 @@ This allows your users to adjust the options before actually applying the plugin
|
|||||||
|
|
||||||
Many plugin systems require you to either execute a plugin function like in `rollup`.
|
Many plugin systems require you to either execute a plugin function like in `rollup`.
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js
|
```js
|
||||||
import json from '@rollup/plugin-json';
|
import json from '@rollup/plugin-json';
|
||||||
export default {
|
|
||||||
|
/** @type {import('rocket/cli').RocketCliConfig} */
|
||||||
|
export default ({
|
||||||
plugins: [json({ preferConst: true })],
|
plugins: [json({ preferConst: true })],
|
||||||
};
|
});
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|
||||||
or add it in a special way like in `eleventy`
|
or add it in a special way like in `eleventy`
|
||||||
|
|
||||||
|
|||||||
@@ -22,17 +22,17 @@ The Plugins Manager helps you register and execute your plugins across the vario
|
|||||||
|
|
||||||
If you want to add a plugin to the Markdown processing you can use `setupUnifiedPlugins`.
|
If you want to add a plugin to the Markdown processing you can use `setupUnifiedPlugins`.
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js
|
```js
|
||||||
import emoji from 'remark-emoji';
|
import emoji from 'remark-emoji';
|
||||||
import { addPlugin } from 'plugins-manager';
|
import { addPlugin } from 'plugins-manager';
|
||||||
|
|
||||||
/** @type {Partial<import('@rocket/cli').RocketCliOptions>} */
|
/** @type {Partial<import('@rocket/cli').RocketCliOptions>} */
|
||||||
const config = {
|
export default ({
|
||||||
setupUnifiedPlugins: [addPlugin({ location: 'markdown', name: 'emoji', plugin: emoji })],
|
setupUnifiedPlugins: [addPlugin({ location: 'markdown', name: 'emoji', plugin: emoji })],
|
||||||
};
|
});
|
||||||
|
|
||||||
export default config;
|
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|
||||||
For plugins that should handle the Markdown <abbr title="Abstract Syntax Tree">AST</abbr> you should use `addPlugin({ location: 'markdown', name: 'my-plugin', plugin: MyPlugin})`. <br>
|
For plugins that should handle the Markdown <abbr title="Abstract Syntax Tree">AST</abbr> you should use `addPlugin({ location: 'markdown', name: 'my-plugin', plugin: MyPlugin})`. <br>
|
||||||
While for the rehype AST you should use `addPlugin({ location: 'remark2rehype', name: 'my-plugin', plugin: MyPlugin})`.
|
While for the rehype AST you should use `addPlugin({ location: 'remark2rehype', name: 'my-plugin', plugin: MyPlugin})`.
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ cd my-project
|
|||||||
|
|
||||||
Then initialize a package.json file
|
Then initialize a package.json file
|
||||||
|
|
||||||
<code-tabs collection="package-managers" default-tab="npm">
|
<code-tabs collection="package-managers" default-tab="npm" align="end">
|
||||||
|
|
||||||
```bash tab npm
|
```bash tab npm
|
||||||
npm init -y
|
npm init -y
|
||||||
@@ -39,7 +39,7 @@ pnpm init -y
|
|||||||
|
|
||||||
### Step 2. Install dependencies
|
### Step 2. Install dependencies
|
||||||
|
|
||||||
<code-tabs collection="package-managers" default-tab="npm">
|
<code-tabs collection="package-managers" default-tab="npm" align="end">
|
||||||
|
|
||||||
```bash tab npm
|
```bash tab npm
|
||||||
npm install --save-dev @rocket/cli @rocket/launch
|
npm install --save-dev @rocket/cli @rocket/launch
|
||||||
@@ -57,7 +57,7 @@ pnpm add -D @rocket/cli @rocket/launch
|
|||||||
|
|
||||||
### Step 3. Bootstrap the project
|
### Step 3. Bootstrap the project
|
||||||
|
|
||||||
<code-tabs collection="package-managers" default-tab="npm">
|
<code-tabs collection="package-managers" default-tab="npm" align="end">
|
||||||
|
|
||||||
```bash tab npm
|
```bash tab npm
|
||||||
npx rocket bootstrap
|
npx rocket bootstrap
|
||||||
@@ -92,13 +92,16 @@ If you don't want to use the `module` package type, make sure to rename the gene
|
|||||||
|
|
||||||
<code-tabs default-tab="rocket.config.js">
|
<code-tabs default-tab="rocket.config.js">
|
||||||
|
|
||||||
|
<!-- prettier-ignore-start -->
|
||||||
```js tab rocket.config.js
|
```js tab rocket.config.js
|
||||||
import { rocketLaunch } from '@rocket/launch';
|
import { rocketLaunch } from '@rocket/launch';
|
||||||
|
|
||||||
export default {
|
/** @type {import('rocket/cli').RocketCliConfig} */
|
||||||
|
export default ({
|
||||||
presets: [rocketLaunch()],
|
presets: [rocketLaunch()],
|
||||||
};
|
});
|
||||||
```
|
```
|
||||||
|
<!-- prettier-ignore-end -->
|
||||||
|
|
||||||
```md tab docs/index.md
|
```md tab docs/index.md
|
||||||
# Welcome to Your Rocket Site
|
# Welcome to Your Rocket Site
|
||||||
@@ -145,7 +148,7 @@ Please note that the heading - text prefixed with `#` or `##` - is not optional
|
|||||||
|
|
||||||
Now you can launch your site locally with
|
Now you can launch your site locally with
|
||||||
|
|
||||||
<code-tabs collection="package-managers" default-tab="npm">
|
<code-tabs collection="package-managers" default-tab="npm" align="end">
|
||||||
|
|
||||||
```bash tab npm
|
```bash tab npm
|
||||||
npm start
|
npm start
|
||||||
|
|||||||
17
package.json
17
package.json
@@ -8,15 +8,16 @@
|
|||||||
},
|
},
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"analyze": "node scripts/workspaces-scripts-bin.mjs analyze",
|
"analyze": "run-s analyze:* format:*",
|
||||||
|
"analyze:analyze": "node scripts/workspaces-scripts-bin.mjs analyze",
|
||||||
"build": "npm run build:packages && npm run build:site",
|
"build": "npm run build:packages && npm run build:site",
|
||||||
"build:packages": "node scripts/workspaces-scripts-bin.mjs build:package",
|
"build:packages": "node scripts/workspaces-scripts-bin.mjs build:package",
|
||||||
"build:site": "npm run rocket:build",
|
"build:site": "run-s analyze:* rocket:build",
|
||||||
"changeset": "changeset",
|
"changeset": "changeset",
|
||||||
"debug": "web-test-runner --watch --config web-test-runner-chrome.config.mjs",
|
"debug": "web-test-runner --watch --config web-test-runner-chrome.config.mjs",
|
||||||
"debug:firefox": "web-test-runner --watch --config web-test-runner-firefox.config.mjs",
|
"debug:firefox": "web-test-runner --watch --config web-test-runner-firefox.config.mjs",
|
||||||
"debug:webkit": "web-test-runner --watch --config web-test-runner-webkit.config.mjs",
|
"debug:webkit": "web-test-runner --watch --config web-test-runner-webkit.config.mjs",
|
||||||
"format": "npm run format:eslint && npm run format:prettier",
|
"format": "run-s format:*",
|
||||||
"format:eslint": "eslint --ext .ts,.js,.mjs,.cjs . --fix",
|
"format:eslint": "eslint --ext .ts,.js,.mjs,.cjs . --fix",
|
||||||
"format:prettier": "node node_modules/prettier/bin-prettier.js \"**/*.{ts,js,mjs,cjs,md}\" \"**/!(expected)/package.json\" --write --ignore-path .eslintignore",
|
"format:prettier": "node node_modules/prettier/bin-prettier.js \"**/*.{ts,js,mjs,cjs,md}\" \"**/!(expected)/package.json\" --write --ignore-path .eslintignore",
|
||||||
"lint": "run-p lint:*",
|
"lint": "run-p lint:*",
|
||||||
@@ -32,6 +33,7 @@
|
|||||||
"setup": "npm run setup:ts-configs && npm run build:packages",
|
"setup": "npm run setup:ts-configs && npm run build:packages",
|
||||||
"setup:patches": "npx patch-package",
|
"setup:patches": "npx patch-package",
|
||||||
"setup:ts-configs": "node scripts/generate-ts-configs.mjs",
|
"setup:ts-configs": "node scripts/generate-ts-configs.mjs",
|
||||||
|
"prestart": "yarn analyze",
|
||||||
"start": "node packages/cli/src/cli.js start",
|
"start": "node packages/cli/src/cli.js start",
|
||||||
"test": "yarn test:node && yarn test:web",
|
"test": "yarn test:node && yarn test:web",
|
||||||
"test:node": "mocha \"packages/*/test-node/**/*.test.{ts,js,mjs,cjs}\" --timeout 5000 --reporter dot --exit",
|
"test:node": "mocha \"packages/*/test-node/**/*.test.{ts,js,mjs,cjs}\" --timeout 5000 --reporter dot --exit",
|
||||||
@@ -46,7 +48,7 @@
|
|||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@changesets/cli": "^2.12.0",
|
"@changesets/cli": "^2.12.0",
|
||||||
"@custom-elements-manifest/analyzer": "^0.4.11",
|
"@custom-elements-manifest/analyzer": "^0.4.12",
|
||||||
"@open-wc/testing": "^3.0.0-next.1",
|
"@open-wc/testing": "^3.0.0-next.1",
|
||||||
"@rollup/plugin-commonjs": "^17.0.0",
|
"@rollup/plugin-commonjs": "^17.0.0",
|
||||||
"@rollup/plugin-json": "^4.1.0",
|
"@rollup/plugin-json": "^4.1.0",
|
||||||
@@ -61,12 +63,12 @@
|
|||||||
"@web/test-runner": "^0.12.2",
|
"@web/test-runner": "^0.12.2",
|
||||||
"@web/test-runner-commands": "^0.4.0",
|
"@web/test-runner-commands": "^0.4.0",
|
||||||
"@web/test-runner-playwright": "^0.8.0",
|
"@web/test-runner-playwright": "^0.8.0",
|
||||||
"cem-plugin-readme": "^0.1.2",
|
"cem-plugin-readme": "^0.1.3",
|
||||||
"chai": "^4.2.0",
|
"chai": "^4.2.0",
|
||||||
"concurrently": "^5.3.0",
|
"concurrently": "^5.3.0",
|
||||||
"copyfiles": "^2.4.1",
|
"copyfiles": "^2.4.1",
|
||||||
"deepmerge": "^4.2.2",
|
"deepmerge": "^4.2.2",
|
||||||
"esbuild": "^0.8.31",
|
"esbuild": "^0.12.15",
|
||||||
"eslint": "^7.17.0",
|
"eslint": "^7.17.0",
|
||||||
"eslint-config-prettier": "^7.1.0",
|
"eslint-config-prettier": "^7.1.0",
|
||||||
"hanbi": "^0.4.1",
|
"hanbi": "^0.4.1",
|
||||||
@@ -81,7 +83,8 @@
|
|||||||
"puppeteer": "^9.0.0",
|
"puppeteer": "^9.0.0",
|
||||||
"remark-emoji": "^2.1.0",
|
"remark-emoji": "^2.1.0",
|
||||||
"rimraf": "^3.0.2",
|
"rimraf": "^3.0.2",
|
||||||
"rocket-preset-code-tabs": "^0.2.1",
|
"rocket-preset-code-tabs": "^0.2.6",
|
||||||
|
"rocket-preset-custom-elements-manifest": "^0.1.7",
|
||||||
"rollup": "^2.36.1",
|
"rollup": "^2.36.1",
|
||||||
"rollup-plugin-terser": "^7.0.2",
|
"rollup-plugin-terser": "^7.0.2",
|
||||||
"sinon": "^9.2.3",
|
"sinon": "^9.2.3",
|
||||||
|
|||||||
@@ -1,5 +1,11 @@
|
|||||||
# @rocket/blog
|
# @rocket/blog
|
||||||
|
|
||||||
|
## 0.3.1
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- a5661b8: Updates dependencies
|
||||||
|
|
||||||
## 0.3.0
|
## 0.3.0
|
||||||
|
|
||||||
### Minor Changes
|
### Minor Changes
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@rocket/blog",
|
"name": "@rocket/blog",
|
||||||
"version": "0.3.0",
|
"version": "0.3.1",
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
},
|
},
|
||||||
@@ -38,6 +38,6 @@
|
|||||||
"testing"
|
"testing"
|
||||||
],
|
],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"plugins-manager": "^0.2.2"
|
"plugins-manager": "^0.2.4"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,35 @@
|
|||||||
# @rocket/cli
|
# @rocket/cli
|
||||||
|
|
||||||
|
## 0.9.10
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- 738941a: In `rocket.config.js` you can now supply a rollup config function.
|
||||||
|
|
||||||
|
```js
|
||||||
|
export default {
|
||||||
|
rollup: config => {
|
||||||
|
// config will be the fully generated config object after all presets have been applied
|
||||||
|
if (config.plugins.includes('...')) {
|
||||||
|
// change some config options
|
||||||
|
}
|
||||||
|
return config;
|
||||||
|
},
|
||||||
|
};
|
||||||
|
```
|
||||||
|
|
||||||
|
## 0.9.9
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- adf0f1d: use img openEnd to insert responsive image
|
||||||
|
|
||||||
|
## 0.9.8
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- a5661b8: Updates dependencies
|
||||||
|
|
||||||
## 0.9.7
|
## 0.9.7
|
||||||
|
|
||||||
### Patch Changes
|
### Patch Changes
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@rocket/cli",
|
"name": "@rocket/cli",
|
||||||
"version": "0.9.7",
|
"version": "0.9.10",
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
},
|
},
|
||||||
@@ -59,7 +59,7 @@
|
|||||||
"@11ty/eleventy-img": "^0.9.0",
|
"@11ty/eleventy-img": "^0.9.0",
|
||||||
"@rocket/building-rollup": "^0.3.1",
|
"@rocket/building-rollup": "^0.3.1",
|
||||||
"@rocket/core": "^0.1.2",
|
"@rocket/core": "^0.1.2",
|
||||||
"@rocket/eleventy-plugin-mdjs-unified": "^0.5.1",
|
"@rocket/eleventy-plugin-mdjs-unified": "^0.5.2",
|
||||||
"@rocket/eleventy-rocket-nav": "^0.3.0",
|
"@rocket/eleventy-rocket-nav": "^0.3.0",
|
||||||
"@rollup/plugin-babel": "^5.2.2",
|
"@rollup/plugin-babel": "^5.2.2",
|
||||||
"@rollup/plugin-node-resolve": "^11.0.1",
|
"@rollup/plugin-node-resolve": "^11.0.1",
|
||||||
@@ -72,7 +72,7 @@
|
|||||||
"command-line-usage": "^6.1.1",
|
"command-line-usage": "^6.1.1",
|
||||||
"fs-extra": "^9.0.1",
|
"fs-extra": "^9.0.1",
|
||||||
"micromatch": "^4.0.2",
|
"micromatch": "^4.0.2",
|
||||||
"plugins-manager": "^0.2.3",
|
"plugins-manager": "^0.2.4",
|
||||||
"slash": "^3.0.0",
|
"slash": "^3.0.0",
|
||||||
"utf8": "^3.0.0",
|
"utf8": "^3.0.0",
|
||||||
"workbox-window": "^6.1.5"
|
"workbox-window": "^6.1.5"
|
||||||
|
|||||||
@@ -54,8 +54,8 @@ async function productionBuild(config) {
|
|||||||
...config.setupBuildPlugins,
|
...config.setupBuildPlugins,
|
||||||
],
|
],
|
||||||
});
|
});
|
||||||
|
const finalConfig = typeof config.rollup === 'function' ? config.rollup(mpaConfig) : mpaConfig;
|
||||||
await buildAndWrite(mpaConfig);
|
await buildAndWrite(finalConfig);
|
||||||
|
|
||||||
const serviceWorkerSourcePath = path.resolve('docs/_merged_assets/service-worker.js');
|
const serviceWorkerSourcePath = path.resolve('docs/_merged_assets/service-worker.js');
|
||||||
if (fs.existsSync(serviceWorkerSourcePath)) {
|
if (fs.existsSync(serviceWorkerSourcePath)) {
|
||||||
|
|||||||
@@ -33,7 +33,7 @@ function replaceBetween({ html, start, end, insert = '' }) {
|
|||||||
const i = start.line;
|
const i = start.line;
|
||||||
const line = lines[i];
|
const line = lines[i];
|
||||||
const upToChange = line.slice(0, start.character);
|
const upToChange = line.slice(0, start.character);
|
||||||
const afterChange = line.slice(end.character - 4);
|
const afterChange = line.slice(end.character);
|
||||||
|
|
||||||
lines[i] = `${upToChange}${insert}${afterChange}`;
|
lines[i] = `${upToChange}${insert}${afterChange}`;
|
||||||
return lines.join('\n');
|
return lines.join('\n');
|
||||||
@@ -103,7 +103,8 @@ function getImages(html, { imagePresets }) {
|
|||||||
if (ev === SaxEventType.CloseTag) {
|
if (ev === SaxEventType.CloseTag) {
|
||||||
const data = /** @type {Tag} */ (/** @type {any} */ (_data));
|
const data = /** @type {Tag} */ (/** @type {any} */ (_data));
|
||||||
if (data.name === 'img') {
|
if (data.name === 'img') {
|
||||||
const { openStart, closeEnd } = data;
|
// Img tag only has open tag.
|
||||||
|
const { openStart, openEnd } = data;
|
||||||
|
|
||||||
const attributes = getAttributes(data);
|
const attributes = getAttributes(data);
|
||||||
const presetName = getAttribute(data, 'rocket-image');
|
const presetName = getAttribute(data, 'rocket-image');
|
||||||
@@ -127,7 +128,7 @@ function getImages(html, { imagePresets }) {
|
|||||||
title,
|
title,
|
||||||
alt,
|
alt,
|
||||||
openStart,
|
openStart,
|
||||||
closeEnd,
|
openEnd,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -219,7 +220,7 @@ function updateHtml(html, changes) {
|
|||||||
newHtml = replaceBetween({
|
newHtml = replaceBetween({
|
||||||
html: newHtml,
|
html: newHtml,
|
||||||
start: change.openStart,
|
start: change.openStart,
|
||||||
end: change.closeEnd,
|
end: change.openEnd,
|
||||||
insert: change.newHtml,
|
insert: change.newHtml,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -188,4 +188,23 @@ describe('RocketCli e2e', () => {
|
|||||||
errorMatch: /Found 1 missing reference targets/,
|
errorMatch: /Found 1 missing reference targets/,
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it('can completely take over the rollup config', async () => {
|
||||||
|
cli = await executeBuild('e2e-fixtures/rollup-override/rocket.config.js');
|
||||||
|
|
||||||
|
const indexHtml = await readBuildOutput(cli, 'index.html', {
|
||||||
|
stripToBody: true,
|
||||||
|
formatHtml: true,
|
||||||
|
});
|
||||||
|
expect(indexHtml).to.equal(
|
||||||
|
[
|
||||||
|
'<h1 id="importing-foo">',
|
||||||
|
' <a aria-hidden="true" tabindex="-1" href="#importing-foo"><span class="icon icon-link"></span></a',
|
||||||
|
' >Importing foo',
|
||||||
|
'</h1>',
|
||||||
|
'',
|
||||||
|
'<script type="module" src="./7338509a.js" mdjs-setup=""></script>',
|
||||||
|
].join('\n'),
|
||||||
|
);
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -101,6 +101,52 @@ describe('RocketCli images', () => {
|
|||||||
'</p>',
|
'</p>',
|
||||||
].join('\n'),
|
].join('\n'),
|
||||||
);
|
);
|
||||||
|
|
||||||
|
const tableHtml = await readStartOutput(cli, 'table/index.html', {
|
||||||
|
formatHtml: true,
|
||||||
|
replaceImageHashes: true,
|
||||||
|
});
|
||||||
|
expect(tableHtml).to.equal(
|
||||||
|
[
|
||||||
|
'<table>',
|
||||||
|
' <thead>',
|
||||||
|
' <tr>',
|
||||||
|
' <th>Image</th>',
|
||||||
|
' </tr>',
|
||||||
|
' </thead>',
|
||||||
|
' <tbody>',
|
||||||
|
' <tr>',
|
||||||
|
' <td>',
|
||||||
|
' <figure>',
|
||||||
|
' <picture>',
|
||||||
|
' <source',
|
||||||
|
' type="image/avif"',
|
||||||
|
' srcset="/images/__HASH__-600.avif 600w, /images/__HASH__-900.avif 900w"',
|
||||||
|
' sizes="100vw"',
|
||||||
|
' />',
|
||||||
|
' <source',
|
||||||
|
' type="image/jpeg"',
|
||||||
|
' srcset="/images/__HASH__-600.jpeg 600w, /images/__HASH__-900.jpeg 900w"',
|
||||||
|
' sizes="100vw"',
|
||||||
|
' />',
|
||||||
|
' <img',
|
||||||
|
' alt="My Image Alternative Text"',
|
||||||
|
' rocket-image="responsive"',
|
||||||
|
' src="/images/__HASH__-600.jpeg"',
|
||||||
|
' width="600"',
|
||||||
|
' height="316"',
|
||||||
|
' loading="lazy"',
|
||||||
|
' decoding="async"',
|
||||||
|
' />',
|
||||||
|
' </picture>',
|
||||||
|
' <figcaption>My Image Description</figcaption>',
|
||||||
|
' </figure>',
|
||||||
|
' </td>',
|
||||||
|
' </tr>',
|
||||||
|
' </tbody>',
|
||||||
|
'</table>',
|
||||||
|
].join('\n'),
|
||||||
|
);
|
||||||
});
|
});
|
||||||
|
|
||||||
it('can configure more patterns to ignore', async () => {
|
it('can configure more patterns to ignore', async () => {
|
||||||
|
|||||||
7
packages/cli/test-node/e2e-fixtures/images/docs/table.md
Normal file
7
packages/cli/test-node/e2e-fixtures/images/docs/table.md
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
---
|
||||||
|
layout: layout-raw
|
||||||
|
---
|
||||||
|
|
||||||
|
| Image |
|
||||||
|
| --------------------------------------------------------------------------- |
|
||||||
|
|  |
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
**/*.njk
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
---
|
||||||
|
layout: layout-raw
|
||||||
|
---
|
||||||
|
|
||||||
|
# Importing foo
|
||||||
|
|
||||||
|
```js script
|
||||||
|
import { foo } from './not-foo.js';
|
||||||
|
|
||||||
|
console.log(foo);
|
||||||
|
```
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
export const notFoo = 'not-foo';
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
// @ts-no-check
|
||||||
|
|
||||||
|
/** @type {Partial<import("../../../types/main").RocketCliOptions>} */
|
||||||
|
const config = {
|
||||||
|
rollup: config => ({
|
||||||
|
...config,
|
||||||
|
shimMissingExports: true,
|
||||||
|
}),
|
||||||
|
};
|
||||||
|
|
||||||
|
export default config;
|
||||||
1
packages/cli/types/main.d.ts
vendored
1
packages/cli/types/main.d.ts
vendored
@@ -40,6 +40,7 @@ export interface RocketCliOptions extends Pick<RocketPreset, PresetKeys> {
|
|||||||
start?: RocketStartConfig;
|
start?: RocketStartConfig;
|
||||||
|
|
||||||
// advanced
|
// advanced
|
||||||
|
rollup?: (config: any) => void; // TODO: improve
|
||||||
devServer?: DevServerConfig;
|
devServer?: DevServerConfig;
|
||||||
eleventy?: (eleventyConfig: any) => void; // TODO: improve
|
eleventy?: (eleventyConfig: any) => void; // TODO: improve
|
||||||
plugins?: RocketPlugin[];
|
plugins?: RocketPlugin[];
|
||||||
|
|||||||
@@ -1,5 +1,11 @@
|
|||||||
# @rocket/eleventy-plugin-mdjs-unified
|
# @rocket/eleventy-plugin-mdjs-unified
|
||||||
|
|
||||||
|
## 0.5.2
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- 39f4fa7: Updates dependencies
|
||||||
|
|
||||||
## 0.5.1
|
## 0.5.1
|
||||||
|
|
||||||
### Patch Changes
|
### Patch Changes
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@rocket/eleventy-plugin-mdjs-unified",
|
"name": "@rocket/eleventy-plugin-mdjs-unified",
|
||||||
"version": "0.5.1",
|
"version": "0.5.2",
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
},
|
},
|
||||||
@@ -31,7 +31,7 @@
|
|||||||
"mdjs"
|
"mdjs"
|
||||||
],
|
],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@mdjs/core": "^0.8.1",
|
"@mdjs/core": "^0.8.2",
|
||||||
"es-module-lexer": "^0.3.26",
|
"es-module-lexer": "^0.3.26",
|
||||||
"unist-util-visit": "^2.0.3"
|
"unist-util-visit": "^2.0.3"
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -1,5 +1,11 @@
|
|||||||
# @rocket/launch
|
# @rocket/launch
|
||||||
|
|
||||||
|
## 0.5.5
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- 3d22fbb: Prevent styles from applying to lion components that are rendered in light dom
|
||||||
|
|
||||||
## 0.5.4
|
## 0.5.4
|
||||||
|
|
||||||
### Patch Changes
|
### Patch Changes
|
||||||
|
|||||||
@@ -28,16 +28,22 @@ For docs please see our homepage [https://rocket.modern-web.dev/docs/presets/lau
|
|||||||
|
|
||||||
#### CSS Properties
|
#### CSS Properties
|
||||||
|
|
||||||
|
| Name | Default | Description |
|
||||||
|
| ---------------------------------------------- | -------------------------- | ----------- |
|
||||||
|
| --inline-notification-tip-background-color | `rgba(221, 221, 221, 0.3)` | |
|
||||||
|
| --inline-notification-tip-border-color | `#42b983` | |
|
||||||
|
| --inline-notification-warning-background-color | `rgba(255, 229, 100, 0.2)` | |
|
||||||
|
| --inline-notification-warning-border-color | `#e7c000` | |
|
||||||
|
| --inline-notification-danger-background-color | `rgba(192, 0, 0, 0.1)` | |
|
||||||
|
| --inline-notification-danger-border-color | `#c00` | |
|
||||||
|
| --inline-notification-warning-heading-color | `#b29400` | |
|
||||||
|
| --inline-notification-danger-heading-color | `#900` | |
|
||||||
|
|
||||||
|
#### CSS Parts
|
||||||
|
|
||||||
| Name | Description |
|
| Name | Description |
|
||||||
| ---------------------------------------------- | ----------- |
|
| ----- | ----------------- |
|
||||||
| --inline-notification-tip-background-color | |
|
| title | the title heading |
|
||||||
| --inline-notification-tip-border-color | |
|
|
||||||
| --inline-notification-warning-background-color | |
|
|
||||||
| --inline-notification-warning-border-color | |
|
|
||||||
| --inline-notification-danger-background-color | |
|
|
||||||
| --inline-notification-danger-border-color | |
|
|
||||||
| --inline-notification-warning-heading-color | |
|
|
||||||
| --inline-notification-danger-heading-color | |
|
|
||||||
|
|
||||||
<hr/>
|
<hr/>
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@rocket/launch",
|
"name": "@rocket/launch",
|
||||||
"version": "0.5.4",
|
"version": "0.5.5",
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
@font-face {
|
@font-face {
|
||||||
font-family: octicons-link;
|
font-family: octicons-link;
|
||||||
src:
|
src: url(data:font/woff;charset=utf-8;base64,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)
|
||||||
url(data:font/woff;charset=utf-8;base64,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)
|
|
||||||
format('woff');
|
format('woff');
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -121,7 +120,7 @@
|
|||||||
overflow: visible;
|
overflow: visible;
|
||||||
}
|
}
|
||||||
|
|
||||||
.markdown-body [type='checkbox'] {
|
.markdown-body input[type='checkbox'] {
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,11 @@
|
|||||||
# Change Log
|
# Change Log
|
||||||
|
|
||||||
|
## 0.8.2
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- a5661b8: Updates dependencies
|
||||||
|
|
||||||
## 0.8.1
|
## 0.8.1
|
||||||
|
|
||||||
### Patch Changes
|
### Patch Changes
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@mdjs/core",
|
"name": "@mdjs/core",
|
||||||
"version": "0.8.1",
|
"version": "0.8.2",
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
},
|
},
|
||||||
@@ -49,7 +49,7 @@
|
|||||||
"@types/unist": "^2.0.3",
|
"@types/unist": "^2.0.3",
|
||||||
"es-module-lexer": "^0.3.26",
|
"es-module-lexer": "^0.3.26",
|
||||||
"github-markdown-css": "^4.0.0",
|
"github-markdown-css": "^4.0.0",
|
||||||
"plugins-manager": "^0.2.3",
|
"plugins-manager": "^0.2.4",
|
||||||
"rehype-autolink-headings": "^5.0.1",
|
"rehype-autolink-headings": "^5.0.1",
|
||||||
"rehype-prism-template": "^0.4.1",
|
"rehype-prism-template": "^0.4.1",
|
||||||
"rehype-raw": "^5.0.0",
|
"rehype-raw": "^5.0.0",
|
||||||
|
|||||||
@@ -1,5 +1,11 @@
|
|||||||
# plugins-manager
|
# plugins-manager
|
||||||
|
|
||||||
|
## 0.2.4
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- 61bb700: Fix types
|
||||||
|
|
||||||
## 0.2.3
|
## 0.2.3
|
||||||
|
|
||||||
### Patch Changes
|
### Patch Changes
|
||||||
|
|||||||
@@ -1,4 +1,6 @@
|
|||||||
/** @typedef {import('./types/main').MetaPlugin} MetaPlugin */
|
/** @typedef {import('./types/main').MetaPlugin} MetaPlugin */
|
||||||
|
/** @typedef {import('./types/main').AddPluginFn} AddPluginFn */
|
||||||
|
/** @typedef {import('./types/main').AddPluginType} AddPluginType */
|
||||||
|
|
||||||
export { addPlugin } from './src/addPlugin.js';
|
export { addPlugin } from './src/addPlugin.js';
|
||||||
export { adjustPluginOptions } from './src/adjustPluginOptions.js';
|
export { adjustPluginOptions } from './src/adjustPluginOptions.js';
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "plugins-manager",
|
"name": "plugins-manager",
|
||||||
"version": "0.2.3",
|
"version": "0.2.4",
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
},
|
},
|
||||||
|
|||||||
4
packages/plugins-manager/types/main.d.ts
vendored
4
packages/plugins-manager/types/main.d.ts
vendored
@@ -2,10 +2,10 @@ type AnyFn = (...args: any[]) => any;
|
|||||||
|
|
||||||
export interface MetaPlugin<F = AnyFn> {
|
export interface MetaPlugin<F = AnyFn> {
|
||||||
name: string;
|
name: string;
|
||||||
plugin: F extends (options?: infer O) => P ? F : any;
|
plugin: F extends (options?: infer O) => unknown ? F : any;
|
||||||
options?: /* prettier-ignore */ (
|
options?: /* prettier-ignore */ (
|
||||||
F extends (eleventyConfig: any, options?: infer O) => void ? O
|
F extends (eleventyConfig: any, options?: infer O) => void ? O
|
||||||
: F extends (options: infer O) => P ? O
|
: F extends (options: infer O) => unknown ? O
|
||||||
: any
|
: any
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,11 @@
|
|||||||
# @rocket/search
|
# @rocket/search
|
||||||
|
|
||||||
|
## 0.4.1
|
||||||
|
|
||||||
|
### Patch Changes
|
||||||
|
|
||||||
|
- a5661b8: Updates dependencies
|
||||||
|
|
||||||
## 0.4.0
|
## 0.4.0
|
||||||
|
|
||||||
### Minor Changes
|
### Minor Changes
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ For docs please see our homepage [https://rocket.modern-web.dev/docs/presets/sea
|
|||||||
|
|
||||||
## `src/RocketSearch.js`:
|
## `src/RocketSearch.js`:
|
||||||
|
|
||||||
### class: `RocketSearch`
|
### class: `RocketSearch`, `rocket-search`
|
||||||
|
|
||||||
#### Superclass
|
#### Superclass
|
||||||
|
|
||||||
@@ -23,21 +23,21 @@ For docs please see our homepage [https://rocket.modern-web.dev/docs/presets/sea
|
|||||||
#### Fields
|
#### Fields
|
||||||
|
|
||||||
| Name | Privacy | Type | Default | Description | Inherited From |
|
| Name | Privacy | Type | Default | Description | Inherited From |
|
||||||
| -------------- | ------- | ---------------------- | -------------------- | ----------- | -------------- |
|
| -------------- | ------- | ---------------------------- | -------------------- | ----------- | -------------- |
|
||||||
| scopedElements | | | | | |
|
| scopedElements | | | | | |
|
||||||
| combobox | | | | | |
|
| combobox | | `RocketSearchCombobox\|null` | | | |
|
||||||
| jsonUrl | public | `string` | `''` | | |
|
| jsonUrl | public | `string` | `''` | | |
|
||||||
| search | public | `string` | `''` | | |
|
| search | public | `string` | `''` | | |
|
||||||
| maxResults | public | `number` | `10` | | |
|
| maxResults | public | `number` | `10` | | |
|
||||||
| noResultsText | public | `string` | `'No results found'` | | |
|
| noResultsText | public | `string` | `'No results found'` | | |
|
||||||
| results | public | `RocketSearchResult[]` | `[]` | | |
|
| results | public | `RocketSearchResult[]` | `[]` | | |
|
||||||
| miniSearch | | `null` | `null` | | |
|
| miniSearch | | `MiniSearch\|null` | `null` | | |
|
||||||
|
|
||||||
#### Methods
|
#### Methods
|
||||||
|
|
||||||
| Name | Privacy | Description | Parameters | Return | Inherited From |
|
| Name | Privacy | Description | Parameters | Return | Inherited From |
|
||||||
| ----------- | ------- | ----------- | ---------- | ------ | -------------- |
|
| ----------- | ------- | ------------------------------------------------------------------------- | ---------- | --------------- | -------------- |
|
||||||
| setupSearch | | | | | |
|
| setupSearch | | Fetches the search index at `this.jsonUrl` and sets up the search engine. | | `Promise<void>` | |
|
||||||
|
|
||||||
#### Attributes
|
#### Attributes
|
||||||
|
|
||||||
@@ -49,6 +49,24 @@ For docs please see our homepage [https://rocket.modern-web.dev/docs/presets/sea
|
|||||||
| max-results | maxResults | |
|
| max-results | maxResults | |
|
||||||
| noResultsText | noResultsText | |
|
| noResultsText | noResultsText | |
|
||||||
|
|
||||||
|
#### CSS Properties
|
||||||
|
|
||||||
|
| Name | Default | Description |
|
||||||
|
| ----------------------------------- | --------- | ------------------------------------- |
|
||||||
|
| --rocket-search-background-color | `#fff` | Search results background colour |
|
||||||
|
| --rocket-search-caret-color | `initial` | Search input caret colour |
|
||||||
|
| --rocket-search-input-border-color | `#dfe1e5` | Search input border colour |
|
||||||
|
| --rocket-search-input-border-radius | `24px` | Search input border radius |
|
||||||
|
| --rocket-search-fill-color | `#000` | Search Icon Color |
|
||||||
|
| --rocket-search-highlight-color | `#6c63ff` | Highlighted search result text colour |
|
||||||
|
|
||||||
|
#### CSS Parts
|
||||||
|
|
||||||
|
| Name | Description |
|
||||||
|
| ------------- | -------------------- |
|
||||||
|
| search-option | search result |
|
||||||
|
| empty | empty search results |
|
||||||
|
|
||||||
<hr/>
|
<hr/>
|
||||||
|
|
||||||
### Exports
|
### Exports
|
||||||
@@ -80,11 +98,39 @@ For docs please see our homepage [https://rocket.modern-web.dev/docs/presets/sea
|
|||||||
#### Methods
|
#### Methods
|
||||||
|
|
||||||
| Name | Privacy | Description | Parameters | Return | Inherited From |
|
| Name | Privacy | Description | Parameters | Return | Inherited From |
|
||||||
| --------------------- | ------- | ----------- | ---------- | ------ | -------------- |
|
| ----- | ------- | ----------- | ---------- | ------ | -------------- |
|
||||||
| \_connectSlotMixin | | | | | |
|
|
||||||
| \_defineOverlayConfig | | | | | |
|
|
||||||
| focus | | | | | |
|
| focus | | | | | |
|
||||||
|
|
||||||
|
#### CSS Properties
|
||||||
|
|
||||||
|
| Name | Default | Description |
|
||||||
|
| ------------------------------------------ | --------- | ----------- |
|
||||||
|
| --rocket-search-fill-color | `#000` | |
|
||||||
|
| --rocket-search-background-color | `#fff` | |
|
||||||
|
| --rocket-search-input-overlay-border-color | `#ccc` | |
|
||||||
|
| --rocket-search-input-border-color | `#dfe1e5` | |
|
||||||
|
| --rocket-search-input-border-radius | `24px` | |
|
||||||
|
|
||||||
|
#### Slots
|
||||||
|
|
||||||
|
| Name | Description |
|
||||||
|
| ------- | ----------- |
|
||||||
|
| prefix | |
|
||||||
|
| label | |
|
||||||
|
| listbox | |
|
||||||
|
| input | |
|
||||||
|
|
||||||
|
<details><summary>Private API</summary>
|
||||||
|
|
||||||
|
#### Methods
|
||||||
|
|
||||||
|
| Name | Privacy | Description | Parameters | Return | Inherited From |
|
||||||
|
| --------------------- | ------- | ----------- | ---------- | ------ | -------------- |
|
||||||
|
| \_connectSlotMixin | private | | | | |
|
||||||
|
| \_defineOverlayConfig | private | | | | |
|
||||||
|
|
||||||
|
</details>
|
||||||
|
|
||||||
<hr/>
|
<hr/>
|
||||||
|
|
||||||
### Exports
|
### Exports
|
||||||
|
|||||||
@@ -10,6 +10,48 @@
|
|||||||
"kind": "class",
|
"kind": "class",
|
||||||
"description": "",
|
"description": "",
|
||||||
"name": "RocketSearch",
|
"name": "RocketSearch",
|
||||||
|
"cssProperties": [
|
||||||
|
{
|
||||||
|
"description": "Search results background colour",
|
||||||
|
"name": "--rocket-search-background-color",
|
||||||
|
"default": "#fff"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"description": "Search input caret colour",
|
||||||
|
"name": "--rocket-search-caret-color",
|
||||||
|
"default": "initial"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"description": "Search input border colour",
|
||||||
|
"name": "--rocket-search-input-border-color",
|
||||||
|
"default": "#dfe1e5"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"description": "Search input border radius",
|
||||||
|
"name": "--rocket-search-input-border-radius",
|
||||||
|
"default": "24px"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"description": "Search Icon Color",
|
||||||
|
"name": "--rocket-search-fill-color",
|
||||||
|
"default": "#000"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"description": "Highlighted search result text colour",
|
||||||
|
"name": "--rocket-search-highlight-color",
|
||||||
|
"default": "#6c63ff"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"cssParts": [
|
||||||
|
{
|
||||||
|
"description": "search result",
|
||||||
|
"name": "search-option"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"description": "empty search results",
|
||||||
|
"name": "empty"
|
||||||
|
}
|
||||||
|
],
|
||||||
"members": [
|
"members": [
|
||||||
{
|
{
|
||||||
"kind": "field",
|
"kind": "field",
|
||||||
@@ -18,11 +60,20 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"kind": "method",
|
"kind": "method",
|
||||||
"name": "setupSearch"
|
"name": "setupSearch",
|
||||||
|
"description": "Fetches the search index at `this.jsonUrl` and sets up the search engine.",
|
||||||
|
"return": {
|
||||||
|
"type": {
|
||||||
|
"text": "Promise<void>"
|
||||||
|
}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"kind": "field",
|
"kind": "field",
|
||||||
"name": "combobox"
|
"name": "combobox",
|
||||||
|
"type": {
|
||||||
|
"text": "RocketSearchCombobox|null"
|
||||||
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"kind": "field",
|
"kind": "field",
|
||||||
@@ -78,7 +129,7 @@
|
|||||||
"kind": "field",
|
"kind": "field",
|
||||||
"name": "miniSearch",
|
"name": "miniSearch",
|
||||||
"type": {
|
"type": {
|
||||||
"text": "null"
|
"text": "MiniSearch|null"
|
||||||
},
|
},
|
||||||
"default": "null"
|
"default": "null"
|
||||||
}
|
}
|
||||||
@@ -115,6 +166,7 @@
|
|||||||
"name": "LitElement",
|
"name": "LitElement",
|
||||||
"package": "@lion/core"
|
"package": "@lion/core"
|
||||||
},
|
},
|
||||||
|
"tagName": "rocket-search",
|
||||||
"customElement": true
|
"customElement": true
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
@@ -137,14 +189,52 @@
|
|||||||
"kind": "class",
|
"kind": "class",
|
||||||
"description": "",
|
"description": "",
|
||||||
"name": "RocketSearchCombobox",
|
"name": "RocketSearchCombobox",
|
||||||
|
"cssProperties": [
|
||||||
|
{
|
||||||
|
"name": "--rocket-search-fill-color",
|
||||||
|
"default": "#000"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "--rocket-search-background-color",
|
||||||
|
"default": "#fff"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "--rocket-search-input-overlay-border-color",
|
||||||
|
"default": "#ccc"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "--rocket-search-input-border-color",
|
||||||
|
"default": "#dfe1e5"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "--rocket-search-input-border-radius",
|
||||||
|
"default": "24px"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"slots": [
|
||||||
|
{
|
||||||
|
"name": "prefix"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "label"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "listbox"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "input"
|
||||||
|
}
|
||||||
|
],
|
||||||
"members": [
|
"members": [
|
||||||
{
|
{
|
||||||
"kind": "method",
|
"kind": "method",
|
||||||
"name": "_connectSlotMixin"
|
"name": "_connectSlotMixin",
|
||||||
|
"privacy": "private"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"kind": "method",
|
"kind": "method",
|
||||||
"name": "_defineOverlayConfig"
|
"name": "_defineOverlayConfig",
|
||||||
|
"privacy": "private"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"kind": "field",
|
"kind": "field",
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@rocket/search",
|
"name": "@rocket/search",
|
||||||
"version": "0.4.0",
|
"version": "0.4.1",
|
||||||
"publishConfig": {
|
"publishConfig": {
|
||||||
"access": "public"
|
"access": "public"
|
||||||
},
|
},
|
||||||
@@ -48,7 +48,7 @@
|
|||||||
"@open-wc/scoped-elements": "^2.0.0-next.3",
|
"@open-wc/scoped-elements": "^2.0.0-next.3",
|
||||||
"chalk": "^4.0.0",
|
"chalk": "^4.0.0",
|
||||||
"minisearch": "^3.0.2",
|
"minisearch": "^3.0.2",
|
||||||
"plugins-manager": "^0.2.2",
|
"plugins-manager": "^0.2.4",
|
||||||
"sax-wasm": "^2.0.0"
|
"sax-wasm": "^2.0.0"
|
||||||
},
|
},
|
||||||
"customElements": "custom-elements.json"
|
"customElements": "custom-elements.json"
|
||||||
|
|||||||
@@ -31,7 +31,20 @@ function getText({ result, search }) {
|
|||||||
return highlightSearchTerms({ text: body, search, terms, addEllipsis: true });
|
return highlightSearchTerms({ text: body, search, terms, addEllipsis: true });
|
||||||
}
|
}
|
||||||
|
|
||||||
// @ts-expect-error https://github.com/microsoft/TypeScript/issues/40110
|
// | Property | Default | Description |
|
||||||
|
// | ------------------------------------- | --------- | ------------------------------------ |
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @element rocket-search
|
||||||
|
* @cssprop [--rocket-search-background-color=#fff] - Search results background colour
|
||||||
|
* @cssprop [--rocket-search-caret-color=initial] - Search input caret colour
|
||||||
|
* @cssprop [--rocket-search-input-border-color=#dfe1e5] - Search input border colour
|
||||||
|
* @cssprop [--rocket-search-input-border-radius=24px] - Search input border radius
|
||||||
|
* @cssprop [--rocket-search-fill-color=#000] - Search Icon Color
|
||||||
|
* @cssprop [--rocket-search-highlight-color=#6c63ff] - Highlighted search result text colour
|
||||||
|
* @csspart search-option - search result
|
||||||
|
* @csspart empty - empty search results
|
||||||
|
*/
|
||||||
export class RocketSearch extends ScopedElementsMixin(LitElement) {
|
export class RocketSearch extends ScopedElementsMixin(LitElement) {
|
||||||
static get properties() {
|
static get properties() {
|
||||||
return {
|
return {
|
||||||
@@ -60,9 +73,14 @@ export class RocketSearch extends ScopedElementsMixin(LitElement) {
|
|||||||
* @type {RocketSearchResult[]}
|
* @type {RocketSearchResult[]}
|
||||||
*/
|
*/
|
||||||
this.results = [];
|
this.results = [];
|
||||||
|
/** @type {MiniSearch|null} */
|
||||||
this.miniSearch = null;
|
this.miniSearch = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Fetches the search index at `this.jsonUrl` and sets up the search engine.
|
||||||
|
* @return {Promise<void>}
|
||||||
|
*/
|
||||||
async setupSearch() {
|
async setupSearch() {
|
||||||
if (!this.jsonUrl) {
|
if (!this.jsonUrl) {
|
||||||
throw new Error(
|
throw new Error(
|
||||||
@@ -92,8 +110,9 @@ export class RocketSearch extends ScopedElementsMixin(LitElement) {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** @type {RocketSearchCombobox|null} */
|
||||||
get combobox() {
|
get combobox() {
|
||||||
return this.shadowRoot.querySelector('rocket-search-combobox');
|
return this.shadowRoot?.querySelector?.('rocket-search-combobox') ?? null;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** @param {import('lit-element').PropertyValues } changedProperties */
|
/** @param {import('lit-element').PropertyValues } changedProperties */
|
||||||
@@ -112,9 +131,11 @@ export class RocketSearch extends ScopedElementsMixin(LitElement) {
|
|||||||
<rocket-search-combobox
|
<rocket-search-combobox
|
||||||
name="combo"
|
name="combo"
|
||||||
label="Search"
|
label="Search"
|
||||||
@input=${ev => {
|
@input=${
|
||||||
|
/** @param {Event & { target: HTMLInputElement }} ev */ ev => {
|
||||||
this.search = ev.target.value;
|
this.search = ev.target.value;
|
||||||
}}
|
}
|
||||||
|
}
|
||||||
@focus=${() => {
|
@focus=${() => {
|
||||||
this.setupSearch();
|
this.setupSearch();
|
||||||
}}
|
}}
|
||||||
@@ -125,6 +146,7 @@ export class RocketSearch extends ScopedElementsMixin(LitElement) {
|
|||||||
result => html`
|
result => html`
|
||||||
<rocket-search-option
|
<rocket-search-option
|
||||||
href=${result.id}
|
href=${result.id}
|
||||||
|
part="search-option"
|
||||||
rel="noopener noreferrer"
|
rel="noopener noreferrer"
|
||||||
.title=${getTitle({ result, search: this.search })}
|
.title=${getTitle({ result, search: this.search })}
|
||||||
.choiceValue=${this.search}
|
.choiceValue=${this.search}
|
||||||
@@ -134,7 +156,12 @@ export class RocketSearch extends ScopedElementsMixin(LitElement) {
|
|||||||
`,
|
`,
|
||||||
)}
|
)}
|
||||||
${this.results.length <= 0 && this.search.length > 0
|
${this.results.length <= 0 && this.search.length > 0
|
||||||
? html` <rocket-search-option .title=${this.noResultsText}></rocket-search-option> `
|
? html`
|
||||||
|
<rocket-search-option
|
||||||
|
part="search-option empty"
|
||||||
|
.title=${this.noResultsText}
|
||||||
|
></rocket-search-option>
|
||||||
|
`
|
||||||
: ''}
|
: ''}
|
||||||
</rocket-search-combobox>
|
</rocket-search-combobox>
|
||||||
`;
|
`;
|
||||||
|
|||||||
@@ -21,6 +21,18 @@ searchBtnTmpl.innerHTML = `
|
|||||||
</button>
|
</button>
|
||||||
`;
|
`;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @cssprop [--rocket-search-fill-color=#000]
|
||||||
|
* @cssprop [--rocket-search-background-color=#fff]
|
||||||
|
* @cssprop [--rocket-search-input-overlay-border-color=#ccc]
|
||||||
|
* @cssprop [--rocket-search-input-border-color=#dfe1e5]
|
||||||
|
* @cssprop [--rocket-search-input-border-radius=24px]
|
||||||
|
* @slot prefix
|
||||||
|
* @slot label
|
||||||
|
* @slot listbox
|
||||||
|
* @slot input
|
||||||
|
* @type {String}
|
||||||
|
*/
|
||||||
export class RocketSearchCombobox extends LionCombobox {
|
export class RocketSearchCombobox extends LionCombobox {
|
||||||
static get styles() {
|
static get styles() {
|
||||||
return [
|
return [
|
||||||
@@ -182,6 +194,7 @@ export class RocketSearchCombobox extends LionCombobox {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** @private */
|
||||||
_connectSlotMixin() {
|
_connectSlotMixin() {
|
||||||
if (!this.__isConnectedSlotMixin) {
|
if (!this.__isConnectedSlotMixin) {
|
||||||
Object.keys(this.slots).forEach(slotName => {
|
Object.keys(this.slots).forEach(slotName => {
|
||||||
@@ -208,6 +221,7 @@ export class RocketSearchCombobox extends LionCombobox {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** @private */
|
||||||
_defineOverlayConfig() {
|
_defineOverlayConfig() {
|
||||||
/** @type {'bottom'} */
|
/** @type {'bottom'} */
|
||||||
const placement = 'bottom';
|
const placement = 'bottom';
|
||||||
|
|||||||
@@ -4,6 +4,7 @@ import { rocketSearch } from '@rocket/search';
|
|||||||
import { absoluteBaseUrlNetlify } from '@rocket/core/helpers';
|
import { absoluteBaseUrlNetlify } from '@rocket/core/helpers';
|
||||||
import { adjustPluginOptions } from 'plugins-manager';
|
import { adjustPluginOptions } from 'plugins-manager';
|
||||||
import { codeTabs } from 'rocket-preset-code-tabs';
|
import { codeTabs } from 'rocket-preset-code-tabs';
|
||||||
|
import { customElementsManifest } from 'rocket-preset-custom-elements-manifest';
|
||||||
|
|
||||||
/** @type {import('./packages/cli/types/main').RocketCliOptions} */
|
/** @type {import('./packages/cli/types/main').RocketCliOptions} */
|
||||||
export default {
|
export default {
|
||||||
@@ -22,6 +23,7 @@ export default {
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
}),
|
}),
|
||||||
|
customElementsManifest(),
|
||||||
],
|
],
|
||||||
|
|
||||||
setupUnifiedPlugins: [
|
setupUnifiedPlugins: [
|
||||||
|
|||||||
174
yarn.lock
174
yarn.lock
@@ -1080,10 +1080,10 @@
|
|||||||
human-id "^1.0.2"
|
human-id "^1.0.2"
|
||||||
prettier "^1.18.2"
|
prettier "^1.18.2"
|
||||||
|
|
||||||
"@custom-elements-manifest/analyzer@^0.4.11":
|
"@custom-elements-manifest/analyzer@^0.4.12":
|
||||||
version "0.4.11"
|
version "0.4.12"
|
||||||
resolved "https://registry.yarnpkg.com/@custom-elements-manifest/analyzer/-/analyzer-0.4.11.tgz#40047abe6f7a8ff3d2c83d73e1647d059d71592c"
|
resolved "https://registry.yarnpkg.com/@custom-elements-manifest/analyzer/-/analyzer-0.4.12.tgz#55dd21bf00faa6cc33a1ba248de6b9fcb804ef6f"
|
||||||
integrity sha512-Uymdmoz8yQqSSLHgnxi2zIRZmNhr/845gDBKt5tl9JthegaTM1G8i9CDdHbQxs0sPMRjAVA5UOdpAe3ZS6itsA==
|
integrity sha512-AvHMmiC5TpYBYmjdZ/5OKhsTQbJvb1A7jkTb3/DUuVZrRpvNuVz6/fhyQ0giF5VFwmPWgBdMdaA2qNDQlK0lIg==
|
||||||
dependencies:
|
dependencies:
|
||||||
"@web/config-loader" "^0.1.3"
|
"@web/config-loader" "^0.1.3"
|
||||||
chokidar "^3.5.2"
|
chokidar "^3.5.2"
|
||||||
@@ -1091,13 +1091,13 @@
|
|||||||
comment-parser "^1.1.5"
|
comment-parser "^1.1.5"
|
||||||
custom-elements-manifest "^1.0.0"
|
custom-elements-manifest "^1.0.0"
|
||||||
debounce "^1.2.1"
|
debounce "^1.2.1"
|
||||||
globby "^11.0.1"
|
globby "^11.0.4"
|
||||||
typescript "^4.3.2"
|
typescript "^4.3.2"
|
||||||
|
|
||||||
"@custom-elements-manifest/to-markdown@^0.0.9":
|
"@custom-elements-manifest/to-markdown@^0.0.12":
|
||||||
version "0.0.9"
|
version "0.0.12"
|
||||||
resolved "https://registry.yarnpkg.com/@custom-elements-manifest/to-markdown/-/to-markdown-0.0.9.tgz#4d84db87db48b397cbfd3318ddea093e179f75ae"
|
resolved "https://registry.yarnpkg.com/@custom-elements-manifest/to-markdown/-/to-markdown-0.0.12.tgz#9aae0271636a5300c8d95e6cb8b83c0d74d52747"
|
||||||
integrity sha512-39/GRlSUZMRresuTVSUw56PMTdjrGGpUi8sKll5NZEZq78uJOef8gSKEISpyMPiOmivKoLJAxKA2b0MJP+l0KA==
|
integrity sha512-24RMTw1leMIJuXjtyZXAjYJ3VLRYTSjdNWvYiJ7wKHyLc0Ab4dv27nX9PQvQkxg8huFzweMad5kUkAFp8S9bww==
|
||||||
dependencies:
|
dependencies:
|
||||||
mdast-builder "^1.1.1"
|
mdast-builder "^1.1.1"
|
||||||
mdast-util-from-markdown "^1.0.0"
|
mdast-util-from-markdown "^1.0.0"
|
||||||
@@ -1345,21 +1345,26 @@
|
|||||||
resolved "https://registry.yarnpkg.com/@popperjs/core/-/core-2.6.0.tgz#f022195afdfc942e088ee2101285a1d31c7d727f"
|
resolved "https://registry.yarnpkg.com/@popperjs/core/-/core-2.6.0.tgz#f022195afdfc942e088ee2101285a1d31c7d727f"
|
||||||
integrity sha512-cPqjjzuFWNK3BSKLm0abspP0sp/IGOli4p5I5fKFAzdS8fvjdOwDCfZqAaIiXd9lPkOWi3SUUfZof3hEb7J/uw==
|
integrity sha512-cPqjjzuFWNK3BSKLm0abspP0sp/IGOli4p5I5fKFAzdS8fvjdOwDCfZqAaIiXd9lPkOWi3SUUfZof3hEb7J/uw==
|
||||||
|
|
||||||
"@pwrs/lit-css@^1.0.0":
|
"@power-elements/json-viewer@2.1.1":
|
||||||
version "1.0.0"
|
version "2.1.1"
|
||||||
resolved "https://registry.yarnpkg.com/@pwrs/lit-css/-/lit-css-1.0.0.tgz#4355988398166986d15ba8ae38bcc73e247e50d3"
|
resolved "https://registry.yarnpkg.com/@power-elements/json-viewer/-/json-viewer-2.1.1.tgz#f65a4c9bffb4aae2c4eaa8acc1c74cc38f0aac82"
|
||||||
integrity sha512-Xhku8/mFegXIlh/LyPhTQ0ioCOS3CUl7suJx++ueE2PmqHNL+gn8I5IvSp3Jdmau0ae+pY2BJjfCNFfvCSqPsA==
|
integrity sha512-uQWqhlc1huWMnYycf5ltgU1hStancWyMt7g8bJ0jCZ3QrOlZmHWUdPt55i4I6L7bDKJLbO1J6oB+O4QWj4Nlew==
|
||||||
|
|
||||||
|
"@pwrs/lit-css@^1.0.1":
|
||||||
|
version "1.0.1"
|
||||||
|
resolved "https://registry.yarnpkg.com/@pwrs/lit-css/-/lit-css-1.0.1.tgz#6aa5168e41bd528cdaa6b62c9eb8a7bad6788976"
|
||||||
|
integrity sha512-xSCPI0Uc0vrgBxBIMhglnjjEftQ61ecCR6xVKnN5OlculOaToP8ggCY6iO3PtFyZDPq33hRL5pWH5Y7w1wv+VA==
|
||||||
dependencies:
|
dependencies:
|
||||||
string-to-template-literal "^2.0.0"
|
string-to-template-literal "^2.0.0"
|
||||||
uglifycss "^0.0.29"
|
uglifycss "^0.0.29"
|
||||||
|
|
||||||
"@pwrs/mixins@^0.2.0":
|
"@pwrs/mixins@^0.2.1":
|
||||||
version "0.2.0"
|
version "0.2.1"
|
||||||
resolved "https://registry.yarnpkg.com/@pwrs/mixins/-/mixins-0.2.0.tgz#3834c1f8f1f51454546bcd32855b0a771e7cb703"
|
resolved "https://registry.yarnpkg.com/@pwrs/mixins/-/mixins-0.2.1.tgz#44f65ed393ce2d3a1895222cb7203ac3752515ce"
|
||||||
integrity sha512-ef6mXLUL8FMJXwVDfxw53MHgLu3ZXSVy1/31ECpYjUF7VKsjFbFPW/xz/kEojO/5pFRpXyy7U17sIDbQJZe26w==
|
integrity sha512-hgBU6iDQcczFDOvtZAmzX3/XRy3So3+1HnY3FBwH8be3OEiD816FX1yEj41wLPBcsX2YgjtfcloJ9USxGOrYjA==
|
||||||
dependencies:
|
dependencies:
|
||||||
"@open-wc/dedupe-mixin" "^1.3.0"
|
"@open-wc/dedupe-mixin" "^1.3.0"
|
||||||
"@types/ramda" "^0.27.40"
|
"@types/ramda" "^0.27.44"
|
||||||
bind-decorator "^1.0.11"
|
bind-decorator "^1.0.11"
|
||||||
lit "^2.0.0-rc.2"
|
lit "^2.0.0-rc.2"
|
||||||
lit-element "^2.5.1"
|
lit-element "^2.5.1"
|
||||||
@@ -1705,10 +1710,10 @@
|
|||||||
resolved "https://registry.yarnpkg.com/@types/qs/-/qs-6.9.5.tgz#434711bdd49eb5ee69d90c1d67c354a9a8ecb18b"
|
resolved "https://registry.yarnpkg.com/@types/qs/-/qs-6.9.5.tgz#434711bdd49eb5ee69d90c1d67c354a9a8ecb18b"
|
||||||
integrity sha512-/JHkVHtx/REVG0VVToGRGH2+23hsYLHdyG+GrvoUGlGAd0ErauXDyvHtRI/7H7mzLm+tBCKA7pfcpkQ1lf58iQ==
|
integrity sha512-/JHkVHtx/REVG0VVToGRGH2+23hsYLHdyG+GrvoUGlGAd0ErauXDyvHtRI/7H7mzLm+tBCKA7pfcpkQ1lf58iQ==
|
||||||
|
|
||||||
"@types/ramda@^0.27.40":
|
"@types/ramda@^0.27.44":
|
||||||
version "0.27.43"
|
version "0.27.44"
|
||||||
resolved "https://registry.yarnpkg.com/@types/ramda/-/ramda-0.27.43.tgz#3c0632a82479bccac7455ec77a2b1e43b326fe2f"
|
resolved "https://registry.yarnpkg.com/@types/ramda/-/ramda-0.27.44.tgz#ba2283d67fcff366f7e68bd5124a0466e467967f"
|
||||||
integrity sha512-AZ1q/rG/aBYszHxeZ9/0rzKyH7ghpkMwZSSZGZbCEX+fleRFPhKpXht/tYpyU65tDeXjkaafKd2Sp+PNB5wmGw==
|
integrity sha512-SlEHKcLG36PlU+rLJwp8p4dpC9Hp/LiH6n0REX2m4iEB15PWe1qKQzgNSZrYKhTHDFvkeEM/F2gcYwfighsEuQ==
|
||||||
dependencies:
|
dependencies:
|
||||||
ts-toolbelt "^6.15.1"
|
ts-toolbelt "^6.15.1"
|
||||||
|
|
||||||
@@ -2766,12 +2771,12 @@ ccount@^2.0.0:
|
|||||||
resolved "https://registry.yarnpkg.com/ccount/-/ccount-2.0.0.tgz#3d6fb55803832766a24c6f339abc507297eb5d25"
|
resolved "https://registry.yarnpkg.com/ccount/-/ccount-2.0.0.tgz#3d6fb55803832766a24c6f339abc507297eb5d25"
|
||||||
integrity sha512-VOR0NWFYX65n9gELQdcpqsie5L5ihBXuZGAgaPEp/U7IOSjnPMEH6geE+2f6lcekaNEfWzAHS45mPvSo5bqsUA==
|
integrity sha512-VOR0NWFYX65n9gELQdcpqsie5L5ihBXuZGAgaPEp/U7IOSjnPMEH6geE+2f6lcekaNEfWzAHS45mPvSo5bqsUA==
|
||||||
|
|
||||||
cem-plugin-readme@^0.1.2:
|
cem-plugin-readme@^0.1.3:
|
||||||
version "0.1.2"
|
version "0.1.3"
|
||||||
resolved "https://registry.yarnpkg.com/cem-plugin-readme/-/cem-plugin-readme-0.1.2.tgz#65a4d6c8973bb9c42e2a68fb3053a353e5475379"
|
resolved "https://registry.yarnpkg.com/cem-plugin-readme/-/cem-plugin-readme-0.1.3.tgz#c084415a8af4df73d802b7b395976ed62854e169"
|
||||||
integrity sha512-K28QXc6nG22p+aHzdPnQQi3uM02HLkbERCqDCwLT11mmQMr+WS5sbXwnR4YYUhPc/kUbASUu+OoFLlgmQ+7RgQ==
|
integrity sha512-k160SaxSL8we5qhVbu+/RGXctmRIMCVcBwygKh9xDlXIFXypYggUfWpnvJ825VigMRdimn4ZMj2ITc0oqp1IGg==
|
||||||
dependencies:
|
dependencies:
|
||||||
"@custom-elements-manifest/to-markdown" "^0.0.9"
|
"@custom-elements-manifest/to-markdown" "^0.0.12"
|
||||||
|
|
||||||
center-align@^0.1.1:
|
center-align@^0.1.1:
|
||||||
version "0.1.3"
|
version "0.1.3"
|
||||||
@@ -3723,6 +3728,11 @@ eleventy-plugin-add-web-component-definitions@^2.0.3:
|
|||||||
parse5 "^5.1.1"
|
parse5 "^5.1.1"
|
||||||
unist-util-visit "^2.0.3"
|
unist-util-visit "^2.0.3"
|
||||||
|
|
||||||
|
eleventy-plugin-footnotes@0.9.0:
|
||||||
|
version "0.9.0"
|
||||||
|
resolved "https://registry.yarnpkg.com/eleventy-plugin-footnotes/-/eleventy-plugin-footnotes-0.9.0.tgz#7febf459d0cac929e34219518fb2a2375fe94c98"
|
||||||
|
integrity sha512-y00cfbcUsIFGoL5Xp2rWrmCcM/hz06jhplFZgX3Vo9O4KIncoz+TyhIlAEOljM6IYKEaiffmujgORqgNhSYm4A==
|
||||||
|
|
||||||
emitter-mixin@0.0.3:
|
emitter-mixin@0.0.3:
|
||||||
version "0.0.3"
|
version "0.0.3"
|
||||||
resolved "https://registry.yarnpkg.com/emitter-mixin/-/emitter-mixin-0.0.3.tgz#5948cb286f2e48edc3b251a7cfc1f7883396d65c"
|
resolved "https://registry.yarnpkg.com/emitter-mixin/-/emitter-mixin-0.0.3.tgz#5948cb286f2e48edc3b251a7cfc1f7883396d65c"
|
||||||
@@ -3896,23 +3906,18 @@ es-to-primitive@^1.2.1:
|
|||||||
is-date-object "^1.0.1"
|
is-date-object "^1.0.1"
|
||||||
is-symbol "^1.0.2"
|
is-symbol "^1.0.2"
|
||||||
|
|
||||||
esbuild-plugin-lit-css@^1.0.0:
|
esbuild-plugin-lit-css@^1.0.2:
|
||||||
version "1.0.0"
|
version "1.0.2"
|
||||||
resolved "https://registry.yarnpkg.com/esbuild-plugin-lit-css/-/esbuild-plugin-lit-css-1.0.0.tgz#7c138b2c4c1724ff2a18dfc542ce4396e13e93f8"
|
resolved "https://registry.yarnpkg.com/esbuild-plugin-lit-css/-/esbuild-plugin-lit-css-1.0.2.tgz#d7bd763cdb8ad1f35a2fc8596ad4857faa5f6c23"
|
||||||
integrity sha512-Ng5/F6+l0Dj9/Zl0u1pT9meBmE9itI/xVlSvZwHa25+LxCgDPyx/pbSrr78r3MDF3cUDbQDy7VvjIuCUHVK7zQ==
|
integrity sha512-mVTY8GyqIdwXdkYQ9dU88dMRQ0vvL9Ywro2M81+sn5a3MQXhi4HHJ9U+ORyIhlZMsOtHQvI45QRAll67x4XBeA==
|
||||||
dependencies:
|
dependencies:
|
||||||
"@pwrs/lit-css" "^1.0.0"
|
"@pwrs/lit-css" "^1.0.1"
|
||||||
|
|
||||||
esbuild@^0.12.15:
|
esbuild@^0.12.15:
|
||||||
version "0.12.15"
|
version "0.12.15"
|
||||||
resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.12.15.tgz#9d99cf39aeb2188265c5983e983e236829f08af0"
|
resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.12.15.tgz#9d99cf39aeb2188265c5983e983e236829f08af0"
|
||||||
integrity sha512-72V4JNd2+48eOVCXx49xoSWHgC3/cCy96e7mbXKY+WOWghN00cCmlGnwVLRhRHorvv0dgCyuMYBZlM2xDM5OQw==
|
integrity sha512-72V4JNd2+48eOVCXx49xoSWHgC3/cCy96e7mbXKY+WOWghN00cCmlGnwVLRhRHorvv0dgCyuMYBZlM2xDM5OQw==
|
||||||
|
|
||||||
esbuild@^0.8.31:
|
|
||||||
version "0.8.31"
|
|
||||||
resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.8.31.tgz#c21e7adb3ad283c951a53de7ad64a5ae2df2ed34"
|
|
||||||
integrity sha512-7EIU0VdUxltwivjVezX3HgeNzeIVR1snkrAo57WdUnuBMykdzin5rTrxwCDM6xQqj0RL/HjOEm3wFr2ijHKeaA==
|
|
||||||
|
|
||||||
escalade@^3.1.1:
|
escalade@^3.1.1:
|
||||||
version "3.1.1"
|
version "3.1.1"
|
||||||
resolved "https://registry.yarnpkg.com/escalade/-/escalade-3.1.1.tgz#d8cfdc7000965c5a0174b4a82eaa5c0552742e40"
|
resolved "https://registry.yarnpkg.com/escalade/-/escalade-3.1.1.tgz#d8cfdc7000965c5a0174b4a82eaa5c0552742e40"
|
||||||
@@ -4402,6 +4407,14 @@ get-func-name@^2.0.0:
|
|||||||
resolved "https://registry.yarnpkg.com/get-func-name/-/get-func-name-2.0.0.tgz#ead774abee72e20409433a066366023dd6887a41"
|
resolved "https://registry.yarnpkg.com/get-func-name/-/get-func-name-2.0.0.tgz#ead774abee72e20409433a066366023dd6887a41"
|
||||||
integrity sha1-6td0q+5y4gQJQzoGY2YCPdaIekE=
|
integrity sha1-6td0q+5y4gQJQzoGY2YCPdaIekE=
|
||||||
|
|
||||||
|
get-github-url@1.0.4:
|
||||||
|
version "1.0.4"
|
||||||
|
resolved "https://registry.yarnpkg.com/get-github-url/-/get-github-url-1.0.4.tgz#2d9a6233f173139fe9973e3dcf09aee1eec2e13e"
|
||||||
|
integrity sha1-LZpiM/FzE5/plz49zwmu4e7C4T4=
|
||||||
|
dependencies:
|
||||||
|
is-github-url "^1.1.2"
|
||||||
|
parse-github-url "^0.2.1"
|
||||||
|
|
||||||
get-intrinsic@^1.0.0:
|
get-intrinsic@^1.0.0:
|
||||||
version "1.0.2"
|
version "1.0.2"
|
||||||
resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.0.2.tgz#6820da226e50b24894e08859469dc68361545d49"
|
resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.0.2.tgz#6820da226e50b24894e08859469dc68361545d49"
|
||||||
@@ -4512,6 +4525,18 @@ globby@^11.0.0, globby@^11.0.1:
|
|||||||
merge2 "^1.3.0"
|
merge2 "^1.3.0"
|
||||||
slash "^3.0.0"
|
slash "^3.0.0"
|
||||||
|
|
||||||
|
globby@^11.0.4:
|
||||||
|
version "11.0.4"
|
||||||
|
resolved "https://registry.yarnpkg.com/globby/-/globby-11.0.4.tgz#2cbaff77c2f2a62e71e9b2813a67b97a3a3001a5"
|
||||||
|
integrity sha512-9O4MVG9ioZJ08ffbcyVYyLOJLk5JQ688pJ4eMGLpdWLHq/Wr1D9BlriLQyL0E+jbkuePVZXYFj47QM/v093wHg==
|
||||||
|
dependencies:
|
||||||
|
array-union "^2.1.0"
|
||||||
|
dir-glob "^3.0.1"
|
||||||
|
fast-glob "^3.1.1"
|
||||||
|
ignore "^5.1.4"
|
||||||
|
merge2 "^1.3.0"
|
||||||
|
slash "^3.0.0"
|
||||||
|
|
||||||
globby@^5.0.0:
|
globby@^5.0.0:
|
||||||
version "5.0.0"
|
version "5.0.0"
|
||||||
resolved "https://registry.yarnpkg.com/globby/-/globby-5.0.0.tgz#ebd84667ca0dbb330b99bcfc68eac2bc54370e0d"
|
resolved "https://registry.yarnpkg.com/globby/-/globby-5.0.0.tgz#ebd84667ca0dbb330b99bcfc68eac2bc54370e0d"
|
||||||
@@ -4674,6 +4699,14 @@ hast-util-heading-rank@^1.0.0:
|
|||||||
resolved "https://registry.yarnpkg.com/hast-util-heading-rank/-/hast-util-heading-rank-1.0.1.tgz#28dfd8b0724cfb0da48308e2a794b1d9f24fd80d"
|
resolved "https://registry.yarnpkg.com/hast-util-heading-rank/-/hast-util-heading-rank-1.0.1.tgz#28dfd8b0724cfb0da48308e2a794b1d9f24fd80d"
|
||||||
integrity sha512-P6Hq7RCky9syMevlrN90QWpqWDXCxwIVOfQR2rK6P4GpY4bqjKEuCzoWSRORZ7vz+VgRpLnXimh+mkwvVFjbyQ==
|
integrity sha512-P6Hq7RCky9syMevlrN90QWpqWDXCxwIVOfQR2rK6P4GpY4bqjKEuCzoWSRORZ7vz+VgRpLnXimh+mkwvVFjbyQ==
|
||||||
|
|
||||||
|
hast-util-is-element@2.1.0:
|
||||||
|
version "2.1.0"
|
||||||
|
resolved "https://registry.yarnpkg.com/hast-util-is-element/-/hast-util-is-element-2.1.0.tgz#ecdc0c00c06f5b4de8ea27b9084cb75d1326a7b1"
|
||||||
|
integrity sha512-tg5yLbnC4TYONeeHIF7n0Jtstp+4J0bcBFn+R6wYoZzeHSIp5sl9ApfqGI2mxKtEXi4DEhTssPli6ppGl5PGqg==
|
||||||
|
dependencies:
|
||||||
|
"@types/hast" "^2.0.0"
|
||||||
|
"@types/unist" "^2.0.0"
|
||||||
|
|
||||||
hast-util-is-element@^1.0.0:
|
hast-util-is-element@^1.0.0:
|
||||||
version "1.1.0"
|
version "1.1.0"
|
||||||
resolved "https://registry.yarnpkg.com/hast-util-is-element/-/hast-util-is-element-1.1.0.tgz#3b3ed5159a2707c6137b48637fbfe068e175a425"
|
resolved "https://registry.yarnpkg.com/hast-util-is-element/-/hast-util-is-element-1.1.0.tgz#3b3ed5159a2707c6137b48637fbfe068e175a425"
|
||||||
@@ -4786,7 +4819,7 @@ he@1.2.0, he@^1.2.0:
|
|||||||
resolved "https://registry.yarnpkg.com/he/-/he-1.2.0.tgz#84ae65fa7eafb165fddb61566ae14baf05664f0f"
|
resolved "https://registry.yarnpkg.com/he/-/he-1.2.0.tgz#84ae65fa7eafb165fddb61566ae14baf05664f0f"
|
||||||
integrity sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==
|
integrity sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==
|
||||||
|
|
||||||
hirestime@^6.1.0:
|
hirestime@6.1.0, hirestime@^6.1.0:
|
||||||
version "6.1.0"
|
version "6.1.0"
|
||||||
resolved "https://registry.yarnpkg.com/hirestime/-/hirestime-6.1.0.tgz#10bb2041cb9caffbfe7cf12a26ac38c0c9f42ee3"
|
resolved "https://registry.yarnpkg.com/hirestime/-/hirestime-6.1.0.tgz#10bb2041cb9caffbfe7cf12a26ac38c0c9f42ee3"
|
||||||
integrity sha512-sCVxYT/2iSUanrRuiUspZaF78crKojzmVz2mI+gjq1/N+7RPCyZu8S0KyBlE4O+Aq/YmtTzJWGxLxByZvCiKPA==
|
integrity sha512-sCVxYT/2iSUanrRuiUspZaF78crKojzmVz2mI+gjq1/N+7RPCyZu8S0KyBlE4O+Aq/YmtTzJWGxLxByZvCiKPA==
|
||||||
@@ -5150,6 +5183,11 @@ is-generator-function@^1.0.7:
|
|||||||
resolved "https://registry.yarnpkg.com/is-generator-function/-/is-generator-function-1.0.8.tgz#dfb5c2b120e02b0a8d9d2c6806cd5621aa922f7b"
|
resolved "https://registry.yarnpkg.com/is-generator-function/-/is-generator-function-1.0.8.tgz#dfb5c2b120e02b0a8d9d2c6806cd5621aa922f7b"
|
||||||
integrity sha512-2Omr/twNtufVZFr1GhxjOMFPAj2sjc/dKaIqBhvo4qciXfJmITGH6ZGd8eZYNHza8t1y0e01AuqRhJwfWp26WQ==
|
integrity sha512-2Omr/twNtufVZFr1GhxjOMFPAj2sjc/dKaIqBhvo4qciXfJmITGH6ZGd8eZYNHza8t1y0e01AuqRhJwfWp26WQ==
|
||||||
|
|
||||||
|
is-github-url@^1.1.2:
|
||||||
|
version "1.2.2"
|
||||||
|
resolved "https://registry.yarnpkg.com/is-github-url/-/is-github-url-1.2.2.tgz#0734176092c9599a38a72422d121ff3e11d6ff3e"
|
||||||
|
integrity sha1-BzQXYJLJWZo4pyQi0SH/PhHW/z4=
|
||||||
|
|
||||||
is-glob@^4.0.0, is-glob@^4.0.1, is-glob@~4.0.1:
|
is-glob@^4.0.0, is-glob@^4.0.1, is-glob@~4.0.1:
|
||||||
version "4.0.1"
|
version "4.0.1"
|
||||||
resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.1.tgz#7567dbe9f2f5e2467bc77ab83c4a29482407a5dc"
|
resolved "https://registry.yarnpkg.com/is-glob/-/is-glob-4.0.1.tgz#7567dbe9f2f5e2467bc77ab83c4a29482407a5dc"
|
||||||
@@ -7091,6 +7129,11 @@ parse-filepath@^1.0.2:
|
|||||||
map-cache "^0.2.0"
|
map-cache "^0.2.0"
|
||||||
path-root "^0.1.1"
|
path-root "^0.1.1"
|
||||||
|
|
||||||
|
parse-github-url@^0.2.1:
|
||||||
|
version "0.2.1"
|
||||||
|
resolved "https://registry.yarnpkg.com/parse-github-url/-/parse-github-url-0.2.1.tgz#e17335025e02c827a14198b614e73ab5b9904be8"
|
||||||
|
integrity sha1-4XM1Al4CyCehQZi2FOc6tbmQS+g=
|
||||||
|
|
||||||
parse-json@^4.0.0:
|
parse-json@^4.0.0:
|
||||||
version "4.0.0"
|
version "4.0.0"
|
||||||
resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-4.0.0.tgz#be35f5425be1f7f6c747184f98a788cb99477ee0"
|
resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-4.0.0.tgz#be35f5425be1f7f6c747184f98a788cb99477ee0"
|
||||||
@@ -8088,23 +8131,38 @@ rimraf@^3.0.2:
|
|||||||
dependencies:
|
dependencies:
|
||||||
glob "^7.1.3"
|
glob "^7.1.3"
|
||||||
|
|
||||||
rocket-preset-code-tabs@^0.2.1:
|
rocket-preset-code-tabs@^0.2.6:
|
||||||
version "0.2.1"
|
version "0.2.6"
|
||||||
resolved "https://registry.yarnpkg.com/rocket-preset-code-tabs/-/rocket-preset-code-tabs-0.2.1.tgz#19fbdbf05736c5783187d73fc4a95b1df4e88ca5"
|
resolved "https://registry.yarnpkg.com/rocket-preset-code-tabs/-/rocket-preset-code-tabs-0.2.6.tgz#695dc31f2b75184e12b02e8b17d18d37441c9009"
|
||||||
integrity sha512-m1E8u70iyCrcUDE7tghGZlTjzal0mhvQ1ESIbz/i1iRr3Y/t103FtDfnndZWSUaNcaXECsf8e1zn6DKk53YrMg==
|
integrity sha512-TSvlibssXgTOKVnOa/xTPDUrHfcUcW15FeBFyMvfQRre9bEzA7l1Yv40j8chSlXZ2ysNbkox+Xq9HmyRIYjorQ==
|
||||||
dependencies:
|
dependencies:
|
||||||
"@pwrs/mixins" "^0.2.0"
|
"@pwrs/mixins" "^0.2.1"
|
||||||
eleventy-plugin-add-web-component-definitions "^2.0.3"
|
eleventy-plugin-add-web-component-definitions "^2.0.3"
|
||||||
esbuild "^0.12.15"
|
esbuild "^0.12.15"
|
||||||
esbuild-plugin-lit-css "^1.0.0"
|
esbuild-plugin-lit-css "^1.0.2"
|
||||||
hirestime "^6.1.0"
|
hirestime "^6.1.0"
|
||||||
lit "^2.0.0-rc.2"
|
lit "^2.0.0-rc.2"
|
||||||
rocket-preset-markdown-directives "^0.1.1"
|
rocket-preset-markdown-directives "^0.1.3"
|
||||||
|
|
||||||
rocket-preset-markdown-directives@^0.1.1:
|
rocket-preset-custom-elements-manifest@^0.1.7:
|
||||||
version "0.1.2"
|
version "0.1.7"
|
||||||
resolved "https://registry.yarnpkg.com/rocket-preset-markdown-directives/-/rocket-preset-markdown-directives-0.1.2.tgz#1d2384327c28c9c3b9ebc7a41b3b6103a6831f56"
|
resolved "https://registry.yarnpkg.com/rocket-preset-custom-elements-manifest/-/rocket-preset-custom-elements-manifest-0.1.7.tgz#d5474182bd11cf05207445808ab83cd3a318d596"
|
||||||
integrity sha512-XIbvlnYJu/iK0WlQ4XBZdsC7ZiOE8ga0IpQGCbBSb4C3yIbqFV58Wv/sI/Z8j6OVxb7RSCC/arpdfZaf30EQuQ==
|
integrity sha512-p8DFVgxxivEBZgLE3i5bMMeCvMrdTmNH2WzHHmgnhXVDBny0l2Ma1yO+/hE6/p0iQc5+vAUxpTVazVdoD1csDg==
|
||||||
|
dependencies:
|
||||||
|
"@power-elements/json-viewer" "2.1.1"
|
||||||
|
eleventy-plugin-footnotes "0.9.0"
|
||||||
|
esbuild "^0.12.15"
|
||||||
|
esbuild-plugin-lit-css "^1.0.2"
|
||||||
|
get-github-url "1.0.4"
|
||||||
|
hast-util-is-element "2.1.0"
|
||||||
|
hirestime "6.1.0"
|
||||||
|
rocket-preset-markdown-directives "0.1.3"
|
||||||
|
unist-util-visit "3.1.0"
|
||||||
|
|
||||||
|
rocket-preset-markdown-directives@0.1.3, rocket-preset-markdown-directives@^0.1.3:
|
||||||
|
version "0.1.3"
|
||||||
|
resolved "https://registry.yarnpkg.com/rocket-preset-markdown-directives/-/rocket-preset-markdown-directives-0.1.3.tgz#d1b8eb3dab1e6842b56c7d3d2e9e468950c3584b"
|
||||||
|
integrity sha512-N0npyQjJkPgKBeDeQBXK2/61Sb4gRCoG5VQRw7v3M3by3bv1JaFd1+x37SyvtEk6b/XYmP74A+Nfg8obJ1I4EQ==
|
||||||
dependencies:
|
dependencies:
|
||||||
markdown-it "12.1.0"
|
markdown-it "12.1.0"
|
||||||
markdown-it-prism "2.1.8"
|
markdown-it-prism "2.1.8"
|
||||||
@@ -9350,6 +9408,15 @@ unist-util-visit-parents@^4.0.0:
|
|||||||
"@types/unist" "^2.0.0"
|
"@types/unist" "^2.0.0"
|
||||||
unist-util-is "^5.0.0"
|
unist-util-is "^5.0.0"
|
||||||
|
|
||||||
|
unist-util-visit@3.1.0, unist-util-visit@^3.1.0:
|
||||||
|
version "3.1.0"
|
||||||
|
resolved "https://registry.yarnpkg.com/unist-util-visit/-/unist-util-visit-3.1.0.tgz#9420d285e1aee938c7d9acbafc8e160186dbaf7b"
|
||||||
|
integrity sha512-Szoh+R/Ll68QWAyQyZZpQzZQm2UPbxibDvaY8Xc9SUtYgPsDzx5AWSk++UUt2hJuow8mvwR+rG+LQLw+KsuAKA==
|
||||||
|
dependencies:
|
||||||
|
"@types/unist" "^2.0.0"
|
||||||
|
unist-util-is "^5.0.0"
|
||||||
|
unist-util-visit-parents "^4.0.0"
|
||||||
|
|
||||||
unist-util-visit@^1.1.3:
|
unist-util-visit@^1.1.3:
|
||||||
version "1.4.1"
|
version "1.4.1"
|
||||||
resolved "https://registry.yarnpkg.com/unist-util-visit/-/unist-util-visit-1.4.1.tgz#4724aaa8486e6ee6e26d7ff3c8685960d560b1e3"
|
resolved "https://registry.yarnpkg.com/unist-util-visit/-/unist-util-visit-1.4.1.tgz#4724aaa8486e6ee6e26d7ff3c8685960d560b1e3"
|
||||||
@@ -9366,15 +9433,6 @@ unist-util-visit@^2.0.0, unist-util-visit@^2.0.2, unist-util-visit@^2.0.3:
|
|||||||
unist-util-is "^4.0.0"
|
unist-util-is "^4.0.0"
|
||||||
unist-util-visit-parents "^3.0.0"
|
unist-util-visit-parents "^3.0.0"
|
||||||
|
|
||||||
unist-util-visit@^3.1.0:
|
|
||||||
version "3.1.0"
|
|
||||||
resolved "https://registry.yarnpkg.com/unist-util-visit/-/unist-util-visit-3.1.0.tgz#9420d285e1aee938c7d9acbafc8e160186dbaf7b"
|
|
||||||
integrity sha512-Szoh+R/Ll68QWAyQyZZpQzZQm2UPbxibDvaY8Xc9SUtYgPsDzx5AWSk++UUt2hJuow8mvwR+rG+LQLw+KsuAKA==
|
|
||||||
dependencies:
|
|
||||||
"@types/unist" "^2.0.0"
|
|
||||||
unist-util-is "^5.0.0"
|
|
||||||
unist-util-visit-parents "^4.0.0"
|
|
||||||
|
|
||||||
universalify@^0.1.0:
|
universalify@^0.1.0:
|
||||||
version "0.1.2"
|
version "0.1.2"
|
||||||
resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.1.2.tgz#b646f69be3942dabcecc9d6639c80dc105efaa66"
|
resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.1.2.tgz#b646f69be3942dabcecc9d6639c80dc105efaa66"
|
||||||
|
|||||||
Reference in New Issue
Block a user