Update css file name
Browse files- docs/package.json +1 -1
- docs/pnpm-lock.yaml +4 -4
- docs/src/components/examples/SimpleHighlight.tsx +1 -1
- index.html +0 -1
- src/driver.ts +1 -0
- vite.config.ts +7 -0
docs/package.json
CHANGED
@@ -16,7 +16,7 @@
|
|
16 |
"@types/react": "^18.0.21",
|
17 |
"@types/react-dom": "^18.0.6",
|
18 |
"astro": "^2.7.0",
|
19 |
-
"driver.js": "1.1.
|
20 |
"react": "^18.0.0",
|
21 |
"react-dom": "^18.0.0",
|
22 |
"react-fast-marquee": "^1.6.0",
|
|
|
16 |
"@types/react": "^18.0.21",
|
17 |
"@types/react-dom": "^18.0.6",
|
18 |
"astro": "^2.7.0",
|
19 |
+
"driver.js": "1.1.3-next.0",
|
20 |
"react": "^18.0.0",
|
21 |
"react-dom": "^18.0.0",
|
22 |
"react-fast-marquee": "^1.6.0",
|
docs/pnpm-lock.yaml
CHANGED
@@ -24,8 +24,8 @@ dependencies:
|
|
24 |
specifier: ^2.7.0
|
25 |
version: 2.7.0
|
26 |
driver.js:
|
27 |
-
specifier: 1.1.
|
28 |
-
version: 1.1.
|
29 |
react:
|
30 |
specifier: ^18.0.0
|
31 |
version: 18.2.0
|
@@ -1376,8 +1376,8 @@ packages:
|
|
1376 | |
1377 |
resolution: {integrity: sha512-+HlytyjlPKnIG8XuRG8WvmBP8xs8P71y+SKKS6ZXWoEgLuePxtDoUEiH7WkdePWrQ5JBpE6aoVqfZfJUQkjXwA==}
|
1378 |
|
1379 |
-
/[email protected].
|
1380 |
-
resolution: {integrity: sha512-
|
1381 |
dev: false
|
1382 |
|
1383 |
|
|
24 |
specifier: ^2.7.0
|
25 |
version: 2.7.0
|
26 |
driver.js:
|
27 |
+
specifier: 1.1.3-next.0
|
28 |
+
version: 1.1.3-next.0
|
29 |
react:
|
30 |
specifier: ^18.0.0
|
31 |
version: 18.2.0
|
|
|
1376 | |
1377 |
resolution: {integrity: sha512-+HlytyjlPKnIG8XuRG8WvmBP8xs8P71y+SKKS6ZXWoEgLuePxtDoUEiH7WkdePWrQ5JBpE6aoVqfZfJUQkjXwA==}
|
1378 |
|
1379 |
+
/[email protected].3-next.0:
|
1380 |
+
resolution: {integrity: sha512-O2Lsz+f2TZ6Twp349MkFXd+2JVH8b2dQhlNUDIxkagFsJ6oxgTOnWdAqtYmv8cjSEgmu+IzWHfgkJukp7GcPUQ==}
|
1381 |
dev: false
|
1382 |
|
1383 |
docs/src/components/examples/SimpleHighlight.tsx
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
import { useEffect } from "react";
|
2 |
import { Config, driver } from "driver.js";
|
3 |
-
import "driver.js/dist/
|
4 |
|
5 |
import type { DriveStep } from "driver.js";
|
6 |
|
|
|
1 |
import { useEffect } from "react";
|
2 |
import { Config, driver } from "driver.js";
|
3 |
+
import "driver.js/dist/driver.css";
|
4 |
|
5 |
import type { DriveStep } from "driver.js";
|
6 |
|
index.html
CHANGED
@@ -338,7 +338,6 @@ npm install driver.js</pre
|
|
338 |
</div>
|
339 |
<script type="module">
|
340 |
import { driver } from "./src/driver.ts";
|
341 |
-
import "./src/driver.css";
|
342 |
|
343 |
const basicTourSteps = [
|
344 |
{
|
|
|
338 |
</div>
|
339 |
<script type="module">
|
340 |
import { driver } from "./src/driver.ts";
|
|
|
341 |
|
342 |
const basicTourSteps = [
|
343 |
{
|
src/driver.ts
CHANGED
@@ -5,6 +5,7 @@ import { Config, configure, getConfig } from "./config";
|
|
5 |
import { destroyHighlight, highlight } from "./highlight";
|
6 |
import { destroyEmitter, listen } from "./emitter";
|
7 |
import { getState, resetState, setState } from "./state";
|
|
|
8 |
|
9 |
export type DriveStep = {
|
10 |
element?: string | Element;
|
|
|
5 |
import { destroyHighlight, highlight } from "./highlight";
|
6 |
import { destroyEmitter, listen } from "./emitter";
|
7 |
import { getState, resetState, setState } from "./state";
|
8 |
+
import "./driver.css";
|
9 |
|
10 |
export type DriveStep = {
|
11 |
element?: string | Element;
|
vite.config.ts
CHANGED
@@ -21,6 +21,13 @@ module.exports = defineConfig({
|
|
21 |
formats,
|
22 |
fileName: format => fileName[format],
|
23 |
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
24 |
},
|
25 |
test: {},
|
26 |
});
|
|
|
21 |
formats,
|
22 |
fileName: format => fileName[format],
|
23 |
},
|
24 |
+
rollupOptions: {
|
25 |
+
output: {
|
26 |
+
assetFileNames: assetInfo => {
|
27 |
+
return assetInfo.name === "style.css" ? `${packageName}.css` : assetInfo.name;
|
28 |
+
},
|
29 |
+
},
|
30 |
+
},
|
31 |
},
|
32 |
test: {},
|
33 |
});
|