Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/shgkme/nextcloud-styles-extractor
Nextcloud server global styles for testing and development
https://github.com/shgkme/nextcloud-styles-extractor
nextcloud
Last synced: about 1 month ago
JSON representation
Nextcloud server global styles for testing and development
- Host: GitHub
- URL: https://github.com/shgkme/nextcloud-styles-extractor
- Owner: ShGKme
- License: agpl-3.0
- Created: 2024-05-31T20:31:29.000Z (7 months ago)
- Default Branch: main
- Last Pushed: 2024-11-09T21:55:09.000Z (about 1 month ago)
- Last Synced: 2024-11-09T22:30:32.777Z (about 1 month ago)
- Topics: nextcloud
- Language: CSS
- Homepage:
- Size: 1000 Bytes
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# Nextcloud Server Styles
> Extracted Nextcloud server global styles
- β‘ Zero dependencies
- π² Different branches: `master`, `stable30`, `stable29`
- β `REUSE.toml` included## π₯ Install
```sh
npm i @shgk/nextcloud-styles
```## ποΈ Prerequisites
Requires a bundler with `.css` import support, such as Webpack with `css-loader` ot Vite.
## π§βπ» Usage
Import all styles and themes:
```js
// master
import '@shgk/nextcloud-styles'
// or a specific branch
import '@shgk/nextcloud-styles/master'
import '@shgk/nextcloud-styles/stable30'
import '@shgk/nextcloud-styles/stable29'
```Importing a specific file:
```js
// master
import '@shgk/nextcloud-styles/apps/theming/theme/dark.css'
import '@shgk/nextcloud-styles/core/img/logo/logo.svg'
// or a specific branch
import '@shgk/nextcloud-styles/master/apps/theming/css/default.css'
import '@shgk/nextcloud-styles/stable30/core/css/server.css'
```## π¦ Details
Styles are close to the original. Changes:
- Added `light.plain.css` and `light.dark.css` to be used as server's
```html
```
- Absolute paths in `url()` are changed to relative
- Added `REUSE.toml` for license information
- Added `theme.css` for re-export theming styles including plain style on `prefers-color-scheme`
- Added `index.js` for re-export all styles and `themes.css`Styles structure:
```
ββββBRANCH
ββββapps
β ββββtheming
β ββββcss
β β ββββdefault.css
β ββββimg
β β ββββ...
β ββββtheme
β ββββdark.css
β ββββdark.plain.css
β ββββdark.css
β ββββlight.plain.css
ββββcore
β ββββcss
β β ββββapps.css
β β ββββserver.css
β ββββimg
β ββββ...
ββββdist
β ββββicons.css
ββββREUSE.toml
ββββtheme.css = apps/theming/css/default.css + apps/theming/theme/* with prefers-color-scheme
ββββindex.js = core/css/server.css + core/css/apps.css + theme.css
```Based on awesome [`szaimen/nextcloud-simple-test`](https://github.com/szaimen/nextcloud-easy-test/).
## πΎ Development
Update styles:
```sh
node ./build/extract.js
```## TODO
- [ ] Add high-contrast theme and dyslexia-friendly font
- [ ] Add automatic updates
- [ ] Add custom themes support
- [ ] Add private servers support
- [ ] Improve building performance
- [ ] Remove unneeded images