From 4d6f85147be37e3a6a38faa705cccf408ac8835e Mon Sep 17 00:00:00 2001 From: Julian Gojani Date: Sat, 7 Nov 2020 18:43:32 +0100 Subject: [PATCH 01/42] Added sidenav collapsable menu --- src/assets/docs/structure.js | 135 +++++++++++++++++++++++++++-- src/assets/scss/app.scss | 2 +- src/components/Navigation.vue | 42 ++++----- src/components/NavigationEntry.vue | 65 ++++++++++++++ 4 files changed, 211 insertions(+), 33 deletions(-) create mode 100644 src/components/NavigationEntry.vue diff --git a/src/assets/docs/structure.js b/src/assets/docs/structure.js index a91232d..be6aaa8 100644 --- a/src/assets/docs/structure.js +++ b/src/assets/docs/structure.js @@ -4,10 +4,10 @@ export default { content: require("./index.md").default, children: [ { - "name": "orm", - "title": "ORM", - "content": require("./orm/index.md").default, - "children": [ + name: "orm", + title: "ORM", + content: require("./orm/index.md").default, + children: [ { "name": "getting-started", "title": "Getting Started", @@ -16,7 +16,132 @@ export default { { "name": "query-dsl", "title": "Query DSL", - "content": require("./orm/query-dsl.md").default + "content": require("./orm/query-dsl.md").default, + children: [ + { + "name": "getting-started", + "title": "Getting Started", + "content": require("./orm/getting-started.md").default + } + ] + }, + { + "name": "soft-deletes", + "title": "Soft-Deletes", + "content": require("./orm/soft-deletes.md").default + }, + { + "name": "config", + "title": "ORMConfig", + "content": require("./orm/config.md").default + }, + { + "name": "migrations", + "title": "Migrations", + "content": require("./orm/migrations.md").default + }, + { + "name": "observer", + "title": "Observer", + "content": require("./orm/observer.md").default + }, + { + "name": "dates", + "title": "Auto-Dates", + "content": require("./orm/dates.md").default + }, + { + "name": "type-mapping", + "title": "Type Mapping", + "content": require("./orm/type-mapping.md").default + }, + { + "name": "table-and-column-options", + "title": "Table and Column Options", + "content": require("./orm/table-and-column-options.md").default + } + ] + }, + { + name: "test1", + title: "Test1", + content: require("./orm/index.md").default, + children: [ + { + "name": "getting-started", + "title": "Getting Started", + "content": require("./orm/getting-started.md").default + }, + { + "name": "query-dsl", + "title": "Query DSL", + "content": require("./orm/query-dsl.md").default, + children: [ + { + "name": "getting-started", + "title": "Getting Started", + "content": require("./orm/getting-started.md").default + } + ] + }, + { + "name": "soft-deletes", + "title": "Soft-Deletes", + "content": require("./orm/soft-deletes.md").default + }, + { + "name": "config", + "title": "ORMConfig", + "content": require("./orm/config.md").default + }, + { + "name": "migrations", + "title": "Migrations", + "content": require("./orm/migrations.md").default + }, + { + "name": "observer", + "title": "Observer", + "content": require("./orm/observer.md").default + }, + { + "name": "dates", + "title": "Auto-Dates", + "content": require("./orm/dates.md").default + }, + { + "name": "type-mapping", + "title": "Type Mapping", + "content": require("./orm/type-mapping.md").default + }, + { + "name": "table-and-column-options", + "title": "Table and Column Options", + "content": require("./orm/table-and-column-options.md").default + } + ] + }, + { + name: "test2", + title: "Test2", + content: require("./orm/index.md").default, + children: [ + { + "name": "getting-started", + "title": "Getting Started", + "content": require("./orm/getting-started.md").default + }, + { + "name": "query-dsl", + "title": "Query DSL", + "content": require("./orm/query-dsl.md").default, + children: [ + { + "name": "getting-started", + "title": "Getting Started", + "content": require("./orm/getting-started.md").default + } + ] }, { "name": "soft-deletes", diff --git a/src/assets/scss/app.scss b/src/assets/scss/app.scss index 8b734dd..3961f52 100644 --- a/src/assets/scss/app.scss +++ b/src/assets/scss/app.scss @@ -26,7 +26,7 @@ html { font-size: 21px; code { - background: #00000011; + background: #262B390F; border-radius: 5px; padding: 0px 4px; } diff --git a/src/components/Navigation.vue b/src/components/Navigation.vue index e9538f3..d9bf638 100644 --- a/src/components/Navigation.vue +++ b/src/components/Navigation.vue @@ -1,5 +1,5 @@ @@ -100,24 +105,7 @@ export default { width: 300px; height: 100%; top: 71.1px; - - .sidenav-entry, - .sidenav-entry:visited { - text-decoration: none; - color: #434343; - display: block; - padding: 7px 10px; - font-weight: 600; - transition: 0.3s; - font-size: 18px; - &.selected { - color: #60A8FD; - background: #60A8FD22; - } - &:hover { - color: #60A8FD; - background: #60A8FD11; - } - } + overflow: auto; + } \ No newline at end of file diff --git a/src/components/NavigationEntry.vue b/src/components/NavigationEntry.vue new file mode 100644 index 0000000..bb78ef4 --- /dev/null +++ b/src/components/NavigationEntry.vue @@ -0,0 +1,65 @@ + + + \ No newline at end of file From 16da883ecc2f3cd29ad88f01b4aca0fefe1e25cf Mon Sep 17 00:00:00 2001 From: Julian Gojani Date: Sat, 7 Nov 2020 20:51:18 +0100 Subject: [PATCH 02/42] Changed soft-deletes.md --- src/assets/docs/orm/soft-deletes.md | 2 +- src/assets/docs/structure.js | 118 ---------------------------- 2 files changed, 1 insertion(+), 119 deletions(-) diff --git a/src/assets/docs/orm/soft-deletes.md b/src/assets/docs/orm/soft-deletes.md index 5ef90b8..0218208 100644 --- a/src/assets/docs/orm/soft-deletes.md +++ b/src/assets/docs/orm/soft-deletes.md @@ -2,7 +2,7 @@ Soft-Deletes are a concept that describes marking certain objects as "deleted" instead of actually deleting them in case you still need to access them at a later point. We implemented soft-deletes using a timestamp field that gets set to the current date and time on deletion. Whenever you query on a repository with soft-deletes enabled the deleted entries are automatically getting filtered out in the query. ## Usage -In order to enable soft-deletes for a model you need to give it the `@SoftDelete` annotation. This will by default use the field "deletedAt" as soft-delete field but you can also give the field name as a parameter to the annotation. +In order to enable soft-deletes for a model you need to give it the `@SoftDelete` annotation. This will by default use the field "deletedAt" as soft-delete field but you can also give the field name as a parameter to the annotation. You can also set `expiryMode` to true if you want to check if the deletion-timestamp is in the past. ```java @SoftDelete class User extends Model { diff --git a/src/assets/docs/structure.js b/src/assets/docs/structure.js index be6aaa8..f876da4 100644 --- a/src/assets/docs/structure.js +++ b/src/assets/docs/structure.js @@ -61,124 +61,6 @@ export default { "content": require("./orm/table-and-column-options.md").default } ] - }, - { - name: "test1", - title: "Test1", - content: require("./orm/index.md").default, - children: [ - { - "name": "getting-started", - "title": "Getting Started", - "content": require("./orm/getting-started.md").default - }, - { - "name": "query-dsl", - "title": "Query DSL", - "content": require("./orm/query-dsl.md").default, - children: [ - { - "name": "getting-started", - "title": "Getting Started", - "content": require("./orm/getting-started.md").default - } - ] - }, - { - "name": "soft-deletes", - "title": "Soft-Deletes", - "content": require("./orm/soft-deletes.md").default - }, - { - "name": "config", - "title": "ORMConfig", - "content": require("./orm/config.md").default - }, - { - "name": "migrations", - "title": "Migrations", - "content": require("./orm/migrations.md").default - }, - { - "name": "observer", - "title": "Observer", - "content": require("./orm/observer.md").default - }, - { - "name": "dates", - "title": "Auto-Dates", - "content": require("./orm/dates.md").default - }, - { - "name": "type-mapping", - "title": "Type Mapping", - "content": require("./orm/type-mapping.md").default - }, - { - "name": "table-and-column-options", - "title": "Table and Column Options", - "content": require("./orm/table-and-column-options.md").default - } - ] - }, - { - name: "test2", - title: "Test2", - content: require("./orm/index.md").default, - children: [ - { - "name": "getting-started", - "title": "Getting Started", - "content": require("./orm/getting-started.md").default - }, - { - "name": "query-dsl", - "title": "Query DSL", - "content": require("./orm/query-dsl.md").default, - children: [ - { - "name": "getting-started", - "title": "Getting Started", - "content": require("./orm/getting-started.md").default - } - ] - }, - { - "name": "soft-deletes", - "title": "Soft-Deletes", - "content": require("./orm/soft-deletes.md").default - }, - { - "name": "config", - "title": "ORMConfig", - "content": require("./orm/config.md").default - }, - { - "name": "migrations", - "title": "Migrations", - "content": require("./orm/migrations.md").default - }, - { - "name": "observer", - "title": "Observer", - "content": require("./orm/observer.md").default - }, - { - "name": "dates", - "title": "Auto-Dates", - "content": require("./orm/dates.md").default - }, - { - "name": "type-mapping", - "title": "Type Mapping", - "content": require("./orm/type-mapping.md").default - }, - { - "name": "table-and-column-options", - "title": "Table and Column Options", - "content": require("./orm/table-and-column-options.md").default - } - ] } ] } \ No newline at end of file From 99c81cceb2b072c86d1465ea934a993776b2b150 Mon Sep 17 00:00:00 2001 From: Julian Gojani Date: Sat, 7 Nov 2020 23:30:38 +0100 Subject: [PATCH 03/42] Added some structure as template --- deploy.sh | 25 ++++++++ src/assets/docs/structure.js | 114 +++++++++++++++++++++++++--------- src/components/Navigation.vue | 2 +- 3 files changed, 110 insertions(+), 31 deletions(-) create mode 100644 deploy.sh diff --git a/deploy.sh b/deploy.sh new file mode 100644 index 0000000..e31934d --- /dev/null +++ b/deploy.sh @@ -0,0 +1,25 @@ +#!/usr/bin/env sh + +# abort on errors +set -e + +# build +npm run build + +# navigate into the build output directory +cd dist + +# if you are deploying to a custom domain +# echo 'www.example.com' > CNAME + +git init +git add -A +git commit -m 'deploy' + +# if you are deploying to https://.github.io +# git push -f git@github.com:/.github.io.git master + +# if you are deploying to https://.github.io/ +git push -f git@github.com:javawebstack/docs.git master:gh-pages + +cd - \ No newline at end of file diff --git a/src/assets/docs/structure.js b/src/assets/docs/structure.js index f876da4..ace9897 100644 --- a/src/assets/docs/structure.js +++ b/src/assets/docs/structure.js @@ -3,62 +3,116 @@ export default { title: "Docs", content: require("./index.md").default, children: [ + { + name: "http-server", + title: "HTTP-Server", + content: require("./orm/index.md").default, + children: [ + { + name: "getting-started", + title: "Getting Started", + content: require("./orm/getting-started.md").default + }, + { + name: "controller", + title: "Controller", + content: require("./orm/getting-started.md").default, + children: [ + { + name: "getting-started", + title: "Getting Started", + content: require("./orm/getting-started.md").default + }, + { + name: "annotations", + title: "Annotations", + content: require("./orm/getting-started.md").default, + children: [] + } + ] + }, + { + name: "web-sockets", + title: "Web-Sockets", + content: require("./orm/getting-started.md").default, + children: [ + { + name: "getting-started", + title: "Getting Started", + content: require("./orm/getting-started.md").default + } + ] + } + ] + }, + { + name: "web-framework", + title: "Web-Framework", + content: require("./orm/index.md").default, + children: [ + { + name: "getting-started", + title: "Getting Started", + content: require("./orm/getting-started.md").default + } + ] + }, { name: "orm", title: "ORM", content: require("./orm/index.md").default, children: [ { - "name": "getting-started", - "title": "Getting Started", - "content": require("./orm/getting-started.md").default + name: "getting-started", + title: "Getting Started", + content: require("./orm/getting-started.md").default }, { - "name": "query-dsl", - "title": "Query DSL", - "content": require("./orm/query-dsl.md").default, + name: "query-dsl", + title: "Query DSL", + content: require("./orm/query-dsl.md").default, children: [ { - "name": "getting-started", - "title": "Getting Started", - "content": require("./orm/getting-started.md").default + name: "getting-started", + title: "Getting Started", + content: require("./orm/getting-started.md").default } ] }, { - "name": "soft-deletes", - "title": "Soft-Deletes", - "content": require("./orm/soft-deletes.md").default + name: "soft-deletes", + title: "Soft-Deletes", + content: require("./orm/soft-deletes.md").default }, { - "name": "config", - "title": "ORMConfig", - "content": require("./orm/config.md").default + name: "config", + title: "ORMConfig", + content: require("./orm/config.md").default }, { - "name": "migrations", - "title": "Migrations", - "content": require("./orm/migrations.md").default + name: "migrations", + title: "Migrations", + content: require("./orm/migrations.md").default }, { - "name": "observer", - "title": "Observer", - "content": require("./orm/observer.md").default + name: "observer", + title: "Observer", + content: require("./orm/observer.md").default }, { - "name": "dates", - "title": "Auto-Dates", - "content": require("./orm/dates.md").default + name: "dates", + title: "Auto-Dates", + content: require("./orm/dates.md").default }, { - "name": "type-mapping", - "title": "Type Mapping", - "content": require("./orm/type-mapping.md").default + name: "type-mapping", + title: "Type Mapping", + content: require("./orm/type-mapping.md").default }, { - "name": "table-and-column-options", - "title": "Table and Column Options", - "content": require("./orm/table-and-column-options.md").default + name: "table-and-column-options", + title: "Table and Column Options", + content: require("./orm/table-and-column-options.md").default } ] } diff --git a/src/components/Navigation.vue b/src/components/Navigation.vue index d9bf638..a45e8d4 100644 --- a/src/components/Navigation.vue +++ b/src/components/Navigation.vue @@ -14,7 +14,7 @@
- +
From fa6c9151f49e248ecd4a30dfd59a5c4d8647e71d Mon Sep 17 00:00:00 2001 From: Julian Gojani Date: Sat, 7 Nov 2020 23:34:43 +0100 Subject: [PATCH 04/42] Create CNAME --- CNAME | 1 + 1 file changed, 1 insertion(+) create mode 100644 CNAME diff --git a/CNAME b/CNAME new file mode 100644 index 0000000..f534b47 --- /dev/null +++ b/CNAME @@ -0,0 +1 @@ +jws.gjni.eu \ No newline at end of file From b1d4e3bc8b15557248c4d2a72657fadbba0b0e35 Mon Sep 17 00:00:00 2001 From: Julian Gojani Date: Sun, 8 Nov 2020 00:20:46 +0100 Subject: [PATCH 05/42] Made the everything responsive --- CNAME | 1 - deploy.sh | 25 ------------- package.json | 1 - src/assets/docs/structure.js | 8 ++++- src/assets/scss/app.scss | 9 +++++ src/components/Footer.vue | 9 +++++ src/components/Navigation.vue | 35 +++++++++++++++++-- src/store/index.js | 5 ++- src/views/Doc.vue | 18 ++++++++-- src/views/Home.vue | 66 ++++++++++++++++++++++++++++++++--- 10 files changed, 138 insertions(+), 39 deletions(-) delete mode 100644 CNAME delete mode 100644 deploy.sh diff --git a/CNAME b/CNAME deleted file mode 100644 index f534b47..0000000 --- a/CNAME +++ /dev/null @@ -1 +0,0 @@ -jws.gjni.eu \ No newline at end of file diff --git a/deploy.sh b/deploy.sh deleted file mode 100644 index e31934d..0000000 --- a/deploy.sh +++ /dev/null @@ -1,25 +0,0 @@ -#!/usr/bin/env sh - -# abort on errors -set -e - -# build -npm run build - -# navigate into the build output directory -cd dist - -# if you are deploying to a custom domain -# echo 'www.example.com' > CNAME - -git init -git add -A -git commit -m 'deploy' - -# if you are deploying to https://.github.io -# git push -f git@github.com:/.github.io.git master - -# if you are deploying to https://.github.io/ -git push -f git@github.com:javawebstack/docs.git master:gh-pages - -cd - \ No newline at end of file diff --git a/package.json b/package.json index a344897..c551edc 100644 --- a/package.json +++ b/package.json @@ -27,7 +27,6 @@ "eslint": "^6.7.2", "eslint-plugin-vue": "^6.2.2", "file-loader": "^6.2.0", - "highlight.js": "^10.3.2", "markdown-it": "^12.0.2", "node-sass": "^4.14.1", "raw-loader": "^4.0.2", diff --git a/src/assets/docs/structure.js b/src/assets/docs/structure.js index ace9897..d631f58 100644 --- a/src/assets/docs/structure.js +++ b/src/assets/docs/structure.js @@ -27,7 +27,13 @@ export default { name: "annotations", title: "Annotations", content: require("./orm/getting-started.md").default, - children: [] + children: [ + { + name: "get", + title: "@Get", + content: require("./orm/getting-started.md").default + }, + ] } ] }, diff --git a/src/assets/scss/app.scss b/src/assets/scss/app.scss index 3961f52..a637940 100644 --- a/src/assets/scss/app.scss +++ b/src/assets/scss/app.scss @@ -67,4 +67,13 @@ html { color: #4a8edb; } } +} + + +@media screen and (max-width: 720px){ + #page { + &.docs { + margin-left: 0px; + } + } } \ No newline at end of file diff --git a/src/components/Footer.vue b/src/components/Footer.vue index b7ce79d..7524ce5 100644 --- a/src/components/Footer.vue +++ b/src/components/Footer.vue @@ -96,4 +96,13 @@ } } + + +@media screen and (max-width: 720px){ + #footer { + &.docs { + margin-left: 0px; + } + } +} \ No newline at end of file diff --git a/src/components/Navigation.vue b/src/components/Navigation.vue index a45e8d4..18e24ae 100644 --- a/src/components/Navigation.vue +++ b/src/components/Navigation.vue @@ -1,6 +1,10 @@