@lincyaw/presmium 1.0.0-rc.5 → 1.0.0-rc.50

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/bin/presmium.mjs CHANGED
@@ -1,28 +1,14 @@
1
1
  #!/usr/bin/env node
2
- import { existsSync, realpathSync } from 'node:fs'
3
- import { dirname, join } from 'node:path'
4
- import { fileURLToPath, pathToFileURL } from 'node:url'
2
+ import { realpathSync } from 'node:fs'
3
+ import { fileURLToPath } from 'node:url'
5
4
  import { createJiti } from 'jiti'
6
5
 
7
6
  const own = realpathSync(fileURLToPath(new URL('..', import.meta.url)))
8
7
 
9
- function projectPresmium(from) {
10
- for (let dir = from; ; dir = dirname(dir)) {
11
- const found = join(dir, 'node_modules/@lincyaw/presmium/bin/presmium.mjs')
12
- if (existsSync(found)) return found
13
- if (dirname(dir) === dir) return undefined
14
- }
15
- }
16
-
17
- const local = projectPresmium(process.cwd())
18
- if (local && realpathSync(join(dirname(local), '..')) !== own) {
19
- await import(pathToFileURL(local).href)
20
- } else {
21
- const emitWarning = process.emitWarning
22
- process.emitWarning = (warning, ...args) => {
23
- const code = typeof args[0] === 'object' ? args[0]?.code : args[1]
24
- if (code !== 'DEP0040') emitWarning.call(process, warning, ...args)
25
- }
26
- const { main } = await createJiti(import.meta.url).import('@lincyaw/cli')
27
- process.exitCode = await main(process.argv.slice(2), { bundled: own, bin: fileURLToPath(import.meta.url) })
8
+ const emitWarning = process.emitWarning
9
+ process.emitWarning = (warning, ...args) => {
10
+ const code = typeof args[0] === 'object' ? args[0]?.code : args[1]
11
+ if (code !== 'DEP0040') emitWarning.call(process, warning, ...args)
28
12
  }
13
+ const { main } = await createJiti(import.meta.url).import('@lincyaw/cli')
14
+ process.exitCode = await main(process.argv.slice(2), { bundled: own, bin: fileURLToPath(import.meta.url) })
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lincyaw/presmium",
3
- "version": "1.0.0-rc.5",
3
+ "version": "1.0.0-rc.50",
4
4
  "description": "The presmium command with the renderers and the official plugins: pnpm add -g @lincyaw/presmium",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -27,34 +27,41 @@
27
27
  "bin": {
28
28
  "presmium": "./bin/presmium.mjs"
29
29
  },
30
+ "exports": {
31
+ "./site": "./src/site.ts",
32
+ "./package.json": "./package.json"
33
+ },
30
34
  "files": [
31
- "bin"
35
+ "bin",
36
+ "src"
32
37
  ],
33
38
  "dependencies": {
34
39
  "jiti": "^2.7.0",
35
- "@lincyaw/cli": "1.0.0-rc.5",
36
- "@lincyaw/render-notebook": "1.0.0-rc.5",
37
- "@lincyaw/host": "1.0.0-rc.5",
38
- "@lincyaw/kernel": "1.0.0-rc.5",
39
- "@lincyaw/render-slides": "1.0.0-rc.5",
40
- "@lincyaw/addon-assistant": "1.0.0-rc.5",
41
- "@lincyaw/addon-classroom": "1.0.0-rc.5",
42
- "@lincyaw/addon-code": "1.0.0-rc.5",
43
- "@lincyaw/addon-content": "1.0.0-rc.5",
44
- "@lincyaw/addon-exec": "1.0.0-rc.5",
45
- "@lincyaw/addon-exec-local": "1.0.0-rc.5",
46
- "@lincyaw/addon-exec-jupyter": "1.0.0-rc.5",
47
- "@lincyaw/addon-exec-wasi": "1.0.0-rc.5",
48
- "@lincyaw/addon-exec-webgpu": "1.0.0-rc.5",
49
- "@lincyaw/addon-guide": "1.0.0-rc.5",
50
- "@lincyaw/addon-motion": "1.0.0-rc.5",
51
- "@lincyaw/addon-lecture": "1.0.0-rc.5",
52
- "@lincyaw/addon-publish": "1.0.0-rc.5",
53
- "@lincyaw/addon-session": "1.0.0-rc.5",
54
- "@lincyaw/addon-speech": "1.0.0-rc.5",
55
- "@lincyaw/addon-stage": "1.0.0-rc.5",
56
- "@lincyaw/web": "1.0.0-rc.5",
57
- "@lincyaw/viewer": "1.0.0-rc.5",
58
- "create-presmium": "1.0.0-rc.5"
40
+ "@lincyaw/cli": "1.0.0-rc.50",
41
+ "@lincyaw/studio": "0.2.0-rc.49",
42
+ "@lincyaw/kernel": "1.0.0-rc.50",
43
+ "@lincyaw/host": "1.0.0-rc.50",
44
+ "@lincyaw/mcp": "1.0.0-rc.50",
45
+ "@lincyaw/render-notebook": "1.0.0-rc.50",
46
+ "@lincyaw/render-slides": "1.0.0-rc.50",
47
+ "@lincyaw/addon-assistant": "1.0.0-rc.50",
48
+ "@lincyaw/addon-classroom": "1.0.0-rc.50",
49
+ "@lincyaw/addon-code": "1.0.0-rc.50",
50
+ "@lincyaw/addon-exec": "1.0.0-rc.50",
51
+ "@lincyaw/addon-exec-jupyter": "1.0.0-rc.50",
52
+ "@lincyaw/addon-exec-local": "1.0.0-rc.50",
53
+ "@lincyaw/addon-exec-wasi": "1.0.0-rc.50",
54
+ "@lincyaw/addon-content": "1.0.0-rc.50",
55
+ "@lincyaw/addon-exec-webgpu": "1.0.0-rc.50",
56
+ "@lincyaw/addon-guide": "1.0.0-rc.50",
57
+ "@lincyaw/addon-motion": "1.0.0-rc.50",
58
+ "@lincyaw/addon-lecture": "1.0.0-rc.50",
59
+ "@lincyaw/addon-session": "1.0.0-rc.50",
60
+ "@lincyaw/addon-publish": "1.0.0-rc.50",
61
+ "@lincyaw/addon-speech": "1.0.0-rc.50",
62
+ "@lincyaw/web": "1.0.0-rc.50",
63
+ "@lincyaw/viewer": "1.0.0-rc.50",
64
+ "@lincyaw/addon-stage": "1.0.0-rc.50",
65
+ "create-presmium": "1.0.0-rc.50"
59
66
  }
60
67
  }
package/src/site.ts ADDED
@@ -0,0 +1,2 @@
1
+ /** For a site template's own page: playing the site's presentations in frames (`prefetchPresentation`, `whenPresentationReady`). */
2
+ export * from '@lincyaw/web/site'