Skip to content

Commit 444a811

Browse files
committed
[Release] v1.0.20210402
1 parent 775ddeb commit 444a811

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+6268
-4707
lines changed

.all-shieldsrc

Lines changed: 23 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -266,19 +266,37 @@
266266
"platform": "shields"
267267
},
268268
{
269-
"url": "https://github.com/ptkdev-bot",
269+
"url": "https://github.com/ptkdev-boilerplate?q=svelte",
270270
"color": "#f368e0",
271-
"label": "🤖 Boilerplate",
271+
"label": "👔 Boilerplate",
272+
"message": "Svelte",
273+
"style": "flat",
274+
"logo": "",
275+
"platform": "shields"
276+
},
277+
{
278+
"url": "https://github.com/ptkdev-boilerplate?q=webcomponent",
279+
"color": "#f368e0",
280+
"label": "👔 Boilerplate",
281+
"message": "WebComponents",
282+
"style": "flat",
283+
"logo": "",
284+
"platform": "shields"
285+
},
286+
{
287+
"url": "https://github.com/ptkdev-boilerplate?q=bot",
288+
"color": "#f368e0",
289+
"label": "👔 Boilerplate",
272290
"message": "BOT",
273291
"style": "flat",
274292
"logo": "",
275293
"platform": "shields"
276294
},
277295
{
278-
"url": "hhttps://github.com/ptkdev-boilerplate",
296+
"url": "https://github.com/ptkdev-boilerplate?q=node",
279297
"color": "#f368e0",
280-
"label": "🦄 Boilerplate",
281-
"message": "Website / App",
298+
"label": "👔 Boilerplate",
299+
"message": "Node",
282300
"style": "flat",
283301
"logo": "",
284302
"platform": "shields"

.eslintignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,2 @@
11
/dist
2-
/build
32
/examples

.eslintrc.json renamed to .eslintrc.cjs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
{
1+
module.exports = {
22
"env": {
33
"es6": true,
44
"node": true,
@@ -20,7 +20,8 @@
2020
"tagNamePreference": {
2121
"returns": "return"
2222
}
23-
}
23+
},
24+
"svelte3/typescript": require("typescript")
2425
},
2526
"overrides": [
2627
{
@@ -92,7 +93,7 @@
9293
"no-mixed-spaces-and-tabs": ["error", "smart-tabs"],
9394
"spaced-comment": [2, "always"],
9495
"space-before-blocks": ["error", "always"],
95-
"space-before-function-paren": ["error", "never"],
96+
"space-before-function-paren": "off",
9697
"prefer-template": "error",
9798
"no-useless-concat": "error",
9899
"linebreak-style": ["error", "unix"],
@@ -114,4 +115,4 @@
114115
"jsdoc/require-returns-check": 1,
115116
"jsdoc/require-hyphen-before-param-description": 1
116117
}
117-
}
118+
};

.github/assets/screenshot.png

112 KB
Loading

.gitignore

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@ Thumbs.db
8585
*.apk
8686
*.ap_
8787
*.dex
88+
bin/
8889
gen/
8990
.gradle/
9091
build/
@@ -120,11 +121,8 @@ npm-debug.log
120121

121122
# App #
122123
#######
123-
config.js
124-
config/*.js
125-
configs/*.js
126-
config.ts
127-
config/*.ts
128-
configs/*.ts
124+
/app/configs/config.js
125+
/app/configs/config.ts
126+
/extra
129127
/dist
130128
/build

.npmignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
**/*
22
!/dist/**/*
3+
!/extra/**/*
34
!*.md
45
!package*.json

CHANGELOG.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
1-
# v1.0.20210325 (March 25, 2021)
1+
# v1.0.20210402 (April 02, 2021)
22

33
- First release
44

55
<!-- all-shields/sponsors-badges:START -->
6-
[![Donate Paypal](https://img.shields.io/badge/donate-paypal-005EA6.svg?style=flat&logo=paypal)](https://www.paypal.me/ptkdev) [![Donate Ko-Fi](https://img.shields.io/badge/donate-ko--fi-29abe0.svg?style=flat&logo=ko-fi)](https://ko-fi.com/ptkdev) [![Donate Github Sponsors](https://img.shields.io/badge/donate-sponsors-ea4aaa.svg?style=flat&logo=github)](https://github.com/sponsors/ptkdev) [![Donate Patreon](https://img.shields.io/badge/donate-patreon-F87668.svg?style=flat&logo=patreon)](https://www.patreon.com/ptkdev) [![Donate Bitcoin](https://img.shields.io/badge/donate-35jQmZCy4nsxoMM3QPFrnZePDVhdKaHMRH-E38B29.svg?style=flat&logo=bitcoin)]() [![Donate Ethereum](https://img.shields.io/badge/donate-0x8b8171661bEb032828e82baBb0B5B98Ba8fBEBFc-4E8EE9.svg?style=flat&logo=ethereum)]()
6+
7+
[![Donate Paypal](https://img.shields.io/badge/donate-paypal-005EA6.svg?style=flat&logo=paypal)](https://www.paypal.me/ptkdev) [![Donate Ko-Fi](https://img.shields.io/badge/donate-ko--fi-29abe0.svg?style=flat&logo=ko-fi)](https://ko-fi.com/ptkdev) [![Donate Github Sponsors](https://img.shields.io/badge/donate-sponsors-ea4aaa.svg?style=flat&logo=github)](https://github.com/sponsors/ptkdev) [![Donate Patreon](https://img.shields.io/badge/donate-patreon-F87668.svg?style=flat&logo=patreon)](https://www.patreon.com/ptkdev) [![Donate Bitcoin](https://img.shields.io/badge/donate-35jQmZCy4nsxoMM3QPFrnZePDVhdKaHMRH-E38B29.svg?style=flat&logo=bitcoin)]() [![Donate Ethereum](https://img.shields.io/badge/donate-0x8b8171661bEb032828e82baBb0B5B98Ba8fBEBFc-4E8EE9.svg?style=flat&logo=ethereum)]()
8+
79
<!-- all-shields/sponsors-badges:END -->

README.md

Lines changed: 55 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
1-
# 🚀 svelte-electron-boilerplate
1+
# 🧬 svelte-electron-boilerplate
22

33
<!-- all-shields/header-badges:START -->
4-
[![v1.0.20210325](https://img.shields.io/badge/version-v1.0.20210325-lightgray.svg?style=flat&logo=)](https://github.com/ptkdev-boilerplate/svelte-electron-boilerplate/blob/main/CHANGELOG.md) [![](https://img.shields.io/npm/v/@ptkdev/svelte-electron-boilerplate?color=CC3534&logo=npm)](https://www.npmjs.com/package/@ptkdev/svelte-electron-boilerplate) [![License: MIT](https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat&logo=license)](https://github.com/ptkdev-boilerplate/svelte-electron-boilerplate/blob/main/LICENSE.md) [![Powered By Svelte](https://img.shields.io/badge/powered%20by-svelte-FF3C02.svg?style=flat&logo=svelte)](https://svelte.dev/) [![Language: TypeScript](https://img.shields.io/badge/language-typescript-blue.svg?style=flat&logo=typescript)](https://www.typescriptlang.org/) [![ECMAScript: 2019](https://img.shields.io/badge/ES-9-F7DF1E.svg?style=flat&logo=javascript)](https://github.com/tc39/ecma262) [![Discord Server](https://discordapp.com/api/guilds/383373985666301975/embed.png)](https://discord.ptkdev.io)
4+
5+
[![v1.0.20210402](https://img.shields.io/badge/version-v1.0.20210402-lightgray.svg?style=flat&logo=)](https://github.com/ptkdev-boilerplate/svelte-electron-boilerplate/blob/main/CHANGELOG.md) [![](https://img.shields.io/npm/v/@ptkdev/svelte-electron-boilerplate?color=CC3534&logo=npm)](https://www.npmjs.com/package/@ptkdev/svelte-electron-boilerplate) [![License: MIT](https://img.shields.io/badge/license-MIT-brightgreen.svg?style=flat&logo=license)](https://github.com/ptkdev-boilerplate/svelte-electron-boilerplate/blob/main/LICENSE.md) [![Powered By Svelte](https://img.shields.io/badge/powered%20by-svelte-FF3C02.svg?style=flat&logo=svelte)](https://svelte.dev/) [![Language: TypeScript](https://img.shields.io/badge/language-typescript-blue.svg?style=flat&logo=typescript)](https://www.typescriptlang.org/) [![ECMAScript: 2019](https://img.shields.io/badge/ES-9-F7DF1E.svg?style=flat&logo=javascript)](https://github.com/tc39/ecma262) [![Discord Server](https://discordapp.com/api/guilds/383373985666301975/embed.png)](https://discord.ptkdev.io)
6+
57
<!-- all-shields/header-badges:END -->
68

79
Create a desktop app with this friendly Svelte boilerplate for electron
@@ -11,29 +13,66 @@ Create a desktop app with this friendly Svelte boilerplate for electron
1113
> This project is **free**, **open source** and I try to provide excellent **free support**. Why donate? I work on this project several hours in my spare time and try to keep it up to date and working. **THANK YOU!**
1214
1315
<!-- all-shields/sponsors-badges:START -->
14-
[![Donate Paypal](https://img.shields.io/badge/donate-paypal-005EA6.svg?style=flat&logo=paypal)](https://www.paypal.me/ptkdev) [![Donate Ko-Fi](https://img.shields.io/badge/donate-ko--fi-29abe0.svg?style=flat&logo=ko-fi)](https://ko-fi.com/ptkdev) [![Donate Github Sponsors](https://img.shields.io/badge/donate-sponsors-ea4aaa.svg?style=flat&logo=github)](https://github.com/sponsors/ptkdev) [![Donate Patreon](https://img.shields.io/badge/donate-patreon-F87668.svg?style=flat&logo=patreon)](https://www.patreon.com/ptkdev) [![Donate Bitcoin](https://img.shields.io/badge/donate-35jQmZCy4nsxoMM3QPFrnZePDVhdKaHMRH-E38B29.svg?style=flat&logo=bitcoin)]() [![Donate Ethereum](https://img.shields.io/badge/donate-0x8b8171661bEb032828e82baBb0B5B98Ba8fBEBFc-4E8EE9.svg?style=flat&logo=ethereum)]()
16+
17+
[![Donate Paypal](https://img.shields.io/badge/donate-paypal-005EA6.svg?style=flat&logo=paypal)](https://www.paypal.me/ptkdev) [![Donate Ko-Fi](https://img.shields.io/badge/donate-ko--fi-29abe0.svg?style=flat&logo=ko-fi)](https://ko-fi.com/ptkdev) [![Donate Github Sponsors](https://img.shields.io/badge/donate-sponsors-ea4aaa.svg?style=flat&logo=github)](https://github.com/sponsors/ptkdev) [![Donate Patreon](https://img.shields.io/badge/donate-patreon-F87668.svg?style=flat&logo=patreon)](https://www.patreon.com/ptkdev) [![Donate Bitcoin](https://img.shields.io/badge/donate-35jQmZCy4nsxoMM3QPFrnZePDVhdKaHMRH-E38B29.svg?style=flat&logo=bitcoin)]() [![Donate Ethereum](https://img.shields.io/badge/donate-0x8b8171661bEb032828e82baBb0B5B98Ba8fBEBFc-4E8EE9.svg?style=flat&logo=ethereum)]()
18+
1519
<!-- all-shields/sponsors-badges:END -->
1620

1721
## 📎 Menu
1822

1923
- 💡 [Features](#-features)
24+
- 🚀 [How to use](#-usage)
25+
- 👔 [Screenshot](#-screenshot)
26+
- 📚 [Documentation](#-documentation)
2027
- 🔨 [Developer Mode](#-developer-mode)
2128
- 👨‍💻 [Contributing](#-contributing)
2229
- 🐛 [Known Bugs](https://github.com/ptkdev-boilerplate/svelte-electron-boilerplate/issues?q=is%3Aopen+is%3Aissue+label%3Abug)
2330
- 🍻 Community:
24-
- <img src="https://raw.githubusercontent.com/ptkdev-boilerplate/svelte-electron-boilerplate/main/.github/assets/social_discord.png" height="18px"> [Discord](http://discord.ptkdev.io) ([🇬🇧 English Channel](https://discord.gg/YkMG26f) | [🇮🇹 Italian Channel](https://discord.gg/HFtdBAJ) | [🇵🇱 Polish Channel](https://discord.gg/TV5EXFd))
31+
- <img src="https://raw.githubusercontent.com/ptkdev-boilerplate/node-cli-boilerplate/main/.github/assets/social_discord.png" height="18px"> [Discord](http://discord.ptkdev.io) ([🇬🇧 English Channel](https://discord.gg/jqUSGPKdmA) | [🇮🇹 Italian Channel](https://discord.gg/SJFcbvG6RU) | [🇵🇱 Polish Channel](https://discord.gg/25vg4VFhb7))
2532

2633
## 💡 Features
2734

2835
- [✔️] Easy to use
2936
- [✔️] MIT License
37+
- [✔️] Svelte SPA + Electron Desktop App
38+
- [✔️] Browser sync, auto refresh, auto reload
39+
- [✔️] Dark mode
40+
- [✔️] 100% on Google Speedpage
41+
- [✔️] Friendly boilerplate + Github templates
42+
- [✔️] Powered by svelte framework
43+
- [✔️] Without jQuery depencence
44+
- [✔️] Typescript + TSPaths preconfigured
45+
- [✔️] Userfriendly folders tree
46+
- [✔️] Prettiers and ESLint preconfigured
47+
- [✔️] all-contributors-cli and all-shields-cli preconfigured
48+
- [✔️] JEST Test preconfigured
49+
- [✔️] Full async code
50+
- [✔️] Github and Vscode dotfiles preconfigured
51+
- [✔️] Translations i18n: 🇬🇧 🇮🇹 🇵🇱 (Help me ❤️)
52+
53+
## 👔 Screenshot
54+
55+
[![WebComponent: SvelteWebComponentBoilerplate](https://raw.githubusercontent.com/ptkdev-boilerplate/svelte-electron-boilerplate/main/.github/assets/screenshot.png)](https://raw.githubusercontent.com/ptkdev-boilerplate/svelte-electron-boilerplate/main/.github/assets/screenshot.png)
56+
57+
## 🚀 Usage: Deploy
58+
59+
1. Clone this repository or download [nightly](https://github.com/ptkdev-boilerplate/svelte-electron-boilerplate/archive/nightly.zip), [beta](https://github.com/ptkdev-boilerplate/svelte-electron-boilerplate/archive/beta.zip) or [stable](https://github.com/ptkdev-boilerplate/svelte-electron-boilerplate/archive/main.zip).
60+
2. Run `npm install`
61+
3. For create desktop application insaller (exe, dmg or appImage) run:
62+
63+
- Windows: `npm run build-win` or `npm run build-win-32bit`
64+
- Linux: `npm run build-lnx`
65+
- Mac: `npm run build-mac` (Only on Apple machine)
66+
67+
...or try build all with: `nom run build`. Installers are available in `build` folder.
3068

3169
## 🔨 Developer Mode
3270

3371
1. Clone this repository or download [nightly](https://github.com/ptkdev-boilerplate/svelte-electron-boilerplate/archive/nightly.zip), [beta](https://github.com/ptkdev-boilerplate/svelte-electron-boilerplate/archive/beta.zip) or [stable](https://github.com/ptkdev-boilerplate/svelte-electron-boilerplate/archive/main.zip).
3472
2. Run `npm install`
3573
3. Run `npm run dev`
3674
4. Run `npm run dev:electron`
75+
5. Run `http://localhost:5000`
3776

3877
## 📚 Documentation
3978

@@ -70,19 +109,27 @@ Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/d
70109
## 🦄 Other Projects
71110

72111
<!-- all-shields/projects-badges1:START -->
73-
[![](https://img.shields.io/badge/💻%20My-Portfolio-3498db.svg?style=flat&logo=)](https://ptk.dev/)
112+
113+
[![](https://img.shields.io/badge/💻%20My-Portfolio-3498db.svg?style=flat&logo=)](https://ptk.dev/)
114+
74115
<!-- all-shields/projects-badges1:END -->
75116

76117
<!-- all-shields/projects-badges2:START -->
77-
[![](https://img.shields.io/badge/🦒%20Tools-Node%20Logger-9b59b6.svg?style=flat&logo=)](https://github.com/ptkdev/ptkdev-logger) [![](https://img.shields.io/badge/🦌%20Tools-All%20Shields%20CLI-9b59b6.svg?style=flat&logo=)](https://github.com/ptkdev/all-shields-cli) [![](https://img.shields.io/badge/🖥️%20Tools-Aspect%20Ratio%2021:9-9b59b6.svg?style=flat&logo=)](https://github.com/ptkdev/chrome-extension-aspectratio219) [![](https://img.shields.io/badge/🛡%20Tools-Badges:%20Available%20on-9b59b6.svg?style=flat&logo=)](https://availableon.badge.ptkdev.io/) [![](https://img.shields.io/badge/🐾%20Tools-JSON%20Token%20Replace-9b59b6.svg?style=flat&logo=)](https://github.com/ptkdev/json-token-replace) [![](https://img.shields.io/badge/🐍%20Tools-ESLint:%20snakecasejs-9b59b6.svg?style=flat&logo=)](https://github.com/ptkdev/eslint-plugin-snakecasejs)
118+
119+
[![](https://img.shields.io/badge/🦒%20Tools-Node%20Logger-9b59b6.svg?style=flat&logo=)](https://github.com/ptkdev/ptkdev-logger) [![](https://img.shields.io/badge/🦌%20Tools-All%20Shields%20CLI-9b59b6.svg?style=flat&logo=)](https://github.com/ptkdev/all-shields-cli) [![](https://img.shields.io/badge/🖥️%20Tools-Aspect%20Ratio%2021:9-9b59b6.svg?style=flat&logo=)](https://github.com/ptkdev/chrome-extension-aspectratio219) [![](https://img.shields.io/badge/🛡%20Tools-Badges:%20Available%20on-9b59b6.svg?style=flat&logo=)](https://availableon.badge.ptkdev.io/) [![](https://img.shields.io/badge/🐾%20Tools-JSON%20Token%20Replace-9b59b6.svg?style=flat&logo=)](https://github.com/ptkdev/json-token-replace) [![](https://img.shields.io/badge/🐍%20Tools-ESLint:%20snakecasejs-9b59b6.svg?style=flat&logo=)](https://github.com/ptkdev/eslint-plugin-snakecasejs)
120+
78121
<!-- all-shields/projects-badges2:END -->
79122

80123
<!-- all-shields/projects-badges3:START -->
81-
[![](https://img.shields.io/badge/📸%20WebComponent-Instagram%20Widget-e74c3c.svg?style=flat&logo=)](https://github.com/ptkdev-components/webcomponent-instagram-widget) [![](https://img.shields.io/badge/👑%20WebComponent-My%20Patreon%20Box-e74c3c.svg?style=flat&logo=)](https://github.com/ptkdev-components/webcomponent-patreon-box) [![](https://img.shields.io/badge/🏞%20WebComponent-Carousel%20Slideshow-e74c3c.svg?style=flat&logo=)](https://github.com/ptkdev-components/webcomponent-carousel-slideshow)
124+
125+
[![](https://img.shields.io/badge/📸%20WebComponent-Instagram%20Widget-e74c3c.svg?style=flat&logo=)](https://github.com/ptkdev-components/webcomponent-instagram-widget) [![](https://img.shields.io/badge/👑%20WebComponent-My%20Patreon%20Box-e74c3c.svg?style=flat&logo=)](https://github.com/ptkdev-components/webcomponent-patreon-box) [![](https://img.shields.io/badge/🏞%20WebComponent-Carousel%20Slideshow-e74c3c.svg?style=flat&logo=)](https://github.com/ptkdev-components/webcomponent-carousel-slideshow)
126+
82127
<!-- all-shields/projects-badges3:END -->
83128

84129
<!-- all-shields/projects-badges4:START -->
85-
[![](https://img.shields.io/badge/🎨%20Themes-VSCode-f1c40f.svg?style=flat&logo=)](https://github.com/ptkdev/vscode-theme-dark-blood) [![](https://img.shields.io/badge/📚%20Bot-GameBookChat-34495e.svg?style=flat&logo=)](https://t.me/gamebookchatbot) [![](https://img.shields.io/badge/🤖%20Boilerplate-BOT-f368e0.svg?style=flat&logo=)](https://github.com/ptkdev-bot) [![](https://img.shields.io/badge/🦄%20Boilerplate-Website%20/%20App-f368e0.svg?style=flat&logo=)](hhttps://github.com/ptkdev-boilerplate) [![](https://img.shields.io/badge/💅%20App-Me%20in%20Gifs-2ecc71.svg?style=flat&logo=)](https://meingifs.pics/) [![](https://img.shields.io/badge/📱%20App-Stickers-2ecc71.svg?style=flat&logo=)](https://github.com/ptkdev/ptkdev-stickers#-install-free)
130+
131+
[![](https://img.shields.io/badge/🎨%20Themes-VSCode-f1c40f.svg?style=flat&logo=)](https://github.com/ptkdev/vscode-theme-dark-blood) [![](https://img.shields.io/badge/📚%20Bot-GameBookChat-34495e.svg?style=flat&logo=)](https://t.me/gamebookchatbot) [![](https://img.shields.io/badge/👔%20Boilerplate-Svelte-f368e0.svg?style=flat&logo=)](https://github.com/ptkdev-boilerplate?q=svelte) [![](https://img.shields.io/badge/👔%20Boilerplate-WebComponents-f368e0.svg?style=flat&logo=)](https://github.com/ptkdev-boilerplate?q=webcomponent) [![](https://img.shields.io/badge/👔%20Boilerplate-BOT-f368e0.svg?style=flat&logo=)](https://github.com/ptkdev-boilerplate?q=bot) [![](https://img.shields.io/badge/👔%20Boilerplate-Node-f368e0.svg?style=flat&logo=)](https://github.com/ptkdev-boilerplate?q=node) [![](https://img.shields.io/badge/💅%20App-Me%20in%20Gifs-2ecc71.svg?style=flat&logo=)](https://meingifs.pics/) [![](https://img.shields.io/badge/📱%20App-Stickers-2ecc71.svg?style=flat&logo=)](https://github.com/ptkdev/ptkdev-stickers#-install-free)
132+
86133
<!-- all-shields/projects-badges4:END -->
87134

88135
## 💫 License
Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
/**
2+
* Dark Mode SCSS
3+
* =====================
4+
*
5+
* @contributors: Patryk Rzucidło [@ptkdev] <support@ptkdev.io> (https://ptk.dev)
6+
*
7+
* @license: MIT License
8+
*
9+
*/
10+
#app.darkmode {
11+
color: white;
12+
background: black;
13+
background-color: black;
14+
15+
body::-webkit-scrollbar {
16+
width: 0.4em;
17+
}
18+
19+
body::-webkit-scrollbar-track {
20+
box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
21+
}
22+
23+
body::-webkit-scrollbar-thumb {
24+
background-color: rgb(51, 50, 50);
25+
outline: 1px solid rgb(4, 6, 7);
26+
}
27+
28+
.switch[type="checkbox"]:focus + label::after,
29+
.switch[type="checkbox"]:focus + label::before,
30+
.switch[type="checkbox"]:focus + label:after,
31+
.switch[type="checkbox"]:focus + label:before {
32+
outline: none;
33+
}
34+
35+
a {
36+
color: white;
37+
}
38+
39+
.navbar,
40+
.footer,
41+
.navbar-dropdown,
42+
.navbar-dropdown,
43+
a.navbar-link,
44+
a.navbar-item,
45+
a.navbar-item:focus,
46+
a.navbar-link:focus-within,
47+
a.navbar-item:focus-within,
48+
a.navbar-item.is-active,
49+
.is-primary {
50+
color: white;
51+
background: black;
52+
background-color: black;
53+
background-image: none;
54+
}
55+
56+
.navbar-link:focus,
57+
a.navbar-item:hover,
58+
a.navbar-link:focus,
59+
a.navbar-link:hover {
60+
background: darkslategray;
61+
background-color: darkslategray;
62+
background-image: none;
63+
}
64+
65+
.hero.is-primary {
66+
background-image: linear-gradient(141deg, black 0%, rgb(35, 59, 59) 50%, black 100%);
67+
}
68+
}
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
<script lang="ts">
2+
/**
3+
* Dark Mode HTML
4+
* =====================
5+
*
6+
* @contributors: Patryk Rzucidło [@ptkdev] <support@ptkdev.io> (https://ptk.dev)
7+
*
8+
* @license: MIT License
9+
*
10+
*/
11+
import { onMount } from "svelte";
12+
import { darkModeToggle, darkModeDetect, darkmode } from "./darkmode";
13+
14+
let checked = darkmode;
15+
16+
onMount(async () => {
17+
checked = darkModeDetect();
18+
});
19+
</script>
20+
21+
<div class="field">
22+
<input id="dark-mode" type="checkbox" name="dark-mode" class="switch" on:click={() => darkModeToggle()} {checked} />
23+
<label for="dark-mode" />
24+
</div>

0 commit comments

Comments
 (0)