@ckeditor/ckeditor5-dev-manual-server 57.0.0-alpha.0 → 57.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +3 -3
- package/dist/index.js +287 -396
- package/dist/manual-test-plugin/collect-pages.d.ts +7 -0
- package/dist/manual-test-plugin/plugin.d.ts +0 -1
- package/dist/manual-test-plugin/types.d.ts +0 -9
- package/dist/static-assets-plugin/plugin.d.ts +10 -0
- package/dist/{manual-test-plugin → static-assets-plugin}/static-assets.d.ts +0 -1
- package/dist/{raw-plugin → svg-plugin}/plugin.d.ts +1 -1
- package/dist/utils.d.ts +8 -0
- package/package.json +2 -10
- package/theme/catalog.css +2 -16
- package/theme/catalog.html +0 -1
- package/theme/catalog.ts +2 -4
- package/theme/manual-bootstrap.css +44 -0
- package/theme/manual-bootstrap.ts +105 -0
- package/theme/manual-header.css +217 -0
- package/theme/manual-header.ts +193 -0
- package/theme/manual-instructions.css +130 -0
- package/dist/manual-test-plugin/parse-markdown.d.ts +0 -6
- package/dist/manual-test-plugin/shell-html.d.ts +0 -14
- package/theme/shell.css +0 -361
- package/theme/shell.html +0 -46
- package/theme/shell.ts +0 -199
|
@@ -0,0 +1,193 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license Copyright (c) 2003-2026, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
+
* For licensing, see LICENSE.md.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
// Shadow DOM chrome styles and document-scoped instruction typography.
|
|
7
|
+
// Imported as raw strings so they can be adopted into constructable stylesheets.
|
|
8
|
+
import headerStyles from './manual-header.css?inline';
|
|
9
|
+
import instructionsStyles from './manual-instructions.css?inline';
|
|
10
|
+
|
|
11
|
+
const MANUAL_HEADER_DATA_META = 'ck-manual-header';
|
|
12
|
+
|
|
13
|
+
const headerStyleSheet = createStyleSheet( headerStyles );
|
|
14
|
+
const instructionsStyleSheet = createStyleSheet( instructionsStyles );
|
|
15
|
+
|
|
16
|
+
/* eslint-disable @stylistic/max-len */
|
|
17
|
+
const TEMPLATE = /* html */ `
|
|
18
|
+
<div class="bar">
|
|
19
|
+
<a class="pill back" title="Back to test index">← All tests</a>
|
|
20
|
+
<span class="divider" aria-hidden="true"></span>
|
|
21
|
+
<span class="label">
|
|
22
|
+
<span class="label__name" data-field="name"></span>
|
|
23
|
+
<span class="label__package" data-field="package"></span>
|
|
24
|
+
</span>
|
|
25
|
+
<span class="divider instructions-only" aria-hidden="true"></span>
|
|
26
|
+
<button type="button" class="pill instructions-only" data-action="toggle" aria-expanded="false">
|
|
27
|
+
Instructions
|
|
28
|
+
</button>
|
|
29
|
+
</div>
|
|
30
|
+
<aside class="panel" aria-hidden="true" inert>
|
|
31
|
+
<div class="panel__inner">
|
|
32
|
+
<header class="panel__header">
|
|
33
|
+
<div class="panel__titles">
|
|
34
|
+
<h1 class="panel__title" data-field="name"></h1>
|
|
35
|
+
<code class="panel__package" data-field="package"></code>
|
|
36
|
+
</div>
|
|
37
|
+
<button type="button" class="panel__close" data-action="close" aria-label="Close">
|
|
38
|
+
<svg viewBox="0 0 16 16" width="16" height="16" aria-hidden="true">
|
|
39
|
+
<path fill="currentColor" d="M3.72 3.72a.75.75 0 011.06 0L8 6.94l3.22-3.22a.75.75 0 111.06 1.06L9.06 8l3.22 3.22a.75.75 0 11-1.06 1.06L8 9.06l-3.22 3.22a.75.75 0 01-1.06-1.06L6.94 8 3.72 4.78a.75.75 0 010-1.06z"/>
|
|
40
|
+
</svg>
|
|
41
|
+
</button>
|
|
42
|
+
</header>
|
|
43
|
+
<article class="panel__body"><slot></slot></article>
|
|
44
|
+
</div>
|
|
45
|
+
</aside>
|
|
46
|
+
`;
|
|
47
|
+
/* eslint-enable @stylistic/max-len */
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* `<ck-manual-header>` renders the manual test chrome: a fixed header bar with the test
|
|
51
|
+
* name, package name and a back-to-index link, plus a collapsible instructions panel that
|
|
52
|
+
* projects the element's light-DOM children (default slot).
|
|
53
|
+
*
|
|
54
|
+
* The manual test server injects a `<meta name="ck-manual-header">` carrying the package
|
|
55
|
+
* name and the base-aware catalog href, and the `<script>` that defines this
|
|
56
|
+
* element — only on pages whose source contains `<ck-manual-header`. Pages without the
|
|
57
|
+
* element render with no chrome. The invisible environment setup (license key, inspector,
|
|
58
|
+
* refresh prompt) lives in `manual-bootstrap.ts` and is injected into every manual test page.
|
|
59
|
+
*
|
|
60
|
+
* Without this script the element is unknown and its children render as plain readable markup.
|
|
61
|
+
*/
|
|
62
|
+
class ManualHeaderElement extends HTMLElement {
|
|
63
|
+
private _panel!: HTMLElement;
|
|
64
|
+
|
|
65
|
+
constructor() {
|
|
66
|
+
super();
|
|
67
|
+
|
|
68
|
+
const shadow = this.attachShadow( { mode: 'open' } );
|
|
69
|
+
|
|
70
|
+
shadow.adoptedStyleSheets = [ headerStyleSheet ];
|
|
71
|
+
shadow.innerHTML = TEMPLATE;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
public connectedCallback(): void {
|
|
75
|
+
adoptInstructionsStyles();
|
|
76
|
+
|
|
77
|
+
const data = readManualHeaderData();
|
|
78
|
+
const shadow = this.shadowRoot!;
|
|
79
|
+
|
|
80
|
+
this._panel = shadow.querySelector<HTMLElement>( '.panel' )!;
|
|
81
|
+
|
|
82
|
+
const backLink = shadow.querySelector<HTMLAnchorElement>( '.back' )!;
|
|
83
|
+
|
|
84
|
+
backLink.href = data.catalogHref;
|
|
85
|
+
|
|
86
|
+
for ( const element of shadow.querySelectorAll<HTMLElement>( '[data-field="name"]' ) ) {
|
|
87
|
+
element.textContent = this._resolveDisplayName();
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
for ( const element of shadow.querySelectorAll<HTMLElement>( '[data-field="package"]' ) ) {
|
|
91
|
+
element.textContent = data.packageName;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
this._setUpInstructions();
|
|
95
|
+
this._setUpActions( shadow );
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
/**
|
|
99
|
+
* The visible name comes from the first slotted heading if present, otherwise `document.title`,
|
|
100
|
+
* falling back to the test path relative to `tests/manual/` derived from the page URL.
|
|
101
|
+
* This avoids `<title>`/instructions drift while letting authors override it with a heading.
|
|
102
|
+
*/
|
|
103
|
+
private _resolveDisplayName(): string {
|
|
104
|
+
const heading = this.querySelector( 'h1, h2, h3, h4, h5, h6' );
|
|
105
|
+
const headingText = heading?.textContent?.trim();
|
|
106
|
+
|
|
107
|
+
return headingText || document.title.trim() || getSlugFromLocation();
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
/**
|
|
111
|
+
* Toggles the availability of the instructions panel based on whether the default slot has
|
|
112
|
+
* meaningful content.
|
|
113
|
+
*/
|
|
114
|
+
private _setUpInstructions(): void {
|
|
115
|
+
const slot = this.shadowRoot!.querySelector<HTMLSlotElement>( 'slot' )!;
|
|
116
|
+
const update = (): void => {
|
|
117
|
+
this.toggleAttribute( 'has-instructions', hasSlottedContent( slot ) );
|
|
118
|
+
};
|
|
119
|
+
|
|
120
|
+
update();
|
|
121
|
+
slot.addEventListener( 'slotchange', update );
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
private _setUpActions( shadow: ShadowRoot ): void {
|
|
125
|
+
shadow.addEventListener( 'click', event => {
|
|
126
|
+
const trigger = ( event.target as Element ).closest<HTMLElement>( '[data-action]' );
|
|
127
|
+
|
|
128
|
+
if ( !trigger ) {
|
|
129
|
+
return;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
if ( trigger.dataset.action == 'toggle' ) {
|
|
133
|
+
this._toggleInstructions( !this._panel.classList.contains( 'panel--open' ) );
|
|
134
|
+
} else if ( trigger.dataset.action == 'close' ) {
|
|
135
|
+
this._toggleInstructions( false );
|
|
136
|
+
}
|
|
137
|
+
} );
|
|
138
|
+
|
|
139
|
+
document.addEventListener( 'keydown', event => {
|
|
140
|
+
if ( event.key == 'Escape' ) {
|
|
141
|
+
this._toggleInstructions( false );
|
|
142
|
+
}
|
|
143
|
+
} );
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
private _toggleInstructions( isOpen: boolean ): void {
|
|
147
|
+
const trigger = this.shadowRoot!.querySelector<HTMLElement>( '[data-action="toggle"]' )!;
|
|
148
|
+
|
|
149
|
+
this._panel.classList.toggle( 'panel--open', isOpen );
|
|
150
|
+
this._panel.toggleAttribute( 'inert', !isOpen );
|
|
151
|
+
this._panel.setAttribute( 'aria-hidden', String( !isOpen ) );
|
|
152
|
+
trigger.setAttribute( 'aria-expanded', String( isOpen ) );
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
function readManualHeaderData(): { packageName: string; catalogHref: string } {
|
|
157
|
+
const meta = document.querySelector<HTMLMetaElement>( `meta[name="${ MANUAL_HEADER_DATA_META }"]` );
|
|
158
|
+
|
|
159
|
+
return {
|
|
160
|
+
packageName: meta?.dataset.packageName || '',
|
|
161
|
+
catalogHref: meta?.dataset.catalogHref || '/'
|
|
162
|
+
};
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
function getSlugFromLocation(): string {
|
|
166
|
+
const path = decodeURIComponent( window.location.pathname );
|
|
167
|
+
const slugPath = path.split( '/tests/manual/' )[ 1 ] || path.split( '/' ).pop() || '';
|
|
168
|
+
|
|
169
|
+
return slugPath.replace( /\.manual\.html$/, '' );
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
function hasSlottedContent( slot: HTMLSlotElement ): boolean {
|
|
173
|
+
return slot.assignedNodes().some( node =>
|
|
174
|
+
node.nodeType == Node.ELEMENT_NODE ||
|
|
175
|
+
node.nodeType == Node.TEXT_NODE && Boolean( node.textContent?.trim() )
|
|
176
|
+
);
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
function createStyleSheet( css: string ): CSSStyleSheet {
|
|
180
|
+
const sheet = new CSSStyleSheet();
|
|
181
|
+
|
|
182
|
+
sheet.replaceSync( css );
|
|
183
|
+
|
|
184
|
+
return sheet;
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
function adoptInstructionsStyles(): void {
|
|
188
|
+
if ( !document.adoptedStyleSheets.includes( instructionsStyleSheet ) ) {
|
|
189
|
+
document.adoptedStyleSheets = [ ...document.adoptedStyleSheets, instructionsStyleSheet ];
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
customElements.define( 'ck-manual-header', ManualHeaderElement );
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license Copyright (c) 2003-2026, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
+
* For licensing, see LICENSE.md.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
/*
|
|
7
|
+
* Adopted into the *document* (not the shadow root) by the <ck-manual-header> component.
|
|
8
|
+
*
|
|
9
|
+
* The instructions are authored as light-DOM children of <ck-manual-header> and projected
|
|
10
|
+
* into the shadow slot. Because slotted content stays in the light DOM, `::slotted()` cannot
|
|
11
|
+
* reach nested nodes, so instruction typography is scoped here to `ck-manual-header` descendants.
|
|
12
|
+
*/
|
|
13
|
+
|
|
14
|
+
/* Offset for the fixed header bar injected by the component. */
|
|
15
|
+
body {
|
|
16
|
+
padding-top: var( --ck-manual-header-height, 44px );
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
ck-manual-header {
|
|
20
|
+
font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
|
|
21
|
+
line-height: 1.6;
|
|
22
|
+
color: #0a0a0a;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
ck-manual-header h1,
|
|
26
|
+
ck-manual-header h2,
|
|
27
|
+
ck-manual-header h3,
|
|
28
|
+
ck-manual-header h4,
|
|
29
|
+
ck-manual-header h5,
|
|
30
|
+
ck-manual-header h6 {
|
|
31
|
+
margin: 24px 0 8px;
|
|
32
|
+
font-weight: 600;
|
|
33
|
+
letter-spacing: -0.01em;
|
|
34
|
+
line-height: 1.3;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
ck-manual-header h1 { font-size: 20px; }
|
|
38
|
+
ck-manual-header h2 { font-size: 17px; }
|
|
39
|
+
ck-manual-header h3 { font-size: 15px; }
|
|
40
|
+
ck-manual-header h4,
|
|
41
|
+
ck-manual-header h5,
|
|
42
|
+
ck-manual-header h6 { font-size: 14px; }
|
|
43
|
+
|
|
44
|
+
ck-manual-header > :first-child { margin-top: 0; }
|
|
45
|
+
ck-manual-header > :last-child { margin-bottom: 0; }
|
|
46
|
+
|
|
47
|
+
ck-manual-header p {
|
|
48
|
+
margin: 8px 0;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
ck-manual-header ul,
|
|
52
|
+
ck-manual-header ol {
|
|
53
|
+
margin: 8px 0;
|
|
54
|
+
padding-left: 24px;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
ck-manual-header li {
|
|
58
|
+
margin: 3px 0;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
ck-manual-header code {
|
|
62
|
+
padding: 1px 6px;
|
|
63
|
+
border-radius: 4px;
|
|
64
|
+
background: #f0f0f0;
|
|
65
|
+
font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
|
|
66
|
+
font-size: 0.9em;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
ck-manual-header kbd {
|
|
70
|
+
padding: 1px 6px;
|
|
71
|
+
border: 1px solid rgb(0 0 0 / 15%);
|
|
72
|
+
border-bottom-width: 2px;
|
|
73
|
+
border-radius: 4px;
|
|
74
|
+
background: #fafafa;
|
|
75
|
+
font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
|
|
76
|
+
font-size: 0.85em;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
ck-manual-header pre {
|
|
80
|
+
margin: 12px 0;
|
|
81
|
+
padding: 12px 14px;
|
|
82
|
+
border-radius: 8px;
|
|
83
|
+
background: #f5f5f5;
|
|
84
|
+
overflow-x: auto;
|
|
85
|
+
font-size: 12px;
|
|
86
|
+
line-height: 1.5;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
ck-manual-header pre code {
|
|
90
|
+
padding: 0;
|
|
91
|
+
background: transparent;
|
|
92
|
+
font-size: inherit;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
ck-manual-header a {
|
|
96
|
+
color: #1d4ed8;
|
|
97
|
+
text-decoration: underline;
|
|
98
|
+
text-underline-offset: 2px;
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
ck-manual-header blockquote {
|
|
102
|
+
margin: 12px 0;
|
|
103
|
+
padding: 4px 14px;
|
|
104
|
+
border-left: 3px solid rgb(0 0 0 / 15%);
|
|
105
|
+
color: #525252;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
ck-manual-header table {
|
|
109
|
+
margin: 12px 0;
|
|
110
|
+
border-collapse: collapse;
|
|
111
|
+
font-size: 13px;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
ck-manual-header th,
|
|
115
|
+
ck-manual-header td {
|
|
116
|
+
padding: 6px 10px;
|
|
117
|
+
border: 1px solid rgb(0 0 0 / 10%);
|
|
118
|
+
text-align: left;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
ck-manual-header th {
|
|
122
|
+
background: #f5f5f5;
|
|
123
|
+
font-weight: 600;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
ck-manual-header hr {
|
|
127
|
+
margin: 16px 0;
|
|
128
|
+
border: 0;
|
|
129
|
+
border-top: 1px solid rgb(0 0 0 / 10%);
|
|
130
|
+
}
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license Copyright (c) 2003-2026, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
-
* For licensing, see LICENSE.md.
|
|
4
|
-
*/
|
|
5
|
-
import type { ManualPageEntry } from "./types.js";
|
|
6
|
-
export declare function loadRenderedInstructions(entry: ManualPageEntry, workspaceRoot: string): string;
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license Copyright (c) 2003-2026, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
-
* For licensing, see LICENSE.md.
|
|
4
|
-
*/
|
|
5
|
-
import type { ManualPageEntry } from "./types.js";
|
|
6
|
-
export interface CreateManualShellHtmlOptions {
|
|
7
|
-
catalogPublicPath?: string;
|
|
8
|
-
entry: ManualPageEntry;
|
|
9
|
-
html: string;
|
|
10
|
-
shellScriptPublicPath: string;
|
|
11
|
-
shellTemplateFilePath: string;
|
|
12
|
-
workspaceRoot: string;
|
|
13
|
-
}
|
|
14
|
-
export declare function createManualShellHtml({ catalogPublicPath, entry, html, shellScriptPublicPath, shellTemplateFilePath, workspaceRoot }: CreateManualShellHtmlOptions): string;
|
package/theme/shell.css
DELETED
|
@@ -1,361 +0,0 @@
|
|
|
1
|
-
.manual-test-container {
|
|
2
|
-
min-width: 0;
|
|
3
|
-
box-sizing: border-box;
|
|
4
|
-
padding: calc( var( --shell-height, 44px ) + 8px ) 8px 8px;
|
|
5
|
-
}
|
|
6
|
-
|
|
7
|
-
body.shell-enabled {
|
|
8
|
-
box-sizing: border-box;
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
.shell {
|
|
12
|
-
position: fixed;
|
|
13
|
-
top: 0;
|
|
14
|
-
left: 0;
|
|
15
|
-
right: 0;
|
|
16
|
-
z-index: 99999;
|
|
17
|
-
display: flex;
|
|
18
|
-
align-items: stretch;
|
|
19
|
-
box-sizing: border-box;
|
|
20
|
-
padding: 6px 8px;
|
|
21
|
-
font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
|
|
22
|
-
font-size: 12px;
|
|
23
|
-
line-height: 1.25;
|
|
24
|
-
color: #0a0a0a;
|
|
25
|
-
background: rgb(255 255 255 / 85%);
|
|
26
|
-
backdrop-filter: saturate(180%) blur(20px);
|
|
27
|
-
-webkit-backdrop-filter: saturate(180%) blur(20px);
|
|
28
|
-
border-bottom: 1px solid rgb(0 0 0 / 8%);
|
|
29
|
-
box-shadow: 0 1px 2px rgb(0 0 0 / 4%);
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
.shell__pill {
|
|
33
|
-
display: inline-flex;
|
|
34
|
-
align-items: center;
|
|
35
|
-
padding: 8px 14px;
|
|
36
|
-
border: 0;
|
|
37
|
-
background: transparent;
|
|
38
|
-
border-radius: 999px;
|
|
39
|
-
text-decoration: none;
|
|
40
|
-
color: inherit;
|
|
41
|
-
font: inherit;
|
|
42
|
-
font-weight: 500;
|
|
43
|
-
white-space: nowrap;
|
|
44
|
-
transition: background 0.1s;
|
|
45
|
-
cursor: pointer;
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
.shell__pill:hover {
|
|
49
|
-
background: rgb(0 0 0 / 5%);
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
.shell__pill:active {
|
|
53
|
-
background: rgb(0 0 0 / 10%);
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
.shell__pill:focus-visible {
|
|
57
|
-
outline: 2px solid rgb(0 0 0 / 30%);
|
|
58
|
-
outline-offset: 1px;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
.shell__divider {
|
|
62
|
-
flex-shrink: 0;
|
|
63
|
-
align-self: center;
|
|
64
|
-
width: 1px;
|
|
65
|
-
height: 16px;
|
|
66
|
-
background: rgb(0 0 0 / 10%);
|
|
67
|
-
margin: 0 2px;
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
.shell__label {
|
|
71
|
-
display: inline-flex;
|
|
72
|
-
align-items: center;
|
|
73
|
-
flex: 1 1 auto;
|
|
74
|
-
gap: 10px;
|
|
75
|
-
padding: 8px 14px;
|
|
76
|
-
overflow: hidden;
|
|
77
|
-
min-width: 0;
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
.shell__label-name {
|
|
81
|
-
font-weight: 600;
|
|
82
|
-
overflow: hidden;
|
|
83
|
-
text-overflow: ellipsis;
|
|
84
|
-
white-space: nowrap;
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
.shell__label-package {
|
|
88
|
-
font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
|
|
89
|
-
font-weight: 400;
|
|
90
|
-
font-size: 11px;
|
|
91
|
-
opacity: 0.55;
|
|
92
|
-
overflow: hidden;
|
|
93
|
-
text-overflow: ellipsis;
|
|
94
|
-
white-space: nowrap;
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
.manual-refresh-prompt {
|
|
98
|
-
position: fixed;
|
|
99
|
-
top: calc( var( --shell-height, 44px ) / 1.25 );
|
|
100
|
-
left: 50%;
|
|
101
|
-
z-index: 100000;
|
|
102
|
-
box-sizing: border-box;
|
|
103
|
-
padding: 8px 14px;
|
|
104
|
-
border: 1px solid #bfdbfe;
|
|
105
|
-
border-radius: 999px;
|
|
106
|
-
font: 600 12px/1.25 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
|
|
107
|
-
color: #1d4ed8;
|
|
108
|
-
background: #dbeafe;
|
|
109
|
-
cursor: pointer;
|
|
110
|
-
opacity: 0;
|
|
111
|
-
pointer-events: none;
|
|
112
|
-
transform: translate(-50%, calc( -100% - var( --shell-height, 44px ) ) );
|
|
113
|
-
transition: transform 0.18s ease-out, opacity 0.18s ease-out, background 0.1s;
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
.manual-refresh-prompt--visible {
|
|
117
|
-
opacity: 1;
|
|
118
|
-
pointer-events: auto;
|
|
119
|
-
transform: translate(-50%, -50%);
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
.manual-refresh-prompt:hover {
|
|
123
|
-
background: #bfdbfe;
|
|
124
|
-
}
|
|
125
|
-
|
|
126
|
-
.manual-refresh-prompt:active {
|
|
127
|
-
background: #93c5fd;
|
|
128
|
-
}
|
|
129
|
-
|
|
130
|
-
.manual-refresh-prompt:focus-visible {
|
|
131
|
-
outline: 2px solid #2563eb;
|
|
132
|
-
outline-offset: 1px;
|
|
133
|
-
}
|
|
134
|
-
|
|
135
|
-
@media (max-width: 600px) {
|
|
136
|
-
.shell {
|
|
137
|
-
font-size: 11px;
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
.shell__label-package {
|
|
141
|
-
display: none;
|
|
142
|
-
}
|
|
143
|
-
|
|
144
|
-
.shell__label-name {
|
|
145
|
-
max-width: 20ch;
|
|
146
|
-
}
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
.shell-instructions {
|
|
150
|
-
--shell-instructions-width: min(420px, 45vw);
|
|
151
|
-
--shell-instructions-transition-duration: 0.18s;
|
|
152
|
-
|
|
153
|
-
position: fixed;
|
|
154
|
-
top: 44px;
|
|
155
|
-
right: 0;
|
|
156
|
-
bottom: 0;
|
|
157
|
-
z-index: 99998;
|
|
158
|
-
order: 2;
|
|
159
|
-
align-self: start;
|
|
160
|
-
flex: 0 0 0;
|
|
161
|
-
width: 0;
|
|
162
|
-
height: 0;
|
|
163
|
-
min-height: 0;
|
|
164
|
-
padding: 0;
|
|
165
|
-
border: 0;
|
|
166
|
-
background: #fff;
|
|
167
|
-
color: #0a0a0a;
|
|
168
|
-
font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
|
|
169
|
-
line-height: 1.6;
|
|
170
|
-
overflow: hidden;
|
|
171
|
-
transition:
|
|
172
|
-
flex-basis var(--shell-instructions-transition-duration) ease-out,
|
|
173
|
-
width var(--shell-instructions-transition-duration) ease-out;
|
|
174
|
-
}
|
|
175
|
-
|
|
176
|
-
.shell-instructions--open,
|
|
177
|
-
.shell-instructions--closing {
|
|
178
|
-
align-self: stretch;
|
|
179
|
-
height: auto;
|
|
180
|
-
border-left: 1px solid rgb(0 0 0 / 8%);
|
|
181
|
-
box-shadow: -8px 0 24px rgb(0 0 0 / 8%);
|
|
182
|
-
}
|
|
183
|
-
|
|
184
|
-
.shell-instructions--open {
|
|
185
|
-
flex-basis: var(--shell-instructions-width);
|
|
186
|
-
width: var(--shell-instructions-width);
|
|
187
|
-
}
|
|
188
|
-
|
|
189
|
-
.shell-instructions__inner {
|
|
190
|
-
display: flex;
|
|
191
|
-
flex-direction: column;
|
|
192
|
-
width: var(--shell-instructions-width);
|
|
193
|
-
height: 100%;
|
|
194
|
-
}
|
|
195
|
-
|
|
196
|
-
.shell-instructions__header {
|
|
197
|
-
display: flex;
|
|
198
|
-
align-items: flex-start;
|
|
199
|
-
justify-content: space-between;
|
|
200
|
-
gap: 16px;
|
|
201
|
-
padding: 20px 24px;
|
|
202
|
-
border-bottom: 1px solid rgb(0 0 0 / 8%);
|
|
203
|
-
flex-shrink: 0;
|
|
204
|
-
}
|
|
205
|
-
|
|
206
|
-
.shell-instructions__titles {
|
|
207
|
-
min-width: 0;
|
|
208
|
-
}
|
|
209
|
-
|
|
210
|
-
.shell-instructions__title {
|
|
211
|
-
margin: 0 0 4px;
|
|
212
|
-
font-size: 18px;
|
|
213
|
-
font-weight: 700;
|
|
214
|
-
letter-spacing: -0.01em;
|
|
215
|
-
line-height: 1.3;
|
|
216
|
-
overflow: hidden;
|
|
217
|
-
text-overflow: ellipsis;
|
|
218
|
-
white-space: nowrap;
|
|
219
|
-
}
|
|
220
|
-
|
|
221
|
-
.shell-instructions__package {
|
|
222
|
-
font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
|
|
223
|
-
font-size: 12px;
|
|
224
|
-
color: #737373;
|
|
225
|
-
}
|
|
226
|
-
|
|
227
|
-
.shell-instructions__close {
|
|
228
|
-
flex-shrink: 0;
|
|
229
|
-
display: inline-flex;
|
|
230
|
-
align-items: center;
|
|
231
|
-
justify-content: center;
|
|
232
|
-
width: 32px;
|
|
233
|
-
height: 32px;
|
|
234
|
-
padding: 0;
|
|
235
|
-
border: 0;
|
|
236
|
-
border-radius: 8px;
|
|
237
|
-
background: transparent;
|
|
238
|
-
color: #737373;
|
|
239
|
-
cursor: pointer;
|
|
240
|
-
transition: background 0.1s, color 0.1s;
|
|
241
|
-
}
|
|
242
|
-
|
|
243
|
-
.shell-instructions__close:hover {
|
|
244
|
-
background: rgb(0 0 0 / 5%);
|
|
245
|
-
color: #0a0a0a;
|
|
246
|
-
}
|
|
247
|
-
|
|
248
|
-
.shell-instructions__close:focus-visible {
|
|
249
|
-
outline: 2px solid rgb(0 0 0 / 30%);
|
|
250
|
-
outline-offset: 1px;
|
|
251
|
-
}
|
|
252
|
-
|
|
253
|
-
.shell-instructions__body {
|
|
254
|
-
padding: 20px 24px 28px;
|
|
255
|
-
font-size: 14px;
|
|
256
|
-
overflow-y: auto;
|
|
257
|
-
min-height: 0;
|
|
258
|
-
}
|
|
259
|
-
|
|
260
|
-
.shell-instructions__body h1,
|
|
261
|
-
.shell-instructions__body h2,
|
|
262
|
-
.shell-instructions__body h3,
|
|
263
|
-
.shell-instructions__body h4,
|
|
264
|
-
.shell-instructions__body h5,
|
|
265
|
-
.shell-instructions__body h6 {
|
|
266
|
-
margin: 24px 0 8px;
|
|
267
|
-
font-weight: 600;
|
|
268
|
-
letter-spacing: -0.01em;
|
|
269
|
-
line-height: 1.3;
|
|
270
|
-
}
|
|
271
|
-
|
|
272
|
-
.shell-instructions__body h1 { font-size: 20px; }
|
|
273
|
-
.shell-instructions__body h2 { font-size: 17px; }
|
|
274
|
-
.shell-instructions__body h3 { font-size: 15px; }
|
|
275
|
-
.shell-instructions__body h4,
|
|
276
|
-
.shell-instructions__body h5,
|
|
277
|
-
.shell-instructions__body h6 { font-size: 14px; }
|
|
278
|
-
|
|
279
|
-
.shell-instructions__body > :first-child { margin-top: 0; }
|
|
280
|
-
.shell-instructions__body > :last-child { margin-bottom: 0; }
|
|
281
|
-
|
|
282
|
-
.shell-instructions__body p {
|
|
283
|
-
margin: 8px 0;
|
|
284
|
-
}
|
|
285
|
-
|
|
286
|
-
.shell-instructions__body ul,
|
|
287
|
-
.shell-instructions__body ol {
|
|
288
|
-
margin: 8px 0;
|
|
289
|
-
padding-left: 24px;
|
|
290
|
-
}
|
|
291
|
-
|
|
292
|
-
.shell-instructions__body li {
|
|
293
|
-
margin: 3px 0;
|
|
294
|
-
}
|
|
295
|
-
|
|
296
|
-
.shell-instructions__body code {
|
|
297
|
-
padding: 1px 6px;
|
|
298
|
-
border-radius: 4px;
|
|
299
|
-
background: #f0f0f0;
|
|
300
|
-
font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
|
|
301
|
-
font-size: 0.9em;
|
|
302
|
-
}
|
|
303
|
-
|
|
304
|
-
.shell-instructions__body pre {
|
|
305
|
-
margin: 12px 0;
|
|
306
|
-
padding: 12px 14px;
|
|
307
|
-
border-radius: 8px;
|
|
308
|
-
background: #f5f5f5;
|
|
309
|
-
overflow-x: auto;
|
|
310
|
-
font-size: 12px;
|
|
311
|
-
line-height: 1.5;
|
|
312
|
-
}
|
|
313
|
-
|
|
314
|
-
.shell-instructions__body pre code {
|
|
315
|
-
padding: 0;
|
|
316
|
-
background: transparent;
|
|
317
|
-
font-size: inherit;
|
|
318
|
-
}
|
|
319
|
-
|
|
320
|
-
.shell-instructions__body a {
|
|
321
|
-
color: #1d4ed8;
|
|
322
|
-
text-decoration: underline;
|
|
323
|
-
text-underline-offset: 2px;
|
|
324
|
-
}
|
|
325
|
-
|
|
326
|
-
.shell-instructions__body blockquote {
|
|
327
|
-
margin: 12px 0;
|
|
328
|
-
padding: 4px 14px;
|
|
329
|
-
border-left: 3px solid rgb(0 0 0 / 15%);
|
|
330
|
-
color: #525252;
|
|
331
|
-
}
|
|
332
|
-
|
|
333
|
-
.shell-instructions__body table {
|
|
334
|
-
margin: 12px 0;
|
|
335
|
-
border-collapse: collapse;
|
|
336
|
-
font-size: 13px;
|
|
337
|
-
}
|
|
338
|
-
|
|
339
|
-
.shell-instructions__body th,
|
|
340
|
-
.shell-instructions__body td {
|
|
341
|
-
padding: 6px 10px;
|
|
342
|
-
border: 1px solid rgb(0 0 0 / 10%);
|
|
343
|
-
text-align: left;
|
|
344
|
-
}
|
|
345
|
-
|
|
346
|
-
.shell-instructions__body th {
|
|
347
|
-
background: #f5f5f5;
|
|
348
|
-
font-weight: 600;
|
|
349
|
-
}
|
|
350
|
-
|
|
351
|
-
.shell-instructions__body hr {
|
|
352
|
-
margin: 16px 0;
|
|
353
|
-
border: 0;
|
|
354
|
-
border-top: 1px solid rgb(0 0 0 / 10%);
|
|
355
|
-
}
|
|
356
|
-
|
|
357
|
-
@media (max-width: 800px) {
|
|
358
|
-
.shell-instructions {
|
|
359
|
-
--shell-instructions-width: min(360px, 70vw);
|
|
360
|
-
}
|
|
361
|
-
}
|