diff --git a/README_ZH.md b/README_ZH.md deleted file mode 100644 index 24e7352..0000000 --- a/README_ZH.md +++ /dev/null @@ -1,50 +0,0 @@ -

-English | -中文 -

-

wails-template-solid-ts

- -

Wails 的模版,开箱即用的 Vite, Solid, TypeScript 并支持热重载

- -## 使用模版 - -```bash -wails init -n my-wails-solid -t https://github.com/xijaja/wails-template-solid-ts -``` - -## 启动调试 - -在工程目录中执行 `wails dev` 即可启动。 - -如果你想在浏览器中调试,请在另一个终端进入 `frontend` 目录,然后执行 `npm run dev` ,前端开发服务器将在 http://localhost:34115 上运行。 - -## Tailwindcss - -如果你需要使用 tailwindcss 和 postcss ,请进入 `frontend` 目录, -然后执行命令: - -```bash -# 安装 -npm install -D tailwindcss@latest postcss@latest autoprefixer@latest - -# 初始化 tailwind.config.cjs 和 postcss.config.cjs -npx tailwindcss init tailwind.config.cjs -p -``` - -创建 tailwind.css 文件并写入: - -```css -@import "tailwindcss/base"; -@import "tailwindcss/components"; -@import "tailwindcss/utilities"; -``` - -最后,在 `frontend/src/index.tsx` 中引入: - -```tsx -import "./tailwind.css"; -``` - -## 构建 - -给你的项目打包,请执行命令: `wails build` 。 diff --git a/frontend/index.html b/frontend/index.html index 83590ba..75a9398 100644 --- a/frontend/index.html +++ b/frontend/index.html @@ -2,18 +2,21 @@ - - - - - Solid App + + + + + Solid App + + + - -
+ +
- + \ No newline at end of file diff --git a/frontend/src/App.tsx b/frontend/src/App.tsx index 81a8cbd..b867c14 100644 --- a/frontend/src/App.tsx +++ b/frontend/src/App.tsx @@ -1,22 +1,13 @@ +import { Route, HashRouter as Router } from "@solidjs/router"; import type { Component } from "solid-js"; +import { Login } from "./routes/Login"; + const App: Component = () => (
-
-

- Edit src/App.tsx and save to reload. -

- - Learn Solid - - -
+ + +
); diff --git a/frontend/src/index.css b/frontend/src/index.css index b5c61c9..f75cff6 100644 --- a/frontend/src/index.css +++ b/frontend/src/index.css @@ -1,3 +1,9 @@ @tailwind base; @tailwind components; @tailwind utilities; + +html { + font-family: "Inter", sans-serif; + font-optical-sizing: auto; + font-variation-settings: "slnt" 0; +} diff --git a/frontend/src/routes/Login.tsx b/frontend/src/routes/Login.tsx new file mode 100644 index 0000000..1523923 --- /dev/null +++ b/frontend/src/routes/Login.tsx @@ -0,0 +1,40 @@ +export function Login() { + return ( +
+
+

Login

+ + + +
+
+ +
+
+
+ ); +} diff --git a/frontend/tailwind.config.mjs b/frontend/tailwind.config.mjs index c35f2d1..966eec8 100644 --- a/frontend/tailwind.config.mjs +++ b/frontend/tailwind.config.mjs @@ -9,6 +9,39 @@ export default { daisyui, ], daisyui: { - themes: ["black"], + themes: [ + "light", + "dark", + "cupcake", + "bumblebee", + "emerald", + "corporate", + "synthwave", + "retro", + "cyberpunk", + "valentine", + "halloween", + "garden", + "forest", + "aqua", + "lofi", + "pastel", + "fantasy", + "wireframe", + "black", + "luxury", + "dracula", + "cmyk", + "autumn", + "business", + "acid", + "lemonade", + "night", + "coffee", + "winter", + "dim", + "nord", + "sunset", + ], }, };