diff --git a/.gitignore b/.gitignore
index 620cdae..918ee2a 100644
--- a/.gitignore
+++ b/.gitignore
@@ -158,5 +158,69 @@ venv.bak/
# mypy
.mypy_cache/
+### Node template
+# Logs
+logs
+*.log
+npm-debug.log*
+yarn-debug.log*
+yarn-error.log*
+
+# Runtime data
+pids
+*.pid
+*.seed
+*.pid.lock
+
+# Directory for instrumented libs generated by jscoverage/JSCover
+lib-cov
+
+# Coverage directory used by tools like istanbul
+coverage
+
+# nyc test coverage
+.nyc_output
+
+# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
+.grunt
+
+# Bower dependency directory (https://bower.io/)
+bower_components
+
+# node-waf configuration
+.lock-wscript
+
+# Compiled binary addons (https://nodejs.org/api/addons.html)
+build/Release
+
+# Dependency directories
+node_modules/
+jspm_packages/
+
+# TypeScript v1 declaration files
+typings/
+
+# Optional npm cache directory
+.npm
+
+# Optional eslint cache
+.eslintcache
+
+# Optional REPL history
+.node_repl_history
+
+# Output of 'npm pack'
+*.tgz
+
+# Yarn Integrity file
+.yarn-integrity
+
+# dotenv environment variables file
+.env
+
+# next.js build output
+.next
+
+### Custom
polls
tmp
diff --git a/.idea/watcherTasks.xml b/.idea/watcherTasks.xml
new file mode 100644
index 0000000..fb0d65a
--- /dev/null
+++ b/.idea/watcherTasks.xml
@@ -0,0 +1,4 @@
+
+
+
+
\ No newline at end of file
diff --git a/bookmarks/styles/base.scss b/bookmarks/styles/base.scss
new file mode 100644
index 0000000..4f21edc
--- /dev/null
+++ b/bookmarks/styles/base.scss
@@ -0,0 +1 @@
+@import "../../node_modules/spectre.css/src/spectre";
diff --git a/bookmarks/templates/bookmarks/index.html b/bookmarks/templates/bookmarks/index.html
index 05c2e87..6f3d80f 100644
--- a/bookmarks/templates/bookmarks/index.html
+++ b/bookmarks/templates/bookmarks/index.html
@@ -4,12 +4,14 @@
{% block content %}
diff --git a/bookmarks/templates/bookmarks/layout.html b/bookmarks/templates/bookmarks/layout.html
index 1ccffcf..473e46d 100644
--- a/bookmarks/templates/bookmarks/layout.html
+++ b/bookmarks/templates/bookmarks/layout.html
@@ -1,8 +1,13 @@
+{% load static %}
+{% load sass_tags %}
+
linkdings
+ {# Include SASS styles, files are resolved from bookmarks/styles #}
+
diff --git a/package-lock.json b/package-lock.json
new file mode 100644
index 0000000..f2b8457
--- /dev/null
+++ b/package-lock.json
@@ -0,0 +1,13 @@
+{
+ "name": "linkdings",
+ "version": "1.0.0",
+ "lockfileVersion": 1,
+ "requires": true,
+ "dependencies": {
+ "spectre.css": {
+ "version": "0.5.8",
+ "resolved": "https://registry.npmjs.org/spectre.css/-/spectre.css-0.5.8.tgz",
+ "integrity": "sha512-3N4WocWY+Dl6b3e5v3nsZYyp+VSDcBfGDzyyHw/H78ie9BoAhHkxmrhLxo9y8RadxYzVrPjfPdlev3hXEUzR2w=="
+ }
+ }
+}
diff --git a/package.json b/package.json
new file mode 100644
index 0000000..0bd3618
--- /dev/null
+++ b/package.json
@@ -0,0 +1,23 @@
+{
+ "name": "linkdings",
+ "version": "1.0.0",
+ "description": "",
+ "main": "index.js",
+ "scripts": {
+ "test": "echo \"Error: no test specified\" && exit 1"
+ },
+ "repository": {
+ "type": "git",
+ "url": "git+https://github.com/sissbruecker/linkdings.git"
+ },
+ "keywords": [],
+ "author": "",
+ "license": "ISC",
+ "bugs": {
+ "url": "https://github.com/sissbruecker/linkdings/issues"
+ },
+ "homepage": "https://github.com/sissbruecker/linkdings#readme",
+ "dependencies": {
+ "spectre.css": "^0.5.8"
+ }
+}
diff --git a/requirements.txt b/requirements.txt
index 4a8de07..b9f9146 100644
--- a/requirements.txt
+++ b/requirements.txt
@@ -2,10 +2,17 @@ beautifulsoup4==4.7.1
certifi==2019.6.16
chardet==3.0.4
Django==2.2.2
+django-appconf==1.0.3
+django-compressor==2.3
django-picklefield==2.0
+django-sass-processor==0.7.3
idna==2.8
+libsass==0.19.2
pytz==2019.1
+rcssmin==1.0.6
requests==2.22.0
+rjsmin==1.1.0
+six==1.12.0
soupsieve==1.9.2
sqlparse==0.3.0
urllib3==1.25.3
diff --git a/siteroot/settings.py b/siteroot/settings.py
index feb20e0..3c47354 100644
--- a/siteroot/settings.py
+++ b/siteroot/settings.py
@@ -15,7 +15,6 @@ import os
# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
-
# Quick-start development settings - unsuitable for production
# See https://docs.djangoproject.com/en/2.2/howto/deployment/checklist/
@@ -27,7 +26,6 @@ DEBUG = True
ALLOWED_HOSTS = []
-
# Application definition
INSTALLED_APPS = [
@@ -38,6 +36,7 @@ INSTALLED_APPS = [
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
+ 'sass_processor',
]
MIDDLEWARE = [
@@ -70,7 +69,6 @@ TEMPLATES = [
WSGI_APPLICATION = 'siteroot.wsgi.application'
-
# Database
# https://docs.djangoproject.com/en/2.2/ref/settings/#databases
@@ -81,7 +79,6 @@ DATABASES = {
}
}
-
# Password validation
# https://docs.djangoproject.com/en/2.2/ref/settings/#auth-password-validators
@@ -100,7 +97,6 @@ AUTH_PASSWORD_VALIDATORS = [
},
]
-
# Internationalization
# https://docs.djangoproject.com/en/2.2/topics/i18n/
@@ -114,8 +110,23 @@ USE_L10N = True
USE_TZ = True
-
# Static files (CSS, JavaScript, Images)
# https://docs.djangoproject.com/en/2.2/howto/static-files/
STATIC_URL = '/static/'
+
+# Location where generated CSS files are saved
+SASS_PROCESSOR_ROOT = os.path.join(BASE_DIR, 'bookmarks', 'static', 'build')
+
+# Add SASS preprocessor finder to resolve generated CSS
+STATICFILES_FINDERS = [
+ 'django.contrib.staticfiles.finders.FileSystemFinder',
+ 'django.contrib.staticfiles.finders.AppDirectoriesFinder',
+ 'sass_processor.finders.CssFinder',
+]
+
+# Include SASS styles into static path, otherwise they can not be found by the SASS preprocessor
+STATICFILES_DIRS = [
+ os.path.join(BASE_DIR, 'bookmarks', 'styles'),
+]
+