@weaverclub/render 0.0.2 → 0.0.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.
Files changed (64) hide show
  1. package/dist/entrypoint +0 -0
  2. package/package.json +6 -2
  3. package/.github/workflows/publish.yml +0 -44
  4. package/biome.json +0 -42
  5. package/build.ts +0 -62
  6. package/bun.lock +0 -733
  7. package/bunfig.toml +0 -3
  8. package/ideas.md +0 -11
  9. package/publish.ts +0 -62
  10. package/src/cli/command/renderCommand.ts +0 -112
  11. package/src/cli/entrypoint.ts +0 -25
  12. package/src/core/bundler.ts +0 -180
  13. package/src/core/control/arrayControl.ts +0 -15
  14. package/src/core/control/booleanControl.ts +0 -15
  15. package/src/core/control/control.ts +0 -7
  16. package/src/core/control/controlBuilder.ts +0 -87
  17. package/src/core/control/numberControl.ts +0 -15
  18. package/src/core/control/stringControl.ts +0 -15
  19. package/src/core/control/variantControl.ts +0 -18
  20. package/src/core/css/css.ts +0 -50
  21. package/src/core/css/tailwind.ts +0 -172
  22. package/src/core/html.ts +0 -63
  23. package/src/core/pkg.ts +0 -92
  24. package/src/core/story.ts +0 -52
  25. package/src/core/tsconfig.ts +0 -46
  26. package/src/react/react.ts +0 -2
  27. package/src/react/reactControlBuilder.ts +0 -130
  28. package/src/react/reactStory.ts +0 -36
  29. package/src/server/api/getStories.ts +0 -44
  30. package/src/server/api/renderIframe.ts +0 -66
  31. package/src/server/backend.ts +0 -104
  32. package/src/server/streaming.ts +0 -16
  33. package/src/ui/api.ts +0 -16
  34. package/src/ui/app.tsx +0 -23
  35. package/src/ui/cn.ts +0 -6
  36. package/src/ui/components/appSidebar.tsx +0 -76
  37. package/src/ui/components/button.stories.tsx +0 -32
  38. package/src/ui/components/button.tsx +0 -55
  39. package/src/ui/components/command.tsx +0 -187
  40. package/src/ui/components/contextMenu.tsx +0 -261
  41. package/src/ui/components/dialog.tsx +0 -153
  42. package/src/ui/components/input.tsx +0 -23
  43. package/src/ui/components/inputGroup.tsx +0 -157
  44. package/src/ui/components/kdb.tsx +0 -26
  45. package/src/ui/components/searchCommand.tsx +0 -5
  46. package/src/ui/components/separator.tsx +0 -22
  47. package/src/ui/components/sheet.tsx +0 -131
  48. package/src/ui/components/sidebar.tsx +0 -725
  49. package/src/ui/components/skeleton.tsx +0 -13
  50. package/src/ui/components/spinner.tsx +0 -15
  51. package/src/ui/components/tabButton.tsx +0 -80
  52. package/src/ui/components/tabContent.tsx +0 -20
  53. package/src/ui/components/tabList.tsx +0 -53
  54. package/src/ui/components/textarea.tsx +0 -17
  55. package/src/ui/components/tooltip.tsx +0 -67
  56. package/src/ui/frontend.tsx +0 -68
  57. package/src/ui/hooks/useMobile.ts +0 -23
  58. package/src/ui/index.html +0 -12
  59. package/src/ui/routeTree.gen.ts +0 -35
  60. package/src/ui/routes/__root.tsx +0 -9
  61. package/src/ui/styles.css +0 -123
  62. package/src/ui/tabs.tsx +0 -89
  63. package/tsconfig.json +0 -25
  64. package/tsr.config.json +0 -6
package/dist/entrypoint CHANGED
Binary file
package/package.json CHANGED
@@ -1,8 +1,12 @@
1
1
  {
2
2
  "name": "@weaverclub/render",
3
- "version": "0.0.2",
3
+ "version": "0.0.3",
4
4
  "description": "The simplest way to preview React components",
5
5
  "packageManager": "bun@1.3.5",
6
+ "files": [
7
+ "dist",
8
+ "package.json"
9
+ ],
6
10
  "scripts": {
7
11
  "router:gen": "tsr generate",
8
12
  "router:watch": "tsr watch",
@@ -13,7 +17,7 @@
13
17
  "release": "bun run publish.ts"
14
18
  },
15
19
  "bin": {
16
- "render": "dist/entrypoint"
20
+ "render": "./dist/entrypoint.mjs"
17
21
  },
18
22
  "repository": {
19
23
  "type": "git",
@@ -1,44 +0,0 @@
1
- name: Publish to npm
2
-
3
- on:
4
- push:
5
- tags:
6
- - "v*" # Triggers on tags like v1.0.0, v2.1.3, etc.
7
-
8
- jobs:
9
- publish:
10
- runs-on: ubuntu-latest
11
- environment: prod
12
- permissions:
13
- contents: read
14
- id-token: write # Required for npm provenance
15
-
16
- steps:
17
- - name: Checkout
18
- uses: actions/checkout@v4
19
-
20
- - name: Setup Bun
21
- uses: oven-sh/setup-bun@v2
22
- with:
23
- bun-version: latest
24
-
25
- - name: Install dependencies
26
- run: bun install --frozen-lockfile
27
-
28
- - name: Run tests
29
- run: bun run test --run
30
-
31
- - name: Build
32
- run: bun run build
33
-
34
- - name: Setup Node.js for npm publish
35
- uses: actions/setup-node@v4
36
- with:
37
- node-version: "20"
38
- registry-url: "https://registry.npmjs.org"
39
-
40
- - name: Update npm for trusted publishing
41
- run: npm install -g npm@latest
42
-
43
- - name: Publish to npm
44
- run: npm publish --access public
package/biome.json DELETED
@@ -1,42 +0,0 @@
1
- {
2
- "$schema": "https://biomejs.dev/schemas/2.3.10/schema.json",
3
- "vcs": {
4
- "enabled": false,
5
- "clientKind": "git",
6
- "useIgnoreFile": false
7
- },
8
- "files": {
9
- "ignoreUnknown": false,
10
- "includes": ["**", "!src/**/*.gen.ts"]
11
- },
12
- "formatter": {
13
- "enabled": true,
14
- "indentStyle": "tab"
15
- },
16
- "linter": {
17
- "enabled": true,
18
- "rules": {
19
- "recommended": true
20
- }
21
- },
22
- "css": {
23
- "parser": {
24
- "tailwindDirectives": true
25
- }
26
- },
27
- "javascript": {
28
- "formatter": {
29
- "quoteStyle": "single",
30
- "semicolons": "asNeeded",
31
- "trailingCommas": "none"
32
- }
33
- },
34
- "assist": {
35
- "enabled": true,
36
- "actions": {
37
- "source": {
38
- "organizeImports": "on"
39
- }
40
- }
41
- }
42
- }
package/build.ts DELETED
@@ -1,62 +0,0 @@
1
- // We need to build:
2
- // 1. The UI frontend
3
- // 2. The CLI
4
- // 3. The library
5
-
6
- import { FileSystem } from '@effect/platform'
7
- import { BunContext, BunRuntime } from '@effect/platform-bun'
8
- import tailwind from 'bun-plugin-tailwind'
9
- import { Effect } from 'effect'
10
- import { build as tsdownBuild } from 'tsdown'
11
-
12
- export const buildUI = Effect.tryPromise(() =>
13
- Bun.build({
14
- entrypoints: ['./src/ui/index.html'],
15
- outdir: './dist/ui',
16
- minify: true,
17
- target: 'browser',
18
- sourcemap: 'linked',
19
- plugins: [tailwind]
20
- })
21
- )
22
-
23
- export const buildCLI = Effect.tryPromise(() =>
24
- Bun.build({
25
- entrypoints: ['./src/cli/entrypoint.ts'],
26
- outdir: './dist',
27
- minify: true,
28
- compile: true,
29
- target: 'bun',
30
- sourcemap: 'linked'
31
- })
32
- )
33
-
34
- export const buildLibrary = Effect.tryPromise(() =>
35
- tsdownBuild({
36
- entry: {
37
- index: './src/react/react.ts'
38
- },
39
- outDir: 'dist',
40
- sourcemap: true,
41
- dts: true,
42
- clean: true,
43
- format: ['esm']
44
- })
45
- )
46
-
47
- const cleanFolder = FileSystem.FileSystem.pipe(
48
- Effect.flatMap((fs) =>
49
- fs.remove('./dist', {
50
- recursive: true
51
- })
52
- ),
53
- Effect.ignore
54
- )
55
-
56
- cleanFolder.pipe(
57
- Effect.tap(() => buildLibrary),
58
- Effect.tap(() => buildUI),
59
- Effect.tap(() => buildCLI),
60
- Effect.provide(BunContext.layer),
61
- BunRuntime.runMain
62
- )