Bugfixes and structure for default theme
parent
ad76d5fbdf
commit
53afa29aa4
File diff suppressed because it is too large
Load Diff
|
|
@ -0,0 +1,29 @@
|
|||
{
|
||||
"name": "@librecms/default-theme",
|
||||
"version": "7.0.0",
|
||||
"scripts": {
|
||||
"build": "npm-run-all build:*",
|
||||
"build:mkdir": "shx mkdir -p target/generated-resources/themes/librecms",
|
||||
"build:theme": "shx cp -r src/main/resources/themes/librecms/* target/generated-resources/themes/librecms",
|
||||
"build:js": "webpack",
|
||||
"build:css": "npm-run-all build:css:*",
|
||||
"build:css:librecms": "sass src/main/scss/librecms.scss target/generated-resources/themes/librecms/styles/librecms.css",
|
||||
"build:index": "theme-index-builder target/generated-resources/themes/librecms"
|
||||
},
|
||||
"author": "Jens Pelzetter",
|
||||
"license": "LGPL-3.0-or-later",
|
||||
"devDependencies": {
|
||||
"@types/bootstrap": "^5.1.8",
|
||||
"npm-run-all": "^4.1.5",
|
||||
"sass": "^1.48.0",
|
||||
"shx": "^0.3.4",
|
||||
"ts-loader": "^9.2.6",
|
||||
"typescript": "^4.5.4",
|
||||
"webpack": "^5.66.0",
|
||||
"webpack-cli": "^4.9.1"
|
||||
},
|
||||
"dependencies": {
|
||||
"bootstrap": "^5.1.3",
|
||||
"bootstrap-icons": "^1.7.2"
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,113 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<properties>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<timestamp>${maven.build.timestamp}</timestamp>
|
||||
<maven.build.timestamp.format>yyyy-MM-dd'T'HH:mm:ss'Z'Z</maven.build.timestamp.format>
|
||||
</properties>
|
||||
|
||||
<parent>
|
||||
<groupId>org.libreccm</groupId>
|
||||
<artifactId>libreccm-parent</artifactId>
|
||||
<version>7.0.0-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<groupId>org.librecms</groupId>
|
||||
<artifactId>ccm-cms-default-theme</artifactId>
|
||||
<version>7.0.0-SNAPSHOT</version>
|
||||
<packaging>jar</packaging>
|
||||
|
||||
<name>LibreCMS Default Theme</name>
|
||||
|
||||
<licenses>
|
||||
<license>
|
||||
<name>Lesser GPL 2.1</name>
|
||||
<url>http://www.gnu.org/licenses/old-licenses/lgpl-2.1</url>
|
||||
</license>
|
||||
</licenses>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>org.libreccm</groupId>
|
||||
<artifactId>ccm-static-theme-index-builder</artifactId>
|
||||
<version>7.0.0-SNAPSHOT</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
|
||||
<build>
|
||||
<finalName>ccm-cms-default-theme</finalName>
|
||||
|
||||
<resources>
|
||||
<!-- <resource>
|
||||
<directory>src/main/resources</directory>
|
||||
</resource>
|
||||
<resource>
|
||||
<directory>src/main/typescript</directory>
|
||||
</resource> -->
|
||||
<resource>
|
||||
<directory>${project.build.directory}/generated-resources</directory>
|
||||
</resource>
|
||||
</resources>
|
||||
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>com.github.eirslett</groupId>
|
||||
<artifactId>frontend-maven-plugin</artifactId>
|
||||
<configuration>
|
||||
<installDirectory>../node</installDirectory>
|
||||
</configuration>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>Install node.js and NPM</id>
|
||||
<goals>
|
||||
<goal>install-node-and-npm</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<nodeVersion>v14.17.0</nodeVersion>
|
||||
</configuration>
|
||||
</execution>
|
||||
<execution>
|
||||
<id>npm install</id>
|
||||
<goals>
|
||||
<goal>npm</goal>
|
||||
</goals>
|
||||
</execution>
|
||||
<execution>
|
||||
<id>npm link @libreccm/ccm-static-theme-index-builder</id>
|
||||
<goals>
|
||||
<goal>npm</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<arguments>link @libreccm/ccm-static-theme-index-builder</arguments>
|
||||
</configuration>
|
||||
</execution>
|
||||
<execution>
|
||||
<id>build</id>
|
||||
<goals>
|
||||
<goal>npm</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<arguments>run build</arguments>
|
||||
</configuration>
|
||||
</execution>
|
||||
<execution>
|
||||
<id>npm link</id>
|
||||
<goals>
|
||||
<goal>npm</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<arguments>link</arguments>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
</project>
|
||||
|
|
@ -0,0 +1 @@
|
|||
export {};
|
||||
|
|
@ -0,0 +1,39 @@
|
|||
{
|
||||
"name": "librecms",
|
||||
"type": "freemarker",
|
||||
"master-theme": null,
|
||||
"title": "LibreCMS Default Theme",
|
||||
"description": "The LibreCMS default theme",
|
||||
"template": [],
|
||||
"default-template": null,
|
||||
"mvc-templates": {
|
||||
"default": {
|
||||
"description": {
|
||||
"values": {
|
||||
"value": [
|
||||
{
|
||||
"lang": "en",
|
||||
"value": "Default Template used if no other template fits."
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
"name": "Default Template",
|
||||
"path": "templates/default.html.ftl",
|
||||
"title": {
|
||||
"values": {
|
||||
"value": [
|
||||
{
|
||||
"lang": "en",
|
||||
"value": "Default Template"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"views": {
|
||||
"default": "default",
|
||||
"@default": "default"
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
@import "custom";
|
||||
@import "../../../node_modules/bootstrap/scss/bootstrap"
|
||||
|
|
@ -0,0 +1 @@
|
|||
import bootstrap from "bootstrap";
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
{
|
||||
"compilerOptions": {
|
||||
"allowSyntheticDefaultImports": true,
|
||||
"declaration": true,
|
||||
"lib": ["DOM", "ES2016"],
|
||||
"module": "commonjs",
|
||||
"moduleResolution": "node",
|
||||
"outDir": "scripts",
|
||||
"sourceMap": true,
|
||||
"strict": true,
|
||||
"target": "ES5"
|
||||
},
|
||||
"include": ["src/main/typescript/**/*"]
|
||||
}
|
||||
|
|
@ -0,0 +1,25 @@
|
|||
|
||||
module.exports = {
|
||||
mode: "development",
|
||||
devtool: "source-map",
|
||||
optimization: {
|
||||
chunkIds: false
|
||||
},
|
||||
entry: {
|
||||
librecms: "./src/main/typescript/librecms.ts"
|
||||
},
|
||||
output: {
|
||||
filename: "[name].js",
|
||||
path: __dirname + "/target/generated-resources/themes/librecms/scripts"
|
||||
},
|
||||
resolve: {
|
||||
extensions: [".tsx", ".ts", ".js", ".jsx"],
|
||||
},
|
||||
module: {
|
||||
rules: [
|
||||
// all files with a '.ts' or '.tsx' extension will be handled by 'ts-loader'
|
||||
{ test: /\.tsx?$/, use: ["ts-loader"], exclude: /node_modules/ },
|
||||
],
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -3,6 +3,9 @@
|
|||
"version": "7.0.0",
|
||||
"type": "module",
|
||||
"main": "target/dist/StaticThemeIndexBuilder.js",
|
||||
"bin": {
|
||||
"theme-index-builder": "target/dist/StaticThemeIndexBuilder.js"
|
||||
},
|
||||
"types": "target/dist/StaticThemeIndexBuilder.d.ts",
|
||||
"description": "CLI tool for building the theme-index.json file for static themes.",
|
||||
"author": "Jens Pelzetter",
|
||||
|
|
|
|||
|
|
@ -45,66 +45,69 @@
|
|||
</resource>
|
||||
</resources>
|
||||
|
||||
<plugin>
|
||||
<groupId>com.github.eirslett</groupId>
|
||||
<artifactId>frontend-maven-plugin</artifactId>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>com.github.eirslett</groupId>
|
||||
<artifactId>frontend-maven-plugin</artifactId>
|
||||
|
||||
<configuration>
|
||||
<installDirectory>../node</installDirectory>
|
||||
</configuration>
|
||||
<configuration>
|
||||
<installDirectory>../node</installDirectory>
|
||||
</configuration>
|
||||
|
||||
<executions>
|
||||
<execution>
|
||||
<id>Install node.js and NPM</id>
|
||||
<goals>
|
||||
<goal>install-node-and-npm</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<nodeVersion>v14.17.0</nodeVersion>
|
||||
</configuration>
|
||||
</execution>
|
||||
<execution>
|
||||
<id>npm install</id>
|
||||
<goals>
|
||||
<goal>npm</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<arguments>install</arguments>
|
||||
</configuration>
|
||||
</execution>
|
||||
<execution>
|
||||
<id>build</id>
|
||||
<goals>
|
||||
<goal>npm</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<arguments>run build</arguments>
|
||||
</configuration>
|
||||
</execution>
|
||||
<execution>
|
||||
<id>npm link</id>
|
||||
<goals>
|
||||
<goal>npm</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<arguments>link</arguments>
|
||||
</configuration>
|
||||
</execution>
|
||||
<executions>
|
||||
<execution>
|
||||
<id>Install node.js and NPM</id>
|
||||
<goals>
|
||||
<goal>install-node-and-npm</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<nodeVersion>v14.17.0</nodeVersion>
|
||||
</configuration>
|
||||
</execution>
|
||||
<execution>
|
||||
<id>npm install</id>
|
||||
<goals>
|
||||
<goal>npm</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<arguments>install</arguments>
|
||||
</configuration>
|
||||
</execution>
|
||||
<execution>
|
||||
<id>build</id>
|
||||
<goals>
|
||||
<goal>npm</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<arguments>run build</arguments>
|
||||
</configuration>
|
||||
</execution>
|
||||
<execution>
|
||||
<id>npm link</id>
|
||||
<goals>
|
||||
<goal>npm</goal>
|
||||
</goals>
|
||||
<configuration>
|
||||
<arguments>link</arguments>
|
||||
</configuration>
|
||||
</execution>
|
||||
|
||||
<execution>
|
||||
<id>npm publish</id>
|
||||
<goals>
|
||||
<goal>npm</goal>
|
||||
</goals>
|
||||
<execution>
|
||||
<id>npm publish</id>
|
||||
<goals>
|
||||
<goal>npm</goal>
|
||||
</goals>
|
||||
|
||||
<phase>deploy</phase>
|
||||
<phase>deploy</phase>
|
||||
|
||||
<configuration>
|
||||
<arguments>publish --userconfig ../libreccm.npmrc</arguments>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</plugins>
|
||||
|
||||
<configuration>
|
||||
<arguments>publish --userconfig ../libreccm.npmrc</arguments>
|
||||
</configuration>
|
||||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
</build>
|
||||
|
||||
</project>
|
||||
|
|
@ -1,3 +1,5 @@
|
|||
#!/usr/bin/env node
|
||||
|
||||
import * as path from "path";
|
||||
import * as fs from "fs";
|
||||
import * as fsPromises from "fs/promises";
|
||||
|
|
|
|||
4
pom.xml
4
pom.xml
|
|
@ -57,6 +57,9 @@
|
|||
|
||||
<!-- Simple HTML editor for use in the backend -->
|
||||
<module>ccm-editor</module>
|
||||
|
||||
<!-- Utilities for building themes -->
|
||||
<module>ccm-static-theme-index-builder</module>
|
||||
|
||||
<!-- React.js based editor for PageModels -->
|
||||
<module>ccm-pagemodelseditor</module>
|
||||
|
|
@ -84,6 +87,7 @@
|
|||
<!-- Modules providing themes -->
|
||||
<module>ccm-theme-foundry</module>
|
||||
<module>ccm-theme-ftllibs-devel</module>
|
||||
<module>ccm-cms-default-theme</module>
|
||||
|
||||
<!-- Bundle modules -->
|
||||
<module>ccm-bundle-devel</module>
|
||||
|
|
|
|||
Loading…
Reference in New Issue