opentwig 1.1.0 → 1.1.2
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/AGENTS.md +49 -200
- package/package.json +2 -3
- package/src/live-ui/editor.js +1 -0
- package/src/live-ui/index.html +94 -0
- package/src/live-ui/sidebar.js +2 -0
- package/src/live-ui/styles.css +578 -0
- package/src/utils/favicon.js +20 -0
- package/src/utils/loadConfig.js +3 -1
- package/src/utils/setupWatcher.js +2 -2
- package/src/utils/startLiveServer.js +11 -8
- package/theme/default/index.js +2 -0
- package/vitest.config.js +19 -10
- package/website/README.md +42 -0
- package/website/components.json +16 -0
- package/website/eslint.config.js +36 -0
- package/website/package-lock.json +4136 -0
- package/website/package.json +41 -0
- package/website/shadcn-svelte.md +118 -0
- package/website/src/app.d.ts +13 -0
- package/website/src/app.html +11 -0
- package/website/src/lib/assets/favicon.svg +4 -0
- package/website/src/lib/components/ui/badge/badge.svelte +50 -0
- package/website/src/lib/components/ui/badge/index.ts +2 -0
- package/website/src/lib/components/ui/button/button.svelte +82 -0
- package/website/src/lib/components/ui/button/index.ts +17 -0
- package/website/src/lib/components/ui/card/card-action.svelte +20 -0
- package/website/src/lib/components/ui/card/card-content.svelte +15 -0
- package/website/src/lib/components/ui/card/card-description.svelte +20 -0
- package/website/src/lib/components/ui/card/card-footer.svelte +20 -0
- package/website/src/lib/components/ui/card/card-header.svelte +23 -0
- package/website/src/lib/components/ui/card/card-title.svelte +20 -0
- package/website/src/lib/components/ui/card/card.svelte +23 -0
- package/website/src/lib/components/ui/card/index.ts +25 -0
- package/website/src/lib/components/ui/separator/index.ts +7 -0
- package/website/src/lib/components/ui/separator/separator.svelte +21 -0
- package/website/src/lib/components/ui/tooltip/index.ts +19 -0
- package/website/src/lib/components/ui/tooltip/tooltip-content.svelte +52 -0
- package/website/src/lib/components/ui/tooltip/tooltip-portal.svelte +7 -0
- package/website/src/lib/components/ui/tooltip/tooltip-provider.svelte +7 -0
- package/website/src/lib/components/ui/tooltip/tooltip-trigger.svelte +7 -0
- package/website/src/lib/components/ui/tooltip/tooltip.svelte +7 -0
- package/website/src/lib/index.ts +1 -0
- package/website/src/lib/utils.ts +13 -0
- package/website/src/routes/+layout.svelte +23 -0
- package/website/src/routes/+page.server.ts +82 -0
- package/website/src/routes/+page.svelte +892 -0
- package/website/src/routes/layout.css +199 -0
- package/website/static/live-editor.png +0 -0
- package/website/static/robots.txt +3 -0
- package/website/static/theme-colorful.png +0 -0
- package/website/static/theme-dark.png +0 -0
- package/website/static/theme-default.png +0 -0
- package/website/static/theme-minimal.png +0 -0
- package/website/svelte.config.js +31 -0
- package/website/vite.config.ts +5 -0
- package/test-og.js +0 -40
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
# sv
|
|
2
|
+
|
|
3
|
+
Everything you need to build a Svelte project, powered by [`sv`](https://github.com/sveltejs/cli).
|
|
4
|
+
|
|
5
|
+
## Creating a project
|
|
6
|
+
|
|
7
|
+
If you're seeing this, you've probably already done this step. Congrats!
|
|
8
|
+
|
|
9
|
+
```sh
|
|
10
|
+
# create a new project
|
|
11
|
+
npx sv create my-app
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
To recreate this project with the same configuration:
|
|
15
|
+
|
|
16
|
+
```sh
|
|
17
|
+
# recreate this project
|
|
18
|
+
npx sv create --template minimal --types ts --add eslint tailwindcss="plugins:typography" sveltekit-adapter="adapter:static" --install npm website
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Developing
|
|
22
|
+
|
|
23
|
+
Once you've created a project and installed dependencies with `npm install` (or `pnpm install` or `yarn`), start a development server:
|
|
24
|
+
|
|
25
|
+
```sh
|
|
26
|
+
npm run dev
|
|
27
|
+
|
|
28
|
+
# or start the server and open the app in a new browser tab
|
|
29
|
+
npm run dev -- --open
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
## Building
|
|
33
|
+
|
|
34
|
+
To create a production version of your app:
|
|
35
|
+
|
|
36
|
+
```sh
|
|
37
|
+
npm run build
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
You can preview the production build with `npm run preview`.
|
|
41
|
+
|
|
42
|
+
> To deploy your app, you may need to install an [adapter](https://svelte.dev/docs/kit/adapters) for your target environment.
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://shadcn-svelte.com/schema.json",
|
|
3
|
+
"tailwind": {
|
|
4
|
+
"css": "src/routes/layout.css",
|
|
5
|
+
"baseColor": "slate"
|
|
6
|
+
},
|
|
7
|
+
"aliases": {
|
|
8
|
+
"components": "$lib/components",
|
|
9
|
+
"utils": "$lib/utils",
|
|
10
|
+
"ui": "$lib/components/ui",
|
|
11
|
+
"hooks": "$lib/hooks",
|
|
12
|
+
"lib": "$lib"
|
|
13
|
+
},
|
|
14
|
+
"typescript": true,
|
|
15
|
+
"registry": "https://shadcn-svelte.com/registry"
|
|
16
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import path from 'node:path';
|
|
2
|
+
import { includeIgnoreFile } from '@eslint/compat';
|
|
3
|
+
import js from '@eslint/js';
|
|
4
|
+
import svelte from 'eslint-plugin-svelte';
|
|
5
|
+
import { defineConfig } from 'eslint/config';
|
|
6
|
+
import globals from 'globals';
|
|
7
|
+
import ts from 'typescript-eslint';
|
|
8
|
+
import svelteConfig from './svelte.config.js';
|
|
9
|
+
|
|
10
|
+
const gitignorePath = path.resolve(import.meta.dirname, '.gitignore');
|
|
11
|
+
|
|
12
|
+
export default defineConfig(
|
|
13
|
+
includeIgnoreFile(gitignorePath),
|
|
14
|
+
js.configs.recommended,
|
|
15
|
+
...ts.configs.recommended,
|
|
16
|
+
...svelte.configs.recommended,
|
|
17
|
+
{
|
|
18
|
+
languageOptions: { globals: { ...globals.browser, ...globals.node } },
|
|
19
|
+
rules: {
|
|
20
|
+
// typescript-eslint strongly recommend that you do not use the no-undef lint rule on TypeScript projects.
|
|
21
|
+
// see: https://typescript-eslint.io/troubleshooting/faqs/eslint/#i-get-errors-from-the-no-undef-rule-about-global-variables-not-being-defined-even-though-there-are-no-typescript-errors
|
|
22
|
+
"no-undef": 'off'
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
files: ['**/*.svelte', '**/*.svelte.ts', '**/*.svelte.js'],
|
|
27
|
+
languageOptions: {
|
|
28
|
+
parserOptions: {
|
|
29
|
+
projectService: true,
|
|
30
|
+
extraFileExtensions: ['.svelte'],
|
|
31
|
+
parser: ts.parser,
|
|
32
|
+
svelteConfig
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
);
|