blume 1.6.2 → 1.6.3
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/CHANGELOG.md +6 -0
- package/dist/cli/index.js +14 -23
- package/dist/cli/index.js.map +4 -4
- package/docs/content/components.mdx +1 -1
- package/package.json +1 -1
- package/src/components/content/Component.astro +5 -9
- package/src/components/content/Tabs.astro +24 -9
- package/src/components/layout/RootLayout.astro +105 -36
- package/src/theme/code-block-padding.ts +0 -8
- package/src/theme/entry.ts +14 -25
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# blume
|
|
2
2
|
|
|
3
|
+
## 1.6.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 7d3fb47: Drop the strip of empty space above code blocks inside `<CodeGroup>`, `<Tabs>`, `<Steps>`, `<Callout>` and the other flush contexts. The 2.5rem top inset added to keep the copy button off a long first line read as a rendering bug over a one-line install command. A code switcher (a `<CodeGroup>`, a `ts2js` fence, code-only `<Tab>`s) now hosts a single copy button in its tab strip that copies whichever panel is showing, and every other bar-less block keeps the plain 1rem inset with enough end padding on the scrolling code that a long first line's tail clears the overlay button.
|
|
8
|
+
|
|
3
9
|
## 1.6.2
|
|
4
10
|
|
|
5
11
|
### Patch Changes
|
package/dist/cli/index.js
CHANGED
|
@@ -20288,7 +20288,6 @@ var resolveSearchPopular = (popular, basePath) => popular.map(({ href, icon, lab
|
|
|
20288
20288
|
|
|
20289
20289
|
// src/theme/code-block-padding.ts
|
|
20290
20290
|
var CODE_PADDING_BLOCK_REM = 1;
|
|
20291
|
-
var FLUSH_CODE_PADDING_TOP_REM = 2.5;
|
|
20292
20291
|
|
|
20293
20292
|
// src/theme/entry.ts
|
|
20294
20293
|
var DARK_VARIANT = `/* Dark mode is driven by data-theme on the <html> element. */
|
|
@@ -20864,27 +20863,19 @@ blume-tabs pre[data-language],
|
|
|
20864
20863
|
padding-top: ${CODE_PADDING_BLOCK_REM}rem;
|
|
20865
20864
|
}
|
|
20866
20865
|
|
|
20867
|
-
/*
|
|
20868
|
-
|
|
20869
|
-
|
|
20870
|
-
|
|
20871
|
-
|
|
20872
|
-
|
|
20873
|
-
|
|
20874
|
-
|
|
20875
|
-
|
|
20876
|
-
|
|
20877
|
-
|
|
20878
|
-
|
|
20879
|
-
|
|
20880
|
-
\`.astro-code\`, no language bar, but the injector gives it a button all
|
|
20881
|
-
the same — keyed on that injected button, which is exactly what separates
|
|
20882
|
-
it from the playground's pre. API panel blocks match, but their own
|
|
20883
|
-
!important padding wins and they hide the injected button. */
|
|
20884
|
-
[data-blume-code-copy] :is(blume-tabs, .not-prose) pre.astro-code,
|
|
20885
|
-
[data-blume-code-copy] .prose pre.astro-code:not([data-language]),
|
|
20886
|
-
[data-blume-code-copy] .prose pre:not([data-language]):has(> [data-blume-copy]) {
|
|
20887
|
-
padding-top: ${FLUSH_CODE_PADDING_TOP_REM}rem;
|
|
20866
|
+
/* Where no language bar holds the copy button — a flush block in tabs or a
|
|
20867
|
+
not-prose component, a bar-less block in prose — the docs layout still pins
|
|
20868
|
+
one over the block's top-right corner, so a first line long enough to reach
|
|
20869
|
+
it would end underneath. A code switcher (CodeGroup, ts2js) hosts the button
|
|
20870
|
+
in its tab strip instead and needs nothing here; for every block that keeps
|
|
20871
|
+
an overlay button, give the scrolling code element enough end padding that
|
|
20872
|
+
the line's tail clears the button at the end of its scroll. Keyed on the
|
|
20873
|
+
injected button itself (which the playground's client-created response pre
|
|
20874
|
+
never gets), and \`.prose\`-scoped to outrank the base \`:where(pre code)\`
|
|
20875
|
+
inset. Not a vertical inset — that reserved a strip above every one-line
|
|
20876
|
+
command and read as a rendering bug. */
|
|
20877
|
+
.prose :is(blume-tabs pre, .not-prose pre, pre:not([data-language])):not(.twoslash, .twoslash pre, blume-panel-tabs *):has(> [data-blume-copy]) > code {
|
|
20878
|
+
padding-inline-end: 3.5rem;
|
|
20888
20879
|
}
|
|
20889
20880
|
|
|
20890
20881
|
blume-tabs pre[data-language]::before,
|
|
@@ -27377,5 +27368,5 @@ process.on("unhandledRejection", (error) => {
|
|
|
27377
27368
|
});
|
|
27378
27369
|
runMain(main, { rawArgs: normalizeHostArgs(process.argv.slice(2)) });
|
|
27379
27370
|
|
|
27380
|
-
//# debugId=
|
|
27371
|
+
//# debugId=91C1BFDA6463CA2664756E2164756E21
|
|
27381
27372
|
//# sourceMappingURL=index.js.map
|