Skip to content

Commit bb59f5f

Browse files
authored
docs: styling fix (#697)
1 parent 24315fb commit bb59f5f

11 files changed

Lines changed: 81 additions & 20 deletions

File tree

apps/docs/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
},
3636
"dependencies": {
3737
"@kobalte/core": "workspace:*",
38-
"@kobalte/solidbase": "0.6.10",
38+
"@kobalte/solidbase": "0.6.11",
3939
"@solidjs/meta": "0.29.4",
4040
"@solidjs/router": "0.16.2",
4141
"@solidjs/start": "2.0.0-beta.0",

apps/docs/src/examples/navigation-menu.module.css

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
background-color: white;
77
width: max-content;
88
border-radius: 6px;
9+
list-style: none;
910
}
1011

1112
.navigation-menu__root[data-orientation="vertical"] {
@@ -178,6 +179,7 @@
178179
animation-timing-function: ease;
179180
animation-fill-mode: forwards;
180181
pointer-events: none;
182+
list-style: none;
181183
}
182184

183185
.navigation-menu__content[data-expanded] {

apps/docs/src/examples/pagination.module.css

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
.pagination__root > ul {
2+
list-style: none;
23
display: inline-flex;
34
align-items: center;
45
justify-content: space-between;
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import { Navigate, redirect } from "@solidjs/router";
2+
3+
const target = "./0-13-x";
4+
5+
export const route = {
6+
preload() {
7+
return redirect(target);
8+
},
9+
};
10+
11+
export function GET() {
12+
throw redirect(target);
13+
}
14+
15+
export default function () {
16+
return <Navigate href={target} />;
17+
}

apps/docs/src/routes/docs/changelog/index.tsx

Lines changed: 0 additions & 5 deletions
This file was deleted.
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import { Navigate, redirect } from "@solidjs/router";
2+
3+
const target = "./introduction";
4+
5+
export const route = {
6+
preload() {
7+
return redirect(target);
8+
},
9+
};
10+
11+
export function GET() {
12+
throw redirect(target);
13+
}
14+
15+
export default function () {
16+
return <Navigate href={target} />;
17+
}

apps/docs/src/routes/docs/core/(1)components/navigation-menu.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ Since the viewport content has a position of `absolute` to allow animating, Koba
149149
The height and width will be copied from the active `NavigationMenu.Content`, which can either be set using CSS or automatically calculated based on it's content.
150150
Combined with a transition CSS rule the size can be animated.
151151

152-
```css {2-3}
152+
```css {3-4}
153153
/* style.css */
154154
.navigation-menu__viewport {
155155
width: var(--kb-navigation-menu-viewport-width);
@@ -188,7 +188,7 @@ To make one of the navigation menu triggers a link instead of opening a menu, om
188188

189189
We expose a CSS custom property `--kb-menu-content-transform-origin` which can be used to animate the viewport from its computed origin.
190190

191-
```css {2}
191+
```css {3}
192192
/* style.css */
193193
.navigation-menu__viewport {
194194
transform-origin: var(--kb-menu-content-transform-origin);
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import { Navigate, redirect } from "@solidjs/router";
2+
3+
const target = "/docs/core/overview/introduction";
4+
5+
export const route = {
6+
preload() {
7+
return redirect(target);
8+
},
9+
};
10+
11+
export function GET() {
12+
throw redirect(target);
13+
}
14+
15+
export default function () {
16+
return <Navigate href={target} />;
17+
}

apps/docs/vite.config.ts

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,14 @@ import { defineConfig } from "vite";
99
import { version as KBVersion } from "../../packages/core/package.json";
1010

1111
const theme = defineTheme({
12-
componentsPath: import.meta.resolve("./src/solidbase-theme"),
12+
componentsPath: await import.meta.resolve("./src/solidbase-theme"),
1313
extends: defaultTheme,
1414
});
1515

1616
const solidBase = createSolidBase(theme);
1717

18+
const collator = new Intl.Collator(undefined, { numeric: true });
19+
1820
export default defineConfig({
1921
resolve: {
2022
dedupe: ["solid-js", "@solidjs/router"],
@@ -84,9 +86,19 @@ export default defineConfig({
8486
},
8587
},
8688
),
87-
"/docs/changelog": createDefaultThemeFilesystemSidebar(
88-
"./src/routes/docs/changelog",
89-
),
89+
"/docs/changelog": [
90+
{
91+
title: "Changelog",
92+
items: createDefaultThemeFilesystemSidebar(
93+
"./src/routes/docs/changelog",
94+
{
95+
sort: (a, b) => {
96+
return collator.compare(b.filePath, a.filePath);
97+
},
98+
},
99+
),
100+
},
101+
],
90102
},
91103
search: {
92104
docsearch: {

pnpm-lock.yaml

Lines changed: 7 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)